Skip to content
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

Matlab disabled #38

Closed
vhda opened this issue Jun 20, 2014 · 17 comments
Closed

Matlab disabled #38

vhda opened this issue Jun 20, 2014 · 17 comments

Comments

@vhda
Copy link
Contributor

vhda commented Jun 20, 2014

Just to open this for discussion: why is matlab parser being disabled to overcome the mapping conflict with objective c?
Why not use --langmap or --language-force?

@masatake
Copy link
Member

Good question!

You are right. I disabled it temporary to pass tests; from the name of file(*.s) matlab parser is choose always in tests.
Even if there is no test related issue, it is nice that a proper parser is choose automatically.
I think ctags should have preprocessing stage for choosing proper parser; we can choose a parser from scores returned from the stage. The most of preprocessing stage may be language specific.
However, some can be generic; we can use modeline of editors as hit. See http://www.wireshark.org/tools/modelines.html.

determineInterpreter is good place to start. determineInterpreter is used only if a language parser cannot be choose from file suffix. It also should be used when conflicting is occured from the suffix rule.

@masatake
Copy link
Member

I started working on this area. See #39.

@masatake
Copy link
Member

Sorry, look at #41.
#41 introduces change incompatible with exuberant ctags.
Please, review it.

My colleague tells me 2-gram can be used for scoring.

@masatake
Copy link
Member

h of C++ conflicts that of ObjectiveC
cmd of DosBatch conflicts that of REXX

@vhda
Copy link
Contributor Author

vhda commented Jun 23, 2014

In the meanwhile, might I suggest that we reenable the Matlab parser and adjust the failing test cases such that they use the correct parser?
I don't it makes sense to disable functionality for testability purposes.

@masatake
Copy link
Member

With the modeline patches we can adjust the failing test cases such that they use the correct parser.
However, I would like to fix this issue completely with the 2gram aproach; we don't have serious deadline now.

Do YOU need matlab parser now?

@vhda
Copy link
Contributor Author

vhda commented Jun 23, 2014

I thought we were trying to coordinate our efforts with the SF maintainers.
I don't think they will love to see parsers disabled just to make test
units pass and may even take this effort not seriously because of that.

On Mon, Jun 23, 2014 at 1:23 PM, Masatake YAMATO notifications@github.com
wrote:

With the modeline patches we can adjust the failing test cases such that
they use the correct parser.
However, I would like to fix this issue completely with the 2gram aproach;
we don't have serious deadline now.

Do YOU need matlab parser now?


Reply to this email directly or view it on GitHub
#38 (comment).

@masatake
Copy link
Member

I think they will love to see that ctags chooses a proper parser automatically from input.
However, this is just my opinion.

Do you have any good patch?
What I have is very ugly and doesn't work with out modeline patches.

@vhda
Copy link
Contributor Author

vhda commented Jun 24, 2014

Please check pull request #46.

@masatake
Copy link
Member

2-gram engine shows good detections:)
After cleaning up the table generator, I will send pull request.

% ./ctags -o - Test/.m > /dev/null
./ctags -o - Test/
.m > /dev/null
about Test/matlab_backtracking.m winner: MatLab
about Test/matlab_backtracking.m winner: MatLab
about Test/matlab_test.m winner: MatLab
about Test/matlab_test.m winner: MatLab
about Test/objc.m winner: ObjectiveC
about Test/objc.m winner: ObjectiveC
about Test/objectivec_implementation.m winner: ObjectiveC
about Test/objectivec_implementation.m winner: ObjectiveC

@vhda
Copy link
Contributor Author

vhda commented Jun 26, 2014

That's great news :)
Keep it going!

@masatake
Copy link
Member

Could you try https://github.com/masatake/ctags/tree/tg?
Matlab parser is enabled.

@vhda
Copy link
Contributor Author

vhda commented Jul 1, 2014

Your work looks great, but I still did not have the time to run some tests. Please give me a day or two to do so.

@vhda
Copy link
Contributor Author

vhda commented Jul 6, 2014

Great work!
I don't have anything to add.

@masatake
Copy link
Member

masatake commented Jul 7, 2014

Thank you for testing.
I will start merging modeline branch first.

@vhda
Copy link
Contributor Author

vhda commented Jul 7, 2014

Excellent work Masatake!
I have much to learn from you :)

On Mon, Jul 7, 2014 at 11:42 AM, Masatake YAMATO notifications@github.com
wrote:

Thank you for testing.
I will start merging modeline branch first.


Reply to this email directly or view it on GitHub
#38 (comment).

@masatake
Copy link
Member

masatake commented Jul 7, 2014

tg branch is merged.

I have to add tg tables for

h of C++ conflicts that of ObjectiveC
cmd of DosBatch conflicts that of REXX

But these are rather unimportant task.

