From Jason Turner

[expr.bit.and]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpirp3l8vm/{from.md → to.md} +10 -4
tmp/tmpirp3l8vm/{from.md → to.md} RENAMED
@@ -1,12 +1,18 @@
1
- ## Bitwise AND operator <a id="expr.bit.and">[[expr.bit.and]]</a>
2
 
3
  ``` bnf
4
  and-expression:
5
  equality-expression
6
  and-expression '&' equality-expression
7
  ```
8
 
9
- The usual arithmetic conversions are performed; the result is the
10
- bitwise function of the operands. The operator applies only to integral
11
- or unscoped enumeration operands.
 
 
 
 
 
 
12
 
 
1
+ ### Bitwise AND operator <a id="expr.bit.and">[[expr.bit.and]]</a>
2
 
3
  ``` bnf
4
  and-expression:
5
  equality-expression
6
  and-expression '&' equality-expression
7
  ```
8
 
9
+ The `&` operator groups left-to-right. The operands shall be of integral
10
+ or unscoped enumeration type. The usual arithmetic conversions
11
+ [[expr.arith.conv]] are performed. Given the coefficients `xᵢ` and `yᵢ`
12
+ of the base-2 representation [[basic.fundamental]] of the converted
13
+ operands `x` and `y`, the coefficient `rᵢ` of the base-2 representation
14
+ of the result `r` is 1 if both `xᵢ` and `yᵢ` are 1, and 0 otherwise.
15
+
16
+ [*Note 1*: The result is the bitwise function of the
17
+ operands. — *end note*]
18