-
Notifications
You must be signed in to change notification settings - Fork 23
Description
The discussion has continued from JunoLab/Atom.jl#192 (comment).
In short, we now have 3 alternatives to detect a file's module:
- old way based on CodeTools: https://github.com/JunoLab/Atom.jl/blob/9cf10173e4c5727451e43950872d6cdb3795c720/src/eval.jl#L13-L39
- Revise-like approach: https://github.com/JunoLab/Atom.jl/blob/9cf10173e4c5727451e43950872d6cdb3795c720/src/utils.jl#L175-L359
- CSTParser-based approach: https://github.com/JunoLab/Atom.jl/blob/9cf10173e4c5727451e43950872d6cdb3795c720/src/goto.jl#L185-L205
1 is being used for module
handler, 2 and 3 are being used for the recent goto
(and renamerefactor
, in the future) handler.
The main purpose of this refactor is to implement a more robust module detection logic in the module
handler by replacing 1. with something like a combination of 2. and 3.
Or at least, since 1. and 3. are kinda duplicated works, so we want to unify the logic. (and this will hopefully leads to less JIT compiles)
We may need to significantly refactor the frontend code as well -- it's old too.
@pfitzseb can you bundle the related issues here (link to an issue report if exists or just list the random confirmed cases), so that we can easily check if we could address them by this refactor ?
P.S. Feel free to edit this issue for the future reference. We want more structured information for this.