Skip to content
Snippets Groups Projects
Commit ca790f73 authored by Kitty Barnett's avatar Kitty Barnett
Browse files

Bypass GCC template stumble by specializing getMaterialField for LLUUID

parent 5824e60c
No related branches found
No related tags found
No related merge requests found
...@@ -76,6 +76,17 @@ template<typename T> T getMaterialField(const LLSD& data, const std::string& fie ...@@ -76,6 +76,17 @@ template<typename T> T getMaterialField(const LLSD& data, const std::string& fie
return (T)LLSD(); return (T)LLSD();
} }
// GCC didn't like the generic form above for some reason
template<> LLUUID getMaterialField(const LLSD& data, const std::string& field, const LLSD::Type field_type)
{
if ( (data.has(field)) && (field_type == data[field].type()) )
{
return data[field].asUUID();
}
llerrs << "Missing or mistyped field '" << field << "' in material definition" << llendl;
return LLUUID::null;
}
/** /**
* LLMaterial class * LLMaterial class
*/ */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment