Changed parsing-conversion behaviour of the void value. It is now less strict.
This commit is contained in:
@@ -180,6 +180,12 @@ Value* Hazelnupp::ParseValue(const std::vector<std::string>& values, const Param
|
||||
(constraint->wantedType == DATA_TYPE::LIST))
|
||||
return new ListValue();
|
||||
|
||||
// Is a string forced via a constraint? If yes, return an empty string
|
||||
if ((constrainType) &&
|
||||
(constraint->wantedType == DATA_TYPE::STRING))
|
||||
return new StringValue("");
|
||||
|
||||
// Else, just return the void type
|
||||
return new VoidValue;
|
||||
}
|
||||
|
||||
|
@@ -159,6 +159,7 @@
|
||||
<ClInclude Include="ParamConstraint.h" />
|
||||
<ClInclude Include="Parameter.h" />
|
||||
<ClInclude Include="DataType.h" />
|
||||
<ClInclude Include="Placeholders.h" />
|
||||
<ClInclude Include="StringTools.h" />
|
||||
<ClInclude Include="StringValue.h" />
|
||||
<ClInclude Include="Value.h" />
|
||||
|
@@ -83,5 +83,8 @@
|
||||
<ClInclude Include="HazelnuppException.h">
|
||||
<Filter>Headerdateien</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Placeholders.h">
|
||||
<Filter>Headerdateien</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
</Project>
|
Reference in New Issue
Block a user