Skip to content
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

co19/LanguageFeatures/Parts-with-imports/grammar_A05_t01 #2925

Closed
scheglov opened this issue Oct 8, 2024 · 3 comments
Closed

co19/LanguageFeatures/Parts-with-imports/grammar_A05_t01 #2925

scheglov opened this issue Oct 8, 2024 · 3 comments
Assignees
Labels
bad-test Report tests in need of updates. When closed, the tests should be considered good

Comments

@scheglov
Copy link

scheglov commented Oct 8, 2024

FAILED: dart2analyzer-none release_arm64 co19/LanguageFeatures/Parts-with-imports/grammar_A05_t01
Expected: Pass
Actual: MissingCompileTimeError

--- Command "dart2analyzer" (took 62ms):
DART_CONFIGURATION=ReleaseARM64 sdk/bin/dart --packages=.dart_tool/package_config.json pkg/analyzer_cli/bin/analyzer.dart --use-analysis-driver-memory-byte-store --dart-sdk=/Users/scheglov/Source/Dart/sdk.git/sdk/sdk -Dtest_runner.configuration=custom-configuration-1 --enable-experiment=macros --ignore-unrecognized-flags --packages=/Users/scheglov/Source/Dart/sdk.git/sdk/.dart_tool/package_config.json --format=json /Users/scheglov/Source/Dart/sdk.git/sdk/tests/co19/src/LanguageFeatures/Parts-with-imports/grammar_A05_t01.dart

static error failures:
- Missing expected unspecified error at tests/co19/src/LanguageFeatures/Parts-with-imports/grammar_A05_t01_lib.dart line 32, column 5, length 4.

--- Re-run this test:
python3 tools/test.py -m release -c dart2analyzer -a arm64 co19/LanguageFeatures/Parts-with-imports/grammar_A05_t01

LanguageFeatures/Parts-with-imports/grammar_A05_t01_lib.dart has

library;

/**/part of 'grammar_A05_t01.dart';
//  ^^^^
// [analyzer] unspecified
// [cfe] unspecified

Because it has library; it is not recognized by Parts-with-imports/grammar_A05_t01.dart as a part, and so is not analyzed, so no errors it it. But we do report an error in Parts-with-imports/grammar_A05_t01.dart.

@sgrekhov sgrekhov self-assigned this Oct 9, 2024
@eernstg
Copy link
Member

eernstg commented Oct 9, 2024

And it isn't even reported that LanguageFeatures/Parts-with-imports/grammar_A05_t01_lib.dart has a syntax error?

@sgrekhov sgrekhov added bad-test Report tests in need of updates. When closed, the tests should be considered good type-question A question about expected behavior or functionality labels Oct 9, 2024
@scheglov
Copy link
Author

scheglov commented Oct 9, 2024

We analyze Parts-with-imports/grammar_A05_t01.dart, which attempts to include grammar_A05_t01_lib.dart as a part. But because it has library; it is not considered to be a valid part, and skipped. So, it is not analyzed by the test.

In DAS it would be analyzed as a library on its own, and get an error reported.

@sgrekhov sgrekhov removed the type-question A question about expected behavior or functionality label Oct 10, 2024
sgrekhov added a commit to sgrekhov/co19 that referenced this issue Oct 10, 2024
@eernstg
Copy link
Member

eernstg commented Oct 10, 2024

OK, thanks!

sgrekhov added a commit to sgrekhov/co19 that referenced this issue Oct 10, 2024
eernstg pushed a commit that referenced this issue Oct 10, 2024
copybara-service bot pushed a commit to dart-lang/sdk that referenced this issue Oct 11, 2024
2024-10-10 sgrekhov22@gmail.com dart-lang/co19#2925. Add comment explaining why the syntax error is not reported in grammar_A05_t01_lib.dart (dart-lang/co19#2931)
2024-10-10 sgrekhov22@gmail.com Fixes dart-lang/co19#2925. Fix expected errors positions in grammar_A05_t01_lib.dart (dart-lang/co19#2929)
2024-10-09 sgrekhov22@gmail.com dart-lang/co19#2923. More tests for import and export library with the same URI. (dart-lang/co19#2928)
2024-10-09 sgrekhov22@gmail.com Fixes dart-lang/co19#2926. Remove unnecessary error expectation from grammar_A04_t01.dart (dart-lang/co19#2927)
2024-10-08 sgrekhov22@gmail.com dart-lang/co19#2923. Add tests for import/exports with the same URI (dart-lang/co19#2924)
2024-10-07 sgrekhov22@gmail.com dart-lang/co19#2825. Fix dotted.library.name syntax in `part of` directive (dart-lang/co19#2922)
2024-10-04 sgrekhov22@gmail.com dart-lang/co19#2559. Add augmenting enum values test. (dart-lang/co19#2921)

Cq-Include-Trybots: luci.dart.try:analyzer-linux-release-try
Change-Id: I81902e4e4eac8a0b0ffd3f20d957aa9bfcc2cdc5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/389700
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bad-test Report tests in need of updates. When closed, the tests should be considered good
Projects
None yet
Development

No branches or pull requests

3 participants