Граф коммитов

2328 Коммитов

Автор SHA1 Сообщение Дата
matz a23075a53e * lib/cgi.rb (CGI::Cookie): tiny typo fix.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4777 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 08:34:35 +00:00
nobu c12ae030ba * eval.c (ruby_run): just return FAILURE instead of parse error
count.  [ruby-list:38569]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4776 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 06:00:57 +00:00
usa 0ac52b49f4 * ext/digest/digest.c (rb_digest_base_alloc): need to initialize
buffer. [ruby-dev:21622]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4775 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 04:19:48 +00:00
matz 87025fdd43 * marshal.c (w_object): dump extended modules as well.
* marshal.c (r_object0): TYPE_USRMARSHAL should restore extended
  modules before invoking marshal_load.  these two fixes are done
  by Masatoshi Seki <m_seki@mva.biglobe.ne.jp>.

* parse.y (yylex): argument parentheses preceded by spaces should
  be warned; not error.  [ruby-talk:84103]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 02:27:56 +00:00
nobu 0c25b62505 ruby-list
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 00:49:35 +00:00
usa 888d06be01 * ext/enumerator/enumerator.c (enumerator_each): avoid VC++ warning.
* ext/syck/syck.h: include stdio.h for definition of FILE.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4770 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 00:32:44 +00:00
why c76c3349e4 * ext/syck/bytecode.c: Checkin of YAML bytecode support.
* ext/syck/gram.c: Ditto.

* ext/syck/syck.c: Ditto.

* ext/syck/token.c: Ditto.

* ext/syck/handler.c: Ditto.

* ext/syck/handler.c: Now using 'tag' rather than 'taguri' in type URIs.

* ext/syck/rubyext.c: Ditto (on both counts).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 23:15:19 +00:00
knu 3982f82b03 * lib/generator.rb: A new library which converts an internal
iterator to an external iterator.

* lib/abbrev.rb: A new library which creates an abbreviation table
  from a list.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4767 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 20:14:20 +00:00
nagai 6bd9229984 ext/tk/sample/demos-en/entry3.rb, ext/tk/sample/demos-jp/entry3.rb :
* new demo-scripts

