Examples of toVariant()


Examples of xtc.type.Type.toVariant()

          }
          break;

        case VARIANT:
          if (seenPoly) {
            result = merge(result.toVariant(), t.toVariant(), p);
            if (result.isError()) break loop;

          } else if (result.isWildcard()) {
            result = t;
View Full Code Here

Examples of xtc.type.Type.toVariant()

          } else if (result.isWildcard()) {
            result = t;

          } else if (! result.equals(t)) {
            if (isGeneric) {
              runtime.error("variant '" + result.toVariant().getName() + "' " +
                            "overlaps with '" + t.toVariant().getName() + "'",p);
              result = ErrorT.TYPE;
              break loop;

            } else if (seenWild) {
View Full Code Here

Examples of xtc.type.Type.toVariant()

                pln(": error: but has alternatives without static type").flush();
              result = ErrorT.TYPE;
              break loop;

            } else {
              VariantT v = result.toVariant();
              result     = merge(ast.toVariant(p.qName.name, true), v, p);
              if (result.isError()) break loop;
              result     = merge(result.toVariant(), t.toVariant(), p);
              if (result.isError()) break loop;
              seenPoly   = true;
View Full Code Here

Examples of xtc.type.Type.toVariant()

            } else {
              VariantT v = result.toVariant();
              result     = merge(ast.toVariant(p.qName.name, true), v, p);
              if (result.isError()) break loop;
              result     = merge(result.toVariant(), t.toVariant(), p);
              if (result.isError()) break loop;
              seenPoly   = true;
            }
          }
          break;
View Full Code Here

Examples of xtc.type.Type.toVariant()

      // If we have a meaningful result, update the production's type.
      if (! result.isWildcard()) {
        setType(p, result);

        final Type r = result.resolve();
        if (r.isVariant() && ! r.toVariant().isPolymorphic()) {
          // Push the production's variant type.
          productions.add(p);
        }
      }
    }
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.