intel / intel/dml-language-server

Spurious internal errors when on ambiguous overridden methods

Open
#220 0 comments 0 reactions 1 assignee Claimed by @JonatanWaern View on GitHub
bug Medium Priority
Dominant language
Rust
Stars
9
Forks
9
PR merge metrics
No merged PRs in 30d

Description

In cases like

```
template a {
method foo default { ... }
}

is a;

#if (some_constant) {
method foo() {
local int bar = 5;
do_stuff(bar);
}
} #else {
method foo() {
...
}
}
```

DLS does not know which method should be the actual final override, and picks one arbitrarily. This will result in an internal error when resolving the reference from 'bar' if the second definition of foo is picked. Will be automatically solved once #13 is resolved properly

In practice I have never found a case where this also results in a goto-ref/def/decl/etc fails, but in theory that could happen so a future workaround might be neccessary.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.