modified: src/main/java/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntacticSugar.java
Some checks failed
Build and Test with Maven / Build-and-test-with-Maven (push) Failing after 2m21s
Some checks failed
Build and Test with Maven / Build-and-test-with-Maven (push) Failing after 2m21s
Im Visitor ReturnFinder wuder nicht beruecksichtigt, dass auch in einem Lambda-Ausdruck ein Reurn stehen kann, welchen die umgebenden Block nicht beendet.
This commit is contained in:
parent
e6cd4038e2
commit
bcce4cee19
@ -34,6 +34,11 @@ public class SyntacticSugar {
|
|||||||
public void visit(ReturnVoid aReturn) {
|
public void visit(ReturnVoid aReturn) {
|
||||||
hasReturn = true;
|
hasReturn = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void visit(LambdaExpression le) {
|
||||||
|
//PL 2024-04-09 Do nothing, as in a LambdaExpression a return could be
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean hasReturn(Block block) {
|
private static boolean hasReturn(Block block) {
|
||||||
|
Loading…
Reference in New Issue
Block a user