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

Typechecker crashes when importing a module annotated with @ignoreCompiler{} #2161

Open
PieterOlivier opened this issue Feb 27, 2025 · 0 comments

Comments

@PieterOlivier
Copy link
Contributor

Describe the bug

When importing a module that has a @ignoreCompiler annotation, the typechecker will crash with a
"Rascal check crashed unexpectedly with: NoSuchKey" error.

To Reproduce
Create the following modules:

module ignored::RegularModule

import ignored::IgnoredModule;

and

@ignoreCompiler{Test ignored module}
module ignored::IgnoredModule

Now trigger a typecheck by saving the second module. The typechecker will crash with a "Rascal check crashed unexpectedly with: NoSuchKey" error.

Expected behavior
A warning or error message that typechecking encountered a module that is ignored.

Screenshots
Image

Stack traces
Exception thrown:

|lib://rascal-core/lang/rascalcore/check/Import.rsc|:328,84: NoSuchKey("ignored::IgnoredModule")

Stacktrace:

	at prepareForCompilation(|lib://rascal-core/lang/rascalcore/check/Import.rsc|(14132,47,<328,67>,<328,114>))
	at rascalTModelForLocs(|lib://rascal-core/lang/rascalcore/check/Checker.rsc|(13495,77,<314,38>,<314,115>))
	at check(|lib://rascal-core/lang/rascalcore/check/Checker.rsc|(22262,64,<547,9>,<547,73>))
	at $shell$(|main://$shell$|)

Version info
rascal version 0.41.0-RC13
rascal-core version 0.12.16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant