-
Notifications
You must be signed in to change notification settings - Fork 635
JavaScript: # indicates a private class field or method #4269
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
Merged
masatake
merged 1 commit into
universal-ctags:master
from
jafl:javascript-private-class-members
Jun 12, 2025
+148
−15
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
--fields=+a | ||
--fields-javascript=+{properties} | ||
--sort=no |
25 changes: 25 additions & 0 deletions
25
Units/parser-javascript.r/js-es6-class-private.d/expected.tags
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
Class1 input.js /^class Class1$/;" c | ||
#value1 input.js /^ #value1$/;" M class:Class1 access:private | ||
#value2 input.js /^ static #value2$/;" M class:Class1 access:private properties:static | ||
method1 input.js /^ method1(arg1,arg2)$/;" m class:Class1 | ||
#method2 input.js /^ #method2(arg1,arg2)$/;" m class:Class1 access:private | ||
Class2 input.js /^class Class2$/;" c | ||
#method3 input.js /^ static #method3(arg = 10)$/;" m class:Class2 access:private properties:static | ||
Class3 input.js /^var Class3 = class {$/;" c | ||
#method4 input.js /^ #method4(){}$/;" m class:Class3 access:private | ||
method5 input.js /^ static method5(){}$/;" m class:Class3 properties:static | ||
Class4 input.js /^var Class4 = class Class4_2 {$/;" c | ||
Class4_2 input.js /^var Class4 = class Class4_2 {$/;" c | ||
method6 input.js /^ method6(){}$/;" m class:Class4 | ||
method7 input.js /^ static method7(){}$/;" m class:Class4 properties:static | ||
AnonymousClass1fa6c9a30101 input.js /^class {$/;" c | ||
method8 input.js /^ method8(n) { return n * n; }$/;" m class:AnonymousClass1fa6c9a30101 | ||
func1 input.js /^function func1() {$/;" f | ||
InnerClass1 input.js /^ class InnerClass1 {$/;" c function:func1 | ||
#method9 input.js /^ #method9() {$/;" m class:func1.InnerClass1 access:private | ||
InnerClass2 input.js /^ class InnerClass2 {$/;" c function:func1 | ||
method10 input.js /^ method10() {$/;" m class:func1.InnerClass2 | ||
Class5 input.js /^class Class5 {$/;" c | ||
method11 input.js /^ method11() {};$/;" m class:Class5 | ||
#method12 input.js /^ #method12() {};$/;" m class:Class5 access:private | ||
func2 input.js /^function func2() {$/;" f |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
|
||
class Class1 | ||
{ | ||
#value1 | ||
static #value2 | ||
|
||
method1(arg1,arg2) | ||
{ | ||
} | ||
|
||
#method2(arg1,arg2) | ||
{ | ||
} | ||
} | ||
|
||
class Class2 | ||
{ | ||
static #method3(arg = 10) | ||
{ | ||
} | ||
} | ||
|
||
var Class3 = class { | ||
#method4(){} | ||
static method5(){} | ||
} | ||
|
||
var Class4 = class Class4_2 { | ||
method6(){} | ||
static method7(){} | ||
} | ||
|
||
class { | ||
method8(n) { return n * n; } | ||
} | ||
|
||
function func1() { | ||
class InnerClass1 { | ||
#method9() { | ||
} | ||
} | ||
class InnerClass2 { | ||
method10() { | ||
} | ||
} | ||
} | ||
|
||
class Class5 { | ||
method11() {}; | ||
#method12() {}; | ||
} | ||
|
||
function func2() { | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.