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

1489 Коммитов

Автор SHA1 Сообщение Дата
eban a2020f907a * lib/mkmf.rb: typo fix(RUBY_PLAT_FORM -> RUBY_PLATFORM).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2563 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-13 02:21:53 +00:00
suke 698e61aaa7 avoid some warnings
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-12 12:23:10 +00:00
eban 5838e5bc4e 2002-06-12
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2561 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-12 09:33:40 +00:00
akira b8be8d535a merged differences between uri-0.9.6 and uri-0.9.7
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2560 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-12 09:32:35 +00:00
matz 91511afa9c * parse.y (yylex): 'do' should return kDO_BLOCK on EXPR_ENDARG.
* parse.y (singleton): "def (()).a end" dumped core.

* parse.y (range_op): node may be null.

* parse.y (match_gen): ditto.

* parse.y (arg): void value check for "..", "...", "!", and "not".

* parse.y (match_gen): void value check for "=~".

* parse.y (value_expr): check NODE_AND and NODE_OR recursively.

* parse.y (cond0): void value check added for conditionals.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2558 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-12 09:22:20 +00:00
nobu 94f86651d6 * parse.y (stmt): fix typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2556 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 17:39:38 +00:00
ttate 28b8274e51 Include ctype.h for isdigit().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2555 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 14:59:43 +00:00
ttate 2690939122 Check the length of proto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2554 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 14:54:51 +00:00
ttate 5434d73ef7 Get rid of STR2CSTR. (Thanks N.Nakada)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2553 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 14:44:53 +00:00
ttate 176542da7f bugfix. (Thanks U.Nakamura)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 11:16:56 +00:00
eban 7f80a1800f * configure.in (LIBRUBY): rename to lib$(LIBRUBY_SO).a on Cygwin/MinGW.
* configure.in, cygwin/GNUmakefile: use dllwrap when --disable-shared
  is specified.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 10:26:13 +00:00
eban 65caf01223 2002-06-11
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2550 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 07:27:22 +00:00
eban 6e01d2e2f5 * parse.y (%%): remove '%%' line on the end of the file(parse error).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2549 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 07:26:03 +00:00
matz 22010642b2 * eval.c (rb_eval): ruby_frame->last_func may be null, if it's
called outside of a method.

* parse.y (arg): use INT2NUM, not INT2FIX for tUMINUS.

* parse.y (arg): unnecessary negative tPOW treatment.

* parse.y (tokadd_escape): wrong backslash escapement.

* parse.y (stmt,arg): too much void value check.

* parse.y (stmt,arg): need to check void value on rules which does
  not use node_assign().

* ext/socket/socket.c (ipaddr): need not to taint hostnames.

* range.c (range_include): should be based on "<=>", whereas
  member? still is based on "each".

* range.c (range_min,range_max): redefine methods based on "<=>".


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2548 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 07:02:23 +00:00
shugo a5fd4cec84 * lib/net/ftp.rb (noop): new method.
* lib/net/ftp.rb (site): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2546 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 04:20:11 +00:00
usa ec16af8173 * bcc32/Makefile.sub: set PROCESSOR_LEVEL to 6 if it's too big value.
* win32/Makefile.sub: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2545 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 04:16:58 +00:00
H_Konishi 0b67be50a5 * bcc32/configure.bat fix.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2544 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 03:41:52 +00:00
H_Konishi d0b3651906 new platform [bccwin32] merged.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2543 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-11 01:27:48 +00:00
ttate ceade7b926 bugfix.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2542 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 18:23:39 +00:00
ttate 5c1bdda10c Add DL::Importable::Internal::callback().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2541 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 17:47:48 +00:00
akr be87030ea8 fix PR#.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2539 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 13:02:00 +00:00
nobu 10d0deaa99 2002-06-10
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2538 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 10:18:24 +00:00
nobu d94aa88749 *** empty log message ***
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2537 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 10:16:13 +00:00
nobu 31de741673 * numeric.c (fix_lshift): negative shift count means right shift.
* numeric.c (fix_rshift): return -1 when left side operand is
  negative.

