diff options
author | 2017-09-27 11:42:30 -0400 | |
---|---|---|
committer | 2017-09-28 18:08:28 +0000 | |
commit | f7729c262076b88b2635e7f8d09e7f3340eea79b (patch) | |
tree | 20ecc274046d229721ae9383359e4e5ff370a2a1 /src/jumper/SkJumper_misc.h | |
parent | 6c08b7bbe47201a21d9e53a907b4baa906bb20b4 (diff) |
Move context types into STAGE() macros.
This is something I came up with while writing _lowp.cpp.
This should all be a logical no-op, but there are some code generation
changes. I'm not exactly sure why.
Change-Id: Iaad36b5298b37fe26ebd375a147a48852f98e1e4
Reviewed-on: https://skia-review.googlesource.com/52003
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Herb Derby <herb@google.com>
Diffstat (limited to 'src/jumper/SkJumper_misc.h')
-rw-r--r-- | src/jumper/SkJumper_misc.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/jumper/SkJumper_misc.h b/src/jumper/SkJumper_misc.h index 8f7ebb56ac..5db2709f05 100644 --- a/src/jumper/SkJumper_misc.h +++ b/src/jumper/SkJumper_misc.h @@ -65,7 +65,7 @@ SI void* load_and_inc(void**& program) { // Lazily resolved on first cast. Does nothing if cast to Ctx::None. struct Ctx { - using None = decltype(nullptr); + struct None {}; void* ptr; void**& program; @@ -77,7 +77,7 @@ struct Ctx { if (!ptr) { ptr = load_and_inc(program); } return (T*)ptr; } - operator None() { return nullptr; } + operator None() { return None{}; } }; #endif//SkJumper_misc_DEFINED |