Lines Matching defs:right

54     public FieldExpression(long where, Expression right, Identifier id) {
55 super(FIELD, where, Type.tError, right);
58 public FieldExpression(long where, Expression right, MemberDefinition field) {
59 super(FIELD, where, field.getType(), right);
90 e = fe.right;
111 Type rty = right.toQualifiedType(env, ctx);
197 FieldExpression.reportFailedPackagePrefix(env, right, true);
251 static void reportFailedPackagePrefix(Environment env, Expression right) {
252 reportFailedPackagePrefix(env, right, false);
256 Expression right,
259 Expression idp = right;
261 idp = ((UnaryExpression)idp).right;
269 env.error(right.where, "ambig.class", e.name1, e.name2);
274 if (idp == right) {
426 Type t = right.toType(env, ctx);
445 env.error(right.where, "invalid.type.expr");
459 env.error(right.where, "void.array");
515 implementation = implementFieldAccess(env, ctx, right, isLHS);
516 return (right == null) ?
517 vset : right.checkAmbigName(env, ctx, vset, exp, this);
521 vset = right.checkAmbigName(env, ctx, vset, exp, this);
522 if (right.type == Type.tPackage) {
525 FieldExpression.reportFailedPackagePrefix(env, right);
529 // ASSERT(loc.right == this)
534 loc.right = new TypeExpression(where, Type.tClass(nm));
537 env.resolve(where, ctxClass, loc.right.type);
549 boolean staticRef = (right instanceof TypeExpression);
555 if (!right.type.isType(TC_CLASS)) {
556 if (right.type.isType(TC_ARRAY) && id.equals(idLength)) {
559 if (!FieldExpression.isTypeAccessible(where, env, right.type, ctxClass)) {
563 id, right.type.toString(), cdecl);
566 id, right.type.toString(), cdecl);
570 implementation = new LengthExpression(where, right);
573 if (!right.type.isType(TC_ERROR)) {
574 env.error(where, "invalid.field.reference", id, right.type);
579 // At this point, we know that 'right.type' is a class type.
595 if (right instanceof FieldExpression) {
596 Identifier id = ((FieldExpression)right).id;
598 sourceClass = ((FieldExpression)right).clazz;
600 sourceClass = ((FieldExpression)right).clazz;
617 //ClassDefinition clazz = env.getClassDefinition(right.type);
618 clazz = env.getClassDefinition(right.type);
621 env.error(right.where, "invalid.type.expr");
624 // We used to check that 'right.type' is accessible here,
685 if (!FieldExpression.isTypeAccessible(where, env, right.type, sourceClass)) {
689 id, right.type.toString(), cdecl);
692 id, right.type.toString(), cdecl);
713 implementation = implementFieldAccess(env, ctx, right, isLHS);
718 && !(right instanceof SuperExpression
720 || (right instanceof FieldExpression &&
721 ((FieldExpression)right).id == idSuper))
722 && !sourceClass.protectedAccess(env, field, right.type)) {
725 right.type);
730 (right.op == THIS) && !vset.testVar(ctx.getThisNumber())) {
794 * Must be called after 'checkValue', else 'right' will be invalid.
809 // It may not be necessary to copy 'right' here.
810 Expression base = (right == null) ? null : right.copyInline(ctx);
826 * Must be called after 'checkValue', else 'right' will be invalid.
841 // It may not be necessary to copy 'right' here.
842 Expression base = (right == null) ? null : right.copyInline(ctx);
868 ClassDefinition clazz = env.getClassDefinition(right.type);
877 && !(right instanceof SuperExpression
879 || (right instanceof FieldExpression &&
880 ((FieldExpression)right).id == idSuper))
881 && !ctxClass.protectedAccess(env, field, right.type)){
884 right.type);
898 loc.right = te;
923 if (right != null) {
929 if ((right != null) && (right.op != THIS)) {
1104 && (right == null || right instanceof TypeExpression
1105 || (right.op == THIS && right.where == where))) {
1129 if ((fe.right != null) && (fe.right.op==THIS))
1152 return new CommaExpression(where, right, e).inlineValue(env, ctx);
1156 if (right != null) {
1158 Expression e = right.inline(env, ctx);
1159 right = null;
1164 right = right.inlineValue(env, ctx);
1176 if (right != null) {
1178 Expression e = right.inline(env, ctx);
1179 right = null;
1184 right = right.inlineValue(env, ctx);
1203 return 3 + ((right == null) ? 0
1204 : right.costInline(thresh, env, ctx));
1210 // the field, the field's class, and right's declared type.
1213 if (right == null) {
1216 ClassDeclaration rt = env.getClassDeclaration(right.type);
1218 return 3 + right.costInline(thresh, env, ctx);
1234 if (right != null) {
1235 right.code(env, ctx, asm);
1240 right.codeValue(env, ctx, asm);
1271 if (right != null) {
1272 right.print(out);