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

10242 Коммитов

Автор SHA1 Сообщение Дата
matz 58c070aa9b * enum.c (enum_take_while): returns Enumerator if no block given.
* enum.c (enum_drop_while): ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-30 08:15:12 +00:00
matz efedaa432b * hash.c (rb_hash_eql): recursive comparison should be based on
eql?  [ruby-core:13803]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-30 05:26:59 +00:00
nobu 058ec52c0d * parse.y (stmt): remove unnecessary NODE_BEGIN. [ruby-core:13814]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-29 07:59:12 +00:00
naruse 0cf0b82418 * ext/json, lib/json, test/json: Update to JSON 1.1.2.
(RubyForge#15447)

* math.c: fix typo.
-- 

M    ChangeLog
M    math.c
M    ext/json/ext/generator/generator.c
M    ext/json/ext/parser/parser.rl
M    ext/json/ext/parser/parser.c
M    lib/json/version.rb
M    lib/json/editor.rb
M    lib/json/common.rb
M    lib/json/pure/parser.rb
M    test/json/test_json_unicode.rb
M    test/json/test_json_fixtures.rb
M    test/json/test_json_generate.rb
M    test/json/test_json_addition.rb
M    test/json/test_json.rb
M    test/json/runner.rb


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14044 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-28 09:22:57 +00:00
akr 6272cf8ecd add test for enumerator.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14043 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-28 07:48:23 +00:00
ko1 c2aef47c84 * insnhelper.ci (vm_invoke_block): should splat args.
[ruby-dev:32392]
* test/ruby/test_yield.rb: add tests for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-28 07:31:10 +00:00
nobu 49b1513d1e * ext/extmk.rb (extract_makefile): use dldflags instead of DLDFLAGS to
get rid of mixing $LDFLAGS and $ARCH_FLAG.

* lib/mkmf.rb (configuration): ditto.

* lib/mkmf.rb (create_makefile): support for extensions which has no
  shared object.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-28 05:43:17 +00:00
akr c3c320c40a test exceptions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14040 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-28 02:45:12 +00:00
akr f63918441e longer timeout.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14036 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 22:53:28 +00:00
nobu 22c18f1e1b * 2007-11-28
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14035 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 17:44:21 +00:00
nobu 6eea7a7c71 * bignum.c (big2str_find_n1): removed extraneous element.
[ruby-dev:32351], [ruby-dev:32365]

* bignum.c (big2str_find_n1): returns necessary digits now.

* sprintf.c (remove_sign_bits): extends sign bit first.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14034 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 17:42:12 +00:00
ko1 0cdd3bced5 * compile.c (iseq_compile_each): "when *[],1" dumps core.
a patch from Yusuke ENDOH <mame AT tsg.ne.jp>.  [ruby-dev:32350]
* bootstraptest/test_syntax.rb: add a test for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14033 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 06:54:58 +00:00
ko1 1bed0ccca8 * compile.c (iseq_compile_each): "a[*b] += 1" dumps core.
a patch from Yusuke ENDOH <mame AT tsg.ne.jp>.  [ruby-dev:32354]
* bootstraptest/test_syntax.rb: add a test for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14032 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 06:45:01 +00:00
ko1 b0986a8f82 * compile.c, insns.def: change return value of "defined?"
for $&, $1, ... .  If such variables are defined,
  return "global-variable".
* test/ruby/test_defined.rb: add tests.
* bootstraptest/test_syntax.rb: fix a test.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14031 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 04:43:54 +00:00
matz 8e09ab045f lib/finalizer.rb: removed
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14030 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 02:58:11 +00:00
ko1 1152eef81d * insns.def: fix typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 02:56:15 +00:00
ko1 db2b0037fd * test_beginendblock.rb: add loop to wait signal.
[ruby-dev:32332]



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14028 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 02:28:28 +00:00
akr f5ee0fd521 * include/ruby/encoding.h, encoding.c, re.c, string.c, parse.y:
rename ENC_CODERANGE_SINGLE to ENC_CODERANGE_7BIT.
  rename ENC_CODERANGE_MULTI to ENC_CODERANGE_8BIT.
  Because single byte 8bit character, such as Shift_JIS 1byte katakana,
  is represented by ENC_CODERANGE_MULTI even if it is not multi byte.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14027 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 02:21:17 +00:00
ko1 9c7aab17a5 * eval.c (rb_method_missing): fix stack trace.
* bootstraptest/test_knownbug.rb: move solved tests.
* bootstraptest/test_method.rb, test/ruby/test_regexp.rb: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14026 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 01:47:34 +00:00
ko1 329484693a * insns.def, compile.c: fix to allow dsym for alias/undef.
[ruby-dev:32355]
* bootstraptest/test_method.rb: add tests for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-27 01:02:30 +00:00
seki 724de18989 * lib/drb/extserv.rb (initialize, stop_service): synchronize with
ExtServManager.

	* test/drb/test_drb.rb (TestDRbEval): ignored.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14024 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 14:24:29 +00:00
akr bfc502fe51 more tests.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14023 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 13:05:08 +00:00
matz 35adbb5f88 * sprintf.c (rb_str_format): always trim preceding zeros.
[ruby-dev:32351]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 09:38:49 +00:00
akr cbd72b86da * re.c (Init_Regexp): new method Regexp#fixed_encoding?
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14021 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 08:33:11 +00:00
keiju e6140f3e3c * lib/complex.rb: be able to create Complex(0, -0.0). [ruby-list:44268]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 04:33:21 +00:00
akr 2ed2078909 fix coderange.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14019 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 02:49:44 +00:00
akr 0dc9be63a5 * re.c (rb_reg_fixed_encoding_p): extracted from rb_reg_prepare_re and
rb_reg_s_union.
  (rb_reg_s_union): refactored.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14018 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 02:27:59 +00:00
nobu cf74bde83c * io.c (rb_read_internal, rb_sysopen_internal): remove C99 dependency.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14017 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 01:44:23 +00:00
matz 691df99d6a * test/ruby/test_eval.rb (TestEval::test_instance_eval_cvar):
updated not to modify class variable of Object class.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14016 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 01:31:20 +00:00
nobu e42d6b8862 * bootstraptest/test_{io,marshal}.rb, lib/rubygems/require_paths_builder.rb test/ruby/test_m17n.rb: set properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14015 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 01:20:48 +00:00
matz f7bd951bea * variable.c (rb_f_global_variables): variable names should not
duplicate.  [ruby-dev:32344]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14014 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-26 01:17:17 +00:00
akr b2e60b2ce7 * include/ruby/encoding.h (rb_enc_str_asciionly_p): declared.
(rb_enc_str_asciicompat_p): defined.

* re.c (rb_reg_initialize_str): use rb_enc_str_asciionly_p.
  (rb_reg_quote): return ascii-8bit string if the argument is
  ascii-only to generate encoding generic regexp if possible.
  (rb_reg_s_union): fix encoding handling.  [ruby-dev:32094]

* string.c (rb_enc_str_asciionly_p): defined.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14013 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-25 13:25:34 +00:00
akr 43090c9f50 test_to_s refined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14012 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-25 07:47:51 +00:00
drbrain 369697bceb Import fast-loading gem_prelude.rb from RubyGems.
Import RubyGems r1516.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14011 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-25 03:26:36 +00:00
akr f90fdbfc73 add more roundtrip tests.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14010 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-25 00:38:33 +00:00
akr 07ba43734d add test for printf format %x, %o and %b.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14009 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-24 16:32:10 +00:00
akr 1d8519ad86 add a test for [ruby-dev:32351].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14008 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-24 16:08:10 +00:00
ko1 c4c151bed8 * io.c: add rb_read_internal() as blocking function.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14007 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 08:35:29 +00:00
ko1 2a2e4bbbc3 * vm.c: fix comment.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14006 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 08:34:34 +00:00
ko1 1e4278c98d * bootstraptest/test_knownbug.rb: move solved tests.
* bootstraptest/test_io.rb, test_marshal.rb, test_objectspace.rb:
  ditto.
* test/ruby/test_integer.rb, test_regexp.rb: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14005 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 08:33:32 +00:00
akr e265a55740 fix va_start arg.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 07:15:17 +00:00
akr 0d89567252 * struct.c (rb_struct_alloc_noinit): new function.
(rb_struct_define_without_accessor): add allocator to the arguments.

* range.c (range_alloc): re-introduced using rb_struct_alloc_noinit.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14003 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 07:00:50 +00:00
akr 2109a52503 * re.c (REG_CASESTATE): unused macro removed.
(rb_reg_prepare_re): check encoding difference.
  (rb_reg_initialize): check 8bit byte.

* parse.y (parser_tokadd_escape): fix has8bit.

  [ruby-dev:32113]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14002 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 06:30:26 +00:00
akr f1afb3959c add ML ref.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14001 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 04:51:02 +00:00
akr 0dbdad7599 * struct.c (rb_struct_define_without_accessor): new function.
* range.c (range_alloc): removed.
  (Init_Range): use rb_struct_define_without_accessor.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 04:35:53 +00:00
matz d73f08d56d * re.c (match_begin): should return offset by character.
[ruby-dev:32331]

* re.c (match_end): ditto.

* re.c (rb_reg_search): ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13999 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 02:10:44 +00:00
matz 050a10c607 * compile.c (defined_expr): defined(method(x)) dumped core. a
patch from Yusuke ENDOH <mame AT tsg.ne.jp>.  [ruby-dev:32335]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13998 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-23 01:46:44 +00:00
akr cca64ecb9a previous change refined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13997 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-22 01:36:13 +00:00
akr 6ed29c55ef add test for [ruby-dev:32329].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13996 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-22 01:32:32 +00:00
matz c227d3feb3 * insnhelper.ci (vm_search_normal_superclass): rename function.
* insnhelper.ci (vm_search_superclass): ditto.

* proc.c (struct METHOD): rename rklass -> rclass.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13995 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-22 01:17:52 +00:00