@ttsc/playground 0.30.4 → 0.31.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (180) hide show
  1. package/README.md +6 -4
  2. package/lib/src/compiler/buildTsconfigJSON.d.ts +5 -0
  3. package/lib/src/compiler/buildTsconfigJSON.js +5 -0
  4. package/lib/src/compiler/buildTsconfigJSON.js.map +1 -1
  5. package/lib/src/compiler/createTypiaSourcePackMount.d.ts +9 -3
  6. package/lib/src/compiler/createTypiaSourcePackMount.js +9 -3
  7. package/lib/src/compiler/createTypiaSourcePackMount.js.map +1 -1
  8. package/lib/src/compiler/createWorkerCompiler.d.ts +5 -0
  9. package/lib/src/compiler/createWorkerCompiler.js +5 -0
  10. package/lib/src/compiler/createWorkerCompiler.js.map +1 -1
  11. package/lib/src/compiler/installDependenciesIntoMemFS.d.ts +5 -0
  12. package/lib/src/compiler/installDependenciesIntoMemFS.js +5 -0
  13. package/lib/src/compiler/installDependenciesIntoMemFS.js.map +1 -1
  14. package/lib/src/compiler/installTypiaSourcePack.d.ts +7 -2
  15. package/lib/src/compiler/installTypiaSourcePack.js +7 -2
  16. package/lib/src/compiler/installTypiaSourcePack.js.map +1 -1
  17. package/lib/src/compiler/internal/createWorkerCompilerService.d.ts +31 -0
  18. package/lib/src/compiler/internal/createWorkerCompilerService.js +22 -4
  19. package/lib/src/compiler/internal/createWorkerCompilerService.js.map +1 -1
  20. package/lib/src/compiler/internal/joinUnder.d.ts +5 -0
  21. package/lib/src/compiler/internal/joinUnder.js +5 -0
  22. package/lib/src/compiler/internal/joinUnder.js.map +1 -1
  23. package/lib/src/compiler/internal/parseLintDiagnostics.d.ts +5 -0
  24. package/lib/src/compiler/internal/parseLintDiagnostics.js +8 -3
  25. package/lib/src/compiler/internal/parseLintDiagnostics.js.map +1 -1
  26. package/lib/src/compiler/internal/safeParseTypiaTransform.d.ts +14 -1
  27. package/lib/src/compiler/internal/safeParseTypiaTransform.js +12 -1
  28. package/lib/src/compiler/internal/safeParseTypiaTransform.js.map +1 -1
  29. package/lib/src/compiler/lineColumnOf.d.ts +9 -1
  30. package/lib/src/compiler/lineColumnOf.js +23 -7
  31. package/lib/src/compiler/lineColumnOf.js.map +1 -1
  32. package/lib/src/compiler/loadTypiaSourcePack.d.ts +23 -1
  33. package/lib/src/compiler/loadTypiaSourcePack.js +48 -12
  34. package/lib/src/compiler/loadTypiaSourcePack.js.map +1 -1
  35. package/lib/src/compiler/mapDiagnostic.d.ts +7 -2
  36. package/lib/src/compiler/mapDiagnostic.js +53 -6
  37. package/lib/src/compiler/mapDiagnostic.js.map +1 -1
  38. package/lib/src/compiler/normalizeError.d.ts +9 -1
  39. package/lib/src/compiler/normalizeError.js +9 -1
  40. package/lib/src/compiler/normalizeError.js.map +1 -1
  41. package/lib/src/compiler/normalizeNodeModulePath.d.ts +5 -0
  42. package/lib/src/compiler/normalizeNodeModulePath.js +5 -0
  43. package/lib/src/compiler/normalizeNodeModulePath.js.map +1 -1
  44. package/lib/src/compiler/pickEmittedJS.d.ts +9 -2
  45. package/lib/src/compiler/pickEmittedJS.js +23 -6
  46. package/lib/src/compiler/pickEmittedJS.js.map +1 -1
  47. package/lib/src/npm/collectExternalPackageNames.d.ts +17 -0
  48. package/lib/src/npm/collectExternalPackageNames.js +51 -11
  49. package/lib/src/npm/collectExternalPackageNames.js.map +1 -1
  50. package/lib/src/npm/installPlaygroundDependencies.d.ts +10 -2
  51. package/lib/src/npm/installPlaygroundDependencies.js +18 -4
  52. package/lib/src/npm/installPlaygroundDependencies.js.map +1 -1
  53. package/lib/src/npm/internal/npmRegistry.d.ts +149 -2
  54. package/lib/src/npm/internal/npmRegistry.js +95 -4
  55. package/lib/src/npm/internal/npmRegistry.js.map +1 -1
  56. package/lib/src/npm/packageNameFromSpecifier.d.ts +5 -0
  57. package/lib/src/npm/packageNameFromSpecifier.js +7 -0
  58. package/lib/src/npm/packageNameFromSpecifier.js.map +1 -1
  59. package/lib/src/react/ConsoleViewer.d.ts +9 -0
  60. package/lib/src/react/ConsoleViewer.js +11 -2
  61. package/lib/src/react/ConsoleViewer.js.map +1 -1
  62. package/lib/src/react/DependencyProgressModal.d.ts +9 -0
  63. package/lib/src/react/DependencyProgressModal.js +9 -0
  64. package/lib/src/react/DependencyProgressModal.js.map +1 -1
  65. package/lib/src/react/DiagnosticsPanel.d.ts +9 -0
  66. package/lib/src/react/DiagnosticsPanel.js +9 -0
  67. package/lib/src/react/DiagnosticsPanel.js.map +1 -1
  68. package/lib/src/react/ExamplePicker.d.ts +9 -0
  69. package/lib/src/react/ExamplePicker.js +14 -2
  70. package/lib/src/react/ExamplePicker.js.map +1 -1
  71. package/lib/src/react/LintPane.d.ts +5 -0
  72. package/lib/src/react/LintPane.js +5 -0
  73. package/lib/src/react/LintPane.js.map +1 -1
  74. package/lib/src/react/OptionsPanel.d.ts +10 -0
  75. package/lib/src/react/OptionsPanel.js +19 -4
  76. package/lib/src/react/OptionsPanel.js.map +1 -1
  77. package/lib/src/react/PlaygroundShell.d.ts +13 -0
  78. package/lib/src/react/PlaygroundShell.js +17 -5
  79. package/lib/src/react/PlaygroundShell.js.map +1 -1
  80. package/lib/src/react/ResultViewer.d.ts +5 -0
  81. package/lib/src/react/ResultViewer.js +27 -7
  82. package/lib/src/react/ResultViewer.js.map +1 -1
  83. package/lib/src/react/SourceEditor.d.ts +10 -0
  84. package/lib/src/react/SourceEditor.js +10 -0
  85. package/lib/src/react/SourceEditor.js.map +1 -1
  86. package/lib/src/react/createCompilerClient.d.ts +5 -0
  87. package/lib/src/react/createCompilerClient.js +5 -0
  88. package/lib/src/react/createCompilerClient.js.map +1 -1
  89. package/lib/src/react/internal/PlaygroundCompilerLifecycle.d.ts +64 -1
  90. package/lib/src/react/internal/PlaygroundCompilerLifecycle.js +48 -0
  91. package/lib/src/react/internal/PlaygroundCompilerLifecycle.js.map +1 -1
  92. package/lib/src/react/internal/PlaygroundExecutionLifecycle.d.ts +42 -2
  93. package/lib/src/react/internal/PlaygroundExecutionLifecycle.js +18 -0
  94. package/lib/src/react/internal/PlaygroundExecutionLifecycle.js.map +1 -1
  95. package/lib/src/react/internal/recoverTerminalCompilerWorker.d.ts +46 -4
  96. package/lib/src/react/internal/recoverTerminalCompilerWorker.js +14 -1
  97. package/lib/src/react/internal/recoverTerminalCompilerWorker.js.map +1 -1
  98. package/lib/src/sandbox/createSandboxRequire.d.ts +12 -3
  99. package/lib/src/sandbox/createSandboxRequire.js +26 -12
  100. package/lib/src/sandbox/createSandboxRequire.js.map +1 -1
  101. package/lib/src/sandbox/loadTypiaRuntimePack.d.ts +22 -0
  102. package/lib/src/sandbox/loadTypiaRuntimePack.js +30 -1
  103. package/lib/src/sandbox/loadTypiaRuntimePack.js.map +1 -1
  104. package/lib/src/structures/IBuildTsconfigOptions.d.ts +9 -1
  105. package/lib/src/structures/ICompilerService.d.ts +112 -2
  106. package/lib/src/structures/IConsoleMessage.d.ts +5 -0
  107. package/lib/src/structures/ICreateCompilerClientOptions.d.ts +9 -2
  108. package/lib/src/structures/ICreateWorkerCompilerOptions.d.ts +11 -3
  109. package/lib/src/structures/IInstallTypiaSourcePackOptions.d.ts +7 -1
  110. package/lib/src/structures/ILintPluginConfig.d.ts +8 -1
  111. package/lib/src/structures/ILoadTypiaRuntimePackOptions.d.ts +8 -1
  112. package/lib/src/structures/IOptionToggle.d.ts +5 -0
  113. package/lib/src/structures/IPlaygroundDependencyInstallOptions.d.ts +41 -6
  114. package/lib/src/structures/IPlaygroundDependencyInstallResult.d.ts +8 -1
  115. package/lib/src/structures/IPlaygroundDependencyPackage.d.ts +9 -1
  116. package/lib/src/structures/IPlaygroundDependencyProgress.d.ts +9 -1
  117. package/lib/src/structures/IPlaygroundDependencyProgressPhase.d.ts +7 -2
  118. package/lib/src/structures/IPlaygroundDependencyRequest.d.ts +8 -1
  119. package/lib/src/structures/IPlaygroundExample.d.ts +5 -0
  120. package/lib/src/structures/IPlaygroundInstalledDependency.d.ts +8 -1
  121. package/lib/src/structures/IPlaygroundShellProps.d.ts +53 -19
  122. package/lib/src/structures/ISourceEditorProps.d.ts +16 -1
  123. package/lib/src/structures/ITransformOptions.d.ts +5 -0
  124. package/lib/src/structures/ITypiaPluginConfig.d.ts +25 -7
  125. package/package.json +6 -4
  126. package/src/compiler/buildTsconfigJSON.ts +5 -0
  127. package/src/compiler/createTypiaSourcePackMount.ts +9 -3
  128. package/src/compiler/createWorkerCompiler.ts +5 -0
  129. package/src/compiler/installDependenciesIntoMemFS.ts +5 -0
  130. package/src/compiler/installTypiaSourcePack.ts +7 -2
  131. package/src/compiler/internal/createWorkerCompilerService.ts +47 -4
  132. package/src/compiler/internal/joinUnder.ts +5 -0
  133. package/src/compiler/internal/parseLintDiagnostics.ts +8 -3
  134. package/src/compiler/internal/safeParseTypiaTransform.ts +25 -2
  135. package/src/compiler/lineColumnOf.ts +24 -8
  136. package/src/compiler/loadTypiaSourcePack.ts +57 -14
  137. package/src/compiler/mapDiagnostic.ts +67 -7
  138. package/src/compiler/normalizeError.ts +9 -1
  139. package/src/compiler/normalizeNodeModulePath.ts +5 -0
  140. package/src/compiler/pickEmittedJS.ts +22 -5
  141. package/src/npm/collectExternalPackageNames.ts +54 -13
  142. package/src/npm/installPlaygroundDependencies.ts +18 -6
  143. package/src/npm/internal/npmRegistry.ts +156 -4
  144. package/src/npm/packageNameFromSpecifier.ts +6 -0
  145. package/src/react/ConsoleViewer.tsx +10 -1
  146. package/src/react/DependencyProgressModal.tsx +9 -0
  147. package/src/react/DiagnosticsPanel.tsx +9 -0
  148. package/src/react/ExamplePicker.tsx +22 -6
  149. package/src/react/LintPane.tsx +5 -0
  150. package/src/react/OptionsPanel.tsx +22 -4
  151. package/src/react/PlaygroundShell.tsx +17 -5
  152. package/src/react/ResultViewer.tsx +28 -7
  153. package/src/react/SourceEditor.tsx +10 -0
  154. package/src/react/createCompilerClient.ts +5 -0
  155. package/src/react/internal/PlaygroundCompilerLifecycle.ts +64 -1
  156. package/src/react/internal/PlaygroundExecutionLifecycle.ts +44 -2
  157. package/src/react/internal/recoverTerminalCompilerWorker.ts +48 -4
  158. package/src/sandbox/createSandboxRequire.ts +28 -15
  159. package/src/sandbox/loadTypiaRuntimePack.ts +35 -2
  160. package/src/structures/IBuildTsconfigOptions.ts +13 -1
  161. package/src/structures/ICompilerService.ts +119 -2
  162. package/src/structures/IConsoleMessage.ts +5 -0
  163. package/src/structures/ICreateCompilerClientOptions.ts +9 -2
  164. package/src/structures/ICreateWorkerCompilerOptions.ts +15 -3
  165. package/src/structures/IInstallTypiaSourcePackOptions.ts +11 -1
  166. package/src/structures/ILintPluginConfig.ts +8 -1
  167. package/src/structures/ILoadTypiaRuntimePackOptions.ts +8 -1
  168. package/src/structures/IOptionToggle.ts +5 -0
  169. package/src/structures/IPlaygroundDependencyInstallOptions.ts +56 -6
  170. package/src/structures/IPlaygroundDependencyInstallResult.ts +12 -1
  171. package/src/structures/IPlaygroundDependencyPackage.ts +11 -1
  172. package/src/structures/IPlaygroundDependencyProgress.ts +9 -1
  173. package/src/structures/IPlaygroundDependencyProgressPhase.ts +7 -2
  174. package/src/structures/IPlaygroundDependencyRequest.ts +10 -1
  175. package/src/structures/IPlaygroundExample.ts +6 -0
  176. package/src/structures/IPlaygroundInstalledDependency.ts +11 -1
  177. package/src/structures/IPlaygroundShellProps.ts +62 -22
  178. package/src/structures/ISourceEditorProps.ts +20 -1
  179. package/src/structures/ITransformOptions.ts +7 -0
  180. package/src/structures/ITypiaPluginConfig.ts +31 -7
