Fix build android ndk r16b

This commit is contained in:
nihui
2020-09-12 10:04:36 +08:00
committed by GitHub
parent 6a6e311d81
commit a9e16bd73a

View File

@@ -5417,7 +5417,7 @@ void TParseContext::setLayoutQualifier(const TSourceLoc& loc, TPublicType& publi
if (! IsPow2(value))
error(loc, "must be a power of 2", "buffer_reference_align", "");
else
publicType.qualifier.layoutBufferReferenceAlign = (unsigned int)std::log2(value);
publicType.qualifier.layoutBufferReferenceAlign = (unsigned int)log2(value);
if (nonLiteral)
error(loc, "needs a literal integer", "buffer_reference_align", "");
return;