-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
idetools in server mode seems to collapses column information #449
Comments
This is partly by design. Since the server will build a complete index of the contents of all files for fast querying, it tries to optimise its memory usage by remembering only the end positions of the significant identifiers in the code. It is assumed that a smart IDE can provide the remaining intelligence by filtering invalid actions from the user (i.e. the IDE can check whether the cursor is over an identifier). |
Aww... is memory really that tight? I've copied Aporia's main import lines to create an enviroment which uses a lot of source files and using the server mode on it makes the nimrod process reach 112MB of total virtual memory used, which doesn't even register among running processes on my machine until I search for it. Maybe more information could be squeezed through bit packing? With a presumed 32bit value 8 bits could be used for starting column, 6 bits for length of the keyword and 18 bits for line number, which would allow files of 262144 lines, starting column up to 256 and length of 64 characters (these could be tweaked). And then, using two 32bit values, one for line and one for starting column + length just gets rid of any practical limit. But even if the previous 112MB figure was twice as big I'd argue the benefits far outweight the memory consumption, the server mode idetools is meant to run on developer machines for edition, and it's hard to find so constrained configurations where it wouldn't run (if the figure above is right), especially now that mobile phones can handle such memory loads. |
449: sem: overload resolution ast corruption fixes r=saem a=saem ## Summary - signature matching no longer corrupts symbol table ## Details core changes: - matchesAux and friends in sigmatch no longer merge broken symbols - this means defensive ast copies during overload resolution - procs are also more nkError aware and will short circuit - lookups no longer puts error symbols in the top level - this was a hack to stop "cascading errors" - mildly better error message for ident lookups resolving to errors - required fixes in semLetOrVar and semConst: - const/let/var symbol definition tracks errors better - consolidated top level semLetOrVar and semConst miscellaneous: - due to nkError branch changes (`kids`), fixes were required in astrepr - renamed old error proc `defaultConstructionError2`, dropped the `2` - `semParamList` now returns a `PType` instead of unnecessarily mutating Co-authored-by: Saem Ghani <saemghani+github@gmail.com>
Using the wonderful hyperlink on small files would produce similar output for both normal process invokation and idetools continuous server queries. The server version seems to collapse column information, meaning that the first non useful idetools characters seem to inherit the idetools information from the first found entry on the line. Sometimes it uses information from other lines too. This doesn't seem to be a caching problem, as the effect can be seen even for the first character which should return no idetools information.
It's somehow difficult to explain, so just compare http://dl.dropboxusercontent.com/u/145894/t/files.proc.th.html to the http://dl.dropboxusercontent.com/u/145894/t/files.server.th.html version and watch the highlighted grey areas in the server version.
The text was updated successfully, but these errors were encountered: