From 3ab2ba69e2590624f6578766ce0dd2c62cccfaf9 Mon Sep 17 00:00:00 2001 From: daiwei Date: Fri, 13 Jun 2025 11:43:09 +0800 Subject: [PATCH] fix: remove unnecessary increment in line count calculation --- src/sourcemap.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sourcemap.ts b/src/sourcemap.ts index 40d50f98..3ecdf477 100644 --- a/src/sourcemap.ts +++ b/src/sourcemap.ts @@ -40,7 +40,7 @@ export function getSourceMap( templateMap as Omit as TraceEncodedSourceMap, ) const offset = - (trimAnalyzedBindings(scriptCode).match(/\r?\n/g)?.length ?? 0) + 1 + (trimAnalyzedBindings(scriptCode).match(/\r?\n/g)?.length ?? 0) eachMapping(tracer, (m) => { if (m.source == null) return addMapping(gen, {