aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* parse.y: fix overflownobu2018-01-182-2/+9
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61900 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: REQUIRED_KEYWORDnobu2018-01-181-3/+4
| | | | | | | * parse.y (REQUIRED_KEYWORD): special argument for required keyword argument, for core and ripper. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61899 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* resolv.rb: NUL hostsnobu2018-01-181-1/+1
| | | | | | | | | * lib/resolv.rb (Resolv::Hosts::DefaultFileName): fallback to NUL device when Win32::Resolv.get_hosts_path() returned nil, to get rid of TypeError in lazy_initialize. [ruby-core:84907] [Bug #14369] [Fix GH-1791] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61898 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* resolv: use safe navigation operatornobu2018-01-181-3/+1
| | | | | | | * lib/resolv.rb (each_address): use safe navigation operator to avoid extra hash lookups, as well as each_name since r56890. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61897 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* marshal.c: initialize keywordsnobu2018-01-181-4/+3
| | | | | | | * marshal.c (r_object0): initialize `keywords` and removed `keyword_init` flag, to get rid of maybe-uninitialized warning. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* win32/resolv.rb: call rb_w32_osidnobu2018-01-181-13/+12
| | | | | | | * ext/win32/lib/win32/resolv.rb: call rb_w32_osid instead of direct GetVersionExA API. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61895 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* logger: use safe navigation operatornormal2018-01-181-4/+2
| | | | | | Saves a few hundred bytes of bytecode in a frequently loaded module. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61894 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* include ruby/ruby.h before ruby.io.hnaruse2018-01-171-0/+1
| | | | | | | It breaks AIX build: https://rubyci.org/logs/rubyci.s3.amazonaws.com/aix71_ppc/ruby-trunk/log/20180117T113303Z.log.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61893 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* extend timeoutnaruse2018-01-171-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61892 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-01-18svn2018-01-171-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61891 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* iseq.c: dump as non-trace instructionsnobu2018-01-171-3/+3
| | | | | | | | | * iseq.c (iseq_data_to_ary): when OPT_CALL_THREADED_CODE is used, iseq_encoded is overwritten by instructions with trace and the original_iseq is not stored. convert these instructions to the original instructions as external representation. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61890 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix typos.hsbt2018-01-173-4/+4
| | | | | | | | * node.c: strucutre -> structure * random.c: acquried -> acquired * thread.c: accross -> across git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61889 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* process.c: get_clk_tck fallbacknobu2018-01-171-11/+6
| | | | | | | * process.c (get_clk_tck): prefer CLK_TCK over older HZ, next to _SC_CLK_TCK. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61888 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* process.c: remove useless castnobu2018-01-171-2/+2
| | | | | | | | | * process.c (get_clk_tck): remove useless cast, implicitly cast to long again. * process.c (rb_proc_times): cast explicitly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61887 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* common.mk: ripper.c recipenobu2018-01-171-1/+1
| | | | | | | * common.mk (ripper.c): strip nmake-style VPATH from depend file, as well as mkmf.rb does. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61886 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/ripper/depend: Try to fix the path of id.hmame2018-01-171-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61885 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_ast.rb: no base directory namenobu2018-01-171-4/+4
| | | | | | | * test/-ext-/ast/test_ast.rb: exclude base directory name from test method names. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61884 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* iseq.c: flatten TS_NUM operand conditionsnobu2018-01-171-11/+14
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61883 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: refine negate_lit_gen error messagenobu2018-01-171-12/+15
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61882 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c: use "unsigned int" for bitfieldsnormal2018-01-171-8/+2
| | | | | | Followup to r61870 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61881 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper.c: depends on preproc.rbnobu2018-01-172-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61880 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Refactor for-statement generationmame2018-01-161-18/+14
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61879 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (new_args_tail): Use human-friendly variable namesmame2018-01-161-22/+22
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61878 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-01-17svn2018-01-161-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61877 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* node.c: Separately allocate a struct having flexible arraymame2018-01-161-5/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61876 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* nested flexible array member is a GCCismshyouhei2018-01-161-1/+1
| | | | | | | | This is NG. The ISO C section 6.7.2.1 explicitly states that structs having flexible array members "shall not be a member of a structure or an element of an array." git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61875 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* -Wno-overlength-stringsshyouhei2018-01-162-6/+1
| | | | | | | | as per https://bugs.ruby-lang.org/projects/ruby-trunk/wiki/Assumptions we are officially giving up 509 characters limit of C string literal length. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61874 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: unified local_push argumentnobu2018-01-161-5/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: simplified compstmtnobu2018-01-161-17/+11
| | | | | | | * parse.y (top_compstmt, compstmt): unified void_stmts with ripper. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61872 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* node.c: Stop double meaning of NODE_FOR by introducing NODE_FOR_MASGNmame2018-01-166-37/+45
| | | | | | | | | NODE_FOR was used both for "for"-statement itself and for multi-assignment of for-statement (for x, y, in...end). This change separates the two purposes, NODE_FOR for the former, and newly introduced NODE_FOR_MASGN for the latter. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61871 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* timev.h: just use "unsigned int" for bitfieldsnormal2018-01-161-17/+8
| | | | | | | | | | | | There's no point in having separate types depending on C dialect when using bitfields, "unsigned int" bitfields are bitfields anywhere. Note: we also have test_memsize in test_time.rb in case users of other platforms want to enable size assertions if they don't trust their compiler. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61870 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix macro argument names inconsistencyngoto2018-01-161-2/+2
| | | | | | | | | | | * include/ruby/defines.h (RUBY_ALIGNAS): Fix macro definition. Fix compile error with Fujitsu C Compiler (fcc) on Solaris. * include/ruby/defines.h (RUBY_ALIGNOF): Fix macro argument name. Fix compile error with fcc and Oracle Solaris Studio 12.4 on Solaris. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (expr_value_do): factor out COND_PUSH->expr_value->do->COND_POPmame2018-01-161-16/+19
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61868 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: removed PARSER_ARG macronobu2018-01-161-38/+36
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61867 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: expand tokadd_mbcharnobu2018-01-161-11/+9
| | | | | | * parse.y (tokadd_mbchar): renamed and expand callers with p. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61866 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* sizeof(uintptr_t) != sizeof(uintptr_t *)shyouhei2018-01-161-1/+1
| | | | | | | Reported by mame. Thanks. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61865 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: set location of nodes that lexer generatesmame2018-01-161-24/+9
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61864 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: set location of string/literals in the lexer instead of actionsmame2018-01-161-40/+10
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (new_regexp): Fix SEGV of `/#{"\u3042"}#{'い'}/` in non UTF-8mame2018-01-162-4/+7
| | | | | | | Mixing other encoding string literals in one Regexp caused SEGV. This bug was found by CoverityScan. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61862 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (symbol_append): Added to factor out `%i[]` and `%I[]`mame2018-01-161-14/+17
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61861 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * properties.svn2018-01-150-0/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61860 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Add tests for Node code locationsyui-knk2018-01-154-0/+640
| | | | | | | | | | | | | | | | * test/-ext-/ast/test_ast.rb: Add tests for Node code locations. This file tests 1. There are no Node whose code location is default value (#test_not_cared) 2. There are no Node whose children's code locations exceed parent's code location (#test_ranges) * ext/-test-/ast/ast.c, ext/-test-/ast/extconf.rb: Define AST module to help tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61859 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Removes unneeded Ripper/Parser guardsmame2018-01-151-25/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61858 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-01-16svn2018-01-151-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61857 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (new_command_qcall): Receives a block (optional)mame2018-01-151-32/+27
| | | | | | | There were four cases that uses new_command_qcall and then method_add_block. This change factors out the four rules. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61856 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/ruby/test_syntax.rb (test_command_with_cmd_brace_block): Addedmame2018-01-151-0/+5
| | | | | | The bison rules were not covered. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61855 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_console_attr.rb: fix testnobu2018-01-152-3/+19
| | | | | | | * test/-ext-/win32/test_console_attr.rb (reverse_video): fix test when reverse video is set. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61853 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix a typo.hsbt2018-01-151-1/+1
| | | | | | * gc.c: beacuse -> because. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61852 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix a typo.hsbt2018-01-151-1/+1
| | | | | | * win32/win32.c: wrok -> work git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61851 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Removes unreachable warningsmame2018-01-151-29/+14
| | | | | | tIDENTIFIER is now always a local id (except fname). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e