google / google/xls

Disabling formatting within a `proc` sometimes silently does not disable formatting

Open
#1,797 0 comments 0 reactions 0 assignees View on GitHub
bug dslx dslx:fmt
Dominant language
C++
Stars
1.9k
Forks
283
Avg merge
2d 10h
Merged PRs (30d)
135

Description

This:

```
proc p {
config() { }

init { }

// dslx-fmt::off
next(
state: ()) { () }
// dslx-fmt::on
}
```

will get formatted to:

```
proc p {
config() { }

init { }

// dslx-fmt::off
next(state: ()) { () }
// dslx-fmt::on
}
```

even though there was a request to disable formatting around the `next` method.

(Analysis; this happens due to the "ignore desugared functions" code added in c6c8197)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.