intellij-dlanguage / intellij-dlanguage

Intellij Plugin for the D Programming Language
MIT License
328 stars 51 forks source link

auto safe = 1 #79

Closed trikko closed 8 years ago

trikko commented 8 years ago
void test()
{
    auto safe = 1;
}

"declaration or storage class expected, got safe"

kingsleyh commented 8 years ago

That's weird - it's something to do with the word "safe"!

Hackerpilot commented 8 years ago

@safe is built in to the language, safe is a normal identifier.

Hackerpilot commented 8 years ago

Here's your problem: https://github.com/kingsleyh/DLanguage/blob/master/src/net/masterthought/dlanguage/grammar/DLanguage.bnf#L91

Several of those should not be keywords.

kingsleyh commented 8 years ago

ah good spot ! thanks !!!

kingsleyh commented 8 years ago

Hackerpilot: Be sure that you also remove "trusted", "system", and "disable"

kingsleyh commented 8 years ago

fixed and will be in next release