Fixing bug 263978: for compatibility with BSF usage IllegalArgumentException is not thrown on negative line numbers.

This commit is contained in:
igor%mir2.org 2004-10-16 00:37:05 +00:00
Родитель 441a3130bf
Коммит c67a443fc9
3 изменённых файлов: 23 добавлений и 16 удалений

Просмотреть файл

@ -17,7 +17,7 @@ P { text-align: justify; }
<h1 align="center">
Change Log for Rhino</h1>
<h2>Release candidate 2 for Rhino 1.6R1</h2>
<h2>Rhino 1.6R1</h2>
<h3>Release overview</h3>
<p>
@ -135,6 +135,16 @@ The following classes that were deprecated in Rhino 1.5R5 are no longer availabl
See documentation for <a href="apidocs/org/mozilla/javascript/optimizer/ClassCompiler.html"><tt>org.mozilla.javascript.optimizer.ClassCompiler</tt></a> that provides replacement for ClassNameHelper and ClassRepository.
</p>
<h2>Change logs for previous Rhino releases</h2>
<ul>
<li><a href="rhino15R5.html">Rhino 1.5R5</a></li>
<li><a href="rhino15R41.html">Rhino 1.5R4.1</a></li>
<li><a href="rhino15R4.html">Rhino 1.5R4</a></li>
<li><a href="rhino15R3.html">Rhino 1.5R3</a></li>
<li><a href="rhino15R2.html">Rhino 1.5R2</a></li>
<li><a href="rhino15R1.html">Rhino 1.5R1</a></li>
</ul>
<hr width="100%"><br>
<a href="index.html">back to top</a></h3>

Просмотреть файл

@ -17,23 +17,20 @@ You can download binary distributions of Rhino from <a
</p>
<p>
Rhino 1.5R5 is the last qualified release. It is also possible to download the
release candidate 2 for Rhino 1.6R1 but it has not been fully qualified.
</p>
<p>
Release candidate 2 for Rhino 1.6R1 includes support for <a
href="http://www.ecma-international.org/publications/standards/Ecma-357.htm">ECMAScript
for XML</a> (E4X). Please try this out and report any issues as described at
the <a href="help.html">help</a> pages. Note that you need to add
<tt>xbean.jar</tt> from <a
Rhino 1.6R1 is the last qualified release. It includes support for <a
href="http://www.ecma-international.org/publications/standards/Ecma-357.htm">ECMAScript for XML</a> (E4X). Note that you need to add <tt>xbean.jar</tt> from <a
href="http://xmlbeans.apache.org/">XMLBeans</a> project to your class path
if you use E4X in Rhino.
<!--
It is also possible to download the
release candidate 2 for Rhino 1.6R1 but it has not been fully qualified.
-->
</p>
<ul>
<li> <a href="ftp://ftp.mozilla.org/pub/mozilla.org/js/rhino1_6R1pre.zip">Rhino 1.6R1 Release Candidate 2</a>
<li> <a href="ftp://ftp.mozilla.org/pub/mozilla.org/js/rhino1_6R1.zip">Rhino 1.6R1</a>
<ul>
<li> <font size="-1"><a href="changes.html">Change log</a></font></li>
<li> <font size="-1"><a href="rhino16R1.html">Change log</a></font></li>
</ul>
</li>

Просмотреть файл

@ -1319,8 +1319,8 @@ public class Context
throws IOException
{
if (lineno < 0) {
throw new IllegalArgumentException(
"Line number can not be negative:"+lineno);
// For compatibility IllegalArgumentException can not be thrown here
lineno = 0;
}
return (Script) compileImpl(null, in, null, sourceName, lineno,
securityDomain, false, null, null);
@ -1346,8 +1346,8 @@ public class Context
Object securityDomain)
{
if (lineno < 0) {
throw new IllegalArgumentException(
"Line number can not be negative:"+lineno);
// For compatibility IllegalArgumentException can not be thrown here
lineno = 0;
}
return compileString(source, null, null, sourceName, lineno,
securityDomain);