mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 12:17:44 +00: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:
parent
50a446a5d1
commit
92e0378dbd
1 changed files with 1 additions and 1 deletions
|
@ -358,7 +358,7 @@ ALWAYS_INLINE bool Lexer::is_unicode_character() const
|
||||||
return (m_current_char & 128) != 0;
|
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;
|
static constexpr const u32 REPLACEMENT_CHARACTER = 0xFFFD;
|
||||||
if (m_position == 0)
|
if (m_position == 0)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue