Index: src/core/SkShader.cpp |
diff --git a/src/core/SkShader.cpp b/src/core/SkShader.cpp |
index e36df5b5af057df6fcacdff6277e3e7f8d667c46..5fb441a5c31a6c5dff4ed3248c5c3a535aef5e8a 100644 |
--- a/src/core/SkShader.cpp |
+++ b/src/core/SkShader.cpp |
@@ -86,6 +86,9 @@ bool SkShader::asLuminanceColor(SkColor* colorPtr) const { |
} |
SkShader::Context* SkShader::createContext(const ContextRec& rec, void* storage) const { |
+ // We currently require 16byte alignment for some of our subclasses, so assert that here. |
+ SkASSERT(SkIsAlign16((intptr_t)storage)); |
+ |
if (!this->computeTotalInverse(rec, nullptr)) { |
return nullptr; |
} |