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

jscript: don't attempt to generate tags for empty properties #4153

Closed
wants to merge 1 commit into from

Conversation

techee
Copy link
Contributor

@techee techee commented Dec 8, 2024

In javascript it is legal to have e.g. {"": false} and with the current code the parser attempts to generate the tag for the empty string which produces warning.

This is an attempt to fix #4134. I'm actually not sure why I got the other 2 warnings as I cannot reproduce them now - I possibly just used an old ctags version before.

Fixes #4134.

In javascript it is legal to have e.g. {"": false} and with the
current code the parser attempts to generate the tag for the empty
string which produces warning.
Copy link

codecov bot commented Dec 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 85.90%. Comparing base (e5650e9) to head (77cd80e).
Report is 25 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #4153   +/-   ##
=======================================
  Coverage   85.90%   85.90%           
=======================================
  Files         239      239           
  Lines       58727    58728    +1     
=======================================
+ Hits        50447    50448    +1     
  Misses       8280     8280           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jafl jafl self-assigned this Dec 10, 2024
@jafl jafl requested a review from masatake December 10, 2024 02:37
@masatake
Copy link
Member

I'll cherry-pick the test case from here.
I'm working on allowing ctags to emit "" tag in #4152.

@masatake masatake added this to the 6.2 milestone Dec 11, 2024
masatake pushed a commit to masatake/ctags that referenced this pull request Dec 13, 2024
In javascript it is legal to have e.g. {"": false}.  With the
original code the parser attempts to generate the tag for the empty
string which produces warning.

With setting allowNullTag member of tagEntryInfo, the parser can
generate such tags without producing warnings.

Actual tag emission is controlled by --extras=+{nulltag}.

This commit is based on the commit in universal-ctags#4153.

Co-Author: Masatake YAMATO <[email protected]>
masatake pushed a commit to masatake/ctags that referenced this pull request Dec 14, 2024
In javascript it is legal to have e.g. {"": false}.  With the
original code the parser attempts to generate the tag for the empty
string which produces warning.

With setting allowNullTag member of tagEntryInfo, the parser can
generate such tags without producing warnings.

Actual tag emission is controlled by --extras=+{nulltag}.

This commit is based on the commit in universal-ctags#4153.

Co-Author: Masatake YAMATO <[email protected]>
masatake pushed a commit to masatake/ctags that referenced this pull request Dec 14, 2024
In javascript it is legal to have e.g. {"": false}.  With the
original code the parser attempts to generate the tag for the empty
string which produces warning.

With setting allowNullTag member of tagEntryInfo, the parser can
generate such tags without producing warnings.

Actual tag emission is controlled by --extras=+{nulltag}.

This commit is based on the commit in universal-ctags#4153.

Co-Author: Masatake YAMATO <[email protected]>
masatake pushed a commit to masatake/ctags that referenced this pull request Dec 14, 2024
In javascript it is legal to have e.g. {"": false}.  With the
original code the parser attempts to generate the tag for the empty
string which produces warning.

With setting allowNullTag member of tagEntryInfo, the parser can
generate such tags without producing warnings.

Actual tag emission is controlled by --extras=+{nulltag}.

This commit is based on the commit in universal-ctags#4153.

Co-Author: Masatake YAMATO <[email protected]>
masatake pushed a commit to masatake/ctags that referenced this pull request Dec 19, 2024
In javascript it is legal to have e.g. {"": false}.  With the
original code the parser attempts to generate the tag for the empty
string which produces warning.

With setting allowNullTag member of tagEntryInfo, the parser can
generate such tags without producing warnings.

Actual tag emission is controlled by --extras=+{nulltag}.

This commit is based on the commit in universal-ctags#4153.

Co-Author: Masatake YAMATO <[email protected]>
@masatake
Copy link
Member

This pull request was indirectly merged to #4152.
@techee, thank you for digging into the issue behind this pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

javascript: ignoring null tag warnings for jquery 3.6.0
3 participants