lapce / lapce/lapce

Editor indentation errors in one-off bug

Open
#2,913 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

C-bug
Dominant language
Rust
Stars
38.9k
Forks
1.3k
Avg merge
19m
Merged PRs (30d)
1

Description

Lapce Version

0.3.1, with clangd

System information

MacOS Monterey

Describe the bug

As I was writing a program, typing const char *CLEAR = "\e[1;1H\e[2J"; caused the next line to indent 4 spaces more. This does not seem to be the case for any other line, such as const char *CLEAR = "hello there";.

Additional information

screenshot:
image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file or test is named. First reproduce the indentation change in Lapce 0.3.1 on macOS with clangd using the exact escaped string, then trace the editor's indentation handling; done means that line no longer adds four unexpected spaces while ordinary lines retain their behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
developer-experience
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.