diff options
| author | Daniel Jasper <djasper@google.com> | 2014-10-31 18:23:49 +0000 |
|---|---|---|
| committer | Daniel Jasper <djasper@google.com> | 2014-10-31 18:23:49 +0000 |
| commit | e9ab42df0cf305b8ff1f363cc5acd680f954ec16 (patch) | |
| tree | 9a62b60733fd48805056fb171797c549390345af /clang/unittests | |
| parent | 396f80a1eac514b717a4a43a313ffaadde6f7cb0 (diff) | |
| download | bcm5719-llvm-e9ab42df0cf305b8ff1f363cc5acd680f954ec16.tar.gz bcm5719-llvm-e9ab42df0cf305b8ff1f363cc5acd680f954ec16.zip | |
clang-format: [Java] Improve line breaks around annotations.
Before:
@SomeAnnotation("With some really looooooooooooooong text") private static final
long something = 0L;
void SomeFunction(@Nullable
String something) {}
After:
@SomeAnnotation("With some really looooooooooooooong text")
private static final long something = 0L;
void SomeFunction(@Nullable String something) {}
llvm-svn: 220984
Diffstat (limited to 'clang/unittests')
| -rw-r--r-- | clang/unittests/Format/FormatTestJava.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/unittests/Format/FormatTestJava.cpp b/clang/unittests/Format/FormatTestJava.cpp index c9575892342..4f9a3dc31a0 100644 --- a/clang/unittests/Format/FormatTestJava.cpp +++ b/clang/unittests/Format/FormatTestJava.cpp @@ -84,9 +84,15 @@ TEST_F(FormatTestJava, Annotations) { " }\n" "});"); + verifyFormat("void SomeFunction(@Nullable String something) {\n" + "}"); + verifyFormat("@Partial @Mock DataLoader loader;"); verifyFormat("@SuppressWarnings(value = \"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\")\n" "public static int iiiiiiiiiiiiiiiiiiiiiiii;"); + + verifyFormat("@SomeAnnotation(\"With some really looooooooooooooong text\")\n" + "private static final long something = 0L;"); } TEST_F(FormatTestJava, Generics) { |

