diff options
| author | Ellie Hermaszewska <ellieh@nvidia.com> | 2024-10-29 14:49:26 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-10-29 14:49:26 +0800 |
| commit | f65d756bff8d4c5cbc15bd0322a2ae8e6b896a21 (patch) | |
| tree | ea1d61342cd29368e19135000ec2948813096205 /source/slang/slang-mangled-lexer.h | |
| parent | a729c15e9dce9f5116a38afc66329ab2ca4cea54 (diff) | |
format
* format
* Minor test fixes
* enable checking cpp format in ci
Diffstat (limited to 'source/slang/slang-mangled-lexer.h')
| -rw-r--r-- | source/slang/slang-mangled-lexer.h | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/source/slang/slang-mangled-lexer.h b/source/slang/slang-mangled-lexer.h index c9d051259..8436f6127 100644 --- a/source/slang/slang-mangled-lexer.h +++ b/source/slang/slang-mangled-lexer.h @@ -4,7 +4,6 @@ #include "../core/slang-basic.h" #include "../core/slang-char-util.h" - #include "slang-compiler.h" namespace Slang @@ -15,7 +14,7 @@ Expects names to be correctly constructed - any errors will cause asserts/failur class MangledLexer { public: - /// Reads a count at current position + /// Reads a count at current position UInt readCount(); void readGenericParam(); @@ -42,18 +41,17 @@ public: UInt readParamCount(); - /// Returns the character at the current position + /// Returns the character at the current position char peekChar() { return *m_cursor; } - // Returns the current character and moves to next character. + // Returns the current character and moves to next character. char nextChar() { return *m_cursor++; } static String unescapeString(UnownedStringSlice str); - /// Ctor + /// Ctor SLANG_FORCE_INLINE MangledLexer(const UnownedStringSlice& slice); private: - // Call at the beginning of a mangled name, // to strip off the main prefix void _start() { _expect("_S"); } @@ -73,9 +71,7 @@ private: // -------------------------------------------------------------------------- - SLANG_FORCE_INLINE MangledLexer::MangledLexer(const UnownedStringSlice& slice) - : m_cursor(slice.begin()) - , m_begin(slice.begin()) - , m_end(slice.end()) + : m_cursor(slice.begin()), m_begin(slice.begin()), m_end(slice.end()) { _start(); } @@ -126,9 +122,9 @@ SLANG_INLINE void MangledLexer::_expect(char c) struct MangledNameParser { - /// Tries to extract the module name from this mangled name. + /// Tries to extract the module name from this mangled name. static SlangResult parseModuleName(const UnownedStringSlice& in, String& outModuleName); }; -} +} // namespace Slang #endif |
