[Github-comments] [geany] Rewrite scope completion 3 (#862)

Jiří Techet notifications at xxxxx
Sun Jan 17 15:57:04 UTC 2016


So I found one more problem: we now substitute the anon_* names in the sidebar with the corresponding typedef name if it's something like typedef struct {} Foo; The problem is that the sorting in the tree is still done according to the anon_* name instead of the typedef name. I started working on making it based on the typedef name but things started getting ugly - e.g. in compare_symbol_lines() each of the scope components will have to be checked whether it's anon or not and substituted with the typedef name and the typedef_table has to be passed to many functions. Now I'm not sure if these complications are worth it - it was supposed to be a simple patch which doesn't complicate things too much.

There are several options what to do:

1. Ignore the incorrect sorting and leave it as it is.
2. Remove the anon_* renaming patches completely.
3. Use the anon_* renaming only when sorting by line number (should be fine for any reasonable source).
4. Implement the fix (despite making things more complicated).

Right now I'm leaning towards either (2) or (3). What do you think?

---
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/862#issuecomment-172344085
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20160117/f3701568/attachment.html>


More information about the Github-comments mailing list