-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#2275. Add noSuchMethod
tests. Part 3
#2294
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very good! Just one addition would be useful: As far as I can see, we don't catch the case where a getter or setter is noSuchMethod forwarded, but no forwarder has been generated (and noSuchMethod
is just invoked directly). I believe we would be able to detect that there is a noSuchMethod forwarder by using wrong types and seeing that there is a dynamic type check (so we do get a exception).
Language/Classes/Instance_Methods/Method_noSuchMethod/forwarder_A01_t06.dart
Show resolved
Hide resolved
Language/Classes/Instance_Methods/Method_noSuchMethod/forwarder_A01_t07.dart
Show resolved
Hide resolved
Language/Classes/Instance_Methods/Method_noSuchMethod/invocation_A01_t01.dart
Show resolved
Hide resolved
Language/Classes/Instance_Methods/Method_noSuchMethod/invocation_A01_t01.dart
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated. Please take another look
Language/Classes/Instance_Methods/Method_noSuchMethod/forwarder_A01_t06.dart
Show resolved
Hide resolved
Language/Classes/Instance_Methods/Method_noSuchMethod/forwarder_A01_t07.dart
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking at the code again, I'm afraid the setter-causes-dynamic-error-so-we-do-have-a-forwarder test must put dynamic
in a different location, such that we don't get a successful test run for the wrong reasons.
Language/Classes/Instance_Methods/Method_noSuchMethod/forwarder_A01_t09.dart
Outdated
Show resolved
Hide resolved
Language/Classes/Instance_Methods/Method_noSuchMethod/forwarder_A01_t08.dart
Show resolved
Hide resolved
Makes sense! Updated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
2023-10-13 sgrekhov22@gmail.com Fixes dart-lang/co19#2310. Fix new roll failures (dart-lang/co19#2311) 2023-10-13 sgrekhov22@gmail.com Fixes dart-lang/co19#2306. Fix promoted instance type in not_promotable_A01_t04.dart (dart-lang/co19#2309) 2023-10-13 sgrekhov22@gmail.com Fixes dart-lang/co19#2307. Don't expect private fields promotion on static fields (dart-lang/co19#2308) 2023-10-11 sgrekhov22@gmail.com dart-lang/co19#2291. Update `Link.create()` tests according to the documentation (dart-lang/co19#2299) 2023-10-11 sgrekhov22@gmail.com dart-lang/co19#2275. Add `noSuchMethod` tests. Part 3 (dart-lang/co19#2294) 2023-10-10 sgrekhov22@gmail.com dart-lang/co19#2275. Add `noSuchMethod` tests. Part 4 (dynamic semantics) (dart-lang/co19#2296) 2023-10-10 sgrekhov22@gmail.com dart-lang/co19#2291. Update `Link.create()` according to the documentation. Part 2 (dart-lang/co19#2301) 2023-10-10 sgrekhov22@gmail.com Fixes dart-lang/co19#2268. Fix LibTest/io/WebSocket/closeCode_A01_t02.dart to be not racy (dart-lang/co19#2302) 2023-10-09 sgrekhov22@gmail.com dart-lang/co19#1400. Add more tests for private fields promotion of extension types (dart-lang/co19#2300) Change-Id: Ib34f392c8a2a0aaab8b7b0cb028f918ab2a3249f Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/330460 Commit-Queue: Alexander Thomas <athom@google.com> Reviewed-by: Erik Ernst <eernst@google.com> Reviewed-by: Alexander Thomas <athom@google.com>
No description provided.