summaryrefslogtreecommitdiffstats
path: root/gfx/skia/skia/src/sksl/SkSLContext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gfx/skia/skia/src/sksl/SkSLContext.cpp')
-rw-r--r--gfx/skia/skia/src/sksl/SkSLContext.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/gfx/skia/skia/src/sksl/SkSLContext.cpp b/gfx/skia/skia/src/sksl/SkSLContext.cpp
new file mode 100644
index 0000000000..d28fc9d727
--- /dev/null
+++ b/gfx/skia/skia/src/sksl/SkSLContext.cpp
@@ -0,0 +1,29 @@
+/*
+ * Copyright 2021 Google LLC
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#include "src/sksl/SkSLContext.h"
+
+#include "include/core/SkTypes.h"
+#ifdef SK_DEBUG
+#include "src/sksl/SkSLPool.h"
+#endif
+
+namespace SkSL {
+
+Context::Context(const BuiltinTypes& types, const ShaderCaps* caps, ErrorReporter& errors)
+ : fTypes(types)
+ , fCaps(caps)
+ , fErrors(&errors) {
+ SkASSERT(!Pool::IsAttached());
+}
+
+Context::~Context() {
+ SkASSERT(!Pool::IsAttached());
+}
+
+} // namespace SkSL
+