// Path: src/main/java/yk/senjin/shaders/gshader/analysis/GglslAnalyzer.java
// public static final YArrayList<Object> G_BODY_ACCESSORS = al(
//         i(var("access")),
//         p("methodsList", var("access")),
//         p(MethodNode.class, "code", var("access")),
//         p(MethodCallExpression.class, "getReceiver", var("access")),
//         p(BlockStatement.class, "getStatements", var("access")),
//         p(ExpressionStatement.class, "expression", var("access")),
//         p(BinaryExpression.class, "leftExpression", var("access")),
//         p(BinaryExpression.class, "rightExpression", var("access")),
//         p(DeclarationExpression.class, "getLeftExpression", var("access")),
//         p(DeclarationExpression.class, "getRightExpression", var("access")),
//         p(UnaryMinusExpression.class, "getExpression", var("access")),
//         p(UnaryPlusExpression.class, "getExpression", var("access")),
//         p(ReturnStatement.class, "getExpression", var("access")),
//         p(ConstructorCallExpression.class, "arguments", p("expressions", i(var("access")))),
//         p(IfStatement.class, "booleanExpression", var("access")),
//         p(IfStatement.class, "ifBlock", var("access")),
//         p(IfStatement.class, "elseBlock", var("access"))
// );
// 
// Path: src/main/java/yk/senjin/shaders/gshader/analysis/GglslAnalyzer.java
// public static final YList<Object> G_METHOD_ACCESSORS = al(i(var("access")), p("methodsList", var("access")));


import org.codehaus.groovy.ast.MethodNode;
import org.codehaus.groovy.ast.builder.AstBuilder;
import org.codehaus.groovy.ast.expr.*;
import org.codehaus.groovy.control.CompilePhase;
import yk.jcommon.collections.YMap;
import yk.jcommon.fastgeom.Vec3f;
import yk.jcommon.match2.Matcher;
import yk.jcommon.utils.IO;
import static yk.jcommon.collections.YHashMap.hm;
import static yk.jcommon.match2.MatcherShortNames.*;
import static yk.senjin.shaders.gshader.analysis.GglslAnalyzer.G_BODY_ACCESSORS;
import static yk.senjin.shaders.gshader.analysis.GglslAnalyzer.G_METHOD_ACCESSORS;
package yk.senjin.shaders.gshader.analysis;



/**
 * Created with IntelliJ IDEA.
 * User: yuri
 * Date: 04/11/15
 * Time: 12:17
 */
public class HabraExampleJava {

    public static final Object G_FIELD_AS_ARG_PATTERN = stairs(
            //на какой-то глубине
// Path: src/main/java/yk/senjin/shaders/gshader/analysis/GglslAnalyzer.java
// public static final YArrayList<Object> G_BODY_ACCESSORS = al(
//         i(var("access")),
//         p("methodsList", var("access")),
//         p(MethodNode.class, "code", var("access")),
//         p(MethodCallExpression.class, "getReceiver", var("access")),
//         p(BlockStatement.class, "getStatements", var("access")),
//         p(ExpressionStatement.class, "expression", var("access")),
//         p(BinaryExpression.class, "leftExpression", var("access")),
//         p(BinaryExpression.class, "rightExpression", var("access")),
//         p(DeclarationExpression.class, "getLeftExpression", var("access")),
//         p(DeclarationExpression.class, "getRightExpression", var("access")),
//         p(UnaryMinusExpression.class, "getExpression", var("access")),
//         p(UnaryPlusExpression.class, "getExpression", var("access")),
//         p(ReturnStatement.class, "getExpression", var("access")),
//         p(ConstructorCallExpression.class, "arguments", p("expressions", i(var("access")))),
//         p(IfStatement.class, "booleanExpression", var("access")),
//         p(IfStatement.class, "ifBlock", var("access")),
//         p(IfStatement.class, "elseBlock", var("access"))
// );
// 
// Path: src/main/java/yk/senjin/shaders/gshader/analysis/GglslAnalyzer.java
// public static final YList<Object> G_METHOD_ACCESSORS = al(i(var("access")), p("methodsList", var("access")));


// Path: src/main/java/yk/senjin/shaders/gshader/analysis/HabraExampleJava.java
import org.codehaus.groovy.ast.MethodNode;
import org.codehaus.groovy.ast.builder.AstBuilder;
import org.codehaus.groovy.ast.expr.*;
import org.codehaus.groovy.control.CompilePhase;
import yk.jcommon.collections.YMap;
import yk.jcommon.fastgeom.Vec3f;
import yk.jcommon.match2.Matcher;
import yk.jcommon.utils.IO;
import static yk.jcommon.collections.YHashMap.hm;
import static yk.jcommon.match2.MatcherShortNames.*;
import static yk.senjin.shaders.gshader.analysis.GglslAnalyzer.G_BODY_ACCESSORS;
import static yk.senjin.shaders.gshader.analysis.GglslAnalyzer.G_METHOD_ACCESSORS;

package yk.senjin.shaders.gshader.analysis;



/**
 * Created with IntelliJ IDEA.
 * User: yuri
 * Date: 04/11/15
 * Time: 12:17
 */
public class HabraExampleJava {

    public static final Object G_FIELD_AS_ARG_PATTERN = stairs(
            //на какой-то глубине
            deeper(G_BODY_ACCESSORS),