Skip to content

Commit

Permalink
Fix formatting of two remaining files
Browse files Browse the repository at this point in the history
  • Loading branch information
Laupetin committed Nov 19, 2023
1 parent 3f71466 commit ccafc87
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 9 deletions.
20 changes: 12 additions & 8 deletions src/ObjLoading/Parsing/LocalizeFile/LocalizeFileParser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,19 @@ LocalizeFileParser::LocalizeFileParser(SimpleLexer* lexer, GameLanguage language

const std::vector<AbstractParser<SimpleParserValue, LocalizeFileParserState>::sequence_t*>& LocalizeFileParser::GetTestsForState()
{
static std::vector<sequence_t*> tests({new SequenceLocalizeFileReference(),
new SequenceLocalizeFileConfig(),
new SequenceLocalizeFileNotes(),
new SequenceLocalizeFileVersion(),
new SequenceLocalizeFileEndMarker(),
new SequenceLocalizeFileLanguageValue(),
new SequenceLocalizeFileConsumeEmptyLines(),});
static std::vector<sequence_t*> tests({
new SequenceLocalizeFileReference(),
new SequenceLocalizeFileConfig(),
new SequenceLocalizeFileNotes(),
new SequenceLocalizeFileVersion(),
new SequenceLocalizeFileEndMarker(),
new SequenceLocalizeFileLanguageValue(),
new SequenceLocalizeFileConsumeEmptyLines(),
});

static std::vector<sequence_t*> noTests({new SequenceLocalizeFileConsumeEmptyLines(),});
static std::vector<sequence_t*> noTests({
new SequenceLocalizeFileConsumeEmptyLines(),
});

return !m_state->m_end ? tests : noTests;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,12 @@ SequenceLocalizeFileReference::SequenceLocalizeFileReference()

AddMatchers({
create.Keyword("REFERENCE"),
create.Or({create.Identifier(), create.String(),}).Capture(CAPTURE_REFERENCE_NAME),
create
.Or({
create.Identifier(),
create.String(),
})
.Capture(CAPTURE_REFERENCE_NAME),
create.Type(SimpleParserValueType::NEW_LINE),
});
}
Expand Down

0 comments on commit ccafc87

Please sign in to comment.