-
Bug
-
Resolution: Fixed
-
P3
-
8u31
-
b22
-
x86
-
windows_8
FULL PRODUCT VERSION :
java version "1.8.0_31"
Java(TM) SE Runtime Environment (build 1.8.0_31-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.31-b07, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.3.9600]
A DESCRIPTION OF THE PROBLEM :
In a nashorn script, a here document with only whitespace causes an error.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Create a file "test.js" with the following content:
print(<<EOD);
EOD
So the file contains 4 lines: 1 blank line inside the here document, & 1 blank line after the second occurrence of EOD.
Now run the script with the jjs tool, on Windows:
jjs -scripting test.js
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
a blank line is printed
ACTUAL -
test.js:3:3 Here string missing end marker "EOD"
EOD
^
REPRODUCIBILITY :
This bug can be reproduced always.
java version "1.8.0_31"
Java(TM) SE Runtime Environment (build 1.8.0_31-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.31-b07, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.3.9600]
A DESCRIPTION OF THE PROBLEM :
In a nashorn script, a here document with only whitespace causes an error.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Create a file "test.js" with the following content:
print(<<EOD);
EOD
So the file contains 4 lines: 1 blank line inside the here document, & 1 blank line after the second occurrence of EOD.
Now run the script with the jjs tool, on Windows:
jjs -scripting test.js
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
a blank line is printed
ACTUAL -
test.js:3:3 Here string missing end marker "EOD"
EOD
^
REPRODUCIBILITY :
This bug can be reproduced always.