summaryrefslogtreecommitdiff
path: root/test/ripper
AgeCommit message (Collapse)Author
2016-02-02Fix Ripper.lex error in dedenting squiggly heredocnobu
* ext/ripper/lib/ripper/lexer.rb (on_heredoc_dedent): Fix Ripper.lex error in dedenting squiggly heredoc. heredoc tree is also an array of Elem in the outer tree. [Fix GH-1234] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-04Revert r53431 "temporally revert r53411 to debug"naruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53434 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-04temporally revert r53411 to debugnaruse
http://rubyci.s3.amazonaws.com/unstable11s/ruby-trunk/log/20151225T162507Z.diff.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53431 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-02parse.y: use nd_tagnobu
* parse.y (regexp): set_yylval_num sets u1, should use nd_tag instead of nd_state. [ruby-core:72638] [Bug #11932] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53411 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-02Revert r53409 "parse.y: yylval.num should be u3"naruse
It introduces SEGV git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53410 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-02parse.y: yylval.num should be u3nobu
* parse.y (set_yylval_num): should be used as nd_state, set to u3. [ruby-core:72638] [Bug #11932] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-16Add frozen_string_literal: false for all filesnaruse
When you change this to true, you may need to add more tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-07parse.y: indented hereocnobu
* parse.y: add heredoc <<~ syntax. [Feature #9098] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52916 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-11-28parse.y: last content of heredocnobu
* parse.y (parser_here_document): store dispatched result of on_tstring_content at the last fragment of a here document. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52777 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-11-27test_parser_events.rb: suppress a warningnobu
* test/ripper/test_parser_events.rb (test_warn_cr_in_middle): remove unused variable to suppress assigned-but-unused-variable warning. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-11-24parse.y: ripper for warningsnobu
* parse.y (parser_yylex): deal with magic comment warnings also in ripper. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52734 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-11-06change DOTQnobu
* defs/id.def (token_ops), parse.y (parser_yylex): change DOTQ from ".?" to "&.". [ruby-core:71363] [Feature #11537] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52462 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-10-28parse.y: fix op_assign typenobu
* parse.y (new_attr_op_assign): fix op_assign type, which is already an ID since r52284. [Feature #11537] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-10-28test_parser_events.rb: event tokennobu
* test/ripper/test_parser_events.rb (test_opassign): test parsed event tokens too. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-10-26parse.y: call_op2nobu
* parse.y (call_op2): separate from call_op and also allow "::", while dot_or_colon should not allow ".?". [Feature #11537] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52282 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-10-25symbol.c: dotq in rippernobu
* symbol.c (op_tbl): add DOTQ for ripper. [Feature #11537] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52276 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-10-14parse.y: fix ripper warningsnobu
* parse.y (parser_nextc): send a warning to ripper, not to STDERR always. * parse.y (rb_warn1, rb_warning1): move argument conversions to callers. PRIsVALUE is not valid in String#%. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52122 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-09-24parse.y: fix tokennobu
* parse.y (paren_args): fix separator token at `foo::bar()` in ripper. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51927 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-05-13parse.y: refine message for gvar w/o identitirsnobu
* parse.y (parse_gvar): separate message for gvar without non-space characters from message for invalid identitirs. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50480 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-01-04parse.y: fix f_label resultnobu
* parse.y (f_label): return tLABEL value as it is. [ruby-core:67315] [Bug #10693] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49140 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-12-01parse.y: preserve tSTRING_CONTENT resultsnobu
* parse.y (ripper_flush_string_content): preserve the dispatched results at tSTRING_CONTENT. [ruby-dev:48714] [Bug #10437] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48674 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-12-01parse.y: enable encoding pragma in rippernobu
* parse.y (magic_comment_encoding): enable in ripper, since the encoding is necessary to parse non-default encoding scripts. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48668 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-30parse.y: fix a typonobu
* parse.y (regexp_contents): fix a typo. pointed out by wanabe. [ruby-dev:48741] [Bug #10543] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48655 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-22dummyparser.rb: on_rescuenobu
* test/ripper/dummyparser.rb (on_rescue): add to turn exception class list into NodeList, to test exception class list. * test/ripper/test_parser_events.rb (test_rescue_class): add missing test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48537 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-20* test/ripper/test_files.rb: set filename.usa
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48511 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-19parse.y: regexp error in rippernobu
* parse.y (ripper_flush_string_content, parser_parse_string): preserve parsed string content. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48504 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-13* test/lib/envutil.rb: Moved from test/ruby/.akr
* test/lib/find_executable.rb: Ditto. * test/lib/memory_status.rb: Ditto. * test/lib/test/unit.rb: require envutil. * test/: Don't require envutil in test files. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-10-27test_parser_events.rb: split test_binarynobu
* test/ripper/test_parser_events.rb (test_binary): split for each operators. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48151 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-10-26parse.y: Ripper.sexp returns errornobu
* ext/ripper/lib/ripper/sexp.rb (Ripper.sexp, Ripper.sexp_raw): return nil on error. [ruby-dev:48678] [Bug #10405] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-10-24parse.y: fix fluent interface identifiernobu
* parse.y (parser_yylex): dispatch newline and space at fluent interface, so that the following identifier does not include the space. [ruby-dev:48684] [Bug #10411] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48126 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-10-16parse.y: do not use disposed stringnobu
* parse.y (parser_here_document): do not append already appended and disposed code fragment. [ruby-dev:48647] [Bug #10392] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47973 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-09-30parse.y: separate ripper data typenobu
* parse.y (parser_data_type): separate ripper data type for from parser. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47747 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-09-20parse.y: quoted ID keynobu
* parse.y (assoc): allow quoted ID as a key of a hash literal. [ruby-core:34453] [Feature #4276] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47649 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-25test/ripper/test_scanner_events.rb: fill empty test methodsnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46949 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-24parse.y: dynamic const assign_error in rippernobu
* parse.y (mlhs_node): dynamic constant assignment in massign should cause assign_error, like as single assign and backref assignment in massign. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46931 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-03-24parse.y: freeze filenamenobu
* parse.y (ripper_initialize): filename can not be modified. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45397 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-11-10parse.y: remove "f" suffix [ruby-core:57966] [Feature #9042]nobu
revert r42847 "test_string.rb: add test string encoding" revert r42846 "parse.y: freeze in advance to reduce objects" revert r42843 "parse.y: deduplicate frozen string literals" revert r42780 "test_string.rb: yet another test" revert r42779 "parse.y: valid suffix word only" revert r42778 "test_string.rb: remove duplicated code" revert r42775 "parse.y: force_encoding" This reverts commit 93ea04ecec7639ca8d0e58948e78461434782ecc. revert r42773 "Add frozen string literals" git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43634 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-02* NEWS: Add note about frozen string literalscharliesome
* compile.c (case_when_optimizable_literal): optimize NODE_LIT strings in when clauses of case statements * ext/ripper/eventids2.c: add tSTRING_SUFFIX * parse.y: add 'f' suffix on string literals for frozen strings * test/ripper/test_scanner_events.rb: add scanner tests * test/ruby/test_string.rb: add frozen string tests [Feature #8579] [ruby-core:55699] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-08-02eventids2.c: new literalsnobu
* ext/ripper/eventids2.c (ripper_init_eventids2): ripper support for new literals, tRATIONAL and tIMAGINARY. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-05-08parse.y: fail if invalid namenobu
* parse.y (parser_yylex): fail if $, @, @@ are not followed by a valid name character. [ruby-core:54846] [Bug #8375]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40607 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-05-08test_scanner_events.rb: assert_locationnobu
* test/ripper/test_scanner_events.rb (TestRipper#assert_location): rename so skipped in backtraces. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40606 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-04-02Use assert_separately to speed up on test-allnaruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-25scoped constant op-assignmentnobu
* test/ripper/test_parser_events.rb (test_opassign): allow scoped constant op-assignment. [ruby-core:40154] [Bug #5449] * test/ripper/test_parser_events.rb (test_opassign_error): backref opassign is only error. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38587 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-24scoped constant op-assignmentnobu
* test/ripper/test_parser_events.rb (test_opassign_error): allow scoped constant op-assignment. [ruby-core:40154] [Bug #5449] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-06parse.y: flush string contentnobu
* parse.y (parser_here_document): flush string content between new line and :string_embexpr. [ruby-core:48703] [Bug #7255] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38235 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-06test_scanner_events.rb: ruby-mode highlight by heredocnobu
* test/ripper/test_scanner_events.rb (TestRipper::ScannerEvents): get rid of make ruby-mode highlight confused by heredoc. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38234 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-06* ruby.c (load_file_internal): set default source encoding asnaruse
UTF-8 instead of US-ASCII. [ruby-core:46021] [Feature #6679] * parse.y (parser_initialize): set default parser encoding as UTF-8 instead of US-ASCII. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37485 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-10-25revert r37326 "remove string literal concatenation"nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37328 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-10-25remove string literal concatenationnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-09-05Suppress warningsnaruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e