mozilla

Compare Revisions

Operators

Change Revisions

Revision 118584:

Revision 118584 by Bkimman on

Revision 118585:

Revision 118585 by Exaton on

Title:
Operators
Operators
Slug:
JavaScript/Guide/Obsolete_Pages/Operators
JavaScript/Guide/Obsolete_Pages/Operators
Content:

Revision 118584
Revision 118585
nn66    <p>
67      <small><i>In accordance with <a href="Talk:en/Core_JavaScri
 >pt_1.5_Guide/Operators#Precedence_Table">relevant discussion</a>,
 > this table was reversed to list operators in <b>decreasing</b> o
 >rder of priority.</i></small>
68    </p>
nn81            member
82          </td>
83          <td>
84            . &nbsp;[]
85          </td>
86        </tr>
87        <tr>
88          <td>
89            call / create instance
90          </td>
91          <td>
92            () &nbsp;new
93          </td>
94        </tr>
95        <tr>
96          <td>
97            negation/increment
98          </td>
99          <td>
100            ! &nbsp;~ &nbsp;- &nbsp;+ &nbsp;++ &nbsp;-- &nbsp;typ
 >eof &nbsp;void &nbsp;delete
101          </td>
102        </tr>
103        <tr>
104          <td>
105            multiply/divide
106          </td>
107          <td>
108            * &nbsp;/ &nbsp;%
109          </td>
110        </tr>
111        <tr>
112          <td>
113            addition/subtraction
114          </td>
115          <td>
116            + &nbsp;-
117          </td>
118        </tr>
119        <tr>
120          <td>
121            bitwise shift
122          </td>
123          <td>
124            &lt;&lt; &nbsp;&gt;&gt; &nbsp;&gt;&gt;&gt;
125          </td>
126        </tr>
127        <tr>
128          <td>
129            relational
130          </td>
131          <td>
132            &lt; &nbsp;&lt;= &nbsp;&gt; &nbsp;&gt;= &nbsp;in &nbs
 >p;instanceof
133          </td>
134        </tr>
135        <tr>
136          <td>
137            equality
138          </td>
139          <td>
140            == &nbsp;!= &nbsp;=== &nbsp;!==
141          </td>
142        </tr>
143        <tr>
144          <td>
145            bitwise-and
146          </td>
147          <td>
148            &amp;
149          </td>
150        </tr>
151        <tr>
152          <td>
153            bitwise-xor
154          </td>
155          <td>
156            ^
157          </td>
158        </tr>
159        <tr>
160          <td>
161            bitwise-or
162          </td>
163          <td>
164            |
165          </td>
166        </tr>
167        <tr>
168          <td>
169            logical-and
170          </td>
171          <td>
172            &amp;&amp;
173          </td>
174        </tr>
175        <tr>
176          <td>
177            logical-or
178          </td>
179          <td>
180            ||
181          </td>
182        </tr>
183        <tr>
184          <td>
185            conditional
186          </td>
187          <td>
188            ?:
189          </td>
190        </tr>
191        <tr>
192          <td>
193            assignment
194          </td>
195          <td>
196            = &nbsp;+= &nbsp;-= &nbsp;*= &nbsp;/= &nbsp;%= &nbsp;
 >&lt;&lt;= &nbsp;&gt;&gt;= &nbsp;&gt;&gt;&gt;= &nbsp;&amp;= &nbsp;
 >^= &nbsp;|=
197          </td>
198        </tr>
199        <tr>
200          <td>
n82          </td>n
83        </tr>
84        <tr>
85          <td>
86            assignment
87          </td>
88          <td>
89            = &nbsp;+= &nbsp;-= &nbsp;*= &nbsp;/= &nbsp;%= &nbsp;
>&lt;&lt;= &nbsp;&gt;&gt;= &nbsp;&gt;&gt;&gt;= &nbsp;&amp;= &nbsp; 
>^= &nbsp;|= 
90          </td>
91        </tr>
92        <tr>
93          <td>
94            conditional
95          </td>
96          <td>
97            ?:
98          </td>
99        </tr>
100        <tr>
101          <td>
102            logical-or
103          </td>
104          <td>
105            ||
106          </td>
107        </tr>
108        <tr>
109          <td>
110            logical-and
111          </td>
112          <td>
113            &amp;&amp;
114          </td>
115        </tr>
116        <tr>
117          <td>
118            bitwise-or
119          </td>
120          <td>
121            |
122          </td>
123        </tr>
124        <tr>
125          <td>
126            bitwise-xor
127          </td>
128          <td>
129            ^
130          </td>
131        </tr>
132        <tr>
133          <td>
134            bitwise-and
135          </td>
136          <td>
137            &amp;
138          </td>
139        </tr>
140        <tr>
141          <td>
142            equality
143          </td>
144          <td>
145            == &nbsp;!= &nbsp;=== &nbsp;!==
146          </td>
147        </tr>
148        <tr>
149          <td>
150            relational
151          </td>
152          <td>
153            &lt; &nbsp;&lt;= &nbsp;&gt; &nbsp;&gt;= &nbsp;in &nbs
>p;instanceof 
154          </td>
155        </tr>
156        <tr>
157          <td>
158            bitwise shift
159          </td>
160          <td>
161            &lt;&lt; &nbsp;&gt;&gt; &nbsp;&gt;&gt;&gt;
162          </td>
163        </tr>
164        <tr>
165          <td>
166            addition/subtraction
167          </td>
168          <td>
169            + &nbsp;-
170          </td>
171        </tr>
172        <tr>
173          <td>
174            multiply/divide
175          </td>
176          <td>
177            * &nbsp;/ &nbsp;%
178          </td>
179        </tr>
180        <tr>
181          <td>
182            negation/increment
183          </td>
184          <td>
185            ! &nbsp;~ &nbsp;- &nbsp;+ &nbsp;++ &nbsp;-- &nbsp;typ
>eof &nbsp;void &nbsp;delete 
186          </td>
187        </tr>
188        <tr>
189          <td>
190            call / create instance
191          </td>
192          <td>
193            () &nbsp;new
194          </td>
195        </tr>
196        <tr>
197          <td>
198            member
199          </td>
200          <td>
201            . &nbsp;[]
tt213      A more detailed version of this table, complete with links 
 >to additional details about each operator, may be found in <a hre
 >f="en/Core_JavaScript_1.5_Reference/Operators/Operator_Precedence
 >#Table">the Reference section</a>.
214    </p>
215    <p>

Back to History