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

Asciidoc: new parser #1838

Merged
merged 6 commits into from Aug 21, 2018

Conversation

Projects
None yet
5 participants
@hadrielk
Copy link
Contributor

hadrielk commented Aug 20, 2018

This ports the Asciidoc parser from geany, fixes a bug in it, and adds tagging of anchors. (other than anchors inline in one-line titles)

@coveralls

This comment has been minimized.

Copy link

coveralls commented Aug 20, 2018

Coverage Status

Coverage increased (+0.03%) to 84.444% when pulling 734f411 on hadrielk:parser-asciidoc into 2258b24 on universal-ctags:master.

@masatake

This comment has been minimized.

Copy link
Member

masatake commented Aug 20, 2018

I didn't do this because the version of GPL of the orignal code is not written explictly.
@b4n, should we contact to the orignal author?

@b4n

This comment has been minimized.

Copy link
Member

b4n commented Aug 20, 2018

@masatake yeah probably, not sure what is legal when there's no version specified.
Anyway, fortunately he's easy to reach and likely not to care too much… @elextr ? :)

@b4n

This comment has been minimized.

Copy link
Member

b4n commented Aug 20, 2018

@masatake However, as the PR doesn't change the licensing header, I'd think it just makes this file whichever version, doesn't it? Or is it a problem because v3 is incompatible with v1 in a way that cannot be mixed in an executable?

@elextr

This comment has been minimized.

Copy link
Contributor

elextr commented Aug 20, 2018

Well, as the comment at the top says, I copied most of it from the rest parser, including the license section. As that was explicitly included in Geany by the original copyright holder that would make it GPL v2+ in the absence of any other version info.

[Edited, oops accidentally commented too early]

@masatake

This comment has been minimized.

Copy link
Member

masatake commented Aug 20, 2018

@elextr, thank you.
Each source file of Exuberant-ctags didn't show the actual version of GPL. However, COPYING file at the top leve of the source tree is Version 2. So we updated the header of each source files derived from Exuberant-ctags like:

/*
*   Copyright (c) 1996-2003, Darren Hiebert
*
*   This source code is released for free distribution under the terms of the
*   GNU General Public License version 2 or (at your option) any later version.
*
*   This module contains functions for parsing and scanning C, C++, C#, D and Java
*   source files.
*/

As that was explicitly included in Geany that would make it GPL v2+.

It seems that the siltation is similar to old Universal-ctags.
The COPYING file at the top of source tree shows the actual version of GPL.
We I think we can expect we can use the Ascii parser in GPL v2.

However, the asciidoc parser submitted here leaves the original Geany source tree when this
pull request is merge. So it is not obvious that the relation between the source code and Geany's COPYING file. Updating the original header at Geany's side is ideal for me.

@elextr

This comment has been minimized.

Copy link
Contributor

elextr commented Aug 20, 2018

Actually Geany itself is licensed GPL V2 but most of the source has the usual "V2 or later" text.

Each source file of Exuberant-ctags didn't show the actual version of GPL.

Given that Nick (the copyright holder of the rest parser I copied and modified) committed the rest parser to Geany himself back in 2007, he was just copying the then standard Exuberant-ctags approach and clearly intended the Geany license (GPL v2) to cover it. And GPL V2 states "...If the Program does not specify a version number of this License, you may choose any version...".

As the file is being removed from Geany @masatake is right this PR just needs to make the version explicit as above, and also add

Copyright (c) 2007-2011, Nick Treleaven

to cover the material originally copied from the rest parser.

I note that ctags rest parser is still copyright Nick and has the V2 or later added.

@hadrielk

This comment has been minimized.

Copy link
Contributor Author

hadrielk commented Aug 20, 2018

done.

@masatake

This comment has been minimized.

Copy link
Member

masatake commented Aug 20, 2018

@hadrielk, thank you. I will update rst.c side.

@masatake

This comment has been minimized.

Copy link
Member

masatake commented Aug 20, 2018

This ports the Asciidoc parser from geany

Could you add this sentence to the commit log for 1eb07f9.

@@ -38,6 +38,7 @@ The following parsers have been added:

* Ada
* AnsiblePlaybook *libyaml*
* Asciidoc

This comment has been minimized.

@masatake
@masatake

This comment has been minimized.

Copy link
Member

masatake commented Aug 20, 2018

LGTM.
You can add a comment to #1566 after merging this:-)

@hadrielk hadrielk merged commit fca1706 into universal-ctags:master Aug 21, 2018

5 checks passed

ci/circleci: centos_make Your tests passed on CircleCI!
Details
ci/circleci: fedora_bmake Your tests passed on CircleCI!
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.03%) to 84.444%
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment