JEP 494: Module Import Declarations (Second Preview)
🧠 What is JEP 494?
✅ Why it's useful?
RUN:
SimpleModuleImportExample -> Only module import is needed
import module java.base;
public class SimpleModuleImportExample {
public static void main(String[] args) {
var r=List.of(1,2,3);
r.stream().map(BigDecimal::new).map(BigDecimal::negate).forEach(System.out::println);
}
}PreviousJEP 493: Linking Run-Time Images without JMODsNextJEP 495: Simple Source Files and Instance Main Methods (Fourth Preview)
Last updated