Simplify InterfaceBlock by removing multi-dimensional array support.
Maintaining an array of Expression-based sizes is not necessary as GLSL
only supports a single dimension, and doesn't allow any expression other
than a constant integer or nothing (meaning "unsized").
Change-Id: Id58404c5c8d48786e02585d2a6391b2f3e5393e8
Bug: skia:11026
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/340456
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
diff --git a/src/sksl/SkSLDehydrator.cpp b/src/sksl/SkSLDehydrator.cpp
index 5475c21..4bbb16e 100644
--- a/src/sksl/SkSLDehydrator.cpp
+++ b/src/sksl/SkSLDehydrator.cpp
@@ -553,10 +553,7 @@
this->write(i.variable());
this->write(i.typeName());
this->write(i.instanceName());
- this->writeU8(i.sizes().count());
- for (const auto& s : i.sizes()) {
- this->write(s.get());
- }
+ this->writeS8(i.arraySize());
break;
}
case ProgramElement::Kind::kModifiers: