Skip to content

Commit

Permalink
Fix new analysis warnings from Dart 3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
simolus3 committed Feb 19, 2024
1 parent d7a26a6 commit 4fa75cb
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -636,7 +636,7 @@ class _SubqueryExpression<R extends Object> extends Expression<R> {
int get hashCode => statement.hashCode;

@override
bool operator ==(Object? other) {
bool operator ==(Object other) {
return other is _SubqueryExpression && other.statement == statement;
}
}
6 changes: 3 additions & 3 deletions sqlparser/lib/src/analysis/types/data.dart
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class ResolvedType {
}

@override
bool operator ==(dynamic other) {
bool operator ==(Object other) {
return identical(this, other) ||
other is ResolvedType &&
other.type == type &&
Expand Down Expand Up @@ -112,7 +112,7 @@ abstract class TypeHint {
@override
int get hashCode => runtimeType.hashCode;
@override
bool operator ==(dynamic other) => other.runtimeType == runtimeType;
bool operator ==(Object other) => other.runtimeType == runtimeType;
}

/// Type hint to mark that this type will contain a boolean value.
Expand Down Expand Up @@ -181,7 +181,7 @@ class ResolveResult {
}

@override
bool operator ==(dynamic other) {
bool operator ==(Object other) {
return identical(this, other) ||
other is ResolveResult &&
other.type == type &&
Expand Down
4 changes: 2 additions & 2 deletions sqlparser/lib/src/ast/drift/declared_statement.dart
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class SimpleName extends DeclaredStatementIdentifier {
int get hashCode => name.hashCode;

@override
bool operator ==(dynamic other) {
bool operator ==(Object other) {
return identical(this, other) ||
(other is SimpleName && other.name == name);
}
Expand All @@ -87,7 +87,7 @@ class SpecialStatementIdentifier extends DeclaredStatementIdentifier {
String get name => specialName;

@override
bool operator ==(dynamic other) {
bool operator ==(Object other) {
return identical(this, other) ||
(other is SpecialStatementIdentifier &&
other.specialName == specialName);
Expand Down
2 changes: 1 addition & 1 deletion sqlparser/lib/src/ast/expressions/aggregate.dart
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ class FrameBoundary {
}

@override
bool operator ==(dynamic other) {
bool operator ==(Object other) {
if (identical(this, other)) return true;
if (other.runtimeType != runtimeType) return false;

Expand Down
2 changes: 1 addition & 1 deletion sqlparser/lib/src/ast/statements/create_trigger.dart
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ abstract class TriggerTarget extends AstNode {
int get hashCode => runtimeType.hashCode;

@override
bool operator ==(dynamic other) => other.runtimeType == runtimeType;
bool operator ==(Object other) => other.runtimeType == runtimeType;

@override
Iterable<AstNode> get childNodes => const Iterable.empty();
Expand Down
2 changes: 1 addition & 1 deletion sqlparser/lib/utils/find_referenced_tables.dart
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class TableWrite {
int get hashCode => 37 * table.hashCode + kind.hashCode;

@override
bool operator ==(dynamic other) {
bool operator ==(Object other) {
return other is TableWrite && other.table == table && other.kind == kind;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import '../utils.dart';
void main() {
test('parses WITH clauses', () {
testStatement(
'''
'''
WITH RECURSIVE
cnt(x) AS (
SELECT 1
Expand Down

0 comments on commit 4fa75cb

Please sign in to comment.