diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1998-07-24 04:42:07 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1998-07-24 04:42:07 +0000 |
commit | 3b0fec9a5f966fd7ae26bc7b84877fa7209d8605 (patch) | |
tree | 48fbc4b02d73ca0f173ed87e288ee406e0913b97 | |
parent | 0d30af8fd2bcfea8cf5dbf87b623c57960ce81bc (diff) |
1.1c1
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 12 | ||||
-rw-r--r-- | config.sub | 3 | ||||
-rw-r--r-- | error.c | 6 | ||||
-rw-r--r-- | eval.c | 14 | ||||
-rw-r--r-- | ext/tcltklib/extconf.rb | 4 | ||||
-rw-r--r-- | gc.c | 2 | ||||
-rw-r--r-- | io.c | 1 | ||||
-rw-r--r-- | lib/matrix.rb | 1 | ||||
-rw-r--r-- | lib/tk.rb | 19 | ||||
-rw-r--r-- | lib/tracer.rb | 1 | ||||
-rw-r--r-- | regex.c | 12 | ||||
-rw-r--r-- | ruby.c | 2 | ||||
-rw-r--r-- | version.h | 4 |
13 files changed, 48 insertions, 33 deletions
@@ -1,3 +1,7 @@ +Fri Jul 24 13:40:19 1998 Yukihiro Matsumoto <[email protected]> + + * version 1.1c1 released. + Fri Jul 24 02:10:22 1998 Yukihiro Matsumoto <[email protected]> * marshal.c (r_bytes2): allocated buffer size was too short. @@ -8,6 +12,14 @@ Fri Jul 24 02:10:22 1998 Yukihiro Matsumoto <[email protected]> * re.c (reg_get_kcode): code number was wrong. +Thu Jul 23 13:11:32 1998 Yukihiro Matsumoto <[email protected]> + + * eval.c (rb_attr): argument should be symbol or a string. + +Wed Jul 22 11:59:34 1998 Yukihiro Matsumoto <[email protected]> + + * regex.c (calculate_must_string): wrong offset added. + Wed Jul 22 11:59:59 1998 Yukihiro Matsumoto <[email protected]> * st.c (rehash): still had a GC problem. fixed. diff --git a/config.sub b/config.sub index 438abc8152..9775812226 100644 --- a/config.sub +++ b/config.sub @@ -781,6 +781,9 @@ case $os in -xenix) os=-xenix ;; + -uxpds) + os=-uxpds + ;; -human) ;; -beos) @@ -393,12 +393,12 @@ exception(argc, argv) } for (i=0; i<argc; i++) { /* argument check */ id = rb_to_id(argv[i]); - if (!rb_is_const_id(id)) { - ArgError("identifier `%s' needs to be constant", rb_id2name(id)); - } if (!rb_id2name(id)) { ArgError("argument needs to be symbol or string"); } + if (!rb_is_const_id(id)) { + ArgError("identifier `%s' needs to be constant", rb_id2name(id)); + } } for (i=0; i<argc; i++) { v = rb_define_class_under(the_class, @@ -326,7 +326,7 @@ rb_attr(klass, id, read, write, ex) { char *name; char *buf; - ID attr, attreq, attriv; + ID attr, attriv; int noex; if (!ex) noex = NOEX_PUBLIC; @@ -344,17 +344,19 @@ rb_attr(klass, id, read, write, ex) } name = rb_id2name(id); - attr = rb_intern(name); + if (!name) { + ArgError("argument needs to be symbol or string"); + } buf = ALLOCA_N(char,strlen(name)+2); - sprintf(buf, "%s=", name); - attreq = rb_intern(buf); sprintf(buf, "@%s", name); attriv = rb_intern(buf); if (read) { - rb_add_method(klass, attr, NEW_IVAR(attriv), noex); + rb_add_method(klass, id, NEW_IVAR(attriv), noex); } + sprintf(buf, "%s=", name); + id = rb_intern(buf); if (write) { - rb_add_method(klass, attreq, NEW_ATTRSET(attriv), noex); + rb_add_method(klass, id, NEW_ATTRSET(attriv), noex); } } diff --git a/ext/tcltklib/extconf.rb b/ext/tcltklib/extconf.rb index 31c858c203..282e53d09a 100644 --- a/ext/tcltklib/extconf.rb +++ b/ext/tcltklib/extconf.rb @@ -75,9 +75,9 @@ end if have_header("tcl.h") && have_header("tk.h") && search_lib("libX11.{a,so}", "XOpenDisplay", "/usr/lib", "/usr/openwin/lib", "/usr/X11*/lib") && - search_lib("libtcl{,7*,8*}.{a,so}", "Tcl_FindExecutable", + search_lib("libtcl{,8*,7*}.{a,so}", "Tcl_FindExecutable", "/usr/lib", "/usr/local/lib") && - search_lib("libtk{,4*,8*}.{a,so}", "Tk_Init", + search_lib("libtk{,8*,4*}.{a,so}", "Tk_Init", "/usr/lib", "/usr/local/lib") $LDFLAGS = $libraries.collect{|path| "-L" + path}.join(" ") create_makefile("tcltklib") @@ -686,7 +686,7 @@ obj_free(obj) break; case T_DATA: if (DATA_PTR(obj)) { - if (RANY(obj)->as.data.dfree == (void*)-1) { + if ((long)RANY(obj)->as.data.dfree == -1) { free(DATA_PTR(obj)); } if (RANY(obj)->as.data.dfree) { @@ -1327,7 +1327,6 @@ io_mode_string(fptr) case FMODE_READWRITE: return "r+"; } - return "r"; } VALUE diff --git a/lib/matrix.rb b/lib/matrix.rb index 3924e93ecb..14b4d4779f 100644 --- a/lib/matrix.rb +++ b/lib/matrix.rb @@ -1,4 +1,3 @@ -#!/usr/local/bin/ruby # # matrix.rb - # $Release Version: 1.0$ @@ -453,9 +453,9 @@ module TkCore end def rb_appsend(interp, async, *args) - args.unshift('ruby {') - args.push('}') - appsend(interp, async, *args) + args = args.filter{|c| _get_eval_string(c).gsub(/[][$"]/, '\\\\\&')} + args.push(').to_s"') + appsend(interp, async, 'ruby "(', *args) end def appsend_displayof(interp, win, async, *args) @@ -468,9 +468,9 @@ module TkCore end def rb_appsend_displayof(interp, win, async, *args) - args.unshift('ruby {') - args.push('}') - appsend_displayof(interp, win, async, *args) + args = args.filter{|c| _get_eval_string(c).gsub(/[][$"]/, '\\\\\&')} + args.push(').to_s"') + appsend_displayof(interp, win, async, 'ruby "(', *args) end def info(*args) @@ -713,13 +713,14 @@ class TkVariable def value begin - tk_tcl2ruby(INTERP._eval(format('global %s; set %s', @id, @id))) + INTERP._eval(format('global %s; set %s', @id, @id)) rescue if INTERP._eval(format('global %s; array exists %s', @id, @id)) != "1" raise else - Hash[*tk_tcl2ruby(INTERP._eval(format('global %s; array get %s', - @id, @id)))] + Hash[*tk_split_simplelist(INTERP\ + ._eval(format('global %s; array get %s', + @id, @id)))] end end end diff --git a/lib/tracer.rb b/lib/tracer.rb index b7ef536269..fbfca24fe5 100644 --- a/lib/tracer.rb +++ b/lib/tracer.rb @@ -1,4 +1,3 @@ -#!/usr/local/bin/ruby # # tracer.rb - # $Release Version: 0.2$ @@ -193,7 +193,7 @@ void re_set_casetable(table) char *table; { - translate = table; + translate = (unsigned char*)table; } /* Jim Meyering writes: @@ -705,12 +705,12 @@ print_partial_compiled_pattern(start, end) printf ("/charset%s", (enum regexpcode) *(p - 1) == charset_not ? "_not" : ""); - mcnt = *p; + mcnt = *p++; printf("/%d", mcnt); for (c = 0; c < mcnt; c++) { unsigned bit; - unsigned char map_byte = p[1 + c]; + unsigned char map_byte = p[c]; putchar ('/'); @@ -718,7 +718,7 @@ print_partial_compiled_pattern(start, end) if (map_byte & (1 << bit)) printf("%c", c * BYTEWIDTH + bit); } - p += mcnt + 1; + p += mcnt; mcnt = EXTRACT_UNSIGNED_AND_INCR(p); while (mcnt--) { int beg, end; @@ -848,7 +848,7 @@ static void print_compiled_pattern(bufp) struct re_pattern_buffer *bufp; { - unsigned char *buffer = bufp->buffer; + unsigned char *buffer = (unsigned char*)bufp->buffer; print_partial_compiled_pattern (buffer, buffer + bufp->used); } @@ -914,7 +914,7 @@ calculate_must_string(start, end) case charset: case charset_not: mcnt = *p++; - p += mcnt+1; + p += mcnt; mcnt = EXTRACT_UNSIGNED_AND_INCR(p); while (mcnt--) { EXTRACT_MBC_AND_INCR(p); @@ -580,7 +580,7 @@ load_file(fname, script) if (script) { rb_define_global_const("DATA", f); } - if (f != rb_stdin) { + else if (f != rb_stdin) { io_close(f); } } @@ -1,2 +1,2 @@ -#define RUBY_VERSION "1.1c0" -#define VERSION_DATE "98/07/17" +#define RUBY_VERSION "1.1c1" +#define VERSION_DATE "98/07/24" |