-
Notifications
You must be signed in to change notification settings - Fork 628
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
Added new parser for Inko #2094
Conversation
@masatake What do you think of these changes? Should I take a different approach for adding the parser, or is this how they are supposed to be added? |
Please, add following two items to the header of inko.ctags: |
@masatake Oops! I initially had the copyright in place, but must have accidentally removed it before committing my changes. I added it, along with a summary plus link similar to the systemtap parser. |
If you add a new parser specific field, you must update the expected output of some test cases. |
https://docs.ctags.io is not updated. See #2093 . |
Other than some minor issues, it looks good for me. |
This adds a new ctags parser that can parse Inko (https://inko-lang.org/) source code.
What exactly needs to be updated? I didn't see any references there for systemtap, so I'm not sure what to use as a reference. |
Sorry, no update is needed. It is just information. |
Can a real Inko processor accept your test cases as valid inputs? Don't you want full qualified tag? Running ctags with --verbose option, you can see statistics about which regex patterns in tables are matched (and not matched) frequently. You can use it for optimization. You can work on the above items after merging :-) |
A trait can only be implemented once for an object, so I don't think this would be necessary.
Inko does not provide a way of just syntax checking a file at the moment, but all existing input examples are valid syntax.
I personally haven't really had a use for it so far, and only
I tested it with a file that contains 24815 lines. This file takes about 1.2 seconds to process, which seems pretty reasonable to me given the size. |
Is the software having 24815 available as an open source software? |
(I started writing this comment to make a question to you. However, during writing I got an answer by myself. The answer I got is important for improving Rust parser. So I put what I wrote here as notes for myself. )
I'm comapring Inko and Rust. Consistency between languages are not the most important things in ctags. If we introduce "implements" field to Inko, I would like to use it in Rust. It looks for me that the two languages have similar grammars. A. SomeObject implements SomeTrait. Which sentence is correct? |
Thank you. |
It's just the same content repeated over and over and over again, not actual software you'd find anywhere. It's as follows: big.inko.txt Thanks for merging! |
I see. |
This adds a new ctags parser that can parse Inko
(https://inko-lang.org/) source code.
I based this on the commit that added the systemtap parser (6bc1a8a#diff-3dd5375cb7338d3815ab63cd09ddff93), as the documentation about adding a parser (http://docs.ctags.io/en/latest/optlib.html?highlight=optlib#submitting-an-optlib-file-to-the-universal-ctags-project) appears to be a bit out of date (e.g. the PRELOAD variables appear to not be used).