akr
be36a1b138
* include/ruby/missing.h (cbrt): add declaration.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15706 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-06 05:06:30 +00:00
nobu
53577db05b
* misc/ruby-mode.el (ruby-add-log-current-method): use ruby style
...
method name format.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-06 02:14:17 +00:00
nobu
6b10829b22
* sprintf.c (rb_str_format): no need of loop.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15703 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-06 02:12:31 +00:00
matz
bececd35c5
* object.c (rb_mod_freeze): call rb_class_name() directly.
...
[ruby-core:15802]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15702 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-06 01:33:56 +00:00
naruse
98cbcf1bd7
* string.c (count_utf8_lead_bytes_with_ulong): fix shift size.
...
[ruby-dev:33993]
* string.c (str_utf8_nth) fix wrong counting.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15700 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 19:34:15 +00:00
akr
579f16d985
add tests for float format.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15699 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 16:24:09 +00:00
nobu
8c889459cf
* sprintf.c (rb_str_format): size_t returned from strlen() can be
...
unsigned.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 15:34:02 +00:00
nobu
79cdf2ffa2
* struct.c (make_struct): preserve encoding of struct name.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15696 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 15:31:42 +00:00
naruse
fff981ee6d
* string.c (is_utf8_lead_byte, count_utf8_lead_bytes_with_ulong):
...
defined for UTF-8 optimization.
* string.c (str_strlen): use is_utf8_lead_byte and
count_utf8_lead_bytes_with_ulong.
* string.c (str_utf8_nth) ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15695 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 13:54:36 +00:00
akr
e34480c330
add a test.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15694 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 13:31:06 +00:00
nobu
12551ae573
* file.c (rb_file_flock): returns false on EAGAIN if non-blocking.
...
[ruby-core:15795]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 08:53:08 +00:00
duerst
08631278ad
Web Mar 5 17:43:43 2008 Martin Duerst <duerst@it.aoyama.ac.jp>
...
* transcode.c (transcode_loop): Adjusted detection of invalid
(ill-formed) UTF-8 sequences. Fixing potential security issue, see
http://www.unicode.org/versions/Unicode5.1.0/#Notable_Changes .
* test/ruby/test_transcode.rb: Added two tests for above fix.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 08:45:51 +00:00
matz
39787ea14d
* numeric.c (fix_to_s): avoid rb_scan_args() when no argument
...
given.
* bignum.c (rb_big_to_s): ditto.
* enum.c (enum_first): ditto.
* eval_jump.c (rb_f_catch): ditto.
* io.c (rb_obj_display): ditto.
* class.c (rb_obj_singleton_methods): ditto.
* object.c (rb_class_initialize): ditto.
* random.c (rb_f_srand): ditto.
* range.c (range_step): ditto.
* re.c (rb_reg_s_last_match): ditto.
* string.c (rb_str_to_i): ditto.
* string.c (rb_str_each_line): ditto.
* string.c (rb_str_chomp_bang): ditto.
* string.c (rb_str_sum): ditto.
* string.c (str_modifiable): declare inline.
* string.c (str_independent): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 05:22:17 +00:00
matz
413db1b036
* lib/debug.rb: require 'continuation' to implement "restart"
...
command. [ruby-dev:33992]
* lib/debug.rb (Context::debug_command): remove local variable
shadowing to shut up warnings. [ruby-dev:33992]
* lib/debug.rb (Context::display_list): ditto.
* lib/debug.rb (Context::resume): ditto.
* lib/debug.rb (Context::get_thread): no longer use #index for Hash.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15690 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-05 02:52:43 +00:00
matz
772c19298d
* lib/irb.rb (IRB::Irb::eval_input): SyntaxError should not be
...
considered as IRB bug. [ruby-dev:33991]
* lib/irb/workspace.rb (IRB::WorkSpace::filter_backtrace): should
filter 'irb.rb' as well for context mode 2 and 3.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15689 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 12:37:05 +00:00
matz
a110ef359a
* hash.c (hash_equal): two hash tables are different when internal
...
comparison table differ. [ruby-dev:33989]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15688 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 10:19:55 +00:00
matz
f8c5b8ec90
* hash.c (rb_hash_aset): should not copy key string when
...
compare_by_identity is set. [ruby-dev:33604]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15687 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 10:14:40 +00:00
matz
6c76a2577a
* parse.y (parser_yylex): disallow non digits '0o' expression.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15686 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 07:29:38 +00:00
naruse
70b55c5dcf
* io.c (open_key_args): use rb_io_open_with_args instead of rb_f_open.
...
[ruby-core:15763]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 05:36:08 +00:00
akr
8e1d6b214a
* gc.c (add_heap): fix previous change. [ruby-dev:33988]
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15684 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 04:42:31 +00:00
nobu
fd847f79a0
* gc.c (add_heap): use binary search to find the place to insert the
...
new heap slot. [ruby-dev:33983]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15683 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-04 01:21:06 +00:00
naruse
8ac9b7c2ed
* io.c (open_key_args): use rb_io_open instead of rb_f_open.
...
[ruby-core:15746]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15682 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-03 20:34:58 +00:00
gotoyuzo
10a0d4b61d
* lib/webrick/httpservlet/filehandler.rb: should normalize path
...
separators in path_info to prevent directory traversal
attacks on DOSISH platforms.
reported by Digital Security Research Group [DSECRG-08-026].
* lib/webrick/httpservlet/filehandler.rb: pathnames which have
not to be published should be checked case-insensitively.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15676 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-03 14:31:30 +00:00
akr
7c9e815d94
test updated.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15675 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-03 08:54:31 +00:00
matz
384e8e6680
* gc.c (add_heap): sort heaps array in ascending order to use
...
binary search.
* gc.c (is_pointer_to_heap): use binary search to identify object
in heaps. works better when number of heap segments grow big.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15674 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-03 08:27:43 +00:00
matz
bbc2f80a32
* re.c (rb_reg_regsub): remove too strict encoding check.
...
[ruby-dev:33966]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15673 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-03 08:22:18 +00:00
nobu
9b2dd1e20d
* hash.c (rb_any_hash): shrinks all results in Fixnum range.
...
[ruby-core:15713]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15672 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-03 07:14:27 +00:00
nobu
3b5d60c0b1
* io.c (rb_io_ungetc): reduce redundant call.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15671 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-02 14:04:02 +00:00
nobu
6a9bfa23bf
* ruby.c (load_file): parse shebang in us-ascii. a patch from
...
sheepman <sheepman AT sheepman.sakura.ne.jp> in [ruby-dev:33955]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15670 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-02 01:13:15 +00:00
akr
601616d6ff
add tests.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15669 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 16:16:46 +00:00
akr
655fd2dc37
add a test.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15668 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 16:05:10 +00:00
akr
374fac7482
add a test.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15667 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 15:51:04 +00:00
nobu
b4b3180bfa
* object.c (rb_cstr_to_dbl): check for successive underscores.
...
[ruby-dev:33952]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15666 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 15:08:13 +00:00
nobu
8ba29591af
* svn: ignore transdb.h.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15664 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 09:30:34 +00:00
nobu
b8a733d0b8
* io.c (struct argf): packed ARGF stuffs.
...
* ruby.c (proc_options): use ruby_set_inplace_mode().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15663 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 08:59:04 +00:00
nobu
cce9eb092b
* lib/test/unit/collector/dir.rb (recursive_collect): do not always
...
include all test_*.rb.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15662 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 08:51:37 +00:00
nobu
e31eeedb94
* tool/make-snapshot: prefixed r makes $revision always true.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15661 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 08:45:04 +00:00
matz
ffd3954d31
* development snapshot 1.9.0-1 released.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15660 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 05:15:34 +00:00
matz
22dc58bf97
* tool/make-snapshot: make prereq uses MINIRUBY.
...
* tool/make-snapshot: allow packaging like 1.9.0-1 by second
command-line argument.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15659 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 05:13:28 +00:00
akr
00bf4e8a84
* test/ruby/allpairs.rb: new file for all pairs method.
...
* test/ruby/test_m17n_comb.rb: use allpairs.rb to reduce test cases.
* test/ruby/test_sprintf_comb.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15658 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 04:12:13 +00:00
matz
fe7d645eed
bootstraptest/test_marshal.rb: test updated
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15657 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 04:07:26 +00:00
matz
adad6e0300
bootstraptest/test_knownbug.rb: add test
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15656 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 03:42:58 +00:00
matz
88d9f7aeac
* string.c (sym_inspect): use rb_str_inspect() instead of
...
rb_str_dump(). [ruby-dev:33946]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15655 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 03:42:06 +00:00
matz
207b8292ba
* eval_method.c (rb_get_method_body): ent->method may be freed by
...
GC. [ruby-dev:31819]
* thread.c (remove_event_hook): should not access freed memory.
[ruby-dev:31820]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15654 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 03:36:33 +00:00
matz
32c4aa1d14
ChangeLog: typo fixed
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15653 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 01:42:32 +00:00
naruse
4c7d380a81
* io.c (read_all, rb_io_getline_fast): encoding is rb_input_encoding.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15652 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 01:33:17 +00:00
matz
840723e523
test/test_{string,sprintf}.rb: updated.
...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15651 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 01:22:45 +00:00
nobu
79f1b9e93b
* string.c (tr_setup_table, rb_str_split_m, rb_str_chomp_bang):
...
simplified with rb_enc_ascget(). [ruby-dev:33944]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15650 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 01:09:43 +00:00
matz
d5fec27d8e
* string.c (rb_str_coderange_scan_restartable): should not return
...
offset in the middle of a character.
* string.c (rb_str_coderange_scan_restartable): should not return
invalid cr value.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15649 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 01:02:30 +00:00
matz
18e70b266f
* sprintf.c (rb_str_format): "%#.0o" should keep prefix where
...
"%#.0x" should not.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15648 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-03-01 00:38:33 +00:00