Skip to content

Commit

Permalink
Account for valueless PVL keywords that are not reserved keywords
Browse files Browse the repository at this point in the history
  • Loading branch information
acpaquette committed Jul 31, 2024
1 parent 778e471 commit 33bbff2
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion isis/src/base/objs/PvlKeyword/PvlKeyword.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1391,8 +1391,24 @@ namespace Isis {
KEYWORD
Well, no value/units may exist so we're done processing this keyword.
Now check if it's a reserved keyword that is valueless
*/
return 1; // Valid & Successful
bool allowedValueless = false;
std::vector<QString> reservedKeywordNames = {"OBJECT",
"BEGIN_OBJECT",
"END_OBJECT",
"ENDOBJECT",
"GROUP",
"END_GROUP",
"ENDGROUP",
"END"};
QString keywordNameUpper = keywordName.toUpper();
for (auto reservedKeywordName : reservedKeywordNames) {
if (keywordNameUpper == reservedKeywordName) {
allowedValueless = true;
}
}
return allowedValueless;
}

// if we don't have an equal, then we have a problem - an invalid symbol.
Expand Down

0 comments on commit 33bbff2

Please sign in to comment.