aboutsummaryrefslogtreecommitdiffstats
path: root/parse.y
Commit message (Collapse)AuthorAgeFilesLines
* fix public interfaceKoichi Sasada2020-11-181-1/+1
| | | | | | | | | | | | | | | | | | To make some kind of Ractor related extensions, some functions should be exposed. * include/ruby/thread_native.h * rb_native_mutex_* * rb_native_cond_* * include/ruby/ractor.h * RB_OBJ_SHAREABLE_P(obj) * rb_ractor_shareable_p(obj) * rb_ractor_std*() * rb_cRactor and rm ractor_pub.h and rename srcdir/ractor.h to srcdir/ractor_core.h (to avoid conflict with include/ruby/ractor.h)
* Use more specific warning for ambiguous slashJeremy Evans2020-11-151-1/+6
| | | | Fixes [Bug #17124]
* ripper: Invalid pragma value warningNobuyoshi Nakada2020-11-021-1/+1
|
* Compare boolean values for parser pragma locale-insensitivelyNobuyoshi Nakada2020-11-021-2/+2
|
* Change NODE layout for pattern matchingKazuki Tsujimoto2020-11-011-3/+3
| | | | | | | | | | | | | | | | | | | | I prefer pconst to be the first element of NODE. Before: | ARYPTN | FNDPTN | HSHPTN ---+--------+--------+----------- u1 | imemo | imemo | pkwargs u2 | pconst | pconst | pconst u3 | apinfo | fpinfo | pkwrestarg After: | ARYPTN | FNDPTN | HSHPTN ---+--------+--------+----------- u1 | pconst | pconst | pconst u2 | imemo | imemo | pkwargs u3 | apinfo | fpinfo | pkwrestarg
* Pattern matching is no longer experimentalKazuki Tsujimoto2020-11-011-13/+9
|
* Allow non-argument endless-def with a space instead of parenthesesNobuyoshi Nakada2020-10-261-5/+8
|
* Assoc pattern matching (#3703)Nobuyoshi Nakada2020-10-261-34/+3
| | | | | [Feature #17260] One-line pattern matching using tASSOC R-assignment is rejected instead.
* Prohibit setter method names in all kinds of endless methodsNobuyoshi Nakada2020-10-121-3/+16
| | | | Also unwrap NODE_RIPPER to check the method name.
* Refactored lex_context managementNobuyoshi Nakada2020-10-091-8/+8
| | | | | Save and restore `lex_context` as-is wholely, and save in `k_class` and `k_module` to workaround look-ahead reading.
* Unfreeze string-literal-only interpolated string-literalNobuyoshi Nakada2020-09-301-12/+29
| | | | [Feature #17104]
* Introduce Ractor mechanism for parallel executionKoichi Sasada2020-09-031-3/+4
| | | | | | | | | | | | | | | | This commit introduces Ractor mechanism to run Ruby program in parallel. See doc/ractor.md for more details about Ractor. See ticket [Feature #17100] to see the implementation details and discussions. [Feature #17100] This commit does not complete the implementation. You can find many bugs on using Ractor. Also the specification will be changed so that this feature is experimental. You will see a warning when you make the first Ractor with `Ractor.new`. I hope this feature can help programmers from thread-safety issues.
* new_dstr: hoisted out from literal_concat and evstr2dstrNobuyoshi Nakada2020-09-021-6/+12
|
* Prohibit setter method names in endless method definitionYusuke Endoh2020-08-311-0/+3
| | | | https://bugs.ruby-lang.org/issues/16746#note-26
* Fixed error messages at non-ascii %string terminatorNobuyoshi Nakada2020-08-261-0/+6
|
* Removed a never-true conditionNobuyoshi Nakada2020-08-261-1/+1
|
* rb_{ary,fnd}_pattern_info: Remove imemo member to reduce memory usageKazuki Tsujimoto2020-08-021-35/+13
| | | | | | | | | | | | | | | | | | | | | | This is a partial revert commit of 8f096226e1b76f95f4d853d3dea2bc75eeeb5244. NODE layout: Before: | ARYPTN | FNDPTN | HSHPTN ---+--------+--------+----------- u1 | pconst | pconst | pconst u2 | unused | unused | pkwargs u3 | apinfo | fpinfo | pkwrestarg After: | ARYPTN | FNDPTN | HSHPTN ---+--------+--------+----------- u1 | imemo | imemo | pkwargs u2 | pconst | pconst | pconst u3 | apinfo | fpinfo | pkwrestarg
* Use a linked list to eliminate imemo tmp bufs for managing local tablesAaron Patterson2020-07-271-10/+2
| | | | | | | This patch changes local table memory to be managed by a linked list rather than via the garbage collector. It reduces allocations from the GC and also fixes a use-after-free bug in the concurrent-with-sweep compactor I'm working on.
* Switch reserved for numbered parameter warning to SyntaxErrorJeremy Evans2020-07-221-2/+2
|
* Drop token info for endless method definitionNobuyoshi Nakada2020-06-251-0/+23
| | | | Because it does not have closing `end`.
* AST.of needs SCRIPT_LINES__ filled with a newlineNobuyoshi Nakada2020-06-251-1/+1
|
* [ripper] fix mismatched indentations warning [Bug #16981]Nobuyoshi Nakada2020-06-241-4/+5
| | | | | The scanner location has to be set from `lex.ptok` before it is flushed by dispatching the scanner event.
* apinfo/fpinfo should always be non-NULLKazuki Tsujimoto2020-06-141-12/+8
|
* Introduce find pattern [Feature #16828]Kazuki Tsujimoto2020-06-141-10/+111
|
* push_pktbl is needed for hash pattern, not for array patternKazuki Tsujimoto2020-06-141-3/+2
|
* Extracted argument forwarding staffsNobuyoshi Nakada2020-06-131-47/+58
|
* [ripper] use Ripper DSLNobuyoshi Nakada2020-06-131-3/+3
|
* Differentiate `...` in lambda argumentsNobuyoshi Nakada2020-06-071-0/+4
|
* Add leading arguments support to arguments forwardingJeremy Evans2020-06-061-0/+41
| | | | | | | | The idFWD_KWREST sections may be wrong. However, the existing idFWD_KWREST sections for ... without leading arguments are already broken. Implements [Feature #16378]
* Include the entire lambda expression in lambda ruleNobuyoshi Nakada2020-06-021-25/+6
|
* Extracted `excessed_comma` to unify ripper and make the order stableNobuyoshi Nakada2020-06-011-7/+14
|
* Fixed argument forwarding in reserved word method [Bug #16854]Nobuyoshi Nakada2020-05-151-5/+2
|
* Endless method definition including `rescue` modifierNobuyoshi Nakada2020-05-141-2/+34
|
* sed -i 's|ruby/impl|ruby/internal|'卜部昌平2020-05-111-1/+1
| | | | To fix build failures.
* sed -i s|ruby/3|ruby/impl|g卜部昌平2020-05-111-1/+1
| | | | This shall fix compile errors.
* Bison 3.5.91 now defaults parse.error to "simple"Nobuyoshi Nakada2020-05-041-0/+1
|
* Made parentheses mandatory in endless method defitionNobuyoshi Nakada2020-04-221-15/+7
| | | | | Even for empty argument list, not to be confusing with a writer method name.
* Revert "Allow simple R-assign in endless def"Nobuyoshi Nakada2020-04-221-17/+3
| | | | This reverts commit 67bcac879a2e0ddfb4e7bbd7cb5e5401422de76a.
* Disallow line-continuation before R-assignNobuyoshi Nakada2020-04-151-2/+1
|
* Removed duplicate value_expr checksNobuyoshi Nakada2020-04-141-4/+0
| | | | | `arg_rhs` has the same check and is always a non-void value expression.
* Allow simple R-assign in endless defNobuyoshi Nakada2020-04-131-3/+17
|
* Relaxed of R-assign value to argNobuyoshi Nakada2020-04-121-6/+2
|
* Endless method definition [Feature #16746]Nobuyoshi Nakada2020-04-101-38/+105
|
* Rightward-assign by ASSOCNobuyoshi Nakada2020-04-101-2/+38
| | | | [Feature #15921]
* Merge pull request #2991 from shyouhei/ruby.h卜部昌平2020-04-081-1/+1
| | | Split ruby.h
* New macro `NEW_RIPPER` instead of `NEW_CDECL`Nobuyoshi Nakada2020-04-031-1/+2
|
* parse.y: hoisted out new_nil_atNobuyoshi Nakada2020-03-111-41/+17
| | | | new_nil_at: create NEW_NIL node with zero-width location.
* parse.y: unified kwrest and no-kwrestNobuyoshi Nakada2020-03-111-22/+14
|
* Renamed `lex_flags` as `lex_context`Nobuyoshi Nakada2020-03-051-49/+49
|
* Preserve `kwarg` flag and fix up f5c904c2a9Nobuyoshi Nakada2020-03-031-0/+2
|