@masatake masatake closed this as completed Jul 7, 2014
masatake pushed a commit to masatake/ctags that referenced this issue Mar 12, 2020
masatake added a commit to masatake/ctags that referenced this issue May 27, 2022
6c2c21a52 Merge pull request universal-ctags#40 from masatake/masatake--lambertlulala-fix/limitation_of_ftell_and_fseek
a222fcf22 pass 0 instead of 0L to fseek() as the beginning of a file stream
4c2f6b2bc update NEWS.md
195173214 Add _WIN32 preprocessor to use _ftelli64 and _fseeki64
167834bd2 Merge pull request universal-ctags#39 from masatake/add-error-const-for-too-large-tags
096152e47 style: delete a redundant usage of 'else' keyword
6dca8a888 Introduce a new error constant TagErrnoFileMaybeTooBig
31e93940d GitHub Actions: show the test log in failure
0f6a0c281 cosmetic: clean up whitespaces
4a6bca8f6 Merge pull request universal-ctags#38 from universal-ctags/masatake-patch-1
e2a4a43c2 GitHub Actions: run test cases on msys2 and mingw
32f4a95eb Merge pull request universal-ctags#35 from masatake/fix-comment
c5182322f comments: fix a typo

git-subtree-dir: libreadtags
git-subtree-split: 6c2c21a52ab5902f0f579b0537fabdd4d9f74e45
masatake added a commit to masatake/ctags that referenced this issue May 31, 2022
3f5fba867 Merge pull request universal-ctags#42 from masatake/revise-test-case
a05721ba2 tests: report failure if TagErrnoFileMaybeTooBig is set
6c2c21a52 Merge pull request universal-ctags#40 from masatake/masatake--lambertlulala-fix/limitation_of_ftell_and_fseek
a222fcf22 pass 0 instead of 0L to fseek() as the beginning of a file stream
4c2f6b2bc update NEWS.md
195173214 Add _WIN32 preprocessor to use _ftelli64 and _fseeki64
167834bd2 Merge pull request universal-ctags#39 from masatake/add-error-const-for-too-large-tags
096152e47 style: delete a redundant usage of 'else' keyword
6dca8a888 Introduce a new error constant TagErrnoFileMaybeTooBig
31e93940d GitHub Actions: show the test log in failure
0f6a0c281 cosmetic: clean up whitespaces
4a6bca8f6 Merge pull request universal-ctags#38 from universal-ctags/masatake-patch-1
e2a4a43c2 GitHub Actions: run test cases on msys2 and mingw
32f4a95eb Merge pull request universal-ctags#35 from masatake/fix-comment
c5182322f comments: fix a typo

git-subtree-dir: libreadtags
git-subtree-split: 3f5fba867cc2c6a5654ab8c80775c060fa93b633
masatake added a commit to masatake/ctags that referenced this issue Jun 1, 2022
3f5fba867 Merge pull request universal-ctags#42 from masatake/revise-test-case
a05721ba2 tests: report failure if TagErrnoFileMaybeTooBig is set
6c2c21a52 Merge pull request universal-ctags#40 from masatake/masatake--lambertlulala-fix/limitation_of_ftell_and_fseek
a222fcf22 pass 0 instead of 0L to fseek() as the beginning of a file stream
4c2f6b2bc update NEWS.md
195173214 Add _WIN32 preprocessor to use _ftelli64 and _fseeki64
167834bd2 Merge pull request universal-ctags#39 from masatake/add-error-const-for-too-large-tags
096152e47 style: delete a redundant usage of 'else' keyword
6dca8a888 Introduce a new error constant TagErrnoFileMaybeTooBig
31e93940d GitHub Actions: show the test log in failure
0f6a0c281 cosmetic: clean up whitespaces
4a6bca8f6 Merge pull request universal-ctags#38 from universal-ctags/masatake-patch-1
e2a4a43c2 GitHub Actions: run test cases on msys2 and mingw
32f4a95eb Merge pull request universal-ctags#35 from masatake/fix-comment
c5182322f comments: fix a typo

git-subtree-dir: libreadtags
git-subtree-split: 3f5fba867cc2c6a5654ab8c80775c060fa93b633
masatake added a commit to masatake/ctags that referenced this issue Jun 1, 2022
3f5fba867 Merge pull request universal-ctags#42 from masatake/revise-test-case
a05721ba2 tests: report failure if TagErrnoFileMaybeTooBig is set
6c2c21a52 Merge pull request universal-ctags#40 from masatake/masatake--lambertlulala-fix/limitation_of_ftell_and_fseek
a222fcf22 pass 0 instead of 0L to fseek() as the beginning of a file stream
4c2f6b2bc update NEWS.md
195173214 Add _WIN32 preprocessor to use _ftelli64 and _fseeki64
167834bd2 Merge pull request universal-ctags#39 from masatake/add-error-const-for-too-large-tags
096152e47 style: delete a redundant usage of 'else' keyword
6dca8a888 Introduce a new error constant TagErrnoFileMaybeTooBig
31e93940d GitHub Actions: show the test log in failure
0f6a0c281 cosmetic: clean up whitespaces
4a6bca8f6 Merge pull request universal-ctags#38 from universal-ctags/masatake-patch-1
e2a4a43c2 GitHub Actions: run test cases on msys2 and mingw
32f4a95eb Merge pull request universal-ctags#35 from masatake/fix-comment
c5182322f comments: fix a typo

git-subtree-dir: libreadtags
git-subtree-split: 3f5fba867cc2c6a5654ab8c80775c060fa93b633
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants