Closed michaelw85 closed 7 years ago
Support require().func statements This was already fixed on master, fyi.
I know but after merging master into my branch it did not work for the test files so I had to add some logic.
test7.js cannot go to definition on moduleA
get a console error
Cannot read property 'range' of undefined: TypeError: Cannot read property 'range' of undefined at from (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:23:273133) at Array.map (native) at /Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:23:350159 at Object.m [as _notify] (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:23:41973) at Object.enter (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:23:45538) at n.Class.derive._oncancel._run (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:23:47366) at n.Class.derive._oncancel._completed (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:23:46807) at process._tickCallback (internal/process/next_tick.js:103:7) e.onUnexpectedError @ /Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/electron-browser/workbench.main.js:29
Will test and review again soon.
See my new comments. Also, console error still there Cannot read property 'range' of undefined: TypeError:
Pushed new changes resolving test 10.
Still does not work properly for a realistic module file.
I have developed the alternative solution, please check it. I suggest you allocate your resources for writing tests (after fixing current tests) for the new features. Please write your opinion on this.
I'm closing this pr as it has become too complicated for a simple solution. If you feel comfortable with your changes you can send a new one. Fixing and writing tests for the latest changes is appreciated instead.
Updated version of pull request created before to support multiple require statements. Added lots of unit tests + improved functionality.
Manually tested every test file, passed every manual test I did.