Skip to content

ScalaSettings withAbbreviation not accepted #10845

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

Closed
bishabosha opened this issue Dec 17, 2020 · 2 comments
Closed

ScalaSettings withAbbreviation not accepted #10845

bishabosha opened this issue Dec 17, 2020 · 2 comments

Comments

@bishabosha
Copy link
Member

bishabosha commented Dec 17, 2020

Minimized code

in this line we can see that the -Xsemanticdb setting has an abbreviation -Ysemanticdb:

https://github.com/lampepfl/dotty/blob/bfb0b8194a3e96d08abf8d96f3cba8d701febc3e/compiler/src/dotty/tools/dotc/config/ScalaSettings.scala#L138

However invoking the compiler with -Ysemanticdb warns that is is an invalid flag and the setting is not active.

Output

$>scalac -Ysemanticdb
bad option '-Ysemanticdb' was ignored
Usage: scalac <options> <source files>
...

Expectation

passing -Ysemanticdb should act like -Xsemanticdb

linked to #10844, but is more general than that, e.g. -classpath has an abbreviation -cp that is also not accepted

@bishabosha bishabosha changed the title ScalaSettings abbreviations don't seem to work ScalaSettings withAbbreviation not accepted Dec 17, 2020
@som-snytt
Copy link
Contributor

#10810 has a smaller issue number.

@bishabosha
Copy link
Member Author

Thanks for noticing

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

2 participants