Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Bison 3.5.91 now defaults parse.error to "simple" | Nobuyoshi Nakada | 2020-07-10 | 1 | -0/+1 |
| | |||||
* | merge revision(s) 263b941321c3de6afc8f9dafbc2625f866b7437e: [Backport #16981] | nagachika | 2020-06-27 | 1 | -4/+5 |
| | | | | | | | [ripper] fix mismatched indentations warning [Bug #16981] The scanner location has to be set from `lex.ptok` before it is flushed by dispatching the scanner event. | ||||
* | Preserve `kwarg` flag and fix up f5c904c2a9 | Nobuyoshi Nakada | 2020-03-28 | 1 | -0/+2 |
| | | | | (cherry picked from commit c8d0bf0156878df03a71fffc97c44abf7333d5d7) | ||||
* | Allow newlines inside braced pattern | Nobuyoshi Nakada | 2020-03-27 | 1 | -2/+10 |
| | | | | (cherry picked from commit f5c904c2a907013e22ff74bc3686952c5448d493) | ||||
* | Allow trailing comma in hash pattern | Kazuki Tsujimoto | 2020-03-27 | 1 | -0/+4 |
| | | | | (cherry picked from commit d25a4f413dce6ad3a8baaf61591415b9a8cce082) | ||||
* | Fixed duplicated warning | Nobuyoshi Nakada | 2020-03-14 | 1 | -6/+0 |
| | | | | | | | As `command_rhs` is always a "value expression", `command_asgn` does not need the same check. [Bug #16619] (cherry picked from commit 6e6844320de989cb88a154e2ac75066ccea1bba2) | ||||
* | Squashed commit of the following: [Backport #16516] | NARUSE, Yui | 2020-03-13 | 1 | -1/+5 |
| | | | | | | | | | | | | | | commit c98c492578d898dc07a04b8240d8d5b1508ffafa Author: Nobuyoshi Nakada <nobu@ruby-lang.org> Date: Fri Jan 17 16:56:53 2020 +0900 Added test for f38b3e8c707ebdcad05aa9485cf1760640b74fbb commit f38b3e8c707ebdcad05aa9485cf1760640b74fbb Author: Nobuyoshi Nakada <nobu@ruby-lang.org> Date: Thu Jan 16 18:34:31 2020 +0900 Fixed the location of args node with numbered parameter | ||||
* | Show the error line only when same as the current | Nobuyoshi Nakada | 2019-12-25 | 1 | -1/+12 |
| | |||||
* | Added `experimental` warning category | Nobuyoshi Nakada | 2019-12-20 | 1 | -1/+2 |
| | | | | [Feature #16420] | ||||
* | Hoisted out new_case3 | Nobuyoshi Nakada | 2019-12-20 | 1 | -4/+12 |
| | |||||
* | Refined the warning message for numbered-parameter like variables | Nobuyoshi Nakada | 2019-12-20 | 1 | -1/+1 |
| | | | | [Bug #16438] | ||||
* | Refined the warning message for numbered-parameter like variables | Nobuyoshi Nakada | 2019-12-20 | 1 | -1/+1 |
| | | | | [Bug #16438] | ||||
* | Warn also numbered parameter like methods | Nobuyoshi Nakada | 2019-12-20 | 1 | -0/+3 |
| | |||||
* | Warn also numbered parameter like parameters | Nobuyoshi Nakada | 2019-12-20 | 1 | -4/+10 |
| | | | | [Feature #16433] | ||||
* | parse.y: suppress "set but not used" warnings on ripper.y | Yusuke Endoh | 2019-12-05 | 1 | -5/+4 |
| | |||||
* | Silence incorrect assigned but unused variable warnings in ripper | Jeremy Evans | 2019-12-04 | 1 | -0/+2 |
| | | | | | | | To only emit the warnings in correct cases would require tracking local variable usage in ripper, which ripper currently does not do. Fixes [Bug #15188] | ||||
* | Make single line pattern matching void expression | Nobuyoshi Nakada | 2019-11-30 | 1 | -0/+11 |
| | | | | | Instead of returning `nil`, raise a syntax error if its value is used. [Feature #16355] | ||||
* | Raise `NoMatchingPatternError` when expr `in` pat doesn't match | Nobuyoshi Nakada | 2019-11-28 | 1 | -1/+1 |
| | | | | | | | | * `expr in pattern` should raise `NoMatchingError` when unmatched * `expr in pattern` should return `nil`. (this is unspecified, but this feature is experimental, at all) [Feature #16355] | ||||
* | [ripper] Fixed unique key check in pattern matching | Nobuyoshi Nakada | 2019-11-26 | 1 | -67/+52 |
| | | | | | | Check keys * by an internal table, instead of unstable dispatched results * and by parsed key values, instead of escaped forms in the source | ||||
* | Hoisted out `push_pvtbl`/`pop_pvtbl` | Nobuyoshi Nakada | 2019-11-26 | 1 | -16/+19 |
| | |||||
* | Wrap `p_kw` in an array at `p_kwarg` | Nobuyoshi Nakada | 2019-11-26 | 1 | -3/+4 |
| | | | | | Not in `p_kw` itself, which makes key and variable/expr pair only now. | ||||
* | [ripper] Quoted label without expression must be a local variable | Nobuyoshi Nakada | 2019-11-25 | 1 | -34/+58 |
| | | | | | | | | | The difference from 0b8c73aa65add5c57b46b0cfdf4e661508802172 is to add the result of `string_add` event to marking objects. ```C RNODE($1)->nd_rval = add_mark_object(p, $$); ``` | ||||
* | Revert "[ripper] Quoted label without expression must be a local variable" | Nobuyoshi Nakada | 2019-11-20 | 1 | -58/+34 |
| | | | | | This reverts commit 0b8c73aa65add5c57b46b0cfdf4e661508802172, which seems breaking RVALUE consistency check. | ||||
* | [ripper] Quoted label without expression must be a local variable | Nobuyoshi Nakada | 2019-11-19 | 1 | -34/+58 |
| | |||||
* | Warn on access/modify of $SAFE, and remove effects of modifying $SAFE | Jeremy Evans | 2019-11-18 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | | This removes the security features added by $SAFE = 1, and warns for access or modification of $SAFE from Ruby-level, as well as warning when calling all public C functions related to $SAFE. This modifies some internal functions that took a safe level argument to no longer take the argument. rb_require_safe now warns, rb_require_string has been added as a version that takes a VALUE and does not warn. One public C function that still takes a safe level argument and that this doesn't warn for is rb_eval_cmd. We may want to consider adding an alternative method that does not take a safe level argument, and warn for rb_eval_cmd. | ||||
* | delete unused functions | 卜部昌平 | 2019-11-14 | 1 | -35/+2 |
| | | | | | | | | | | | | Looking at the list of symbols inside of libruby-static.a, I found hundreds of functions that are defined, but used from nowhere. There can be reasons for each of them (e.g. some functions are specific to some platform, some are useful when debugging, etc). However it seems the functions deleted here exist for no reason. This changeset reduces the size of ruby binary from 26,671,456 bytes to 26,592,864 bytes on my machine. | ||||
* | `#@1` is no longer an embedded variable | Nobuyoshi Nakada | 2019-11-14 | 1 | -3/+0 |
| | |||||
* | Revert "Method reference operator" | Nobuyoshi Nakada | 2019-11-12 | 1 | -27/+1 |
| | | | | | This reverts commit 67c574736912003c377218153f9d3b9c0c96a17b. [Feature #16275] | ||||
* | Warn on `...` at EOL | Nobuyoshi Nakada | 2019-11-12 | 1 | -0/+3 |
| | |||||
* | Disable tOROP at EXPR_BEG | Nobuyoshi Nakada | 2019-11-12 | 1 | -9/+5 |
| | | | | Both cannot appear there anyway. | ||||
* | Clear current argument name at empty block argument [Bug #16343] | Nobuyoshi Nakada | 2019-11-12 | 1 | -0/+1 |
| | |||||
* | Revert "Warn EOF char in comment" | NARUSE, Yui | 2019-11-11 | 1 | -25/+4 |
| | | | | This reverts commit 69ec3f70fab0c1c537c68fb135cc315181b1d750. | ||||
* | Revert "Elaborated EOF char message a little" | NARUSE, Yui | 2019-11-11 | 1 | -1/+1 |
| | | | | This reverts commit 6eaac7cfac668d6669be694fd7b723c4982ed218. | ||||
* | Elaborated EOF char message a little | Nobuyoshi Nakada | 2019-11-11 | 1 | -1/+1 |
| | |||||
* | Warn EOF char in comment | Nobuyoshi Nakada | 2019-11-11 | 1 | -4/+25 |
| | |||||
* | Fixed embedded document with EOF char | Nobuyoshi Nakada | 2019-11-11 | 1 | -4/+16 |
| | |||||
* | Disallow omission of parentheses/brackets in single line pattern matching ↵ | Kazuki Tsujimoto | 2019-11-10 | 1 | -1/+1 |
| | | | | [Feature #16182] | ||||
* | Disallow duplicated pattern variable | Kazuki Tsujimoto | 2019-11-07 | 1 | -4/+41 |
| | |||||
* | Add missing semicolon | Kazuki Tsujimoto | 2019-11-07 | 1 | -0/+1 |
| | |||||
* | Numbered parameter is an ID_LOCAL now [Bug #16293] | Nobuyoshi Nakada | 2019-11-06 | 1 | -17/+5 |
| | |||||
* | Numbered parameter cannot appear outside block now [Bug #16293] | Nobuyoshi Nakada | 2019-11-06 | 1 | -1/+0 |
| | |||||
* | Fix a typo in WARN_EOL | Kazuhiro NISHIYAMA | 2019-11-05 | 1 | -1/+1 |
| | |||||
* | Fixed conditional expressions with only one void side | Nobuyoshi Nakada | 2019-11-05 | 1 | -1/+1 |
| | |||||
* | Keep `lex.pcur` after `looking_at_eol_p` | Nobuyoshi Nakada | 2019-11-04 | 1 | -3/+3 |
| | |||||
* | Warn `if` and `elsif` at EOL [EXPERIMENTAL] | Nobuyoshi Nakada | 2019-11-04 | 1 | -0/+22 |
| | | | | It is unnatural and probably a typo. | ||||
* | Revert "Warn `if` and `elsif` at EOL [EXPERIMENTAL]" | Yusuke Endoh | 2019-11-04 | 1 | -22/+0 |
| | | | | | This reverts commit ba35c14325ebbf1da8f200df83c45ee9937ff8a1. This is because ripper fails symbol lookup error. | ||||
* | Warn `if` and `elsif` at EOL [EXPERIMENTAL] | Nobuyoshi Nakada | 2019-11-04 | 1 | -0/+22 |
| | | | | It is unnatural and probably a typo. | ||||
* | Restore `in_kwarg` flag properly | Nobuyoshi Nakada | 2019-10-29 | 1 | -1/+1 |
| | |||||
* | Define arguments forwarding as `ruby2_keywords` style | Nobuyoshi Nakada | 2019-10-25 | 1 | -1/+19 |
| | | | | | | | | | | | | Get rid of these redundant and useless warnings. ``` $ ruby -e 'def bar(a) a; end; def foo(...) bar(...) end; foo({})' -e:1: warning: The last argument is used as the keyword parameter -e:1: warning: for `foo' defined here -e:1: warning: The keyword argument is passed as the last hash parameter -e:1: warning: for `bar' defined here ``` | ||||
* | Arguments forwarding is not allowed in lambda [Feature #16253] | Nobuyoshi Nakada | 2019-10-25 | 1 | -11/+13 |
| |