![]() |
ToyGine2 26.2.0
Game Engine for retro consoles
|
Inline implementations for toy::validateFormatPattern(). More...
Go to the source code of this file.
Namespaces | |
| namespace | toy |
| Root namespace containing all engine modules. | |
| namespace | toy::anonymous_namespace{format_pattern.inl} |
Enumerations | |
| enum class | toy::anonymous_namespace{format_pattern.inl}::PlaceholderMode { toy::anonymous_namespace{format_pattern.inl}::none , toy::anonymous_namespace{format_pattern.inl}::autoIndex , toy::anonymous_namespace{format_pattern.inl}::positional } |
Auto vs positional placeholder mode while scanning; used only inside validateFormatImpl(). More... | |
Functions | |
| constexpr bool | toy::anonymous_namespace{format_pattern.inl}::consumeEscapedBrace (const CStringView &string, size_t length, size_t &position, char brace) noexcept |
Consumes a literal {{ or }} pair at position when present. | |
| constexpr FormatPatternValidationError | toy::anonymous_namespace{format_pattern.inl}::parsePositionalIndex (const CStringView &string, size_t length, size_t &position, size_t argCount) noexcept |
Reads the decimal index and closing } for a positional placeholder. | |
| constexpr FormatPatternValidationError | toy::anonymous_namespace{format_pattern.inl}::parseOpeningBrace (const CStringView &string, size_t length, size_t &position, size_t &autoCount, PlaceholderMode &mode, size_t argCount) noexcept |
Parses a non-escaped opening brace: auto {}, positional {N}, or a structural error. | |
| constexpr FormatPatternValidationError | toy::anonymous_namespace{format_pattern.inl}::reconcilePlaceholderMode (PlaceholderMode mode, size_t autoCount, size_t argCount) noexcept |
| Verifies placeholder counts against argCount after the whole pattern has been scanned. | |
| constexpr FormatPatternValidationError | toy::anonymous_namespace{format_pattern.inl}::validateFormatImpl (const CStringView &string, size_t argCount) noexcept |
Validates auto-indexed {} and positional {N} placeholders for argCount arguments. | |
| constexpr FormatPatternValidationError | toy::validateFormatPattern (const CStringView &string, size_t argCount) noexcept |
Validates auto-indexed {} and positional {N} placeholders for argCount arguments. | |
Inline implementations for toy::validateFormatPattern().
Scanning helpers live in an unnamed namespace so they are not named toy sub-entities in the include graph.