зеркало из https://github.com/github/ruby.git
* lib/weakref.rb, lib/irb/ruby-lex.rb, lib/irb/lc/error.rb, enc/trans/japanese.c:
change "illegal" to "invalid" in a context which doesn' t against a law. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14736 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
efd7504d44
Коммит
173f1e1563
|
@ -1,7 +1,9 @@
|
|||
Thu Dec 27 17:25:27 2007 Tanaka Akira <akr@fsij.org>
|
||||
Thu Dec 27 17:57:30 2007 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* parse.y, transcode_data.h, transcode.c: change "illegal" to
|
||||
"invalid" in a context which doesn' t against a law.
|
||||
* parse.y, transcode_data.h, transcode.c, lib/weakref.rb,
|
||||
lib/irb/ruby-lex.rb, lib/irb/lc/error.rb, enc/trans/japanese.c:
|
||||
change "illegal" to "invalid" in a context which doesn' t against
|
||||
a law.
|
||||
|
||||
Thu Dec 27 16:37:06 2007 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
|
|
|
@ -23743,7 +23743,7 @@ from_iso_2022_jp_transcoder_preprocessor(char **in_pos, char **out_pos,
|
|||
/* SHIFT */
|
||||
rb_raise(rb_eRuntimeError /*change exception*/, "shift is not supported");
|
||||
} else if (c1 >= 0x80) {
|
||||
rb_raise(rb_eRuntimeError /*change exception*/, "illegal byte sequence");
|
||||
rb_raise(rb_eRuntimeError /*change exception*/, "invalid byte sequence");
|
||||
} else {
|
||||
switch (cur_mode) {
|
||||
case ISO_2022_GZ_ASCII:
|
||||
|
|
|
@ -18,7 +18,7 @@ module IRB
|
|||
def_exception :UnrecognizedSwitch, "Unrecognized switch: %s"
|
||||
def_exception :NotImplementedError, "Need to define `%s'"
|
||||
def_exception :CantReturnToNormalMode, "Can't return to normal mode."
|
||||
def_exception :IllegalParameter, "Illegal parameter(%s)."
|
||||
def_exception :IllegalParameter, "Invalid parameter(%s)."
|
||||
def_exception :IrbAlreadyDead, "Irb is already dead."
|
||||
def_exception :IrbSwitchedToCurrentThread, "Switched to current thread."
|
||||
def_exception :NoSuchJob, "No such job(%s)."
|
||||
|
|
|
@ -967,7 +967,7 @@ class RubyLex
|
|||
when /[0-7]/
|
||||
match = /[0-7_]/
|
||||
when /[89]/
|
||||
RubyLex.fail SyntaxError, "Illegal octal digit"
|
||||
RubyLex.fail SyntaxError, "Invalid octal digit"
|
||||
else
|
||||
return Token(TkINTEGER)
|
||||
end
|
||||
|
|
|
@ -52,12 +52,12 @@ class WeakRef < Delegator
|
|||
|
||||
def __getobj__
|
||||
unless @@id_rev_map[self.object_id] == @__id
|
||||
Kernel::raise RefError, "Illegal Reference - probably recycled", Kernel::caller(2)
|
||||
Kernel::raise RefError, "Invalid Reference - probably recycled", Kernel::caller(2)
|
||||
end
|
||||
begin
|
||||
ObjectSpace._id2ref(@__id)
|
||||
rescue RangeError
|
||||
Kernel::raise RefError, "Illegal Reference - probably recycled", Kernel::caller(2)
|
||||
Kernel::raise RefError, "Invalid Reference - probably recycled", Kernel::caller(2)
|
||||
end
|
||||
end
|
||||
def __setobj__(obj)
|
||||
|
|
Загрузка…
Ссылка в новой задаче