MCPcopy Create free account
hub / github.com/microsoft/vscode-cpptools / lazy

Function lazy

Extension/src/Utility/Async/lazy.ts:23–25  ·  view source on GitHub ↗
(initializer: T | (() => Promise<T>) | (() => T) | (new () => T))

Source from the content-addressed store, hash-verified

21
22/** Returns a promise from a value (value/lambda/constructor) that isn't resolved until is is awaited. */
23export function lazy<T>(initializer: T | (() => Promise<T>) | (() => T) | (new () => T)): Promise<T> {
24 return new Lazy(initializer);
25}

Callers 2

program.tsFile · 0.90
processFactoryFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected