mirror of
https://github.com/dart-lang/sdk
synced 2024-09-15 22:00:09 +00:00
Fix IMPORT_INTERNAL_LIBRARY error location
Fixes #31682 Bug: https://github.com/dart-lang/sdk/issues/31682 Change-Id: Id4f52006aa7ca3e5fb0ecce61c0393310f18764f Reviewed-on: https://dart-review.googlesource.com/30260 Commit-Queue: Samuel Rawlins <srawlins@google.com> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
This commit is contained in:
parent
76f30b99f5
commit
3bc3ab979e
|
@ -4225,8 +4225,8 @@ class ErrorVerifier extends RecursiveAstVisitor<Object> {
|
|||
|
||||
_errorReporter.reportErrorForNode(
|
||||
CompileTimeErrorCode.IMPORT_INTERNAL_LIBRARY,
|
||||
directive,
|
||||
[directive.uri]);
|
||||
directive.uri,
|
||||
[directive.uri.stringValue]);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -2135,7 +2135,7 @@ main() {
|
|||
// TODO(jmesserly): we should change how this inference works.
|
||||
// For now this test will cover what we use.
|
||||
await checkFileElement('''
|
||||
/*error:IMPORT_INTERNAL_LIBRARY*/import 'dart:_foreign_helper' show JS;
|
||||
import /*error:IMPORT_INTERNAL_LIBRARY*/'dart:_foreign_helper' show JS;
|
||||
main() {
|
||||
String x = /*error:INVALID_ASSIGNMENT*/JS('int', '42');
|
||||
var y = JS('String', '"hello"');
|
||||
|
|
|
@ -8,8 +8,7 @@ import 'dart:_foreign_helper';
|
|||
/// ignore: IMPORT_INTERNAL_LIBRARY
|
||||
import 'dart:_js_embedded_names';
|
||||
|
||||
/// ignore: IMPORT_INTERNAL_LIBRARY
|
||||
/// ignore: UNUSED_IMPORT
|
||||
/// ignore: IMPORT_INTERNAL_LIBRARY, UNUSED_IMPORT
|
||||
import 'dart:_interceptors';
|
||||
|
||||
/*element: main:[null]*/
|
||||
|
|
|
@ -8,8 +8,7 @@ import 'dart:_foreign_helper';
|
|||
/// ignore: IMPORT_INTERNAL_LIBRARY
|
||||
import 'dart:_js_embedded_names';
|
||||
|
||||
/// ignore: IMPORT_INTERNAL_LIBRARY
|
||||
/// ignore: UNUSED_IMPORT
|
||||
/// ignore: IMPORT_INTERNAL_LIBRARY, UNUSED_IMPORT
|
||||
import 'dart:_interceptors';
|
||||
|
||||
/*element: jsCallEmpty:SideEffects(reads nothing; writes nothing)*/
|
||||
|
|
Loading…
Reference in a new issue