Punctuators are composed of special non alphabetic characters and are considered to be valid tokens by the interpreter.
Here is a summary of all the valid tokens:
| Value | Meaning |
|---|---|
| ! | Logical not |
| != | Not equal to |
| !== | Not exactly equal to (ECMA edition 3) |
| % | Remainder |
| %= | Remainder and assign |
| & | Bitwise AND |
| && | Logical AND |
| &= | Bitwise AND and assign |
| ( | Function argument delimiter and precedence control |
| ) | Function argument delimiter and precedence control |
| * | Multiply |
| *= | Multiply and assign |
| + | Unary plus, add, concatenate string |
| ++ | Postfix and prefix increment |
| += | Add and assign |
| , | Argument delimiter |
| - | Unary minus, subtract |
| -- | Postfix and prefix decrement |
| -= | Subtract and assign |
| . | Property accessor |
| / | Divide |
| /= | Divide and assign |
| : | Part of conditional operator |
| ; | Statement terminator |
| < | Less than |
| << | Bitwise shift left |
| <<= | Bitwise shift left and assign |
| <= | Less than or equal to |
| = | Assign value |
| == | Equal to |
| === | Exactly equal to (ECMA edition 3) |
| > | Greater than |
| >= | Greater than or equal to |
| >> | Bitwise shift right |
| >>= | Bitwise shift right and assign |
| >>> | Bitwise shift right (unsigned) |
| >>>= | Bitwise shift right (unsigned) and assign |
| ? | Conditional operator |
| [ | Array index delimiter |
| ] | Array index delimiter |
| ^ | Bitwise XOR |
| ^= | Bitwise XOR and assign |
| { | Start code block |
| | | Bitwise OR |
| |= | Bitwise OR and assign |
| || | Logical OR |
| } | End code block |
| ~ | Bitwise NOT |
Refer to the items in the see-also list for more details of their functionality.
The [ ], { }, and ( ) punctuators must be used in pairs and must also be nested correctly.
Some punctuator symbols are also used as operators.
| Prev | Home | Next |
| public | Up | Put() |
JavaScript Programmer's Reference, Cliff Wootton Wrox Press (www.wrox.com) Join the Wrox JavaScript forum at p2p.wrox.com Please report problems to support@wrox.com © 2001 Wrox Press. All Rights Reserved. Terms and conditions. | ||