mirror of
https://github.com/airbnb/javascript.git
synced 2026-01-14 14:17:55 -05:00
Fixed capitalization
Bitshift changed to bitshift
This commit is contained in:
@@ -2003,7 +2003,7 @@ Other Style Guides
|
||||
const val = inputValue >> 0;
|
||||
```
|
||||
|
||||
- [21.5](#21.5) <a name='21.5'></a> **Note:** Be careful when using bitshift operations. Numbers are represented as [64-bit values](http://es5.github.io/#x4.3.19), but Bitshift operations always return a 32-bit integer ([source](http://es5.github.io/#x11.7)). Bitshift can lead to unexpected behavior for integer values larger than 32 bits. [Discussion](https://github.com/airbnb/javascript/issues/109). Largest signed 32-bit Int is 2,147,483,647:
|
||||
- [21.5](#21.5) <a name='21.5'></a> **Note:** Be careful when using bitshift operations. Numbers are represented as [64-bit values](http://es5.github.io/#x4.3.19), but bitshift operations always return a 32-bit integer ([source](http://es5.github.io/#x11.7)). Bitshift can lead to unexpected behavior for integer values larger than 32 bits. [Discussion](https://github.com/airbnb/javascript/issues/109). Largest signed 32-bit Int is 2,147,483,647:
|
||||
|
||||
```javascript
|
||||
2147483647 >> 0 //=> 2147483647
|
||||
|
||||
Reference in New Issue
Block a user