summaryrefslogtreecommitdiffstats
path: root/source/slang/slang-serialize-ast.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/slang/slang-serialize-ast.cpp')
-rw-r--r--source/slang/slang-serialize-ast.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/slang/slang-serialize-ast.cpp b/source/slang/slang-serialize-ast.cpp
index 0e8acc3b3..bbd8237d2 100644
--- a/source/slang/slang-serialize-ast.cpp
+++ b/source/slang/slang-serialize-ast.cpp
@@ -84,8 +84,6 @@ struct ASTFieldAccess
NamePool namePool;
namePool.setRootNamePool(rootNamePool);
- SerialReader reader(classes, nullptr);
-
ASTBuilder builder(sharedASTBuilder, "Serialize Check");
DefaultSerialObjectFactory objectFactory(&builder);
@@ -96,7 +94,7 @@ struct ASTFieldAccess
const List<SerialInfo::Entry*>& writtenEntries = writer.getEntries();
List<const SerialInfo::Entry*> readEntries;
- SlangResult res = reader.loadEntries(contents.getBuffer(), contents.getCount(), readEntries);
+ SlangResult res = SerialReader::loadEntries(contents.getBuffer(), contents.getCount(), classes, readEntries);
SLANG_UNUSED(res);
SLANG_ASSERT(writtenEntries.getCount() == readEntries.getCount());
@@ -117,7 +115,9 @@ struct ASTFieldAccess
}
+ SerialReader reader(classes, nullptr);
{
+
SlangResult res = reader.load(contents.getBuffer(), contents.getCount(), &namePool);
SLANG_UNUSED(res);
}