Just trying to tame a new machine (W10 OS).
Installed Eclipse Oxygen (previous machine was Neon).
JS files have some curious-spurious errors flagged
All of these say helpful things like "No suggestions available". I also observe that they involve slightly "sophisticated" ES5/6 code. None of them involves any kind of error.
Naturally the first thing I did was to go Windows --> Prefs --> Javascript and see if I could turn off error-flagging. There isn't much there, but I turned off EVERYTHING which could be turned off.
Closed down Eclipse and opened again: still there. Reboot: still there. Annoyance: still there.
PS changing from
await thisQueue.drain() === undefined? throwError( 'broken promise', false ) : 0;
to
const drainResult = thisQueue.drain();
drainResult === undefined? throwError( 'broken promise', false ) : 0;
... gets rid of the marking on that one (there is no error in the one-liner). This suggests to me that the "language definition" being used by whatever is validating this code is out-of-date. Anyone know what I should do?
PPS this is a pretty fresh install... looking at relevant installed "Marketplace" add-ons I had Eclipse Web Developer Tools 3.9.1a, HTML Editor (WTP). I tried updating these (failed), then tried uninstalling these (parts remain, Eclipse tells you it can't do without bits of them).
Spurious errors still there. Grrrr. It's funny how there doesn't appear a way in Eclipse to choose the version of JS you want to work with, as with Python, Java, etc. Mysteries mysteries.
Managed to turn these off by turning everything from "warning" to "ignore" for the "project specific settings":
Update 2019-10-25, Eclipse 2019-06
No longer appears to work.
Nor does going Window --> Prefs --> Validation --> validator "JavaScript Validation" --> uncheck both boxes.
Nor does an all-projects approach, doing this:
- Window --> Prefs --> JavaScript --> Include Path --> Default exclusion patterns --> Patterns: add this pattern: "**/*.js"
- Apply and Close
The only way I find is on a per-project basis:
- Project --> Properties --> JavaScript --> Include Path --> highlight "Excluded..."
- click Edit
- right of the "Exclusions patterns" box click Add
- add "**/*.js"
- click Finish, Apply and Close
- finally the irksome nonsense has gone