Skip to content

Commit 46a844e

Browse files
committed
Finish writing the Name Prettification section
1 parent c08b634 commit 46a844e

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

docs/for-contributors/Generator/name-processing.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,11 +200,20 @@ To learn more about this behavior, please refer to the comments in `NamePrettifi
200200

201201
#### Handling of Consecutive Acronyms
202202

203-
(TODO)
203+
Consecutive acronyms are pascal-cased, if they both are candidates for being uppercased.
204+
205+
For example, assuming a long acronym threshold of 4, `RGBA_ASTC` will be prettified as `RgbaAstc`, not `RGBAASTC`.
206+
This is because the latter is much harder to read.
204207

205208
#### Lowercase "x" between Numbers
206209

207-
(TODO)
210+
Consecutive numbers are separated by a lowercase "x". Furthermore, if a name already is in the format `2_X_2`, the "X"
211+
will be lowercased.
212+
213+
The use of the "x" is to ensure that numbers remain separated, especially because prettified names never contain
214+
underscores, which is usually how consecutive numbers are separated in native code.
215+
216+
The use of a *lowercase* x in particular is a stylistic choice and matches names like `System.Numerics.Matrix4x4`.
208217

209218
## Name Affixes
210219

0 commit comments

Comments
 (0)