ext/tk/sample/demos-en/widget, ext/tk/sample/demos-jp/widget :
 * add entries for 'entry3.rb'


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 19:36:09 +00:00
knu 6d9c20d6a3 * test/digest/test_digest.rb: Moved from ext/digest/test.rb.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 19:34:46 +00:00
nagai e437d32cc1 ChangeLog: forgot. sorry
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 18:55:23 +00:00
nagai 382b4ae9a3 ext/tcltklib/tcltklib.c:
* replace Tcl/Tk's vwait and tkwait to switch on threads smoothly and
   avoid seg-fault.
 * add TclTkIp._thread_vwait and _thread_tkwait for waiting on a thread.
   ( Because Tcl/Tk's vwait and tkwait command wait on a eventloop. )
ext/tk/lib/multi-tk.rb:
 * support TclTkIp._thread_vwait and _thread_tkwait
ext/tk/lib/tk.rb:
 * now, TkVariable#wait has 2 arguments.
   If 1st argument is true, waits on a thread. If false, waits on an eventloop.
   If 2nd argument is true, checks existence of rootwidgets. If false, doesn't.
   Default is wait(true, false).
 * add TkVariable#tkwait(arg) which is equal to TkVariable#wait(arg, true)
 * wait_visibility and wait_destroy have an argument for waiting on a
   thread or an eventloop.
 * improve of accessing Tcl/Tk's special variables
ext/tk/lib/tkafter.rb:
 * support 'wait on a thread' and 'wait on an eventloop'


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4762 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 15:25:45 +00:00
nahi 6adad13946 forgot..
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4761 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 15:14:49 +00:00
nobu 0b841783b5 * eval.c (ruby_finalize_0): return the given exit status unless
SystemExit got raised.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 10:09:39 +00:00
nobu 921d595fd4 * intern.h (ruby_stop): never return.
* ruby.h (ruby_run): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 02:53:53 +00:00
akr 839ef7bfbb * lib/pathname.rb (realpath): make ELOOP check bit more robust.
(children): prepend self by default.
  (chroot): obsoleted.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4757 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-13 19:46:07 +00:00
nobu e7257aa72e * eval.c (rb_require_safe): segfault after loading .so.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4754 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-13 17:29:34 +00:00
knu b2de95d4af Add ext/enumerator, a helper module for the Enumerable interface.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4753 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-13 17:09:23 +00:00
eban 046dff7f11 * test/ruby/envutil.rb: use Config::CONFIG["ruby_install_name"],
not "ruby".


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4752 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-13 14:59:25 +00:00
nobu 4de0bb549b * eval.c (rb_feature_p): match by classified suffix.
* eval.c (rb_require_safe): require library in the specified safe
  level.

* variable.c (rb_autoload, rb_autoload_load): restore safe level
  when autoload was called.  [ruby-dev:21338]

* intern.h: prototypes; rb_require_safe.

* test/runner.rb: accept non-option arguments.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4751 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-13 14:57:36 +00:00
matz 1184373d86 * string.c (str_new4): should not preserve FL_TAINT status in the
internal shared string. [ruby-dev:21601]

* string.c (rb_str_new4): ditto.

* eval.c: use EXIT_SUCCESS and EXIT_FAILURE for exit values.

* process.c: ditto. [ruby-dev:38521]

* lib/debug.rb (debug_command): should enter emacs mode when
  assigned any value to the environment variable "EMACS".
  On Meadow, (getenv "EMACS") is "meadow".


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-13 13:05:24 +00:00
eban 5d0f8cdc6f * ext/win32ole/extconf.rb: check "windows.h", not "windows".
[ruby-talk:84051]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4747 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-12 05:46:59 +00:00
eban d430692b95 * lib/rexml/quickpath.rb (REXML::QuickPath::match):
escape '[' to avoid warning.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4746 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-11 08:10:07 +00:00
akr 31fd8aa681 * lib/pathname.rb (realpath): check existence of the file.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4744 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-11 07:09:19 +00:00
akr b01f0cab31 * lib/pathname.rb (realpath): re-implemented.
(realpath_root?, realpath_rec): removed


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4743 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-11 06:42:41 +00:00
akr 6fc32eb8bb * lib/pathname.rb (realpath_rec): fix handling of symlink to absolute
path.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-11 05:37:41 +00:00
shugo 764722dc27 * lib/monitor.rb: handle exceptions correctly. Thanks, Gennady
Bystritsky.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4740 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-11 01:20:45 +00:00
nobu 3354489d06 * eval.c (is_defined): inheritance line adjustment as like as
rb_call_super().


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4735 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 22:50:57 +00:00
matz 90a88ab9a0 * marshal.c (r_object0): remove unnecessary iv restoration for
USRMARSHAL. [ruby-dev:21582]

* marshal.c (w_object): dump generic instance variables from
  a string from '_dump'.

* variable.c (rb_generic_ivar_table): return 0 if obj's FL_EXIVAR
  is not set.

* time.c (time_dump): copy instance variables to dumped string, to
  be included in the marshaled data.

* bignum.c (rb_big2ulong): add range check to ensure round trip.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4734 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 17:45:53 +00:00
gotoyuzo 80549d5f17 * ext/openssl/ossl_x509name.c (ossl_x509name_initialize): add
optional argument to specify the DirectoryString type
  (ASN1::UTF8STRING by default). RFC3280 deprecates PrintableString
  for DirectoryString, and strongly requires to use UTF8String for
  all certificates issued after December, 31 2003.

* ext/openssl/lib/openssl/x509.rb (X509::Name::parse): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4733 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 16:20:22 +00:00
nobu 67a98cd52f * eval.c (rb_thread_start_0): prevent thread from GC.
[ruby-dev:21572]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 14:50:24 +00:00
nobu 8022abdc69 * eval.c (rb_thread_start_0): non-volatile should be restored from
volatile.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4731 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 10:11:48 +00:00
nobu dd3eed4f08 * eval.c (proc_save_safe_level, proc_get_safe_level,
proc_set_safe_level): save/restore safe level 1..4.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4730 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 08:43:39 +00:00
matz 0b2e94b2ab * pack.c (uv_to_utf8): change message to "out of range", since
negative values are not "too big". [ruby-dev21567]

* marshal.c (w_object): should pass the value of "weak" to
  w_object().  [ruby-dev:21555] and [ruby-dev:21561]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 06:46:40 +00:00
nobu 582b7e1ca9 * eval.c (rb_set_end_proc, rb_exec_end_proc): restore safe level.
[ruby-dev:21557]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4728 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 05:05:43 +00:00
nobu 894d8d9e61 * eval.c (rb_yield_0): no error if block is empty.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4727 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-09 01:51:08 +00:00
nobu 517f019851 commit miss.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4724 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-08 22:40:22 +00:00
nobu c0e5a7c63f * eval.c (localjump_error): id should be ID.
* eval.c (rb_eval): nd_rval is set in copy_node_scope().

* eval.c (rb_yield_0): unused variable.

* eval.c (rb_yield_0): nothing to do for empty node.

* eval.c (call_end_proc, proc_invoke): adjust backtrace in END.
  [ruby-dev:21551]

* eval.c (rb_thread_start_0): set the value by break as the result.
  [ruby-dev:21552]

* eval.c (rb_thread_start_0, rb_thread_raise, rb_callcc): save
  variables across THREAD_SAVE_CONTEXT.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-08 21:43:36 +00:00
ntalbott 09d2946061 * lib/test/unit.rb: removed installation instructions.
* lib/test/unit/ui/testrunnermediator.rb: moved the run flag to a more
	  central location.

	* lib/test/unit.rb: ditto.

	* lib/test/unit.rb: extracted the running code in to AutoRunner.

	* lib/test/unit/autorunner.rb: added.

	* lib/test/unit/collector/objectspace.rb: extracted common test
	  collection functionality in to a module.

	* lib/test/unit/collector.rb: ditto; added.

	* test/testunit/collector/test_objectspace.rb: ditto.

	* lib/test/unit/collector/dir.rb: added. Supports collecting tests out
	  of a directory structure.

	* test/testunit/collector/test_dir.rb: added.

	* test/runner.rb: simplified to use the new capabilities.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-08 13:21:28 +00:00
nahi cd8d08b532 * test/ruby/test_beginendblock.rb: add tests for nested BEGIN/END.
* test/ruby/beginmainend.rb: add tests for nested BEGIN/END.

* test/ruby/endblockwarn.rb: new file added to test of END-in-method warning.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4716 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-07 06:27:11 +00:00
akr 0a5f6fd37d define Fcntl::O_ACCMODE instead of Fcntl::ACCMODE to be consist with
other constants.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4715 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-07 03:30:55 +00:00
akr 4f6558a4ec * ext/fcntl/fcntl.c (Init_fcntl): define Fcntl::ACCMODE.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4714 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-07 03:24:11 +00:00
akr 9c6cfb5672 * ext/socket/extconf.rb: useless assignment removed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4713 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-07 01:04:07 +00:00
nobu cda830ff33 * test/ruby/test_beginendblock.rb (test_endinmethod): END{} is now
allowed in eval.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4712 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-07 00:13:29 +00:00
nobu 6fc88be3d9 * parse.y (stmt): should not expand mrhs if lhs is solely starred.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4711 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06 19:15:29 +00:00
matz 8a4abe47ca * parse.y (stmt): rhs of multiple assignment should not be
expanded using "to_a". [ruby-dev:21527]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4710 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06 17:59:53 +00:00
gotoyuzo 0dd4fde745 * ext/openssl/ossl_asn1.c (ossl_asn1_get_asn1type): use appropriate
free function for ASN1_OBJECT.

* ext/openssl/ossl_asn1.c (ossl_asn1obj_get_sn): add new function for
  ASN1::ObjectId#sn; it returns short name text representation of OID.

* ext/openssl/ossl_asn1.c (ossl_asn1obj_get_ln): add new function for
  ASN1::ObjectId#ln; it returns long name text representation of OID.

* ext/openssl/ossl_asn1.c (ossl_asn1obj_get_oid): add new function for
  ASN1::ObjectId#oid; it returns numerical representation of OID.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4709 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06 16:55:00 +00:00
nahi 11d2edffe6 * lib/csv.rb (IOReader, BasicWriter): call binmode when a given IO
respond_to?(:binmode).  record separator was wrong when you gave text mode IO
  to Reader.parse and Writer.generate.

* test/csv/test_csv.rb: add tests for above change.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4708 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06 14:03:58 +00:00
akr 26d111540e * ext/socket/extconf.rb: check recvmsg even if sendmsg is exists.
* ext/socket/socket.c (thread_read_select): restored.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4707 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06 11:11:07 +00:00
nobu 2a07445e0b * marshal.c (w_object): wrong method name in the message.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4706 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-06 07:23:40 +00:00