Examples of JimpleClassBuilder


Examples of org.renjin.gcc.jimple.JimpleClassBuilder

        return providedType;

      } else {

        // create a new JVM type to back this array
        JimpleClassBuilder recordClass = context.getJimpleOutput().newClass();
        recordClass.setPackageName(context.getMainClass().getPackageName());
        recordClass.setClassName(context.getMainClass().getClassName() + "$" + def.getName());

        SimpleRecordType struct = new SimpleRecordType(new SyntheticJimpleType(recordClass.getFqcn()));
        map.put(recordType.getId(), struct);

        buildFields(struct, recordClass, def);

        return struct;
View Full Code Here

Examples of org.renjin.gcc.jimple.JimpleClassBuilder

  public String getInvokerClassName(MethodRef method) {
    String invokerName = invokerName(method);

    if (!invokers.contains(method)) {

      JimpleClassBuilder invokerClass = context.getJimpleOutput().newClass();
      invokerClass.setClassName(invokerName);
      invokerClass.addInterface(getInterfaceName(method));

      JimpleMethodBuilder applyMethod = invokerClass.newMethod();
      applyMethod.setModifiers(JimpleModifiers.PUBLIC);
      applyMethod.setName("apply");
      applyMethod.setReturnType(method.getReturnType());

      int paramIndex = 0;
View Full Code Here

Examples of org.renjin.gcc.jimple.JimpleClassBuilder

  protected JimpleOutput translate(List<GimpleCompilationUnit> units) throws IOException {

    JimpleOutput jimple = new JimpleOutput();

    JimpleClassBuilder mainClass = jimple.newClass();
    mainClass.setClassName(className);
    mainClass.setPackageName(packageName);

    TranslationContext context = new TranslationContext(mainClass, methodTable, providedTypes, units);
    for(GimpleCompilationUnit unit : units) {
      for (GimpleFunction function : unit.getFunctions()) {
       
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.