populate GlobalCode.sourceMaps

This commit is contained in:
2025-12-11 14:06:54 -07:00
parent 92f0d22805
commit 3edf0324c7
6 changed files with 113 additions and 21 deletions

View File

@@ -26,7 +26,7 @@ public static class SlangPatches
// guard to ensure we have valid IC10 before continuing
if (
!SlangPlugin.IsSlangSource(ref result)
|| !Marshal.CompileFromString(result, out string compiled)
|| !Marshal.CompileFromString(result, out var compiled, out var sourceMap)
|| string.IsNullOrEmpty(compiled)
)
{
@@ -37,6 +37,7 @@ public static class SlangPatches
// Ensure we cache this compiled code for later retreival.
GlobalCode.SetSource(thisRef, result);
GlobalCode.SetSourceMap(thisRef, sourceMap);
_currentlyEditingGuid = null;