MCPcopy
hub / github.com/angular/angular / loop

Method loop

packages/benchpress/src/sampler.ts:53–61  ·  view source on GitHub ↗
(lastState: SampleState)

Source from the content-addressed store, hash-verified

51
52 sample(): Promise<SampleState> {
53 const loop = (lastState: SampleState): Promise<SampleState> => {
54 return this._iterate(lastState).then((newState) => {
55 if (newState.validSample != null) {
56 return newState;
57 } else {
58 return loop(newState);
59 }
60 });
61 };
62 return loop(new SampleState([], null));
63 }
64

Callers

nothing calls this directly

Calls 2

_iterateMethod · 0.95
thenMethod · 0.65

Tested by

no test coverage detected