Kaydet (Commit) 037a1ada authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Work around bug in Clang 3.2 FunctionDecl::isInlined

Change-Id: I214a9745f27c27868b3e74785cf7138fc1db1943
üst b7502a61
......@@ -497,7 +497,18 @@ bool SalBool::VisitFunctionDecl(FunctionDecl const * decl) {
|| (isInUnoIncludeFile(
compiler.getSourceManager().getSpellingLoc(
f->getNameInfo().getLoc()))
&& (!f->isInlined() || f->hasAttr<DeprecatedAttr>()))))
&& (
// Clang 3.2 FunctionDecl::isInlined doesn't work as advertised ("Determine
// whether this function should be inlined, because it is either marked 'inline'
// or 'constexpr' or is a member function of a class that was defined in the
// class body.") but mis-classifies salhelper::Timer's isTicking, isExpired, and
// expiresBefore members as defined in salhelper/source/timer.cxx as inlined:
#if (__clang_major__ == 3 && __clang_minor__ >= 3) || __clang_major__ > 3
!f->isInlined()
#else
true
#endif
|| f->hasAttr<DeprecatedAttr>()))))
{
SourceLocation loc { decl->getLocStart() };
SourceLocation l { compiler.getSourceManager().getExpansionLoc(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment