bareloop 0.11.0 → 0.13.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.
package/types/tools.d.ts CHANGED
@@ -19,8 +19,24 @@ export function strategyFor(granted: string[]): string;
19
19
  * RESULT is invisible cannot be judged: a `ctx_get` that silently reds (stale pointer,
20
20
  * bad range) looks exactly like one that worked, and the worker's fallback to a
21
21
  * whole-file read looks like a free choice instead of a forced one.
22
+ * @param {{onStalePointer?: ((req: {file: string, path: string, startLine: number, endLine: number, detail: string}) => {text: string, outcome: string}|null)|null}} [opts]
23
+ * `onStalePointer`: the read shim's stale-pointer serve, wired ONLY by a capping
24
+ * arm (see `createReadShim`). Absent — every caller today except that one — this
25
+ * whole seam is byte-identical to what it was, which is what keeps A0 the
26
+ * untouched baseline an experiment has already run against.
22
27
  */
23
- export function createCtxTools(lc: any, workdir: string, emit: (type: string, data: object) => void): ({
28
+ export function createCtxTools(lc: any, workdir: string, emit: (type: string, data: object) => void, { onStalePointer }?: {
29
+ onStalePointer?: ((req: {
30
+ file: string;
31
+ path: string;
32
+ startLine: number;
33
+ endLine: number;
34
+ detail: string;
35
+ }) => {
36
+ text: string;
37
+ outcome: string;
38
+ } | null) | null;
39
+ }): ({
24
40
  name: string;
25
41
  description: string;
26
42
  parameters: {