Skip to content

Commit 4a6e6b0

Browse files
committed
Merge branch 'ar/userdiff-java-update'
Userdiff regexp update for Java language. * ar/userdiff-java-update: userdiff: support Java sealed classes userdiff: support Java record types userdiff: support Java type parameters
2 parents f7c208c + 93d52ed commit 4a6e6b0

16 files changed

+95
-2
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
class RIGHT
2+
{
3+
static int ONE;
4+
static int TWO;
5+
static int ChangeMe;
6+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
class RIGHT <TYPE, PARAMS, AFTER, SPACE> {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
private A ChangeMe;
6+
}

t/t4018/java-class-type-parameters

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
class RIGHT<A, B> {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
private A ChangeMe;
6+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
class RIGHT<A, B> implements List<A> {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
private A ChangeMe;
6+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
interface RIGHT<A, B> {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
public B foo(A ChangeMe);
6+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
interface RIGHT<A, B> extends Function<A, B> {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
public B foo(A ChangeMe);
6+
}

t/t4018/java-non-sealed

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
public abstract sealed class SealedClass {
2+
public static non-sealed class RIGHT extends SealedClass {
3+
static int ONE;
4+
static int TWO;
5+
static int THREE;
6+
private int ChangeMe;
7+
}
8+
}

t/t4018/java-record

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
public record RIGHT(int comp1, double comp2, String comp3) {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
static int ChangeMe;
6+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
public record RIGHT (String components, String after, String space) {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
static int ChangeMe;
6+
}

t/t4018/java-record-type-parameters

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
public record RIGHT<A, N extends Number>(A comp1, N comp2, int comp3) {
2+
static int ONE;
3+
static int TWO;
4+
static int THREE;
5+
static int ChangeMe;
6+
}

0 commit comments

Comments
 (0)