[Parse Class] -> content of an if statement
This commit is contained in:
parent
943fa54dac
commit
6715bc6fed
3 changed files with 11 additions and 8 deletions
|
@ -28,7 +28,7 @@ public class Parser<E>{
|
|||
|
||||
//tmp
|
||||
public void build(BufferedWriter writer) throws Exception{
|
||||
Token[] confirmed = new Token[TokenValidator.MAX_VALIDATE];
|
||||
Token[] confirmed = new Token[TokenValidator.MAX_VALIDATE+1];
|
||||
System.arraycopy(tokenizer.getTokens().toArray(), 0, confirmed, 0, confirmed.length);
|
||||
int line = 1;
|
||||
int character = 1;
|
||||
|
|
|
@ -182,25 +182,28 @@ public class JavaParser extends Parser<JavaFile> {
|
|||
variable_q5.then(variable_q2);
|
||||
variable_q10.then(variable_q1);
|
||||
variable_q11.then(variable_q1);
|
||||
|
||||
|
||||
StateTree<JavaElement> function_q17 = new StateTree<>();
|
||||
StateTree<JavaElement> function_q18 = function_q17.then(LAMBDA_42);
|
||||
|
||||
|
||||
StateTree<JavaElement> operation_q0 = new StateTree<>();
|
||||
StateTree<JavaElement> operation_q1 = operation_q0.then(LAMBDA_name);
|
||||
operation_q1.then(LAMBDA_8).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_1).<JavaElement>end(END_OP);
|
||||
StateTree<JavaElement> operation_q5 = operation_q1.then(LAMBDA_25);
|
||||
operation_q5.then(operation_q1);
|
||||
operation_q0.then(LAMBDA_32).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_24).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_33).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_24).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_34).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_24).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_32).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_24).<JavaElement>end(END_OP).then(function_q18);
|
||||
operation_q0.then(LAMBDA_33).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_24).<JavaElement>end(END_OP).then(function_q18);
|
||||
operation_q0.then(LAMBDA_34).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value")).then(LAMBDA_24).<JavaElement>end(END_OP).then(function_q18);
|
||||
operation_q0.then(LAMBDA_35).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value(190)")).then(LAMBDA_1).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_36).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value(191)")).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_37).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value(192)")).then(LAMBDA_24).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_37).then(LAMBDA_23).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value(192)")).then(LAMBDA_24).<JavaElement>end(END_OP).then(function_q18);
|
||||
operation_q0.then(LAMBDA_38).then(LAMBDA_1).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_39).then(new RedirectStateTree<>(value_q0,(bag) -> "op_value(194)")).then(LAMBDA_1).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_40).then(LAMBDA_1).<JavaElement>end(END_OP);
|
||||
operation_q0.then(LAMBDA_41).<JavaElement>end(END_OP);
|
||||
|
||||
StateTree<JavaElement> function_q17 = new StateTree<>();
|
||||
StateTree<JavaElement> function_q18 = function_q17.then(LAMBDA_42);
|
||||
StateTree<JavaElement> function_q19 = function_q18.then(LAMBDA_43);
|
||||
function_q19.end((a,b) -> { System.out.println("\t\tolala"); return a;});
|
||||
StateTree<JavaElement> function_q21 = function_q18.then(new RedirectStateTree<>(variable_q0,(bag) -> "func_var")).loop();
|
||||
|
|
|
@ -28,7 +28,7 @@ public class StateTree<E>{
|
|||
E build = internalSeed(validator, container);
|
||||
if(build == null) break;
|
||||
}
|
||||
System.out.println("Validate "+validator.MAX_VALIDATE+" tokens !");
|
||||
System.out.println("Validate "+validator.MAX_VALIDATE+"/"+tokenizer.getTokens().size()+" tokens !");
|
||||
}
|
||||
|
||||
<B> B internalSeed(TokenValidator validator, E element){
|
||||
|
|
Loading…
Add table
Reference in a new issue