Java proposal addresses scarcity of keywords for new features

try {
threshold : 0, // You can set threshold on how close to the edge ad should come before it is loaded. Default is 0 (when it is visible).
forceLoad : false, // Ad is loaded even if not visible. Default is false.
onLoad : false, // Callback function on call ad loading
onComplete : false, // Callback function when load is loaded
timeout : 1500, // Timeout ad load
debug : false, // For debug use : draw colors border depends on load status
xray : false // For debug use : display a complete page view with ad placements
}) ;
catch (exception){
console.log(“error loading lazyload_ad ” + exception);

A JDK enhancement proposal suggests the use of hyphenated keywords to denote new features in the Java language, with the goal of ensuring compatibility and readability in new keywords as suitable keyword tokens become increasingly scarce. 

The notes that new features in the Java language often require new keywords, but new keywords risk breaking existing programs. For balancing readability and compatibility, a new type of keyword could be used, namely a hyphenated keyword that is a compound of identifiers and pre-existing keywords. Examples cited were non-final, break-with, and short-circuit

A keyword is a series of ASCII letters—such as class, else, and int—that developers are not allowed to use as identifiers in Java programs. Java uses a small set of keywords to denote fundamental language features. The keyword management proposal does not propose any new Java syntax elements or Java syntax optimizations for ease of implementation by compiler developers. The proposal has the following goals:

  • Exploring syntactic options for Java language designers to denote new features.
  • Solving a “perpetual” problem of keyword tokens being scare and expensive, leaving language designers to constrain or corrupt the Java programming model to fit available keywords.
  • Advising language designers on the style of keyword suited to different features.

The proposal notes that Java designers face a challenge in that keywords conceived for Java 1.0 features are rarely suitable for new features. The proposal does carry risks in that some developers may not like hyphenated keywords, while others may accept the idea but dislike hyphenated suggestions that emerge for particular language features. This risk is expected to diminish over time.

The keyword proposal currently does not target a specific version of Java where it would be included. The proposal follows closely another .