diff --git a/compiler/forget/src/Inference/InlineUseMemo.ts b/compiler/forget/src/Inference/InlineUseMemo.ts index 28f45446a8..2e6b5b7e80 100644 --- a/compiler/forget/src/Inference/InlineUseMemo.ts +++ b/compiler/forget/src/Inference/InlineUseMemo.ts @@ -97,7 +97,7 @@ export function inlineUseMemo(fn: HIRFunction): void { if (body === undefined) { CompilerError.invariant( "Expected first argument to useMemo() to be a function expression", - fn.loc + lambda.loc ); } // We know this function is used for useMemo and can prune it later