From Jason Turner

[lex.icon]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpx32ptw2c/{from.md → to.md} +12 -9
tmp/tmpx32ptw2c/{from.md → to.md} RENAMED
@@ -95,12 +95,12 @@ size-suffix: one of
95
  'z Z'
96
  ```
97
 
98
  In an *integer-literal*, the sequence of *binary-digit*s,
99
  *octal-digit*s, *digit*s, or *hexadecimal-digit*s is interpreted as a
100
- base N integer as shown in table [[lex.icon.base]]; the lexically first
101
- digit of the sequence of digits is the most significant.
102
 
103
  [*Note 1*: The prefix and any optional separating single quotes are
104
  ignored when determining the value. — *end note*]
105
 
106
  **Table: Base of *integer-literal*{s}** <a id="lex.icon.base">[lex.icon.base]</a>
@@ -153,16 +153,19 @@ which its value can be represented.
153
  | | | `std::size_t` |
154
  | Both `u` or `U` | `std::size_t` | `std::size_t` |
155
  | and `z` or `Z` | | |
156
 
157
 
158
- If an *integer-literal* cannot be represented by any type in its list
 
159
  and an extended integer type [[basic.fundamental]] can represent its
160
  value, it may have that extended integer type. If all of the types in
161
  the list for the *integer-literal* are signed, the extended integer type
162
- shall be signed. If all of the types in the list for the
163
- *integer-literal* are unsigned, the extended integer type shall be
164
- unsigned. If the list contains both signed and unsigned types, the
165
- extended integer type may be signed or unsigned. A program is ill-formed
166
- if one of its translation units contains an *integer-literal* that
167
- cannot be represented by any of the allowed types.
 
 
168
 
 
95
  'z Z'
96
  ```
97
 
98
  In an *integer-literal*, the sequence of *binary-digit*s,
99
  *octal-digit*s, *digit*s, or *hexadecimal-digit*s is interpreted as a
100
+ base N integer as shown in [[lex.icon.base]]; the lexically first digit
101
+ of the sequence of digits is the most significant.
102
 
103
  [*Note 1*: The prefix and any optional separating single quotes are
104
  ignored when determining the value. — *end note*]
105
 
106
  **Table: Base of *integer-literal*{s}** <a id="lex.icon.base">[lex.icon.base]</a>
 
153
  | | | `std::size_t` |
154
  | Both `u` or `U` | `std::size_t` | `std::size_t` |
155
  | and `z` or `Z` | | |
156
 
157
 
158
+ Except for *integer-literal*s containing a *size-suffix*, if the value
159
+ of an *integer-literal* cannot be represented by any type in its list
160
  and an extended integer type [[basic.fundamental]] can represent its
161
  value, it may have that extended integer type. If all of the types in
162
  the list for the *integer-literal* are signed, the extended integer type
163
+ is signed. If all of the types in the list for the *integer-literal* are
164
+ unsigned, the extended integer type is unsigned. If the list contains
165
+ both signed and unsigned types, the extended integer type may be signed
166
+ or unsigned. If an *integer-literal* cannot be represented by any of the
167
+ allowed types, the program is ill-formed.
168
+
169
+ [*Note 2*: An *integer-literal* with a `z` or `Z` suffix is ill-formed
170
+ if it cannot be represented by `std::size_t`. — *end note*]
171