mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 16:07:46 +00:00
LibCpp: Rename m_definitions=>m_preprocessor_definitions
This commit is contained in:
parent
de9be7cd70
commit
5c42dc854d
3 changed files with 6 additions and 6 deletions
|
@ -14,7 +14,7 @@
|
|||
namespace Cpp {
|
||||
|
||||
Parser::Parser(const StringView& program, const String& filename, Preprocessor::Definitions&& definitions)
|
||||
: m_definitions(move(definitions))
|
||||
: m_preprocessor_definitions(move(definitions))
|
||||
, m_filename(filename)
|
||||
{
|
||||
initialize_program_tokens(program);
|
||||
|
@ -38,7 +38,7 @@ void Parser::initialize_program_tokens(const StringView& program)
|
|||
if (token.type() == Token::Type::Whitespace)
|
||||
continue;
|
||||
if (token.type() == Token::Type::Identifier) {
|
||||
if (auto defined_value = m_definitions.find(text_of_token(token)); defined_value != m_definitions.end()) {
|
||||
if (auto defined_value = m_preprocessor_definitions.find(text_of_token(token)); defined_value != m_preprocessor_definitions.end()) {
|
||||
add_tokens_for_preprocessor(token, defined_value->value);
|
||||
m_replaced_preprocessor_tokens.append({ token, defined_value->value });
|
||||
continue;
|
||||
|
|
|
@ -34,7 +34,7 @@ public:
|
|||
StringView text_of_token(const Cpp::Token& token) const;
|
||||
void print_tokens() const;
|
||||
const Vector<String>& errors() const { return m_state.errors; }
|
||||
const Preprocessor::Definitions& definitions() const { return m_definitions; }
|
||||
const Preprocessor::Definitions& preprocessor_definitions() const { return m_preprocessor_definitions; }
|
||||
|
||||
struct TokenAndPreprocessorDefinition {
|
||||
Token token;
|
||||
|
@ -169,7 +169,7 @@ private:
|
|||
Vector<StringView> parse_type_qualifiers();
|
||||
Vector<StringView> parse_function_qualifiers();
|
||||
|
||||
Preprocessor::Definitions m_definitions;
|
||||
Preprocessor::Definitions m_preprocessor_definitions;
|
||||
String m_filename;
|
||||
Vector<Token> m_tokens;
|
||||
State m_state;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue