Examples of constant()


Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding.constant()

    }
  } else {
    FieldBinding lastFieldBinding = generateReadSequence(currentScope, codeStream);
    if (lastFieldBinding != null) {
      boolean isStatic = lastFieldBinding.isStatic();
      Constant fieldConstant = lastFieldBinding.constant();
      if (fieldConstant != Constant.NotAConstant) {
        if (!isStatic){
          codeStream.invokeObjectGetClass();
          codeStream.pop();
        }
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding.constant()

  switch (this.bits & ASTNode.RestrictiveFlagMASK) {
    case Binding.FIELD :
      lastFieldBinding = (FieldBinding) this.codegenBinding;
      lastGenericCast = this.genericCast;
      // if first field is actually constant, we can inline it
      if (lastFieldBinding.constant() != Constant.NotAConstant) {
        break;
      }
      if ((needValue && !lastFieldBinding.isStatic()) || lastGenericCast != null) {
        int pc = codeStream.position;
        if ((this.bits & ASTNode.DepthMASK) != 0) {
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding.constant()

        fieldBinding);
      this.constant = Constant.NotAConstant;
      return null;
    }
  }
  this.constant = fieldBinding.constant();

  if (isFieldUseDeprecated(fieldBinding, scope, (this.bits & IsStrictlyAssigned) !=0)) {
    scope.problemReporter().deprecatedField(fieldBinding, this);
  }
  return fieldBinding.type;
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding.constant()

    switch (this.bits & RestrictiveFlagMASK) {
      case Binding.FIELD : // reading a field
        if (!valueRequired)
          break;
        FieldBinding fieldBinding = (FieldBinding) this.codegenBinding;
        Constant fieldConstant = fieldBinding.constant();
        if (fieldConstant == Constant.NotAConstant) { // directly use inlined value for constant fields
          if (fieldBinding.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
             // directly use inlined value for constant fields
            boolean isStatic;
            if (!(isStatic = fieldBinding.isStatic())) {
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding.constant()

    // for runtime compatibility on 1.2 VMs : change the declaring class of the binding
    // NOTE: from target 1.2 on, field's declaring class is touched if any different from receiver type
    // and not from Object or implicit static field access. 
    if (fieldBinding.declaringClass != this.delegateThis.type
        && fieldBinding.declaringClass != null // array.length
        && fieldBinding.constant() == Constant.NotAConstant) {
      CompilerOptions options = currentScope.compilerOptions();
      if ((options.targetJDK >= ClassFileConstants.JDK1_2
          && (options.complianceLevel >= ClassFileConstants.JDK1_4 || !fieldBinding.isStatic())
          && fieldBinding.declaringClass.id != T_JavaLangObject) // no change for Object fields
        || !fieldBinding.declaringClass.canBeSeenBy(currentScope)) {
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.LocalVariableBinding.constant()

      break;
    case Binding.LOCAL : // reading the first local variable
      if (!needValue) break; // no value needed
      LocalVariableBinding localBinding = (LocalVariableBinding) this.codegenBinding;
      // regular local variable read
      Constant localConstant = localBinding.constant();
      if (localConstant != Constant.NotAConstant) {
        codeStream.generateConstant(localConstant, 0);
        // no implicit conversion
      } else {
        // outer local?
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.LocalVariableBinding.constant()

      break;
    case Binding.LOCAL : // reading the first local variable
      if (!needValue) break; // no value needed
      LocalVariableBinding localBinding = (LocalVariableBinding) this.codegenBinding;
      // regular local variable read
      Constant localConstant = localBinding.constant();
      if (localConstant != Constant.NotAConstant) {
        codeStream.generateConstant(localConstant, 0);
        // no implicit conversion
      } else {
        // outer local?
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.constant()

    }
  } else {
    FieldBinding lastFieldBinding = generateReadSequence(currentScope, codeStream);
    if (lastFieldBinding != null) {
      boolean isStatic = lastFieldBinding.isStatic();
      Constant fieldConstant = lastFieldBinding.constant();
      if (fieldConstant != Constant.NotAConstant) {
        if (!isStatic){
          codeStream.invokeObjectGetClass();
          codeStream.pop();
        }
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.LocalVariableBinding.constant()

      lastGenericCast = null;
      LocalVariableBinding localBinding = (LocalVariableBinding) this.binding;
      lastReceiverType = localBinding.type;
      if (!needValue) break; // no value needed
      // regular local variable read
      Constant localConstant = localBinding.constant();
      if (localConstant != Constant.NotAConstant) {
        codeStream.generateConstant(localConstant, 0);
        // no implicit conversion
      } else {
        // outer local?
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.VariableBinding.constant()

            this.bits |= Binding.LOCAL;
            if (!variable.isFinal() && (this.bits & ASTNode.DepthMASK) != 0) {
              scope.problemReporter().cannotReferToNonFinalOuterLocal((LocalVariableBinding)variable, this);
            }
            variableType = variable.type;
            this.constant = (this.bits & ASTNode.IsStrictlyAssigned) == 0 ? variable.constant() : Constant.NotAConstant;
          } else {
            // a field
            variableType = checkFieldAccess(scope);
          }
          // perform capture conversion if read access
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.