* parse.y (yylex): `0_' should be an error. (ruby-bugs-ja:PR#239)


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2535 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 10:06:12 +00:00
ttate abca067fb6 dl.c (rb_dl_scan_callback_args): memcpy() -> cast and substitution
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2534 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-10 07:52:10 +00:00
ttate 48bd82e993 Get rid of rb_dl_set_callback() and rb_dl_get_callback().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2533 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-09 17:56:34 +00:00
ttate 2d5b7f7365 * ext/dl: change the callback mechanism.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2532 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-09 17:47:34 +00:00
aamine d5ceb6ef82 modify typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2531 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-09 02:44:32 +00:00
H_Konishi 96654ce041 * sample/biorhythm.rb (getPosiiton,etc)
fix at changing Date module ( Date is changed Fixnum to Rational )


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-06 11:14:04 +00:00
usa 564edcce18 * win32/Makefile.sub (config.status): use sub! instead of []= because
[]= causes exception.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2529 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-06 03:06:11 +00:00
nobu a7a2b1d8f3 typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2528 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-06 02:46:18 +00:00
nobu d760f97172 * lib/thread.rb (Queue::pop): get rid of race condition.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2527 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-06 02:43:02 +00:00
michal 6956135b4b Trivial: GCC3.1 fix (not worth to mention in ChangeLog)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-05 06:10:57 +00:00
nagai a9f672c47b * tcltklib.c:
Stop the running zombi-eventloop when mainloop_watchdog is killed.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2523 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-05 01:56:47 +00:00
eban 160a9f79ef * ext/Win32API/extconf.rb: refactoring.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2522 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 09:52:28 +00:00
eban 9ba6e0738a * ext/socket/extconf.rb: The IPv6 stack of Cygwin is still incomplete.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2521 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 09:33:39 +00:00
eban 1320f85fb0 * ext/tcltklib/tcltklib.c (Init_tcltklib): moved the definition before actions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2520 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 08:03:43 +00:00
eban 4a470051b6 * ext/tk/lib/tkentry.rb: typo fix(!! -> ||).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2519 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 07:48:30 +00:00
eban c0eea52326 2002-06-04
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2518 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 07:35:48 +00:00
matz b7bc0cae53 * string.c (rb_str_aset): should raise error if an indexing string
is not found in the receiver.

* sprintf.c (rb_f_sprintf): "%d" should convert objects into
  integers using Integer().

* lib/tempfile.rb (Tempfile::size): added.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2517 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 07:34:19 +00:00
nagai 4cb164ee2a * tkfont.rb: Fix bugs on TkFont.init_widget_font for Tk8.x.
* tkafter.rb: Add self to 1st argument of interval- and loop-proc
    TkAfter#current_interval returns an interval (sleep) time value
    TkAfter#current_args returns an array of arguments
    TkAfter#return_value returns a return value of last loop-proc
      e.g.
         TkAfter.new(
           proc{|obj| 500 - obj.current_interval}, 10,
           [proc{|obj| p obj.current_args}, 'proc', 1],
           proc{|obj| p obj.current_args; ['return', 2]},
           [proc{|obj|
              p obj.return_value
              p ['proc', obj.current_args[0].call(obj.return_value[1],
                                                  obj.current_args[1])]},
            proc{|*args| args[0] + args[1]}, 1],
           proc{p ['proc', 4]} ).start(100)

* tk*.rb: Allow to use Symbols for parameters.
    Allow new notation of constructor (also allow old notation).
      e.g.
        TkFrame.new('classname'=>'User'){|base|
          pack
          f = TkFrame.new(base, :classname=>'ButtonFrame').pack
          TkButton.new(
             :parent     => f,
             :text       => 'Quit',
             :command    => proc{exit}
          ).pack(
             :fill => :x,
             :pady => 2
          )
        }

* tkcanvas.rb: (TkcItem) Add 'coords' parameter to the canvas item
    constructor (for new notation of constructor).
      e.g.
        c = TkCanvas.new.pack
        l = TkcLine.new(c, :coords=>[[0,0], [100,100]])

* tcltklib.c: New 'mainloop' and 'mainloop_watchdog'.
    The priority of their event-loop can be controlled.
    They accept an optional argument.
    If it false, they don't exit although the root widget is destroyed.
    This function is sometimes useful, if it is used with 'restart'.
    'mainloop' can't treat Thread#join/value in a callback routine.
    (e.g. TkButton.new(:command=>proc{p Thread.new{button.invoke}.value}) )
    'mainloop_watchdog' can treat them, but watchdog thread is always running
    (so, a little heavier than 'mainloop').
    If the purpose of using Thread#join/value is to do something under some
    safe-level, please use Proc object.
    (e.g. :command=>proc{$SAFE=1;proc{$SAFE=2;button.invoke}.call;p $SAFE})

* tk.rb: Support functions of new 'mainloop' and 'mainloop_watchdog'.

* tk.rb: (Tk.restart) Add 'app-name' paramater and 'use' parameter.
    'app-name' specifies the name and the resource class of the
    application. If 'app-name' is specified to 'xxx', the application
    class on the resource database is set to 'Xxx' and the application
    name is changed by the same rule of Tk.appname method.  'use'
    specifies the main window for embedding the root widget instead of
    generating a new window.

* tk.rb: Add new parameter 'widgetname' to the widget constructor to
    support effective use of Resource Database.  For example, the
    resource 'Xxx*quit.text: QUIT' can set the text of the button
    generated by the following code.
      e.g.
        Tk.restart('Xxx')
        TkButton.new(nil, 'widgetname'=>'quit', 'command'=>proc{exit}).pack
        Tk.mainloop

* tk.rb: TkOption::get always returns a tainted string.
    Add TkOption::new_proc_class.
    It generates a class to import procedures defined on the resource
    database. For example, there is a following resource file.
      ----< resource-test >------------
      *CMD.foo: {|*args| p [$SAFE, :foo, args]}
      *CMD.XXX.bar: {|*args| p [$SAFE, :bar, args]}
      *Button.command: ruby {p self; p $SAFE; TkOption::CMD::XXX.bar(1,2,3)}
      ---------------------------------
    The following code is a sample of use of the resource file.
      e.g.
        require 'tk'
        TkOption.readfile 'resource-test'
        p TkOption.new_proc_class(:CMD, [:foo], 1)
        p TkOption.new_proc_class(:XXX, [:bar], 2, false, TkOption::CMD)
        TkButton.new(:text=>'test').pack
        Tk.mainloop


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2515 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-04 07:03:33 +00:00
nobu dc010ff515 * ext/socket/getaddrinfo.c (gai_strerror): make literals const.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2513 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-03 16:02:16 +00:00
nobu 5df72288f8 * ext/socket/addrinfo.h: typo.
* ext/socket/getaddrinfo.c (gai_strerror): get rid of warning.

* ext/socket/socket.c (init_inetsock): ensures resources are
  freed at exceptions.

* ext/socket/socket.c (init_unixsock): ditto.

* ext/socket/socket.c (udp_connect): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2511 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-03 15:52:28 +00:00
suke a52442f27e change PLATFORM with RUBY_PLATFORM.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2510 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-03 11:44:08 +00:00
nobu 2263dbe022 * parse.y (here_document): check if identifier is terminated.
(ruby-bugs-ja:PR#239)

* parse.y (yylex): should pushback proper char after '**'.
  (ruby-bugs-ja:PR#240)


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2509 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-02 22:16:55 +00:00
suke f14180707d merge win32ole from rough
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2508 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-06-01 12:34:30 +00:00
eban 95a5a67142 2002-05-30
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2507 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-05-30 06:14:02 +00:00
matz 34f5c4061c * range.c (range_step): iteration done using "+" if elements are
Numeric.  Otherwise using "succ".

* range.c (range_each): iteration done using "succ".  If the
  elements does not respond to "succ", raise TypeError.  As a
  result, all Enumerable methods, e.g. collect, require elements
  to respond to "succ'.

* range.c (range_member): comparison done using "each", if
  elements are non-Numeric or no-"succ" objects.  Otherwise
  compare using "<=>".

* range.c (Init_Range): remove "size" and "length".


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2506 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-05-30 06:12:29 +00:00
wakou 21b2953030 * lib/cgi.rb: if StringIO is usable then use it.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2505 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-05-30 00:21:05 +00:00
H_Konishi d7c1784297 Wed May 29 18:55:47 2002 KONISHI Hiromasa <H_Konishi@ruby-lang.org>
* function renames my* and win32_* to rb_w32_* in win32/win32.c
	  fixed files win32/win32.c, win32/win32.h, win32/dir.h,
	              hash.c, rubysig.h, signal.c, ext/socket/socket.c


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2504 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-05-29 10:22:19 +00:00