VM does not yields compile error for uncqualified function invocation of undeclared identifier #7025
Labels
area-language
Dart language related items (some items might be better tracked at github.com/dart-lang/language).
This issue was originally filed by alexe.kaigorodov@gmail.com
Consider following test:
main() {
undeclared();
}
According to the spec v0.13:
12.14.3 Unqualified Invocation
"Otherwise, i is equivalent to this.id(a1, …, an, xn+1: an+1, …, xn+k: an+k). "
12.10 This
"It is a compile-time error if this appears in a top-level function or variable initializer, in a factory constructor, or in a static method or variable initializer, or in the initializer of an instance variable. "
the test should not comile. But VM compiles it (and throws NoSuchMethodError)
See also dart issue #6838 and co19 issue #332.
Affected tests:
Language/11_Expressions/14_Function_Invocation/3_Unqualified_Invocation_A01_t10.dart
The text was updated successfully, but these errors were encountered: