google / google/google-java-format

String splitting / wrapping can increase line length

オープン
#989 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Java
スター
6.2k
フォーク
937
平均マージ
6分
マージ済み PR(30日)
3

説明

### Version
1.18.1, all-deps JAR

### Description
In some cases Google Java Format wraps / splits long string literals which exceed the maximum line length in a way which makes the string literal exceed the maximum line length even further.

In those cases maybe it would be better if the string had not been split / wrapped.

### Example
```java
class Test {
void test() {
System.out.println(
"\nSee https://example.com/some-really-long-path-which-exceeds-the-maximum-line-length-of-the-formatter");
}
}
```

The formatted result is:
```java
class Test {
void test() {
System.out.println(
"\n"
+ "See https://example.com/some-really-long-path-which-exceeds-the-maximum-line-length-of-the-formatter");
}
}
```

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。