summaryrefslogtreecommitdiff
path: root/sample
AgeCommit message (Collapse)Author
2018-01-12sample/iseq_loader.rb: spelling fixnormal
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-12Fixed typos.hsbt
* sample/trick2013/kinaba/remarks.markdown: algorthim -> algorithm * sample/trick2015/ksk_1/remarks.markdown: Limination -> Limitation git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61788 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-10-08Remove unnecessary `require 'thread'`kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-09-22Update trick2013/yhara for Ruby 2.4nobu
I need to raise LocalJumpError here (for the first "J" of the output "JUST ANOTHER RUBY HACKER"), but this `return` does not raise error in Ruby 2.4. [Fix GH-1703] Author: Yutaka HARA <yutaka.hara+github@gmail.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59989 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-05-03Fix NoMethodError [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58547 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-05-02Use `\A` and `\z` instead of `^` and `$` [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58541 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-05pty/shl.rb: update [ci skip]nobu
* sample/pty/shl.rb: leap exited child process. [ruby-dev:49974] [Bug #13191] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57537 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-04pty/shl.rb: update [ci skip]nobu
* sample/pty/shl.rb: do not manage array length separately. [ruby-dev:49974] [Bug #13191] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57533 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-04pty/shl.rb: update [ci skip]nobu
* sample/pty/shl.rb: use io/console instead of stty. [ruby-dev:49974] [Bug #13191] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57532 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-04pty/shl.rb: update [ci skip]nobu
* sample/pty/shl.rb: stop writer loop when the child exited. PTY::ChildExited no longer raises asynchronously since r20298. [ruby-dev:49974] [Bug #13191] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57531 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-04sample/pty/shl.rb: update samplekazu
* Specify frozen_string_literal: true. * Fix TypeError of raise. * Use a character literal instead of Integer. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-04sample/pty/script.rb: Specify frozen_string_literal: true.kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57529 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-02-04sample/pty/expect_sample.rb: Update samplekazu
* Fix regexp capture scope bug. * Specify frozen_string_literal: true. * Use passive mode. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57528 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-11-29get rid of ambiguous parentheses warningsnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-10-27fix typos [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56498 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-10-07* basictest/test.rb: Adjust spaces in class declarationshsbt
with inheritance. [fix GH-1227] Patch by @adrfer * lib/irb/*: ditto. * lib/prime.rb: ditto. * lib/shell/builtin-command.rb: ditto. * object.c: ditto. * sample/*.rb: ditto. * test/-ext-/method/test_arity.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56371 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-30Use qualified namesnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-08-29import Ruby/OpenSSL 2.0.0.beta.1rhe
* NEWS, {ext,test,sample}/openssl: Import Ruby/OpenSSL 2.0.0.beta.1. ext/openssl is now converted into a default gem. The full commit history since r55538 can be found at: https://github.com/ruby/openssl/compare/08e1881f5663...v2.0.0.beta.1 [Feature #9612] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56027 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-16* common.mk: test-sample was changed to test-basic.hsbt
[Feature #11982][ruby-core:72823] * basictest/runner.rb: ditto. rename from tool/rubytest.rb. * basictest/test.rb: ditto. rename from sample/test.rb. * defs/gmake.mk: picked from r53540 * sample/test.rb: backword compatibility for chkbuild. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-15Revert r53539 and r53540nobu
* basictest/test.rb: revert r53539 because it depends on r53537. * gmake.mk: ditto, revert r53540. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53544 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-15Revert "* common.mk: test-sample was changed to test-basic."naruse
This reverts r53537. Fix chkbuild first. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53542 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2016-01-15* common.mk: test-sample was changed to test-basic.hsbt
[Feature #11982][ruby-core:72823] * basictest/runner.rb: ditto. rename from tool/rubytest.rb. * basictest/test.rb: ditto. rename from sample/test.rb. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53537 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-11* properties.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53043 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-11* append newline at EOF.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-11* sample/trick2015/: added the award-winning entries of TRICK 2015.mame
See https://github.com/tric/trick2015 for the contest outline. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-09* iseq.c: rename methodsko1
RubyVM::InstructionSequence#to_binary_format -> #to_binary RubyVM::InstructionSequence.from_binary_format -> .load_from_binary RubyVM::InstructionSequence.from_binary_format_extra_data -> .load_from_binary_extra_data * iseq.c: fix document of iseq.to_binary. [Fix GH-1134] * sample/iseq_loader.rb: catch up this change. * test/lib/iseq_loader_checker.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2015-12-08* compile.c (iseq_ibf_dump): dump extra data just string length.ko1
* sample/iseq_loader.rb: add using RubyVM::InstructionSequence.from_binary_format_extra_data method (commented out). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52969 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
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