You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Java8] Replace ConstantPoolTypeIntrospector with TypeResolver
To determine which argument types a lambda function requires we created a
ConstantPoolTypeIntrospector. However it has never functioned quite correctly
(#937, #1140, #957), was prone to breaking (#912, #914) and hasn't been tested
much (#1048).
It is important to understand that while we will get a properly functioning and
tested replacement, TypeResolver uses the same ConstantPool and thus has the
same potential to break. However because TypeResolver is used by a much larger
audience I expect these problems to be shallow.
Because this change the interface of Java8StepDefinition it made sense to
refactor all the Java8 related stuff out of cucumber-java. This will make it easier in
the future to add things like KotlinStepDefintions without creating a separate
KotlinBackend.
Related issues:
- #912
- #914
- #937
- #957
- #1140
- #1048
- #1140Closes#937Closes#1048
new Java8StepDefinition(regexp, 0, StepdefBody.A0.class, body)
12
+
);
11
13
}
12
14
13
15
default void ${java.text.Normalizer.normalize(kw.replaceAll("[\\s',!]", ""), java.text.Normalizer.Form.NFC)}(final String regexp, final long timeoutMillis, final StepdefBody.A0 body) {
new Java8StepDefinition(regexp, 0, StepdefBody.A${arity}.class, body)
27
+
);
28
+
22
29
}
23
30
24
31
default <${genericSignature}> void ${java.text.Normalizer.normalize(kw.replaceAll("[\\s',!]", ""), java.text.Normalizer.Form.NFC)}(final String regexp, final long timeoutMillis, final StepdefBody.A${arity}<${genericSignature}> body) {
0 commit comments