mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 05:39:11 +00:00
LibRegex: Annotate classes with export macro for hidden visibility
This fix demos the gradual opt-in migration process libraries can take to switch to explicit symbol exports via the FOO_API macros.
This commit is contained in:
parent
3dd2fbd041
commit
a3754a7bf1
Notes:
github-actions[bot]
2025-05-12 09:23:32 +00:00
Author: https://github.com/ayeteadoe
Commit: a3754a7bf1
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4667
Reviewed-by: https://github.com/ADKaster ✅
Reviewed-by: https://github.com/alimpfard
6 changed files with 15 additions and 13 deletions
|
@ -50,7 +50,7 @@ struct NamedCaptureGroup {
|
|||
size_t alternative_id;
|
||||
};
|
||||
|
||||
class Parser {
|
||||
class REGEX_API Parser {
|
||||
public:
|
||||
struct Result {
|
||||
ByteCode bytecode;
|
||||
|
@ -137,7 +137,7 @@ protected:
|
|||
ParserState m_parser_state;
|
||||
};
|
||||
|
||||
class AbstractPosixParser : public Parser {
|
||||
class REGEX_API AbstractPosixParser : public Parser {
|
||||
protected:
|
||||
explicit AbstractPosixParser(Lexer& lexer)
|
||||
: Parser(lexer)
|
||||
|
@ -152,7 +152,7 @@ protected:
|
|||
ALWAYS_INLINE bool parse_bracket_expression(Vector<CompareTypeAndValuePair>&, size_t&);
|
||||
};
|
||||
|
||||
class PosixBasicParser final : public AbstractPosixParser {
|
||||
class REGEX_API PosixBasicParser final : public AbstractPosixParser {
|
||||
public:
|
||||
explicit PosixBasicParser(Lexer& lexer)
|
||||
: AbstractPosixParser(lexer)
|
||||
|
@ -181,7 +181,7 @@ private:
|
|||
size_t m_current_capture_group_depth { 0 };
|
||||
};
|
||||
|
||||
class PosixExtendedParser final : public AbstractPosixParser {
|
||||
class REGEX_API PosixExtendedParser final : public AbstractPosixParser {
|
||||
constexpr static auto default_options = static_cast<PosixFlags>(AllFlags::SingleLine) | static_cast<PosixFlags>(AllFlags::Internal_ConsiderNewline);
|
||||
|
||||
public:
|
||||
|
@ -208,7 +208,7 @@ private:
|
|||
ALWAYS_INLINE bool parse_repetition_symbol(ByteCode&, size_t&);
|
||||
};
|
||||
|
||||
class ECMA262Parser final : public Parser {
|
||||
class REGEX_API ECMA262Parser final : public Parser {
|
||||
constexpr static ECMAScriptOptions default_options = static_cast<ECMAScriptFlags>(AllFlags::Internal_ConsiderNewline);
|
||||
|
||||
public:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue