summaryrefslogtreecommitdiff
path: root/test/ruby/test_syntax.rb
AgeCommit message (Collapse)Author
2013-03-26test_syntax.rb: fix test errornobu
* test/ruby/test_syntax.rb (test_syntax): escape interpolation to use the value passed by ARGV. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39955 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-26* test/ruby/test_syntax.rb: fixed a typo introduced at r39935.usa
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-26test_syntax.rb: pass srcdirnobu
* test/ruby/test_syntax.rb (test_syntax): need to pass the source directory, __FILE__ in assert_separately is '-' because the code is passed via a pipe. and this test can't finish in 10 seconds. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39935 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-26test_syntax.rb: envutilnobu
* test/ruby/test_syntax.rb (test_syntax): require envutil for assert_valid_syntax. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39934 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-26Use assert_separately to speed up on test-allnaruse
This creates large string and it pressure GC. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39932 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-21parse.y: refine warning messagenobu
* parse.y (ambiguous_operator): refine warning message, since this warning is shown after literal too. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39870 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-02-23compile.c: no keyword check if kw_restnobu
* compile.c (iseq_set_arguments): no keyword check if any keyword rest argument exists, even unnamed. [ruby-core:52744] [Bug #7922] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39444 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07test_syntax.rb: assert_not_labelnobu
* test/ruby/test_syntax.rb (TestSyntax#assert_not_label): need to eval in the current binding. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38727 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07parse.y: duplicated kwrest namenobu
* parse.y (f_kwrest): reject duplicated kwrest argument name. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38724 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07envutil.rb: optional fnamenobu
* test/ruby/envutil.rb (Test::Unit::Assertions#assert_valid_syntax): make fname optional for inline source. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-24scoped constant op-assignmentnobu
* node.h (NODE_OP_CDECL), compile.c (iseq_compile_each), parse.y (stmt, arg): allow scoped constant op-assignment. [ruby-core:40154] [Bug #5449] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38585 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-20envutil.rb: validate syntaxnobu
* test/ruby/envutil.rb (assert_valid_syntax): move from test_syntax.rb. * test/ruby/envutil.rb (assert_normal_exit): validate syntax before running because this assertion passes even if the code fails by SyntaxError. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38485 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-14parse.y: fix line numbernobu
* parse.y (parser_params): parser_tokline to track the line number at which token started. [ruby-dev:46737] [Bug #7559] * parse.y (fcall): operation with starting line number. * parse.y (command, primary, method_call): point method name line. * parse.y (gettable_gen): return token line for __LINE__. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38378 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-24Fix tests of rb_warning().knu
* test/ruby/envutil.rb (Test::Unit::Assertions#assert_warning) (Test::Unit::Assertions#assert_warn), test/ruby/envutil.rb, test/ruby/test_enumerator.rb, test/ruby/test_io_m17n.rb, test/ruby/test_regexp.rb, test/ruby/test_syntax.rb: assert_warn() and assert_warning() are reversed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37836 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-10-18parse.y: fail if yyerrornobu
* parse.y (assignable_gen): fail if yyerror occurred. fix a bug in r36973. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37251 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-10-18test_syntax.rb: test_unassignablenobu
* test/ruby/test_syntax.rb (TestSyntax#test_unassignable): assert keywords are unassignable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37250 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-07-18test_syntax.rb: updatenobu
* test/ruby/test_syntax.rb (test_warn_grouped_expression): update for r36434. [ruby-core:39050][Bug #5214] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-21parse.y: fix GC problem of keyword rest argumentnobu
* parse.y (new_args_tail_gen): fix GC problem of keyword rest argument. the wrapped struct should be bound to the wrapping node before assignment of child nodes, to get rid of the case the children are referred by only the struct pointer which is not a subject of GC. [ruby-core:45744] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36161 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-05-14Bug #6403: reset states after empty argsnobu
* parse.y (f_arglist): should reset lexical states after empty argument list with no parenthesis as well as parenthesized list, so that reserved name method definition work. [ruby-dev:45626] [Bug #6403] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35644 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-05-11Bug #6419: fix cmdarg beginnobu
* parse.y (primary): begin/end block should be isolated from outside. [ruby-dev:45631][Bug #6419] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35620 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-05-02* parse.y (parser_yylex): allow spaces between lambda arrow andnobu
parenthesis. [ruby-dev:45605][Feature #6390] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35520 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-04-28* parse.y (assoc, parser_yylex): add syntax to splat keyword hash.nobu
[ruby-core:44591][Feature #6353] * compile.c (compile_array_): generate keyword splat insns. * vm.c (m_core_hash_merge_kwd): merge keyword hash into intermediate hash. leftward argument is prior currently. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35489 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-04-24* compile.c: fix to output warning when the same literalsko1
are available as a condition of same case clause. And remove infomation ('#n') because we can find duplicated condition with explicit line numbers. [ruby-core:38343] [Ruby 1.9 - Bug #5068] * test/ruby/test_syntax.rb: add a test for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35459 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-04-24* parse.y (parser_yylex): EXPR_BEG by keywords is a start point ofnobu
commands. [ruby-dev:45563][Bug #6347] * parse.y (superclass): ditto for superclass. * parse.y (parser_parse_string, parser_here_document): ditto for string interpolation. * parse.y (parser_yylex): ditto for singleton class. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35457 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-16fix unreachable warning line numbernobu
* parse.y (block_append_gen): fix unreachable warning line number. should warn at the code, not jump. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35068 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-16bug numbernobu
* test/ruby/test_syntax.rb (test_keyword_rest): give the bug number to assertions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-15* parse.y (parser_yylex): fix warning line number.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-13* compile.c (iseq_set_arguments): keyword rest arg without keyword args.nobu
* node.c (dump_node): dump kw_rest_arg too. * parse.y (block_param, f_arg): more kwrest patterns. [ruby-core:42455][Bug #5989] * parse.y (new_args_gen): no extra kw_rest_arg if no keyword rest arg. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34999 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-13* parse.y (block_param, f_args): add rules for the case argumentsnobu
begin with kwrest. [ruby-core:42455][Bug #5989] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34998 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-05* parse.y (block_call): rules for block_call after block_call.nobu
based on a patch by pasberth https://github.com/ruby/ruby/pull/102 [ruby-dev:45308][Bug #6115] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34913 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-03-05assert_valid_syntaxnobu
* test/ruby/test_syntax.rb (assert_valid_syntax): new assertion to validate syntax. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-02-27* test/ruby/test_syntax.rb (test_newline_in_block_parameters):nobu
test for [ruby-dev:45292]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34832 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-01* test/ruby/test_syntax.rb (TestSyntax#test_syntax): show script namenobu
in assertion message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31890 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-02-04* parse.y (lex_getline, parser_set_encode): set encoding of linesnobu
in SCRIPT_LINES__ as source encoding. [ruby-dev:43168] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-07-04* test/ruby/test_syntax.rb: split test_syntax from test_system.rb.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28540 b2dd03c8-39d4-4d8f-98ff-823fe69b080e