aboutsummaryrefslogtreecommitdiffstats
path: root/ext/ripper
Commit message (Collapse)AuthorAgeFilesLines
* ripper: fix ripper.Enobu2016-04-252-5/+4
| | | | | | | | | * ext/ripper/depend (ripper.E): add missing $(INCFLAGS). * ext/ripper/tools/strip.rb: insert an empty line for blank or line directive lines. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54761 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update dependencies.akr2016-04-111-0/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54544 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix Ripper.lex error in dedenting squiggly heredocnobu2016-02-021-1/+1
| | | | | | | | * 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
* ripper: clean timestampnobu2016-01-191-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/ripper/depend: Just like BSDmake, nmake also recognize the rule ofusa2016-01-071-3/+2
| | | | | | | | | ".eventids2.check" as inference one. but nmake is not cheated by macro. this fixes build failure introduced at r53448. see also the commit log of r53452. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53453 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix r53448naruse2016-01-071-2/+3
| | | | | | | | avoid mkmf.rb's suffix rule scanner (lib/mkmf.rb:2085), it detects suffix rule from depend file and adds .SUFFIXES. It breaks bsdmake to generate check file named ".eventids2.check". git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53452 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mkmf.rb: library installation messagesnobu2016-01-071-1/+4
| | | | | | | | * lib/mkmf.rb (configuration, dummy_makefile, create_makefile): show library installation messages only when any files need to be updated. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53448 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* handle ext/ as r53141naruse2015-12-1610-0/+10
| | | | | | | | g -L frozen_string_literal ext/**/*.rb|xargs ruby -Ka -e'ARGV.each{|fn|puts fn;open(fn,"r+"){|f|s=f.read.sub(/\A(#!.*\n)?(#.*coding.*\n)?/,"\\&# frozen_string_literal: false\n");f.rewind;f.write s}}' git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: indented hereocnobu2015-12-072-6/+75
| | | | | | * parse.y: add heredoc <<~ syntax. [Feature #9098] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52916 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper/lexer.rb: dispatch aliasnobu2015-11-281-5/+5
| | | | | | | * ext/ripper/lib/ripper/lexer.rb: alias same methods instead of eval for each events. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52776 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper/core.rb: share handlersnobu2015-11-281-35/+21
| | | | | | | | * ext/ripper/lib/ripper/sexp.rb (SexpBuilderPP): share scanner event handlers and most of parser event handlers with SexpBuilder. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52775 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper/core.rb: dispatch aliasnobu2015-11-281-10/+11
| | | | | | | * ext/ripper/lib/ripper/core.rb: alias same methods instead of eval for each events. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Rename DOTQ to ANDDOTnobu2015-11-101-1/+1
| | | | | | | * defs/id.def, parse.y: Switch internal token name to reflect current form of safe-call operator. [Fix GH-1090] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52525 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* symbol.c: dotq in rippernobu2015-10-251-0/+1
| | | | | | * 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
* Update dependencies.akr2014-12-191-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48898 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update dependencies.akr2014-11-271-4/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48614 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update dependency.akr2014-11-211-1/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48526 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* common.mk: fix build errornobu2014-11-191-1/+1
| | | | | | | | | | * common.mk (ext/ripper/ripper.c): VPATH is always ../.. from ext/ripper. * ext/ripper/depend (.y.c): VPATH is not needed for an intermediate file. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48499 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * common.mk (ext/ripper/ripper.c): pass build directory as VPATH.naruse2014-11-191-1/+1
| | | | | | * ext/ripper/depend (.y.c): use VPATH for y.tab.c. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48493 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Dependencies updated.akr2014-11-181-13/+14
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48483 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * internal.h: Include ruby.h and ruby/encoding.h to beakr2014-11-151-0/+1
| | | | | | | | includable without prior inclusion. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48447 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Mark auogenerated part.akr2014-11-151-0/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48441 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * common.mk: Remove comments in Dependency lines.akr2014-11-151-24/+24
| | | | | | | | | | | | Notified by usa. * enc/depend: Ditto. * ext/**/depend: Ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48434 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * tool/update-deps: Extend to fix dependencies.akr2014-11-151-13/+26
| | | | | | | | | | | | * common.mk: Dependencies updated by tool/update-deps. * enc/depend: Ditto. * ext/**/depend: Ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48431 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* eventids2.c: reduce sizenobu2014-10-282-5/+11
| | | | | | | * ext/ripper/eventids2.c (token_assoc): reduce size. unsigned short can hold 65535 at least. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* eventids2.c: reduce sizenobu2014-10-271-257/+264
| | | | | | | * ext/ripper/eventids2.c (token_to_eventid): reduce relocations and element size. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper/tools/generate.rb: shorten generated sourcenobu2014-10-271-11/+14
| | | | | | | | | * ext/ripper/tools/generate.rb (generate_eventids1): shorten generated source. * ext/ripper/tools/generate.rb (generate_eventids2): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: Ripper.sexp returns errornobu2014-10-261-2/+6
| | | | | | | * 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
* parse.y: quoted ID keynobu2014-09-201-0/+3
| | | | | | | * 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
* * ext/ripper/lib/ripper/lexer.rb: [DOC] use lower case version of corezzak2014-02-071-2/+2
| | | | | | | | classes when referring to return value, since we aren't directly talking about the class. Patch by Jonathan Jackson [Bug #9483] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44878 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: remove "f" suffix [ruby-core:57966] [Feature #9042]nobu2013-11-101-3/+0
| | | | | | | | | | | | | | | | | | | | | | 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
* * NEWS: Add note about frozen string literalscharliesome2013-09-021-0/+3
| | | | | | | | | | | | | | | | | * 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
* eventids2.c: new literalsnobu2013-08-021-0/+6
| | | | | | | | * 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
* * lib/mkmf.rb (MakeMakefile#create_makefile): remove {$(VPATH)} othernaruse2013-04-131-2/+2
| | | | | | | | than nmke. * ext/ripper/depend: use VPATH expecting removed by above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/mkmf.rb (MakeMakefile#create_makefile): output new macrousa2013-04-131-2/+2
| | | | | | | | | disthdrdir to specify the path of id.h, parse.h and etc. * ext/ripper/depend: use above macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix building ripper: parse.h and id.h doesn't need directorynaruse2013-04-131-5/+5
| | | | | | r40275 breaks Unix build. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40277 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/ripper/depend: parse.h and id.h may be created on topdir.usa2013-04-131-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper/depend: fix out-of-place buildnobu2013-04-131-2/+2
| | | | | | | * ext/ripper/depend (ripper.o): fix out-of-place build. probes.h depends on the platform, so it cannot be in $(top_srcdir). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/mkmf.rb: Add ruby/ruby.h, ruby/missing.h, ruby/intern.h,akr2013-04-131-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ruby/st.h and ruby/subst.h for ruby_headers in generated Makefile. * ext/-test-/old_thread_select/depend: Update dependencies. * ext/-test-/wait_for_single_fd/depend: Ditto. * ext/bigdecimal/depend: Ditto. * ext/curses/depend: Ditto. * ext/digest/bubblebabble/depend: Ditto. * ext/digest/depend: Ditto. * ext/digest/md5/depend: Ditto. * ext/digest/rmd160/depend: Ditto. * ext/digest/sha1/depend: Ditto. * ext/digest/sha2/depend: Ditto. * ext/dl/callback/depend: Ditto. * ext/dl/depend: Ditto. * ext/etc/depend: Ditto. * ext/nkf/depend: Ditto. * ext/objspace/depend: Ditto. * ext/pty/depend: Ditto. * ext/readline/depend: Ditto. * ext/ripper/depend: Ditto. * ext/sdbm/depend: Ditto. * ext/socket/depend: Ditto. * ext/stringio/depend: Ditto. * ext/strscan/depend: Ditto. * ext/syslog/depend: Ditto. * ext/-test-/num2int/depend: Removed. * ext/dbm/depend: Ditto. * ext/fcntl/depend: Ditto. * ext/gdbm/depend: Ditto. * ext/racc/cparse/depend: Ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40268 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vpath.rb: hack for msys makenobu2013-01-201-1/+1
| | | | | | | | * tool/vpath.rb (VPath#def_options): hack for msys make, which converts a command line argument to non-msys command seems like a path list automagically. [Bug #7710] [ruby-core:51489] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38886 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Improve rdoc for Ripper, based on a patch by Oscar Del Ben [github:219]marcandre2012-12-081-1/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38273 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/ripper/lib/ripper.rb:zzak2012-09-211-1/+1
| | | | | | | | Match sample output to Ripper.sexp from current trunk version. [Bug #6929] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37008 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/ripper/lib/ripper.rb: Documentation for Ripper.zzak2012-09-191-8/+7
| | | | | | | | +:void_stmt+ is meaningless [Bug #6929] [ruby-core:47507] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36992 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/ripper/lib/ripper.rb: Documentation for Ripper.zzak2012-09-125-20/+100
| | | | | | | | | | | * ext/ripper/lib/ripper/lexer.rb: ditto. * ext/ripper/lib/ripper/sexp.rb: ditto. * ext/ripper/lib/ripper/filter.rb: ditto. * ext/ripper/lib/ripper/core.rb: ditto. [Bug #6929] [ruby-core:47309] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36954 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* id.h: independent from parse.hnobu2012-08-311-1/+3
| | | | | | | * template/id.h.tmpl, tool/id2token.rb: make id.h independent from parse.h, and make parse.c dependent on it instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36864 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * common.mk (vm_backtrace.o): Added missing dependencies.yugui2012-08-221-1/+1
| | | | | | | | * ext/nkf/depend (nkf.o): ditto. * ext/ripper/depend (ripper.o) ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36767 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * parse.y: added symbols and qsymbols productions for %i and %Itenderlove2012-07-241-0/+6
| | | | | | | | | | | | | | | | support. %i{ .. } returns a list of symbols without interpolation, %I{ .. } returns a list of symbols with interpolation. Thanks to Josh Susser for inspiration of this feature. [Feature #4985] * ext/ripper/eventids2.c: added ripper events for %i and %I. * test/ripper/test_parser_events.rb: ripper tests * test/ripper/test_scanner_events.rb: ditto * test/ruby/test_array.rb: test for %i and %I behavior git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/ripper/extconf.rb: Use an exception instead of barekosaki2012-05-181-2/+1
| | | | | | Logging.message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35687 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * parse.y (assoc, parser_yylex): add syntax to splat keyword hash.nobu2012-04-281-0/+1
| | | | | | | | | | [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
* * encoding.c (rb_enc_codepoint_len): Use UNREACHABLE to avoid "controldrbrain2012-04-131-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | reaches end of non-void function" warnings. [ruby-trunk - Bug #6066] * re.c (name_to_backref_number): ditto. * object.c (rb_Float): ditto. * io.c (io_readpartial): ditto. * io.c (io_read_nonblock): ditto. * pack.c (rb_uv_to_utf8): ditto. * proc.c (rb_method_entry_arity): ditto. * vm_method.c (rb_f_notimplement): ditto. * struct.c (rb_struct_aset_id): ditto. * class.c (rb_scan_args): ditto. * process.c (rlimit_resource_type): ditto. * process.c (rlimit_resource_value): ditto. * process.c (p_uid_switch): ditto. * process.c (p_gid_switch): ditto. * ext/digest/digest.c (rb_digest_instance_update): ditto. * ext/digest/digest.c (rb_digest_instance_finish): ditto. * ext/digest/digest.c (rb_digest_instance_reset): ditto. * ext/digest/digest.c (rb_digest_instance_block_length): ditto. * ext/bigdecimal/bigdecimal.c (BigDecimalCmp): ditto. * ext/dl/handle.c (rb_dlhandle_close): ditto. * ext/tk/tcltklib.c (pending_exception_check0): ditto. * ext/tk/tcltklib.c (pending_exception_check1): ditto. * ext/tk/tcltklib.c (ip_cancel_eval_core): ditto. * ext/tk/tcltklib.c (lib_get_reltype_name): ditto. * ext/tk/tcltklib.c (create_dummy_encoding_for_tk_core): ditto. * ext/tk/tkutil/tkutil.c (tk_hash_kv): ditto. * ext/openssl/ossl_ssl.c (ossl_ssl_session_reused): ditto. * ext/openssl/ossl_pkey_ec.c (ossl_ec_key_dsa_verify_asn1): ditto. * ext/openssl/ossl_pkey_ec.c (ossl_ec_point_is_at_infinit): ditto. * ext/openssl/ossl_pkey_ec.c (ossl_ec_point_is_on_curve): ditto. * ext/fiddle/conversions.c (generic_to_value): ditto. * ext/socket/raddrinfo.c (rsock_io_socket_addrinfo): ditto. * ext/socket/socket.c (sock_s_getnameinfo): ditto. * ext/ripper/eventids2.c (ripper_token2eventid): ditto. * cont.c (return_fiber): ditto. * dmydln.c (dln_load): ditto. * vm_insnhelper.c (vm_search_normal_superclass): ditto. * bignum.c (big_fdiv): ditto. * marshal.c (r_symlink): ditto. * marshal.c (r_symbol): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e