Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion flutter_frontend_server/lib/server.dart
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ class ToStringVisitor extends RecursiveVisitor<void> {
@override
void visitProcedure(Procedure node) {
if (
node.name.name == 'toString' &&
node.name.text == 'toString' &&
node.enclosingClass != null &&
node.enclosingLibrary != null &&
!node.isStatic &&
Expand Down
2 changes: 1 addition & 1 deletion flutter_frontend_server/test/to_string_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ void main(List<String> args) async {
final ReturnStatement replacement = verify(body.replaceWith(captureAny)).captured.single as ReturnStatement;
expect(replacement.expression, isA<SuperMethodInvocation>());
final SuperMethodInvocation superMethodInvocation = replacement.expression as SuperMethodInvocation;
expect(superMethodInvocation.name.name, 'toString');
expect(superMethodInvocation.name.text, 'toString');
}

test('ToStringVisitor replaces toString in specified libraries (dart:ui)', () {
Expand Down