java - Missing semicolon in JSONWithPadding -
the result of jsonwithpadding missing semicolon in end:
jsonwithpadding jsonwithpadding = new jsonwithpadding({"key":"value"}, "cb"); return response.status(200).entity(jsonwithpadding).build();
expected:
cb({"key":"value"}); --> semicolon
actual:
cb({"key":"value"}) --> without semicolon
any ideas?
the semicolon not missing, optional in (this example and) situations. jsonwithpadding
class working correctly.
the ecmascript language specification defines 7.9.1 rules of automatic semicolon insertion, summarised javascript , semicolons as
certain ecmascript statements (empty statement, variable statement, expression statement, do-while statement, continue statement, break statement, return statement, , throw statement) must terminated semicolons
this covered @ what rules javascript's automatic semicolon insertion (asi)?
Comments
Post a Comment