You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Got a sentry report of the parser breaking on dmd/current/import/phobos/etc/c/curl.d:
com.intellij.diagnostic.PluginException: Failed to build index 'DModuleIndex' for file file:///snap/dmd/current/import/phobos/etc/c/curl.d (id = 20066) (file type = D file) [Plugin: net.masterthought.dlanguage]
This is from IntelliJ IDEA Ultimate Edition 2023.1.2 on Linux with plugin version 1.30.1:
java.lang.IllegalArgumentException: Could not find single match for token: 'identifier'. 0 matches found
at io.github.intellij.dlanguage.parser.DLangParser.tok(DLangParser.java:9465)
at io.github.intellij.dlanguage.parser.DLangParser.advance(DLangParser.java:9487)
at io.github.intellij.dlanguage.parser.DLangParser.parseEnumBody(DLangParser.java:3536)
at io.github.intellij.dlanguage.parser.DLangParser.parseEnumDeclaration(DLangParser.java:3687)
at io.github.intellij.dlanguage.parser.DLangParser.parseDeclaration(DLangParser.java:2966)
at io.github.intellij.dlanguage.parser.DLangParser.parseDeclaration(DLangParser.java:2807)
at io.github.intellij.dlanguage.parser.DLangParser.parseModule(DLangParser.java:5655)
at io.github.intellij.dlanguage.parser.ParserWrapper.parseLight(ParserWrapper.java:439)
at io.github.intellij.dlanguage.parser.ParserWrapper.parse(ParserWrapper.java:448)
It would be good to get some tests in place which run the parser against phobos. Potentially it could be an optional test that only runs if a property is set that point to the root of the systems dmd install. That way it would be easy to opt-in to running the test and easy to setup on Github Action once it's possible to run with failing
The text was updated successfully, but these errors were encountered:
IMHO we should change the parser logic to use the real token instead of using the dict we use (aka stop using tok()).
The problem is not related with phobos but just with the order of initialization of the map. This issue is not reproducible every times but it sometimes appear and sometimes not. I got it for some files in other project but just restarting the IDE allowed me to not have the issue after restart. It’s really inconsistent.
Potentially worth having another issue for any changes to the way in which the parser works. This issue is just for testing purposes. I think it would be worth aiming to get to a point in which the automated tests that run against a push/PR make sure that the parser is able to run against the phobos sources without problems. It's a large codebase that should continue to be valid D syntax so will make for a good test case.
Got a sentry report of the parser breaking on
dmd/current/import/phobos/etc/c/curl.d
:This is from IntelliJ IDEA Ultimate Edition 2023.1.2 on Linux with plugin version 1.30.1:
It would be good to get some tests in place which run the parser against phobos. Potentially it could be an optional test that only runs if a property is set that point to the root of the systems dmd install. That way it would be easy to opt-in to running the test and easy to setup on Github Action once it's possible to run with failing
The text was updated successfully, but these errors were encountered: