ceylon - Can't import any java classes -
helloworld.ceylon
import java.util { hashmap } //error:(1, 8) ceylon: bundle not found in imported modules: java.util (define module , add together module import module descriptor) void run() { print("test"); }
module.properties
module ceylonhelloworld "1.0" { import java.base "8"; }
i exception in helloword.ceylon file
like mentioned gavin have utilize legal module name, when alter code utilize module name "java8test" next output when compiling:
$ ceylon compile java8test warning: looks using class files java newer 1.7. should work well, if not, allow know @ https://github.com/ceylon/ceylon-compiler/issues. in near future, ceylon compiler upgraded handle java 1.8. ./source/java8test/run.ceylon:1: warning: import never used: 'hashmap' import java.util { hashmap } ^ 2 warnings note: created module java8test/1.0.0
which expected.
ceylon
No comments:
Post a Comment