/** * Symbol-keyed lazy memoization stamped directly onto the host object. * * Faster than a module-level `WeakMap` in V8/JSC because the symbol slot is * resolved through the object's hidden class instead of a side-table hash * lookup. The slot is defined as a non-enumerable property so the stamp * does not leak through `{...spread}`, `Object.keys`, `JSON.stringify`, or * `toEqual`-style deep equality. * * Caveats: the stamp lives as long as the host object, even after callers * release their references to the cached value — only use this for caches * whose lifetime should match the host. Frozen hosts will throw on write in * strict mode; callers that may receive frozen input must handle that. */ export declare function stamp(target: T, key: symbol, compute: (target: T) => V): V; export declare function epochNext(): number; /** * Marks `target` as visited for this `epoch`. Returns `true` the first time * it is called for a given (target, epoch) pair and `false` on every * subsequent call within the same epoch. */ export declare function once(target: T, epoch: number): boolean; /** Returns `true` on first entry, `false` if `target` is already on the current path. */ export declare function enter(target: T): boolean; export declare function exit(target: T): void;