summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Healy <[email protected]>2024-01-08 21:03:47 +0100
committergit <[email protected]>2024-01-19 15:43:26 +0000
commit9031fd08dc7cd8c305b2e4b19948ddaf2b973ee0 (patch)
tree3cba3f73d9870060d87f668cc04eb925891cdc2d
parent88810f710968ff3148a444633500a4485f4080e8 (diff)
[ruby/prism] Document ClassVariableReadNode fields
https://github.com/ruby/prism/commit/23ed81dd15
-rw-r--r--prism/config.yml12
1 files changed, 12 insertions, 0 deletions
diff --git a/prism/config.yml b/prism/config.yml
index 6f6a2ba8db..00f7a77e60 100644
--- a/prism/config.yml
+++ b/prism/config.yml
@@ -1037,6 +1037,18 @@ nodes:
fields:
- name: name
type: constant
+ comment: |
+ The name of the class variable, including the leading `@@`. Variable
+ names begin with an underscore, alphabetical, or non-ASCII character,
+ followed by arbitrarily many underscores, alphanumeric or non-ASCII
+ characters. The exact definitions of "alphabetical" and "alphanumeric"
+ are encoding-dependent.
+
+ @@abc # name `:@@abc`
+
+ @@_test # name `:@@_test`
+
+ @@🍔 # name `:@@🍔`
comment: |
Represents referencing a class variable.