diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/RecordTestUtils.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/RecordTestUtils.h b/tests/RecordTestUtils.h index 853ee21908..5701dec5d9 100644 --- a/tests/RecordTestUtils.h +++ b/tests/RecordTestUtils.h @@ -33,9 +33,20 @@ static const T* assert_type(skiatest::Reporter* r, const SkRecord& record, int i record.visit(index, reader); REPORTER_ASSERT(r, T::kType == reader.type); REPORTER_ASSERT(r, SkToBool(reader.ptr)); + + // This appears to be a bug in GCC 6.3. There's no problem here. +#if defined(__GNUC__) && !defined(__clang__) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wreturn-local-addr" +#endif return reader.ptr; +#if defined(__GNUC__) && !defined(__clang__) + #pragma GCC diagnostic pop +#endif } + + template <typename DrawT> struct MatchType { template <typename T> int operator()(const T&) { return 0; } int operator()(const DrawT&) { return 1; } |