summaryrefslogtreecommitdiff
path: root/prism/templates/template.rb
AgeCommit message (Collapse)Author
2025-05-29[ruby/prism] [DOC] Simply use `String#ljust`Nobuyoshi Nakada
https://github.com/ruby/prism/commit/ba019ab4b4
2025-05-29[ruby/prism] [DOC] Stop rdoc from processing non-rdoc commentsNobuyoshi Nakada
https://github.com/ruby/prism/commit/de1faa1680
2025-05-29[ruby/prism] [DOC] Specify markdown mode to RDocNobuyoshi Nakada
https://github.com/ruby/prism/commit/12af4e144e
2025-03-22[ruby/prism] Include nodeId in Java Node only if necessaryBenoit Daloze
* See https://github.com/ruby/prism/issues/3502 https://github.com/ruby/prism/commit/b7aedfe696
2024-09-25[ruby/prism] Type every node field and mark on-error-only types explicitlyBenoit Daloze
* For Loader.java, do not deserialize the AST if there are errors, so then Java nodes only have non-error types for fields. https://github.com/ruby/prism/commit/ae78e3c605
2024-09-13[ruby/prism] Refactor and move common node flags count into a constant to ↵Andrew Konchin
reuse in templates https://github.com/ruby/prism/commit/c20bf05ecc
2024-07-11[ruby/prism] Various cleanup for initializers and typechecksKevin Newton
https://github.com/ruby/prism/commit/86cf82794a
2024-07-11[ruby/prism] Expose common flags in inspect outputKevin Newton
https://github.com/ruby/prism/commit/d0143865c2
2024-07-11[ruby/prism] Expose flags on every node typeKevin Newton
https://github.com/ruby/prism/commit/9f12a56fd6
2024-06-25[ruby/prism] Fix documentation comment in generated with templates filesAndrew Konchin
Fix warning ``` /******************************************************************************/ ^ warning: [dangling-doc-comments] documentation comment is not attached to any declaration ``` in Nodes.java and AbstractNodeVisitor.java files. /** is treated as a starting of a javadoc comment. https://github.com/ruby/prism/commit/c83d7844b8
2024-04-24[ruby/prism] Change inspect from recursive to a queueKevin Newton
We would previously cause a stack overflow if we parsed a file that was too deeply nested when we were calling inspect. Instead, we now use a queue of commands to do it linearly so we don't. https://github.com/ruby/prism/commit/0f21f5bfe1
2024-04-17[ruby/prism] Add a reflection API for determining the fields of a nodeKevin Newton
https://github.com/ruby/prism/commit/f3f9950a74
2024-03-06[ruby/prism] Fix rebase templatesKevin Newton
https://github.com/ruby/prism/commit/31b8c6142f
2024-03-06[ruby/prism] Expose types on diagnosticsKevin Newton
https://github.com/ruby/prism/commit/a735c2262f
2024-03-06[ruby/prism] Move template related methods/classes under `Prism::Template` ↵Ufuk Kayserilioglu
namespace https://github.com/ruby/prism/commit/0e4dbcd3e4
2024-03-04[ruby/prism] Drop support for old ERBNobuyoshi Nakada
https://github.com/ruby/prism/commit/acdff3aae3
2024-02-29[ruby/prism] Resync RBI and test it in CIKevin Newton
https://github.com/ruby/prism/commit/4ef4032774
2024-02-28[ruby/prism] Rewrite logic for CHECK_FIELD_KIND to improve readabilityBenoit Daloze
https://github.com/ruby/prism/commit/f731edcc26
2024-02-28[ruby/prism] More precise types for NodeListField in prism.rbiBenoit Daloze
https://github.com/ruby/prism/commit/b7959295e9
2024-02-28[ruby/prism] Make NodeKindField subclass NodeKindFieldBenoit Daloze
* To avoid duplication. https://github.com/ruby/prism/commit/12e5aae0b4
2024-02-28[ruby/prism] Set proper types for node[] in Java-generated codeBenoit Daloze
https://github.com/ruby/prism/commit/322eaea500
2024-02-24[ruby/prism] Replace awkward code changes with steep:ignoreGopal Patel
Also remove RBS for currently ignored files. Will follow-up when those check fully in later PRs. https://github.com/ruby/prism/commit/2cae58f86d
2024-02-24[ruby/prism] Split private typesGopal Patel
https://github.com/ruby/prism/commit/0209d093ec
2024-02-24[ruby/prism] wip: node unionsGopal Patel
https://github.com/ruby/prism/commit/99a71675d4
2024-02-24[ruby/prism] Use steep to type check RBS and Ruby filesGopal Patel
https://github.com/ruby/prism/commit/eabed9f4fd
2024-02-23[PRISM] Sync to latest prismKevin Newton
2024-02-22[ruby/prism] Parse float valuesKevin Newton
https://github.com/ruby/prism/commit/9137226a52
2024-02-22[ruby/prism] Regenerate snapshots using integer valuesKevin Newton
2024-02-22[ruby/prism] Add an IntegerField for parsing integer valuesKevin Newton
https://github.com/ruby/prism/commit/120d8c0479
2024-01-03[ruby/prism] Include field comments in Java sourceBenoit Daloze
https://github.com/ruby/prism/commit/4a9389f304
2024-01-02[ruby/prism] Introduce field commentsKevin Newton
In an effort to further improve our documentation, this commit introduces the concept of templating comments onto fields. I hope to get more documentation above the nuances of specific fields this way going forward. With this, we template the comments into C and Ruby. I haven't done JS or Java yet, but we can touch those in the future, especially once their documentation is published. https://github.com/ruby/prism/commit/af300d5fb3
2023-12-01[ruby/prism] Change numbered parametersKevin Newton
Previously numbered parameters were a field on blocks and lambdas that indicated the maximum number of numbered parameters in either the block or lambda, respectively. However they also had a parameters field that would always be nil in these cases. This changes it so that we introduce a NumberedParametersNode that goes in place of parameters, which has a single uint8_t maximum field on it. That field contains the maximum numbered parameter in either the block or lambda. As a part of the PR, I'm introducing a new UInt8Field type that can be used on nodes, which is just to make it a little more explicit what the maximum values can be (the maximum is actually 9, since it only goes up to _9). Plus we can do a couple of nice things in serialization like just read a single byte. https://github.com/ruby/prism/commit/2d87303903
2023-11-30[prism] Remove escaping C source filesKevin Newton
2023-11-27[ruby/prism] Correct template.rb commentKevin Newton
https://github.com/ruby/prism/commit/4d689fe1df
2023-11-20[ruby/prism] Remove non-ASCII source charactersKevin Newton
(https://github.com/ruby/prism/pull/1787) https://github.com/ruby/prism/commit/5acc38a2f3
2023-11-12[ruby/prism] Add the ability to convert nodes to dotKevin Newton
https://github.com/ruby/prism/commit/3e4b4fb947
2023-11-11[ruby/prism] Implement JavaScript visitorsMarco Roth
https://github.com/ruby/prism/commit/ea00a1b3c6
2023-11-05Do not use non-ASCII chars in sourcesNobuyoshi Nakada
No encodings are guaranteed in C compilers, and other than UTF-8 encodings may be assumed in some platforms, e.g., CP932 on Windows Japanese edition, and may result in compilation errors.
2023-11-03[ruby/prism] Always fully qualify types for RBIs and avoid using attributesVinicius Stock
https://github.com/ruby/prism/commit/0d0d039f8e
2023-11-01[ruby/prism] More documentation for ast.hKevin Newton
https://github.com/ruby/prism/commit/84e22c5581
2023-11-01[ruby/prism] Add comments on flagsKevin Newton
https://github.com/ruby/prism/commit/3abd09c803
2023-10-31[ruby/prism] Share comment generation logicKevin Newton
https://github.com/ruby/prism/commit/6e5556dbdf
2023-10-27[ruby/prism] Add rbi_class to fieldsVinicius Stock
https://github.com/ruby/prism/commit/568fb39e2c
2023-10-27[ruby/prism] Add RBI and RBS templates for PrismVinicius Stock
https://github.com/ruby/prism/commit/b62305ff3e Co-authored-by: Stan Lo <st0012@users.noreply.github.com>
2023-10-26[ruby/prism] Compile with WASIKevin Newton
https://github.com/ruby/prism/commit/73c44b0b9c
2023-10-13[ruby/prism] Move common flags to top bitseileencodes
Moves the common flag bits to the top. This lets us eliminate the `COMMON` constant, and also allows us to group encoding flags on a nibble so we can more easily mask them. https://github.com/ruby/prism/commit/895508659e
2023-10-13[ruby/prism] Remove now-defunct semantic_field from nodesKevin Newton
https://github.com/ruby/prism/commit/c82a9dad64
2023-09-27Sync to prism rename commitsKevin Newton
2023-09-27Rename YARP filepaths to prism filepathsKevin Newton