/w/z/dev 1067>> cat Bar.java
class Bar {
public static void main(String[] args) {
System.out.println(new Foo());
}
}
/w/z/dev 1068>> javac -classpath /tmp/f Bar.java
/w/z/dev 1069>> java -classpath /tmp/f:. Bar
Foo@60616364
/w/z/dev 1070>> ./build/linux-x86_64-normal-server-release/images/jdk/bin/jshell --class-path /tmp/f
| Welcome to JShell -- Version 9-internal
| For an introduction type: /help intro
jshell> new Foo()
| Error:
| cannot find symbol
| symbol: class Foo
| new Foo()
| ^-^
class Bar {
public static void main(String[] args) {
System.out.println(new Foo());
}
}
/w/z/dev 1068>> javac -classpath /tmp/f Bar.java
/w/z/dev 1069>> java -classpath /tmp/f:. Bar
Foo@60616364
/w/z/dev 1070>> ./build/linux-x86_64-normal-server-release/images/jdk/bin/jshell --class-path /tmp/f
| Welcome to JShell -- Version 9-internal
| For an introduction type: /help intro
jshell> new Foo()
| Error:
| cannot find symbol
| symbol: class Foo
| new Foo()
| ^-^