oven-sh / bun

Incredibly fast JavaScript runtime, bundler, test runner, and package manager – all in one
https://bun.sh
Other
71.09k stars 2.47k forks source link

Error display column spacing is off with Tabs in source code #10857

Open e3dio opened 1 week ago

e3dio commented 1 week ago

What version of Bun is running?

1.1.7

What platform is your computer?

Linux

What steps can reproduce the bug?

This code including the Tab space in front:

    123 + error()

What is the expected behavior?

Caret points to correct location in code:

bun

What do you see instead?

Points to wrong location in source code:

image

Additional information

Tabs display as 4 spaces in Error output, but caret position uses 1 space per tab, so the alignment is off