mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-04-20 16:15:43 +00:00
implement name sequence parsing
This commit is contained in:
parent
3ffcac04dd
commit
873c23fb56
@ -18,4 +18,15 @@ SequenceName::SequenceName()
|
||||
|
||||
void SequenceName::ProcessMatch(CommandsParserState* state, SequenceResult<CommandsParserValue>& result) const
|
||||
{
|
||||
const auto& typeNameToken = result.NextCapture(CAPTURE_TYPE);
|
||||
|
||||
StructureInformation* type;
|
||||
std::vector<MemberInformation*> members;
|
||||
if (!state->GetTypenameAndMembersFromTypename(typeNameToken.TypeNameValue(), type, members))
|
||||
throw ParsingException(typeNameToken.GetPos(), "Unknown type");
|
||||
|
||||
if (members.empty())
|
||||
throw ParsingException(typeNameToken.GetPos(), "Need to specify a member when trying to set to a structure name.");
|
||||
|
||||
type->m_name_chain = std::move(members);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user