summaryrefslogtreecommitdiff
path: root/sample
AgeCommit message (Collapse)Author
2015-12-08* remove trailing spaces.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52950 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-08* introduce new ISeq binary format serializer/de-serializerko1
and a pre-compilation/runtime loader sample. [Feature #11788] * iseq.c: add new methods: * RubyVM::InstructionSequence#to_binary_format(extra_data = nil) * RubyVM::InstructionSequence.from_binary_format(binary) * RubyVM::InstructionSequence.from_binary_format_extra_data(binary) * compile.c: implement body of this new feature. * load.c (rb_load_internal0), iseq.c (rb_iseq_load_iseq): call RubyVM::InstructionSequence.load_iseq(fname) with loading script name if this method is defined. We can return any ISeq object as a result value. Otherwise loading will be continue as usual. This interface is not matured and is not extensible. So that we don't guarantee the future compatibility of this method. Basically, you should'nt use this method. * iseq.h: move ISEQ_MAJOR/MINOR_VERSION (and some definitions) from iseq.c. * encoding.c (rb_data_is_encoding), internal.h: added. * vm_core.h: add several supports for lazy load. * add USE_LAZY_LOAD macro to specify enable or disable of this feature. * add several fields to rb_iseq_t. * introduce new macro rb_iseq_check(). * insns.def: some check for lazy loading feature. * vm_insnhelper.c: ditto. * proc.c: ditto. * vm.c: ditto. * test/lib/iseq_loader_checker.rb: enabled iff suitable environment variables are provided. * test/runner.rb: enable lib/iseq_loader_checker.rb. * sample/iseq_loader.rb: add sample compiler and loader. $ ruby sample/iseq_loader.rb [dir] will compile all ruby scripts in [dir]. With default setting, this compile creates *.rb.yarb files in same directory of target .rb scripts. $ ruby -r sample/iseq_loader.rb [app] will run with enable to load compiled binary data. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52949 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-06-12* sample/exyacc.rb: Fix some typos.hsbt
* sample/list.rb: ditto. * sample/trick2013/kinaba/remarks.markdown: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50846 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-05-17default colorsnobu
* bootstraptest/runner.rb, sample/test.rb, test/lib/test/unit.rb: shared the default colors from test/colors file. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50517 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-05-17reset colorsnobu
* bootstraptest/runner.rb, sample/test.rb, test/lib/test/unit.rb: reset for each colors. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50516 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-09fix a typo in comment [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48345 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-02* properties.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48238 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-11-02* sample/simple-bench.rb: added to measure performance of simpleko1
lines. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48237 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-10-07normalize reference to Timeout::Errornormal
From: John Bachir <j@jjb.cc> * bootstraptest/test_io.rb (assert_finish): normalize rescue for Timeout::Error * lib/net/ftp.rb (Net#read_timeout): ditto for doc * lib/resolv.rb (Resolv::ResolvTimeout): ditto for subclass * lib/webrick/httprequest.rb (_read_data): ditto for rescue * sample/timeout.rb (p timeout): ditto for call * test/drb/drbtest.rb (test_06_timeout): ditto * test/ruby/test_readpartial.rb (test_open_pipe): ditto * test/thread/test_queue.rb (test_queue_thread_raise): ditto * thread.c (rb_thread_s_handle_interrupt): ditto for doc [ruby-core:65481] [misc #10339] TimeoutError is a legacy constant, Timeout::Error is the canonical constant. This patch normalizes all code and comments to reference Timeout::Error. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-21* lib/rinda/ring.rb: split executable code into sample directory.hsbt
* sample/rinda-ring.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-21* lib/drb/acl.rb: split executable code into sample directory.hsbt
* sample/drb/acl.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47235 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-21* lib/net/imap.rb: split executable code into sample directory.hsbt
* sample/net-imap.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47232 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-10sample: use IO::NULLnobu
* sample/cgi-session-pstore.rb: use IO::NULL instead of hard coded device name for portability. * sample/drb/ring_place.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47124 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-10* lib/cgi/session/pstore.rb: separated sample code.hsbt
* lib/open3.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47122 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-26* lib/weakref.rb: split executable code into sample directory.hsbt
* sample/weakref.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46967 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-26* lib/delegate.rb: split executable code into sample directory.hsbt
* sample/delegate.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46966 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-23* lib/benchmark.rb: split executable code into sample directory.hsbt
* sample/benchmark.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46922 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-23* lib/tempfile.rb: split executable code into sample directory.hsbt
* sample/tempfile.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46920 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-23* lib/pstore.rb: split executable code into sample directory.hsbt
* sample/pstore.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46917 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-25* remove trailing spaces, append newline at EOF.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44404 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-25* sample/trick2013/: added the award-winning entries of TRICK 2013.mame
See https://github.com/tric/trick2013 for the contest outline. (Matz has approved the attachment.) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44403 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-16* sample/exyacc.rb: Fix typo in a variable namea_matsuda
s/grammer/grammar/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44240 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09* ext/curses, sample/curses: removed curses.shugo
* NEWS: added an entry for the above change. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44089 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-11-03* sample/test.rb: Make temporary file names unique.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43521 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-29* ext/curses/curses.c: [DOC] Update location of sampleszzak
* samples/curses/*: Move Curses samples and refactor from mixin The samples are included in rdoc for module and use of mixin is confusing git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42241 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-23* properties.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-23* sample/drb/README*.rdoc: [DOC] migrate DRb sample READMEs to rdoczzak
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42128 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-21opttest.rb: adust stylesnobu
* sample/optparse/opttest.rb: adjust indent and block stypes. use do/end wholly, put spaces around operators, and deep indent in parentheses. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42099 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-20* sample/*: whitespace patch by Sergio Campama [Fixes GH-364]zzak
https://github.com/ruby/ruby/pull/364 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-18* lib/cgi.rb: [DOC] Capitalize "Ruby" in documentation [Fixes GH-341]zzak
Patch by Dave Worth https://github.com/ruby/ruby/pull/341 * lib/webrick.rb: ditto * lib/scanf.rb: ditto * lib/xmlrpc/config.rb: ditto * lib/resolv.rb: ditto * lib/e2mmap.rb: ditto * lib/fileutils.rb: ditto * lib/mkmf.rb: ditto * lib/cgi/session.rb: ditto * lib/yaml.rb: ditto * lib/erb.rb: ditto * lib/irb.rb: ditto * lib/tracer.rb: ditto * lib/net/http.rb: ditto * ext/syslog/lib/syslog/logger.rb: ditto * sample/pty/expect_sample.rb: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-06-25fix typo by @daveworth [fix GH-340]hsbt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41617 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-05-19fix typos inspired by r40825kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40829 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-25* lib/drb/drb.rb: Improved documentation by adding or hiding methods.drbrain
* lib/drb/eq.rb: ditto. * lib/drb/extserv.rb: ditto. * lib/drb/gw.rb: ditto. * lib/drb/invokemethod.rb: ditto. * lib/drb/observer.rb: ditto. * lib/drb/ssl.rb: ditto. * lib/drb/timeridconv.rb: ditto. * lib/drb/unix.rb: ditto. * sample/drb/gw_cu.rb: Fixed bug in DRb gateway sample. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-15test: tty optionnobu
* bootstraptest/runner.rb (main): add --tty option to output like terminal, for mingw/mswin on cygwin. * lib/test/unit.rb (Test::Unit::Options#setup_options): ditto. * sample/test.rb (Progress#initialize): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38821 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-11test.rb: show messages in one linenobu
* sample/test.rb (Progress#initialize): add --verbose option and show messages in one line unless --verbose is given. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38330 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-08-11remove trailing spaceskazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36681 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-09 * sample/coverage.rb: fix typo.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36676 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-07-11sample/test.rb: fix standalonenobu
* sample/test.rb (Progress#initialize): no rotators when STDOUT is also tty, that is directly invoked but not from tool/rubytest.rb. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36366 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-07-10sample/test.rb: Progress::Rotatornobu
* sample/test.rb (Progress): refactor to separate Rotator. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36353 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-07-10sample/test.rb: newlinenobu
* sample/test.rb (PROGRESS.finish): newline after each tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36352 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-26test: scan ARGVnobu
* sample/test.rb: scan ARGV all. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-26test: reduce output if succedednobu
* bootstraptest/runner.rb (exec_test): reduce output if succeded. * sample/test.rb (PROGRESS.finish): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-15test: TEST_COLORSnobu
* bootstraptest/runner.rb (main): fixed typo. * lib/test/unit.rb (Test::Unit::Runner#_prepare_run): ditto. * sample/test.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36097 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-15test: TEST_COLORSnobu
* bootstraptest/runner.rb (main): customize colors by dircolors-like style environment variable TEST_COLORS. * lib/test/unit.rb (Test::Unit::Runner#_prepare_run): ditto. * sample/test.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36095 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-15test: unknown --color argumentnobu
* bootstraptest/runner.rb (main): warn unknown --color argument. * sample/test.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36094 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-06-04win32: VT100 escapenobu
* win32/win32.c (constat_apply): apply VT100 functions. [ruby-core:44958] [Feature #6418] * win32/win32.c (constat_parse): parse some VT100 escape sequence. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35907 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-05-30color optionnobu
* bootstraptest/runner.rb, sample/test.rb: add --color option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35840 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-05-08tests: customizable colorsnobu
* bootstraptest/runner.rb, lib/test/unit.rb, sample/test.rb: customizable colors. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e