Yet another improvement in not-a-function reporting. Now for foo.bar() when bar does not exist Rhino prints "Can not find function bar"
git-svn-id: svn://10.0.0.236/trunk@179198 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -3304,6 +3304,9 @@ public class ScriptRuntime {
|
||||
// XXX Use value for better error reporting
|
||||
String msg = (messageHelper == null)
|
||||
? "null" : messageHelper.toString();
|
||||
if (value == Scriptable.NOT_FOUND) {
|
||||
return typeError1("msg.function.not.found", msg);
|
||||
}
|
||||
return typeError2("msg.isnt.function", msg,
|
||||
value == null ? "null" : value.getClass().getName());
|
||||
}
|
||||
|
||||
@@ -451,6 +451,9 @@ msg.undef.with =\
|
||||
msg.isnt.function =\
|
||||
{0} is not a function, it is {1}.
|
||||
|
||||
msg.function.not.found =\
|
||||
Cannot find function {0}.
|
||||
|
||||
msg.isnt.xml.object =\
|
||||
{0} is not an xml object.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user