package/README.md CHANGED
@@ -23,7 +23,7 @@ The React components use Tailwind 4 utility classes. See [Tailwind setup](#tailw
23
23
 
24
24
  | Layer | Exports |
25
25
  | --- | --- |
26
- | **Worker core** | `createWorkerCompiler`, `buildTsconfigJSON`, `installDependenciesIntoMemFS`, `mapDiagnostic`, `pickEmittedJS`, `DEFAULT_*` constants |
26
+ | **Worker core** | `createWorkerCompiler`, `buildTsconfigJSON`, `installDependenciesIntoMemFS`, `mapDiagnostic`, `lineColumnOf`, `pickEmittedJS`, `normalizeError`, `normalizeNodeModulePath`, `DEFAULT_*` constants |
27
27
  | **Typia integration** | `createTypiaSourcePackMount`, `installTypiaSourcePack`, `loadTypiaSourcePack` |
28
28
  | **Npm installer** | `installPlaygroundDependencies`, `collectExternalPackageNames`, `packageNameFromSpecifier`, `BUILT_IN_PLAYGROUND_PACKAGES` |
29
29
  | **Execute sandbox** | `createSandboxRequire`, `loadTypiaRuntimePack` |
@@ -101,7 +101,7 @@ export default function SitePlayground() {
101
101
  }
102
102
  ```
103
103
 
104
- `sandbox.signal` aborts when source or compiler options change, another Execute starts, or the shell unmounts. Pass it to setup work such as `loadTypiaRuntimePack(url, { signal: sandbox.signal })`. Runtime-pack loads share one request per URL and evict a rejected request so the next Execute retries. Nothing else ends the load: how long a fetch takes belongs to the network, not to a number chosen here. A signal cannot preempt synchronous evaluated user code; use an isolated executor with its own termination mechanism when that boundary matters.
104
+ `sandbox.signal` aborts when source or compiler options change, another Execute starts, the compiler Worker is replaced, or the shell unmounts. Pass it to setup work such as `loadTypiaRuntimePack(url, { signal: sandbox.signal })`. Runtime-pack loads share one request per URL and evict a rejected request so the next Execute retries. Nothing else ends the load: how long a fetch takes belongs to the network, not to a number chosen here. A signal cannot preempt synchronous evaluated user code; use an isolated executor with its own termination mechanism when that boundary matters.
105
105
 
106
106
  ## Typia integration (optional)
107
107
 
@@ -128,7 +128,9 @@ const service = createWorkerCompiler({
128
128
 
129
129
  The typia pack itself is built by the site (typically with a `pack-typia-sources.cjs`-style script that bundles `typia/`, `@typia/utils`, and `@typia/interface` into a flat JSON map). See the ttsc website's [`build/pack-typia-sources.cjs`](https://github.com/samchon/ttsc/blob/master/website/build/pack-typia-sources.cjs) for the reference implementation.
130
130
 
131
- Calls for one URL share a single in-flight request; any caller's `signal` cancels that shared attempt, and a rejected attempt is evicted so the next compiler request retries the mount without starting another WASM runtime. There is no deadline over the fetch or the JSON body read — the network decides how long it takes. Pass the policy with `createTypiaSourcePackMount({ url, signal })`.
131
+ Calls with the same URL and fetch function share a single in-flight request and decoded pack. Different injected transports have independent caches. Any caller's `signal` cancels its shared attempt, and rejection evicts that attempt so the next compiler request retries mounting without starting another WASM runtime. There is no deadline over the fetch or JSON body read; the network decides how long it takes. Pass cancellation with `createTypiaSourcePackMount({ url, signal })`.
132
+
133
+ Source and runtime packs must be JSON objects mapping virtual paths to source-text strings. Arrays and non-string entries reject the load before mounting or evaluation. Successful packs assume immutable content at a URL; use a new URL when the content changes.
132
134
 
133
135
  ## Runtime npm dependency installer
134
136
 
@@ -203,7 +205,7 @@ If the wasm registers plugins other than typia / `@ttsc/lint`, pass `typiaPlugin
203
205
 
204
206
  ## Conventions
205
207
 
206
- - **One type per file.** Public interfaces / types each live under `src/structures/` in a file named after the type. The barrel `structures/index.ts` re-exports everything.
208
+ - **One interface per file.** Public interfaces live under `src/structures/` in a file named after the interface. A callback type alias that only one interface uses, such as `PlaygroundFetch` or `PlaygroundBundleExecutor`, sits in that interface's file. The barrel `structures/index.ts` re-exports everything.
207
209
  - **One public function per file.** Internal helpers may be grouped in `compiler/internal/` or `npm/internal/`.
208
210
  - **No sub-path exports.** Every public symbol is importable from the package root. Add a sub-path later only when a real consumer needs to avoid pulling React into a Node-only context.
209
211
 
@@ -5,5 +5,10 @@ import type { IBuildTsconfigOptions } from "../structures/IBuildTsconfigOptions"
5
5
  * `buildTsconfigJSON` is deliberately conservative — it returns a string the
6
6
  * caller writes to MemFS as-is, so there's no schema validation here. Bad
7
7
  * compiler options surface as wasm-side errors on the next build call.
8
+ *
9
+ * @evidence contracts/common.md#principled-implementation Object spread applies documented default-then-caller precedence and JSON.stringify emits the compiler's JSON input; compiler validation remains with the compiler.
10
+ * @evidence contracts/common.md#clear-and-simple-design This operation only serializes configuration; the caller owns virtual writes and execution.
11
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Defaults are supported project settings and caller overrides remain explicit, without fixture-dependent branches.
12
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains serialization ownership and validation timing in separate paragraphs under the documentation skill.
8
13
  */
9
14
  export declare function buildTsconfigJSON(options: IBuildTsconfigOptions): string;
@@ -8,6 +8,11 @@ const DEFAULT_PLAYGROUND_COMPILER_OPTIONS_1 = require("./DEFAULT_PLAYGROUND_COMP
8
8
  * `buildTsconfigJSON` is deliberately conservative — it returns a string the
9
9
  * caller writes to MemFS as-is, so there's no schema validation here. Bad
10
10
  * compiler options surface as wasm-side errors on the next build call.
11
+ *
12
+ * @evidence contracts/common.md#principled-implementation Object spread applies documented default-then-caller precedence and JSON.stringify emits the compiler's JSON input; compiler validation remains with the compiler.
13
+ * @evidence contracts/common.md#clear-and-simple-design This operation only serializes configuration; the caller owns virtual writes and execution.
14
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Defaults are supported project settings and caller overrides remain explicit, without fixture-dependent branches.
15
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains serialization ownership and validation timing in separate paragraphs under the documentation skill.
11
16
  */
12
17
  function buildTsconfigJSON(options) {
13
18
  return JSON.stringify({
@@ -1 +1 @@
1
- {"version":3,"file":"buildTsconfigJSON.js","sourceRoot":"","sources":["../../../src/compiler/buildTsconfigJSON.ts"],"names":[],"mappings":";;;AACA,+FAA4F;AAE5F;;;;;;GAMG;AACH,2BAAkC,OAA8B;IAC9D,OAAO,IAAI,CAAC,SAAS,CAAC;QACpB,eAAe,EAAE;YACf,GAAG,yEAAmC;YACtC,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,MAAM,EAAE,OAAO,CAAC,MAAM,IAAI,MAAM;YAChC,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,KAAK;YACjC,GAAG,CAAC,OAAO,CAAC,eAAe,IAAI,EAAE,CAAC;SACnC;QACD,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC;KACpC,CAAC,CAAC;AACL,CAAC"}
1
+ {"version":3,"file":"buildTsconfigJSON.js","sourceRoot":"","sources":["../../../src/compiler/buildTsconfigJSON.ts"],"names":[],"mappings":";;;AACA,+FAA4F;AAE5F;;;;;;;;;;;GAWG;AACH,2BAAkC,OAA8B;IAC9D,OAAO,IAAI,CAAC,SAAS,CAAC;QACpB,eAAe,EAAE;YACf,GAAG,yEAAmC;YACtC,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,MAAM,EAAE,OAAO,CAAC,MAAM,IAAI,MAAM;YAChC,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,KAAK;YACjC,GAAG,CAAC,OAAO,CAAC,eAAe,IAAI,EAAE,CAAC;SACnC;QACD,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC;KACpC,CAAC,CAAC;AACL,CAAC"}
@@ -4,8 +4,14 @@ import type { IInstallTypiaSourcePackOptions } from "../structures/IInstallTypia
4
4
  * Build a `mount` callback for the `typiaPlugin` config of
5
5
  * {@link createWorkerCompiler}.
6
6
  *
7
- * The returned function fetches the pack once (cached per URL by
8
- * {@link loadTypiaSourcePack}) and writes every entry to the MemFS the first
9
- * time it is invoked on a given host.
7
+ * The returned function shares loading by URL and fetch function identity
8
+ * through {@link loadTypiaSourcePack}, then writes every entry to the MemFS on
9
+ * each invocation. Network records are cached, but mounting repeats so a caller
10
+ * can restore files removed from the virtual host.
11
+ *
12
+ * @evidence contracts/common.md#principled-implementation Explicit mountRoot overrides the actual worker workDir; absent both, installation uses its documented virtual root.
13
+ * @evidence contracts/common.md#clear-and-simple-design One adapter derives the root and delegates transport and writes to their owning operations.
14
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The optional workDir preserves the supported single-argument callback while supplied project roots are honored instead of patched with fixed paths.
15
+ * @evidence contracts/common.md#meaningful-documentation Native prose distinguishes cached loading from repeated mounting and explains callback compatibility, following documentation-skill paragraph separation.
10
16
  */
11
17
  export declare function createTypiaSourcePackMount(options: IInstallTypiaSourcePackOptions): (host: IMemFSHost, workDir?: string) => Promise<void>;
@@ -6,9 +6,15 @@ const installTypiaSourcePack_1 = require("./installTypiaSourcePack");
6
6
  * Build a `mount` callback for the `typiaPlugin` config of
7
7
  * {@link createWorkerCompiler}.
8
8
  *
9
- * The returned function fetches the pack once (cached per URL by
10
- * {@link loadTypiaSourcePack}) and writes every entry to the MemFS the first
11
- * time it is invoked on a given host.
9
+ * The returned function shares loading by URL and fetch function identity
10
+ * through {@link loadTypiaSourcePack}, then writes every entry to the MemFS on
11
+ * each invocation. Network records are cached, but mounting repeats so a caller
12
+ * can restore files removed from the virtual host.
13
+ *
14
+ * @evidence contracts/common.md#principled-implementation Explicit mountRoot overrides the actual worker workDir; absent both, installation uses its documented virtual root.
15
+ * @evidence contracts/common.md#clear-and-simple-design One adapter derives the root and delegates transport and writes to their owning operations.
16
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The optional workDir preserves the supported single-argument callback while supplied project roots are honored instead of patched with fixed paths.
17
+ * @evidence contracts/common.md#meaningful-documentation Native prose distinguishes cached loading from repeated mounting and explains callback compatibility, following documentation-skill paragraph separation.
12
18
  */
13
19
  function createTypiaSourcePackMount(options) {
14
20
  return async (host, workDir) => {
@@ -1 +1 @@
1
- {"version":3,"file":"createTypiaSourcePackMount.js","sourceRoot":"","sources":["../../../src/compiler/createTypiaSourcePackMount.ts"],"names":[],"mappings":";;;AAGA,qEAAkE;AAElE;;;;;;;GAOG;AACH,oCACE,OAAuC;IAEvC,OAAO,KAAK,EAAE,IAAgB,EAAE,OAAgB,EAAE,EAAE;QAClD,iEAAiE;QACjE,oEAAoE;QACpE,qEAAqE;QACrE,+CAA+C;QAC/C,EAAE;QACF,mEAAmE;QACnE,oEAAoE;QACpE,sEAAsE;QACtE,kDAAkD;QAClD,MAAM,SAAS,GACb,OAAO,CAAC,SAAS;YACjB,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,eAAe,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;QACxE,MAAM,IAAA,+CAAsB,EAAC,IAAI,EAAE,EAAE,GAAG,OAAO,EAAE,SAAS,EAAE,CAAC,CAAC;IAChE,CAAC,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"createTypiaSourcePackMount.js","sourceRoot":"","sources":["../../../src/compiler/createTypiaSourcePackMount.ts"],"names":[],"mappings":";;;AAGA,qEAAkE;AAElE;;;;;;;;;;;;;GAaG;AACH,oCACE,OAAuC;IAEvC,OAAO,KAAK,EAAE,IAAgB,EAAE,OAAgB,EAAE,EAAE;QAClD,iEAAiE;QACjE,oEAAoE;QACpE,qEAAqE;QACrE,+CAA+C;QAC/C,EAAE;QACF,mEAAmE;QACnE,oEAAoE;QACpE,sEAAsE;QACtE,kDAAkD;QAClD,MAAM,SAAS,GACb,OAAO,CAAC,SAAS;YACjB,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,eAAe,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;QACxE,MAAM,IAAA,+CAAsB,EAAC,IAAI,EAAE,EAAE,GAAG,OAAO,EAAE,SAAS,EAAE,CAAC,CAAC;IAChE,CAAC,CAAC;AACJ,CAAC"}
@@ -21,5 +21,10 @@ import type { ICreateWorkerCompilerOptions } from "../structures/ICreateWorkerCo
21
21
  * };
22
22
  * void main();
23
23
  * ```
24
+ *
25
+ * @evidence contracts/common.md#principled-implementation The wrapper supplies the real WASM boot and result parser to the same typed service core exposed over tgrid.
26
+ * @evidence contracts/common.md#clear-and-simple-design Runtime binding stays in this thin factory while pipeline state and serialization remain in the service core.
27
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Dependency injection is a supported binding seam, without replacement of foreign APIs or test-only production paths.
28
+ * @evidence contracts/common.md#meaningful-documentation Native JSDoc demonstrates WorkerServer registration and required runtime identity, with descriptive text separated from tags under the documentation skill.
24
29
  */
25
30
  export declare function createWorkerCompiler(options: ICreateWorkerCompilerOptions): ICompilerService;
@@ -36,6 +36,11 @@ const createWorkerCompilerService_1 = require("./internal/createWorkerCompilerSe
36
36
  * };
37
37
  * void main();
38
38
  * ```
39
+ *
40
+ * @evidence contracts/common.md#principled-implementation The wrapper supplies the real WASM boot and result parser to the same typed service core exposed over tgrid.
41
+ * @evidence contracts/common.md#clear-and-simple-design Runtime binding stays in this thin factory while pipeline state and serialization remain in the service core.
42
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Dependency injection is a supported binding seam, without replacement of foreign APIs or test-only production paths.
43
+ * @evidence contracts/common.md#meaningful-documentation Native JSDoc demonstrates WorkerServer registration and required runtime identity, with descriptive text separated from tags under the documentation skill.
39
44
  */
40
45
  function createWorkerCompiler(options) {
41
46
  return (0, createWorkerCompilerService_1.createWorkerCompilerService)({ bootTtsc: wasm_1.bootTtsc, parseResult: wasm_1.parseResult }, options);
@@ -1 +1 @@
1
- {"version":3,"file":"createWorkerCompiler.js","sourceRoot":"","sources":["../../../src/compiler/createWorkerCompiler.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAC3C,EAAE;AACF,2EAA2E;AAC3E,4EAA4E;AAC5E,4EAA4E;AAC5E,8EAA8E;AAC9E,kEAAkE;AAClE,EAAE;AACF,6EAA6E;AAC7E,8EAA8E;AAC9E,gFAAgF;AAChF,wEAAwE;AACxE,qCAAmD;AAInD,wFAAqF;AAErF;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,8BACE,OAAqC;IAErC,OAAO,IAAA,yDAA2B,EAAC,EAAE,QAAQ,EAAR,eAAQ,EAAE,WAAW,EAAX,kBAAW,EAAE,EAAE,OAAO,CAAC,CAAC;AACzE,CAAC"}
1
+ {"version":3,"file":"createWorkerCompiler.js","sourceRoot":"","sources":["../../../src/compiler/createWorkerCompiler.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAC3C,EAAE;AACF,2EAA2E;AAC3E,4EAA4E;AAC5E,4EAA4E;AAC5E,8EAA8E;AAC9E,kEAAkE;AAClE,EAAE;AACF,6EAA6E;AAC7E,8EAA8E;AAC9E,gFAAgF;AAChF,wEAAwE;AACxE,qCAAmD;AAInD,wFAAqF;AAErF;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,8BACE,OAAqC;IAErC,OAAO,IAAA,yDAA2B,EAAC,EAAE,QAAQ,EAAR,eAAQ,EAAE,WAAW,EAAX,kBAAW,EAAE,EAAE,OAAO,CAAC,CAAC;AACzE,CAAC"}
@@ -8,5 +8,10 @@ import type { ICompilerService } from "../structures/ICompilerService";
8
8
  * `ICompilerService`. The dependency installer (UI side) feeds keys like
9
9
  * `node_modules/uuid/dist/index.js`; we normalize, sanity-check, and copy each
10
10
  * entry under the project root.
11
+ *
12
+ * @evidence contracts/common.md#principled-implementation Every file passes the node_modules-relative path gate before virtual writes; count reports accepted writes and metadata remains the caller's submitted list.
13
+ * @evidence contracts/common.md#clear-and-simple-design Mounting is one loop with path policy delegated to normalizeNodeModulePath and no registry-resolution responsibility.
14
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Malformed paths are uniformly skipped according to the declared mounting contract, without package-specific exemptions.
15
+ * @evidence contracts/common.md#meaningful-documentation Native prose defines input namespace, project-root mapping and consumer ownership, following documentation-skill paragraphs.
11
16
  */
12
17
  export declare function installDependenciesIntoMemFS(host: IMemFSHost, workDir: string, props: ICompilerService.IInstallDependenciesProps): ICompilerService.IInstallDependenciesResult;
@@ -10,6 +10,11 @@ const normalizeNodeModulePath_1 = require("./normalizeNodeModulePath");
10
10
  * `ICompilerService`. The dependency installer (UI side) feeds keys like
11
11
  * `node_modules/uuid/dist/index.js`; we normalize, sanity-check, and copy each
12
12
  * entry under the project root.
13
+ *
14
+ * @evidence contracts/common.md#principled-implementation Every file passes the node_modules-relative path gate before virtual writes; count reports accepted writes and metadata remains the caller's submitted list.
15
+ * @evidence contracts/common.md#clear-and-simple-design Mounting is one loop with path policy delegated to normalizeNodeModulePath and no registry-resolution responsibility.
16
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Malformed paths are uniformly skipped according to the declared mounting contract, without package-specific exemptions.
17
+ * @evidence contracts/common.md#meaningful-documentation Native prose defines input namespace, project-root mapping and consumer ownership, following documentation-skill paragraphs.
13
18
  */
14
19
  function installDependenciesIntoMemFS(host, workDir, props) {
15
20
  let fileCount = 0;
@@ -1 +1 @@
1
- {"version":3,"file":"installDependenciesIntoMemFS.js","sourceRoot":"","sources":["../../../src/compiler/installDependenciesIntoMemFS.ts"],"names":[],"mappings":";;;AAGA,uEAAoE;AAEpE;;;;;;;;GAQG;AACH,sCACE,IAAgB,EAChB,OAAe,EACf,KAAiD;IAEjD,IAAI,SAAS,GAAG,CAAC,CAAC;IAClB,KAAK,MAAM,CAAC,GAAG,EAAE,IAAI,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC;QACtD,MAAM,UAAU,GAAG,IAAA,iDAAuB,EAAC,GAAG,CAAC,CAAC;QAChD,IAAI,CAAC,UAAU;YAAE,SAAS;QAC1B,IAAI,CAAC,SAAS,CAAC,GAAG,OAAO,IAAI,UAAU,EAAE,EAAE,IAAI,CAAC,CAAC;QACjD,SAAS,EAAE,CAAC;IACd,CAAC;IACD,OAAO,EAAE,SAAS,EAAE,KAAK,CAAC,QAAQ,EAAE,SAAS,EAAE,CAAC;AAClD,CAAC"}
1
+ {"version":3,"file":"installDependenciesIntoMemFS.js","sourceRoot":"","sources":["../../../src/compiler/installDependenciesIntoMemFS.ts"],"names":[],"mappings":";;;AAGA,uEAAoE;AAEpE;;;;;;;;;;;;;GAaG;AACH,sCACE,IAAgB,EAChB,OAAe,EACf,KAAiD;IAEjD,IAAI,SAAS,GAAG,CAAC,CAAC;IAClB,KAAK,MAAM,CAAC,GAAG,EAAE,IAAI,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC;QACtD,MAAM,UAAU,GAAG,IAAA,iDAAuB,EAAC,GAAG,CAAC,CAAC;QAChD,IAAI,CAAC,UAAU;YAAE,SAAS;QAC1B,IAAI,CAAC,SAAS,CAAC,GAAG,OAAO,IAAI,UAAU,EAAE,EAAE,IAAI,CAAC,CAAC;QACjD,SAAS,EAAE,CAAC;IACd,CAAC;IACD,OAAO,EAAE,SAAS,EAAE,KAAK,CAAC,QAAQ,EAAE,SAAS,EAAE,CAAC;AAClD,CAAC"}
@@ -5,7 +5,12 @@ import type { IInstallTypiaSourcePackOptions } from "../structures/IInstallTypia
5
5
  * wasm-side compiler can resolve `import typia, { tags } from "typia"` against
6
6
  * the same code the published package uses.
7
7
  *
8
- * Idempotent on the same host (re-writing the same paths is a no-op for the
9
- * MemFS implementation).
8
+ * Repeated calls write the same loaded records again; this restores any entries
9
+ * the caller removed from the virtual host and replaces values at pack paths.
10
+ *
11
+ * @evidence contracts/common.md#principled-implementation Source-pack entries are written under the selected virtual mount root after the shared transport completes; the pack is a site-produced trusted record map.
12
+ * @evidence contracts/common.md#clear-and-simple-design Loading is delegated and this operation owns only root creation and entry writes.
13
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The caller supplies the pack URL and root; no consumer or fixture determines which source contents are mounted.
14
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains resolution purpose and repeated-write behavior without claiming MemFS suppresses writes, following documentation-skill paragraphs.
10
15
  */
11
16
  export declare function installTypiaSourcePack(host: IMemFSHost, options: IInstallTypiaSourcePackOptions): Promise<void>;
@@ -7,8 +7,13 @@ const loadTypiaSourcePack_1 = require("./loadTypiaSourcePack");
7
7
  * wasm-side compiler can resolve `import typia, { tags } from "typia"` against
8
8
  * the same code the published package uses.
9
9
  *
10
- * Idempotent on the same host (re-writing the same paths is a no-op for the
11
- * MemFS implementation).
10
+ * Repeated calls write the same loaded records again; this restores any entries
11
+ * the caller removed from the virtual host and replaces values at pack paths.
12
+ *
13
+ * @evidence contracts/common.md#principled-implementation Source-pack entries are written under the selected virtual mount root after the shared transport completes; the pack is a site-produced trusted record map.
14
+ * @evidence contracts/common.md#clear-and-simple-design Loading is delegated and this operation owns only root creation and entry writes.
15
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The caller supplies the pack URL and root; no consumer or fixture determines which source contents are mounted.
16
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains resolution purpose and repeated-write behavior without claiming MemFS suppresses writes, following documentation-skill paragraphs.
12
17
  */
13
18
  async function installTypiaSourcePack(host, options) {
14
19
  const mountRoot = options.mountRoot ?? "/work/node_modules";
@@ -1 +1 @@
1
- {"version":3,"file":"installTypiaSourcePack.js","sourceRoot":"","sources":["../../../src/compiler/installTypiaSourcePack.ts"],"names":[],"mappings":";;;AAGA,+DAA4D;AAE5D;;;;;;;GAOG;AACI,KAAK,iCACV,IAAgB,EAChB,OAAuC;IAEvC,MAAM,SAAS,GAAG,OAAO,CAAC,SAAS,IAAI,oBAAoB,CAAC;IAC5D,MAAM,IAAI,GAAG,MAAM,IAAA,yCAAmB,EAAC,OAAO,CAAC,CAAC;IAChD,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;IACvB,KAAK,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC;QAClD,IAAI,CAAC,SAAS,CAAC,GAAG,SAAS,IAAI,GAAG,EAAE,EAAE,OAAO,CAAC,CAAC;IACjD,CAAC;AACH,CAAC"}
1
+ {"version":3,"file":"installTypiaSourcePack.js","sourceRoot":"","sources":["../../../src/compiler/installTypiaSourcePack.ts"],"names":[],"mappings":";;;AAGA,+DAA4D;AAE5D;;;;;;;;;;;;GAYG;AACI,KAAK,iCACV,IAAgB,EAChB,OAAuC;IAEvC,MAAM,SAAS,GAAG,OAAO,CAAC,SAAS,IAAI,oBAAoB,CAAC;IAC5D,MAAM,IAAI,GAAG,MAAM,IAAA,yCAAmB,EAAC,OAAO,CAAC,CAAC;IAChD,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;IACvB,KAAK,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC;QAClD,IAAI,CAAC,SAAS,CAAC,GAAG,SAAS,IAAI,GAAG,EAAE,EAAE,OAAO,CAAC,CAAC;IACjD,CAAC;AACH,CAAC"}
@@ -6,13 +6,44 @@ import type { ICreateWorkerCompilerOptions } from "../../structures/ICreateWorke
6
6
  * `createWorkerCompiler` binds the real implementations; tests bind fakes that
7
7
  * resolve a synthetic `IBootResult` so the plugin-envelope handling can be
8
8
  * verified without a real WASM boot.
9
+ *
10
+ * @evidence contracts/common.md#principled-implementation Boot and generic envelope parsing retain the WASM host signatures and null parse outcome needed by the service.
11
+ * @evidence contracts/common.md#clear-and-simple-design A two-collaborator record isolates runtime binding from pipeline control flow.
12
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Collaborators are explicit production dependencies, not global replacements or fixture-specific dispatch.
13
+ * @evidence contracts/common.md#meaningful-documentation Native paragraphs explain runtime binding and the injection purpose under the documentation skill.
9
14
  */
10
15
  export interface IWorkerCompilerDeps {
16
+ /**
17
+ * Start the configured WASM runtime and return its ready host and API.
18
+ *
19
+ * @evidence contracts/common.md#principled-implementation The host's typed options and ready result preserve runtime identity and boot failure semantics.
20
+ * @evidence contracts/common.md#clear-and-simple-design This dependency owns runtime startup while the service owns mounting and request serialization.
21
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Injection uses the declared host API rather than replacing runtime globals.
22
+ * @evidence contracts/common.md#meaningful-documentation Native prose states readiness and ownership with tag separation under the documentation skill.
23
+ */
11
24
  bootTtsc: (options: IBootTtscOptions) => Promise<IBootResult>;
25
+ /**
26
+ * Decode one host envelope; null denotes absent or unusable payload.
27
+ *
28
+ * @evidence contracts/common.md#principled-implementation The generic parser maps the typed host envelope to the requested payload shape while exposing parse failure as null.
29
+ * @evidence contracts/common.md#clear-and-simple-design Decoding stays distinct from exit-code interpretation in the service.
30
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Null remains failure information and does not fabricate a successful empty compile result.
31
+ * @evidence contracts/common.md#meaningful-documentation Native prose defines null and decoding responsibility, separated from tags under the documentation skill.
32
+ */
12
33
  parseResult: <T>(result: ITtscResult) => T | null;
13
34
  }
14
35
  /**
15
36
  * Dependency-injected worker `ICompilerService` factory. See
16
37
  * `createWorkerCompiler` for the public entry documentation.
38
+ *
39
+ * Runtime boot and source mounting have separate retry state. Requests
40
+ * serialize every mutation of the shared virtual project; configured transform
41
+ * or lint failures remain visible instead of yielding untransformed or clean
42
+ * results.
43
+ *
44
+ * @evidence contracts/common.md#principled-implementation A promise chain orders virtual-file mutations; transform envelopes are validated before writes, and compile and lint outcomes preserve producer failure semantics. Post-start boot rejection remains terminal because an existing Go runtime cannot be replaced inside its Worker.
45
+ * @evidence contracts/common.md#clear-and-simple-design Boot, mounting, project writes and result interpretation are local responsibilities behind one RPC factory; ESM and CommonJS lanes share the build pipeline.
46
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Retry is limited to pre-runtime boot or source mounting; failed configured plugins never silently fall through to successful untransformed emit or a clean lint list.
47
+ * @evidence contracts/common.md#meaningful-documentation Native paragraphs state serialization and retry boundaries; helper comments explain plugin-envelope failures and the runtime replacement reason under the documentation skill.
17
48
  */
18
49
  export declare function createWorkerCompilerService(deps: IWorkerCompilerDeps, options: ICreateWorkerCompilerOptions): ICompilerService;
@@ -26,6 +26,16 @@ const safeParseTypiaTransform_1 = require("./safeParseTypiaTransform");
26
26
  /**
27
27
  * Dependency-injected worker `ICompilerService` factory. See
28
28
  * `createWorkerCompiler` for the public entry documentation.
29
+ *
30
+ * Runtime boot and source mounting have separate retry state. Requests
31
+ * serialize every mutation of the shared virtual project; configured transform
32
+ * or lint failures remain visible instead of yielding untransformed or clean
33
+ * results.
34
+ *
35
+ * @evidence contracts/common.md#principled-implementation A promise chain orders virtual-file mutations; transform envelopes are validated before writes, and compile and lint outcomes preserve producer failure semantics. Post-start boot rejection remains terminal because an existing Go runtime cannot be replaced inside its Worker.
36
+ * @evidence contracts/common.md#clear-and-simple-design Boot, mounting, project writes and result interpretation are local responsibilities behind one RPC factory; ESM and CommonJS lanes share the build pipeline.
37
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Retry is limited to pre-runtime boot or source mounting; failed configured plugins never silently fall through to successful untransformed emit or a clean lint list.
38
+ * @evidence contracts/common.md#meaningful-documentation Native paragraphs state serialization and retry boundaries; helper comments explain plugin-envelope failures and the runtime replacement reason under the documentation skill.
29
39
  */
30
40
  function createWorkerCompilerService(deps, options) {
31
41
  const workDir = options.workDir ?? DEFAULT_WORK_DIR_1.DEFAULT_WORK_DIR;
@@ -38,12 +48,20 @@ function createWorkerCompilerService(deps, options) {
38
48
  const lintPluginName = lintPlugin?.name ?? DEFAULT_LINT_PLUGIN_NAME_1.DEFAULT_LINT_PLUGIN_NAME;
39
49
  // tsconfig variants. ESM for the "Compiled JS" preview lane, CommonJS for
40
50
  // the bundle/Execute lane (whose `new Function` driver expects CJS).
41
- const tsconfigPlugins = typiaPlugin
42
- ? [{ transform: typiaTransformModule }]
51
+ //
52
+ // The typia entry is appended after the site's own `plugins` entries, as the
53
+ // option documents, so enabling typia never discards a site-provided plugin.
54
+ const siteCompilerOptions = options.extraCompilerOptions ?? {};
55
+ const sitePlugins = siteCompilerOptions.plugins;
56
+ const extraPlugins = Array.isArray(sitePlugins)
57
+ ? sitePlugins.filter((entry) => entry?.transform !==
58
+ typiaTransformModule)
43
59
  : [];
44
60
  const extraCompilerOptions = {
45
- ...(options.extraCompilerOptions ?? {}),
46
- ...(tsconfigPlugins.length > 0 ? { plugins: tsconfigPlugins } : {}),
61
+ ...siteCompilerOptions,
62
+ ...(typiaPlugin
63
+ ? { plugins: [...extraPlugins, { transform: typiaTransformModule }] }
64
+ : {}),
47
65
  };
48
66
  const tsconfigESM = (0, buildTsconfigJSON_1.buildTsconfigJSON)({
49
67
  module: "ESNext",
@@ -1 +1 @@
1
- {"version":3,"file":"createWorkerCompilerService.js","sourceRoot":"","sources":["../../../../src/compiler/internal/createWorkerCompilerService.ts"],"names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CAC9B,OAAe;IAEf,OAAO;QACL,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;QACT,QAAQ,EAAE,OAAO;QACjB,OAAO;QACP,IAAI,EAAE,QAAQ;KACf,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"createWorkerCompilerService.js","sourceRoot":"","sources":["../../../../src/compiler/internal/createWorkerCompilerService.ts"],"names":[],"mappings":";;;AAAA,wCAAwC;AACxC,EAAE;AACF,mEAAmE;AACnE,0EAA0E;AAC1E,yEAAyE;AACzE,+EAA+E;AAC/E,4EAA4E;AAC5E,wDAAwD;AACxD,qCAMoB;AAKpB,8DAA2D;AAC3D,0EAAuE;AACvE,oEAAiE;AACjE,4EAAyE;AACzE,0DAAuD;AACvD,4DAAyD;AACzD,kFAA+E;AAC/E,oDAAiD;AACjD,sDAAmD;AACnD,oDAAiD;AACjD,2CAAwC;AACxC,iEAA8D;AAC9D,uEAAoE;AAsCpE;;;;;;;;;;;;;GAaG;AACH,qCACE,IAAyB,EACzB,OAAqC;IAErC,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,IAAI,mCAAgB,CAAC;IACpD,MAAM,YAAY,GAAG,OAAO,CAAC,YAAY,IAAI,6CAAqB,CAAC;IACnE,MAAM,SAAS,GAAG,OAAO,CAAC,SAAS,IAAI,uCAAkB,CAAC;IAE1D,MAAM,WAAW,GACf,OAAO,CAAC,WAAW,KAAK,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,WAAW,IAAI,EAAE,CAAC,CAAC;IACrE,MAAM,eAAe,GAAG,WAAW,EAAE,IAAI,IAAI,qDAAyB,CAAC;IACvE,MAAM,oBAAoB,GACxB,WAAW,EAAE,eAAe,IAAI,qBAAqB,CAAC;IAExD,MAAM,UAAU,GACd,OAAO,CAAC,UAAU,KAAK,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,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,OAAO,CACL,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE;QACjB,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE;QACjB,SAAS,IAAI,IAAI,IAAI,6BAA6B,GAAG,CAAC,IAAI,GAAG,CAC9D,CAAC;AACJ,CAAC;AAED,yCAAyC;AACzC,SAAS,SAAS,CAAC,KAAc;IAC/B,IAAI,KAAK,YAAY,KAAK;QAAE,OAAO,KAAK,CAAC,OAAO,CAAC;IACjD,IACE,KAAK;QACL,OAAO,KAAK,KAAK,QAAQ;QACzB,SAAS,IAAK,KAAiC;QAE/C,OAAO,MAAM,CAAE,KAA8B,CAAC,OAAO,CAAC,CAAC;IACzD,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC;AACvB,CAAC;AAED;;;;GAIG;AACH,SAAS,uBAAuB,CAC9B,OAAe;IAEf,OAAO;QACL,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;QACT,QAAQ,EAAE,OAAO;QACjB,OAAO;QACP,IAAI,EAAE,QAAQ;KACf,CAAC;AACJ,CAAC"}
@@ -1,5 +1,10 @@
1
1
  /**
2
2
  * Join a relative path under a base directory, ignoring base when `rel` is
3
3
  * absolute.
4
+ *
5
+ * @evidence contracts/common.md#principled-implementation Absolute virtual paths retain their meaning and relative paths receive the configured virtual base; this helper is not a confinement check.
6
+ * @evidence contracts/common.md#clear-and-simple-design A narrow virtual join keeps source mapping independent of host filesystem APIs.
7
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Absolute paths are a supported input form rather than a workaround for a particular package.
8
+ * @evidence contracts/common.md#meaningful-documentation Native prose states absolute precedence, with tag separation following the documentation skill.
4
9
  */
5
10
  export declare function joinUnder(base: string, rel: string): string;
@@ -4,6 +4,11 @@ exports.joinUnder = joinUnder;
4
4
  /**
5
5
  * Join a relative path under a base directory, ignoring base when `rel` is
6
6
  * absolute.
7
+ *
8
+ * @evidence contracts/common.md#principled-implementation Absolute virtual paths retain their meaning and relative paths receive the configured virtual base; this helper is not a confinement check.
9
+ * @evidence contracts/common.md#clear-and-simple-design A narrow virtual join keeps source mapping independent of host filesystem APIs.
10
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Absolute paths are a supported input form rather than a workaround for a particular package.
11
+ * @evidence contracts/common.md#meaningful-documentation Native prose states absolute precedence, with tag separation following the documentation skill.
7
12
  */
8
13
  function joinUnder(base, rel) {
9
14
  if (rel.startsWith("/"))
@@ -1 +1 @@
1
- {"version":3,"file":"joinUnder.js","sourceRoot":"","sources":["../../../../src/compiler/internal/joinUnder.ts"],"names":[],"mappings":";;;AAAA;;;GAGG;AACH,mBAA0B,IAAY,EAAE,GAAW;IACjD,IAAI,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC;QAAE,OAAO,GAAG,CAAC;IACpC,OAAO,GAAG,IAAI,IAAI,GAAG,EAAE,CAAC;AAC1B,CAAC"}
1
+ {"version":3,"file":"joinUnder.js","sourceRoot":"","sources":["../../../../src/compiler/internal/joinUnder.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;GAQG;AACH,mBAA0B,IAAY,EAAE,GAAW;IACjD,IAAI,GAAG,CAAC,UAAU,CAAC,GAAG,CAAC;QAAE,OAAO,GAAG,CAAC;IACpC,OAAO,GAAG,IAAI,IAAI,GAAG,EAAE,CAAC;AAC1B,CAAC"}
@@ -2,5 +2,10 @@ import type { ICompilerService } from "../../structures/ICompilerService";
2
2
  /**
3
3
  * Parse the lint plugin's stderr (tsgo-style pretty diagnostics) into the
4
4
  * playground's normalized diagnostic shape.
5
+ *
6
+ * @evidence contracts/common.md#principled-implementation The parser recognizes the supported pretty-diagnostic grammar after removing actual ANSI SGR escapes and carries its one-based line and column unchanged into UI records.
7
+ * @evidence contracts/common.md#clear-and-simple-design Matching and record construction stay in one pass; token-span inference remains a local helper rather than a second diagnostic protocol.
8
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Unknown lines are omitted as non-diagnostics; the owning pipeline separately reports plugin failure instead of treating every empty parse as success.
9
+ * @evidence contracts/common.md#meaningful-documentation Native prose identifies producer format and normalization responsibility; nearby comments explain ANSI matching reasons under the documentation skill.
5
10
  */
6
11
  export declare function parseLintDiagnostics(stderr: string, source: string): ICompilerService.IDiagnostic[];
@@ -14,10 +14,16 @@ const ANSI_REGEXP = /\x1b\[[0-9;]*m/g;
14
14
  /**
15
15
  * Parse the lint plugin's stderr (tsgo-style pretty diagnostics) into the
16
16
  * playground's normalized diagnostic shape.
17
+ *
18
+ * @evidence contracts/common.md#principled-implementation The parser recognizes the supported pretty-diagnostic grammar after removing actual ANSI SGR escapes and carries its one-based line and column unchanged into UI records.
19
+ * @evidence contracts/common.md#clear-and-simple-design Matching and record construction stay in one pass; token-span inference remains a local helper rather than a second diagnostic protocol.
20
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Unknown lines are omitted as non-diagnostics; the owning pipeline separately reports plugin failure instead of treating every empty parse as success.
21
+ * @evidence contracts/common.md#meaningful-documentation Native prose identifies producer format and normalization responsibility; nearby comments explain ANSI matching reasons under the documentation skill.
17
22
  */
18
23
  function parseLintDiagnostics(stderr, source) {
19
24
  const stripped = stderr.replace(ANSI_REGEXP, "");
20
25
  const lines = stripped.split(/\r?\n/);
26
+ const sourceLines = source.split(/\r?\n/);
21
27
  const out = [];
22
28
  for (const line of lines) {
23
29
  const m = line.match(LINT_LINE_REGEXP);
@@ -31,7 +37,7 @@ function parseLintDiagnostics(stderr, source) {
31
37
  out.push({
32
38
  line: lineNum,
33
39
  column: colNum,
34
- length: lengthOfTokenAt(source, lineNum, colNum) ?? 1,
40
+ length: lengthOfTokenAt(sourceLines, lineNum, colNum) ?? 1,
35
41
  severity: sev === "warning" ? "warning" : "error",
36
42
  message: rule ? `[${rule}] ${message ?? ""}` : (message ?? ""),
37
43
  code: `TS${codeStr ?? ""}`,
@@ -43,8 +49,7 @@ function parseLintDiagnostics(stderr, source) {
43
49
  * Best-effort length of the identifier-like token starting at (`line`,
44
50
  * `column`) in `source`. Falls back to 1 when no token is found.
45
51
  */
46
- function lengthOfTokenAt(source, line, column) {
47
- const lines = source.split(/\r?\n/);
52
+ function lengthOfTokenAt(lines, line, column) {
48
53
  if (line < 1 || line > lines.length)
49
54
  return null;
50
55
  const text = lines[line - 1] ?? "";
@@ -1 +1 @@
1
- {"version":3,"file":"parseLintDiagnostics.js","sourceRoot":"","sources":["../../../../src/compiler/internal/parseLintDiagnostics.ts"],"names":[],"mappings":";;;AAEA,4EAA4E;AAC5E,2EAA2E;AAC3E,mEAAmE;AACnE,MAAM,gBAAgB,GACpB,oFAAoF,CAAC;AACvF,yEAAyE;AACzE,2EAA2E;AAC3E,wEAAwE;AACxE,gEAAgE;AAChE,4DAA4D;AAC5D,MAAM,WAAW,GAAG,iBAAiB,CAAC;AAEtC;;;GAGG;AACH,8BACE,MAAc,EACd,MAAc;IAEd,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC;IACjD,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IACtC,MAAM,GAAG,GAAmC,EAAE,CAAC;IAC/C,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,gBAAgB,CAAC,CAAC;QACvC,IAAI,CAAC,CAAC;YAAE,SAAS;QACjB,MAAM,CAAC,EAAE,AAAD,EAAG,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC;QAC7D,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC;QAChC,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QAC9B,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;YAAE,SAAS;QACpE,GAAG,C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I,IAAI,KAAK,OAAO,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,IAAI,EAAE,CAAC;YAC9D,IAAI,EAAE,KAAK,OAAO,IAAI,EAAE,EAAE;SAC3B,CAAC,CAAC;IACL,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC;AAED;;;GAGG;AACH,SAAS,eAAe,CACtB,KAAwB,EACxB,IAAY,EACZ,MAAc;IAEd,IAAI,IAAI,GAAG,CAAC,IAAI,IAAI,GAAG,KAAK,CAAC,MAAM;QAAE,OAAO,IAAI,CAAC;IACjD,MAAM,IAAI,GAAG,KAAK,CAAC,IAAI,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC;IACnC,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,CAAC;IACtC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;IACjD,IAAI,CAAC,KAAK;QAAE,OAAO,IAAI,CAAC;IACxB,OAAO,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC;AACzB,CAAC"}
@@ -1,4 +1,12 @@
1
- /** Shape of the typia transform plugin's stdout JSON payload. */
1
+ /**
2
+ * Typia transform stdout envelope; typescript maps virtual paths to source
3
+ * text.
4
+ *
5
+ * @evidence contracts/common.md#principled-implementation A string-valued source map expresses files the host can write; diagnostics are intentionally opaque because this lane does not consume them.
6
+ * @evidence contracts/common.md#clear-and-simple-design The narrow envelope separates transform payload decoding from compiler result parsing.
7
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The map models the registered transform protocol rather than guessed output for a particular source.
8
+ * @evidence contracts/common.md#meaningful-documentation Native prose defines path and text meaning with tag separation under the documentation skill.
9
+ */
2
10
  export interface ITypiaTransformOutput {
3
11
  diagnostics?: unknown;
4
12
  typescript: Record<string, string>;
@@ -7,5 +15,10 @@ export interface ITypiaTransformOutput {
7
15
  * Parse the typia transform plugin's stdout into the expected shape. Returns
8
16
  * null on any parse / shape mismatch — the caller treats null as "transform
9
17
  * produced no usable output".
18
+ *
19
+ * @evidence contracts/common.md#principled-implementation JSON decoding and a non-array object containing only string source values establish the host-write precondition; malformed payloads return null.
20
+ * @evidence contracts/common.md#clear-and-simple-design One decoder validates the source map before the service mutates MemFS.
21
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Rejected payloads remain failures instead of coercing unknown values into source text.
22
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains null's failure meaning and decoding boundary, separated from tags under the documentation skill.
10
23
  */
11
24
  export declare function safeParseTypiaTransform(text: string): ITypiaTransformOutput | null;
@@ -5,11 +5,22 @@ exports.safeParseTypiaTransform = safeParseTypiaTransform;
5
5
  * Parse the typia transform plugin's stdout into the expected shape. Returns
6
6
  * null on any parse / shape mismatch — the caller treats null as "transform
7
7
  * produced no usable output".
8
+ *
9
+ * @evidence contracts/common.md#principled-implementation JSON decoding and a non-array object containing only string source values establish the host-write precondition; malformed payloads return null.
10
+ * @evidence contracts/common.md#clear-and-simple-design One decoder validates the source map before the service mutates MemFS.
11
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Rejected payloads remain failures instead of coercing unknown values into source text.
12
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains null's failure meaning and decoding boundary, separated from tags under the documentation skill.
8
13
  */
9
14
  function safeParseTypiaTransform(text) {
10
15
  try {
11
16
  const parsed = JSON.parse(text);
12
- if (parsed && typeof parsed === "object" && parsed.typescript) {
17
+ if (parsed &&
18
+ typeof parsed === "object" &&
19
+ !Array.isArray(parsed) &&
20
+ parsed.typescript &&
21
+ typeof parsed.typescript === "object" &&
22
+ !Array.isArray(parsed.typescript) &&
23
+ Object.values(parsed.typescript).every((value) => typeof value === "string")) {
13
24
  return parsed;
14
25
  }
15
26
  return null;
@@ -1 +1 @@
1
- {"version":3,"file":"safeParseTypiaTransform.js","sourceRoot":"","sources":["../../../../src/compiler/internal/safeParseTypiaTransform.ts"],"names":[],"mappings":";;;AAMA;;;;GAIG;AACH,iCACE,IAAY;IAEZ,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAA0B,CAAC;QACzD,IAAI,MAAM,IAAI,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,CAAC,UAAU,EAAE,CAAC;YAC9D,OAAO,MAAM,CAAC;QAChB,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC"}
1
+ {"version":3,"file":"safeParseTypiaTransform.js","sourceRoot":"","sources":["../../../../src/compiler/internal/safeParseTypiaTransform.ts"],"names":[],"mappings":";;;AAcA;;;;;;;;;GASG;AACH,iCACE,IAAY;IAEZ,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAA0B,CAAC;QACzD,IACE,MAAM;YACN,OAAO,MAAM,KAAK,QAAQ;YAC1B,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC;YACtB,MAAM,CAAC,UAAU;YACjB,OAAO,MAAM,CAAC,UAAU,KAAK,QAAQ;YACrC,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC;YACjC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,KAAK,CACpC,CAAC,KAAK,EAAE,EAAE,CAAC,OAAO,KAAK,KAAK,QAAQ,CACrC,EACD,CAAC;YACD,OAAO,MAAM,CAAC;QAChB,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC"}
@@ -1,4 +1,12 @@
1
- /** Compute 1-based line/column for a 0-based char offset into `source`. */
1
+ /**
2
+ * Compute one-based line and column from a zero-based UTF-16 source offset.
3
+ * Missing or negative offsets point to the beginning; offsets past EOF clamp.
4
+ *
5
+ * @evidence contracts/common.md#principled-implementation ECMAScript line terminators advance the line, CRLF counts once, and columns count JavaScript UTF-16 units.
6
+ * @evidence contracts/common.md#clear-and-simple-design A stateless coordinate helper keeps source-location policy separate from diagnostic mapping and rendering.
7
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Beginning and EOF behavior are general coordinate defaults rather than source-specific exceptions.
8
+ * @evidence contracts/common.md#meaningful-documentation Native prose states bases, units and boundary behavior, separated from tags under the documentation skill.
9
+ */
2
10
  export declare function lineColumnOf(source: string, start: number | undefined): {
3
11
  line: number;
4
12
  column: number;
@@ -1,15 +1,31 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.lineColumnOf = lineColumnOf;
4
- /** Compute 1-based line/column for a 0-based char offset into `source`. */
4
+ /**
5
+ * Compute one-based line and column from a zero-based UTF-16 source offset.
6
+ * Missing or negative offsets point to the beginning; offsets past EOF clamp.
7
+ *
8
+ * @evidence contracts/common.md#principled-implementation ECMAScript line terminators advance the line, CRLF counts once, and columns count JavaScript UTF-16 units.
9
+ * @evidence contracts/common.md#clear-and-simple-design A stateless coordinate helper keeps source-location policy separate from diagnostic mapping and rendering.
10
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Beginning and EOF behavior are general coordinate defaults rather than source-specific exceptions.
11
+ * @evidence contracts/common.md#meaningful-documentation Native prose states bases, units and boundary behavior, separated from tags under the documentation skill.
12
+ */
5
13
  function lineColumnOf(source, start) {
6
- if (typeof start !== "number" || start < 0)
14
+ if (typeof start !== "number" || Number.isNaN(start) || start < 0)
7
15
  return { line: 1, column: 1 };
8
- const slice = source.slice(0, Math.min(start, source.length));
9
- const newlines = slice.match(/\n/g);
10
- const line = newlines ? newlines.length + 1 : 1;
11
- const lastNewline = slice.lastIndexOf("\n");
12
- const column = lastNewline === -1 ? slice.length + 1 : slice.length - lastNewline;
16
+ const end = Math.min(Math.trunc(start), source.length);
17
+ let line = 1;
18
+ let lastNewline = -1;
19
+ for (let index = 0; index < end; ++index) {
20
+ const code = source.charCodeAt(index);
21
+ if (code === 13 || code === 10 || code === 0x2028 || code === 0x2029) {
22
+ if (code === 13 && source.charCodeAt(index + 1) === 10 && index + 1 < end)
23
+ ++index;
24
+ ++line;
25
+ lastNewline = index;
26
+ }
27
+ }
28
+ const column = end - lastNewline;
13
29
  return { line, column };
14
30
  }
15
31
  //# sourceMappingURL=lineColumnOf.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"lineColumnOf.js","sourceRoot":"","sources":["../../../src/compiler/lineColumnOf.ts"],"names":[],"mappings":";;;AAAA,2EAA2E;AAC3E,sBACE,MAAc,EACd,KAAyB;IAEzB,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,GAAG,CAAC;QAAE,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;IAC1E,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC;IAC9D,MAAM,QAAQ,GAAG,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACpC,MAAM,IAAI,GAAG,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAChD,MAAM,WAAW,GAAG,KAAK,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;IAC5C,MAAM,MAAM,GACV,WAAW,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,WAAW,CAAC;IACrE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;AAC1B,CAAC"}
1
+ {"version":3,"file":"lineColumnOf.js","sourceRoot":"","sources":["../../../src/compiler/lineColumnOf.ts"],"names":[],"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