summaryrefslogtreecommitdiffstats
path: root/source/compiler-core/slang-json-source-map-util.cpp
diff options
context:
space:
mode:
authorEllie Hermaszewska <ellieh@nvidia.com>2023-03-30 00:25:15 +0800
committerGitHub <noreply@github.com>2023-03-29 12:25:15 -0400
commitbbf12c20dfa7d835a430decc4e029ad467293f20 (patch)
tree628c74e7b3ce58412cff5f4bfc1da7319ac6c81b /source/compiler-core/slang-json-source-map-util.cpp
parent64fe75caadf75a0fefccadb8ffe6fb3ad02ca984 (diff)
Add missing initializer in json source map decoding (#2752)
Diffstat (limited to 'source/compiler-core/slang-json-source-map-util.cpp')
-rw-r--r--source/compiler-core/slang-json-source-map-util.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/compiler-core/slang-json-source-map-util.cpp b/source/compiler-core/slang-json-source-map-util.cpp
index f7c1711f3..5782b0e89 100644
--- a/source/compiler-core/slang-json-source-map-util.cpp
+++ b/source/compiler-core/slang-json-source-map-util.cpp
@@ -180,7 +180,7 @@ void _encode(Index v, StringBuilder& out)
/* static */SlangResult JSONSourceMapUtil::decode(JSONContainer* container, JSONValue root, DiagnosticSink* sink, RefPtr<SourceMap>& out)
{
- RefPtr<SourceMap> sourceMap;
+ RefPtr<SourceMap> sourceMap(new SourceMap);
// Let's try and decode the JSON into native types to make this easier...
RttiTypeFuncsMap typeMap = JSONNativeUtil::getTypeFuncsMap();