arduino / arduino/Arduino

[Bug] Auto formatting does not work if there is an 'R "===== (' in the sketch?

Open
#10,946 5 comments 0 reactions 0 assignees View on GitHub
Component: IDE Type: Bug Upstream notified
Dominant language
Java
Stars
14.6k
Forks
7k
PR merge metrics
No merged PRs in 30d

Description

Hi,

Auto formatting (Ctrl+T) does not work if there are:
```C++
const char webSite1[] PROGMEM = R"=====(
"abc"
)=====";
```
But Auto formatting works if there is no line break:

```C++
const char webSite1[] PROGMEM = R"=====("abc")=====";
```

In both cases the compilation is successful.

Arduino IDE 1.8.13 (Linux)

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the issue in Arduino IDE 1.8.13 using Ctrl+T on the two C++ raw-string examples, comparing the multiline and single-line forms. No repository file or test is named in the report; done means auto formatting handles the multiline raw string without preventing formatting or changing successful compilation behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, java
Domain
tooling
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.