From 573b9f1d7428e00046b1e888f292e4d2374ab152 Mon Sep 17 00:00:00 2001 From: Simon H <5968653+dummdidumm@users.noreply.github.com> Date: Tue, 14 May 2024 23:25:00 +0200 Subject: [PATCH] fix: adjust unknown code warning offset (#11621) They were the wrong way around fixes #11612 --- .../svelte/src/compiler/phases/2-analyze/index.js | 4 ++-- .../validator/samples/unknown-code/warnings.json | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/svelte/src/compiler/phases/2-analyze/index.js b/packages/svelte/src/compiler/phases/2-analyze/index.js index 55373baa41..631c254933 100644 --- a/packages/svelte/src/compiler/phases/2-analyze/index.js +++ b/packages/svelte/src/compiler/phases/2-analyze/index.js @@ -1110,7 +1110,7 @@ const common_visitors = { if (prev.type === 'Comment') { ignores.push( ...extract_svelte_ignore( - prev.start + 2 /* '//'.length */, + prev.start + 4 /* '