Java Reference
In-Depth Information
NotStar CommentTail
CommentTailStar:
/
* CommentTailStar
NotStarNotSlash CommentTail
NotStar:
InputCharacter
but not *
LineTerminator
NotStarNotSlash:
InputCharacter
but not * or /
LineTerminator
CharactersInLine:
InputCharacter
CharactersInLine InputCharacter
These productions imply all of the following properties:
• Comments do not nest.
• /* and */ have no special meaning in comments that begin with //.
• // has no special meaning in comments that begin with /* or /**.
As a result, the text:
/* this comment /* // /** ends here: */
is a single complete comment.
3.8. Identifiers
An
identifier
is an unlimited-length sequence of
Java letters
and
Java digits
, the first of
which must be a
Java letter
.
Identifier:
IdentifierChars
but not a
Keyword
or
BooleanLiteral
or
NullLiteral
IdentifierChars:
JavaLetter
IdentifierChars JavaLetterOrDigit
JavaLetter: