mirror of
https://github.com/SerenityOS/serenity
synced 2026-05-05 22:52:10 +02:00
LibJS: Always inline Lexer::current_code_point()
This gives a ~1% speedup when parsing the largest Discord JS file.
This commit is contained in:
@@ -358,7 +358,7 @@ ALWAYS_INLINE bool Lexer::is_unicode_character() const
|
||||
return (m_current_char & 128) != 0;
|
||||
}
|
||||
|
||||
u32 Lexer::current_code_point() const
|
||||
ALWAYS_INLINE u32 Lexer::current_code_point() const
|
||||
{
|
||||
static constexpr const u32 REPLACEMENT_CHARACTER = 0xFFFD;
|
||||
if (m_position == 0)
|
||||
|
||||
Reference in New Issue
Block a user