1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-23 14:42:11 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2016-03-21 16:29:05 -07:00
parent 9ea3641953
commit 7f6e86085c
4 changed files with 9 additions and 10 deletions

View file

@ -32,8 +32,7 @@ public final class InstantiationContext {
/**
* @param parameterMap mapping of template parameters to arguments, may be {@code null}.
* @param packOffset parameter pack offset, or -1 if expansion of a parameter pack is not desired
* pack.
* @param packOffset parameter pack offset, or -1 if expansion of a parameter pack is not desired pack.
* @param contextTypeSpecialization the type specialization if instantiation happens inside a specialized
* type, otherwise {@code null}.
* @param point the point of instantiation
@ -132,7 +131,7 @@ public final class InstantiationContext {
/**
* Returns the point of instantiation
*/
public IASTNode getPoint() {
public final IASTNode getPoint() {
return point;
}

View file

@ -85,8 +85,7 @@ public class EvalFunctionCall extends CPPDependentEvaluation {
@Override
public boolean isConstantExpression(IASTNode point) {
return areAllConstantExpressions(fArguments, point)
&& isNullOrConstexprFunc(getOverload(point));
return areAllConstantExpressions(fArguments, point) && isNullOrConstexprFunc(getOverload(point));
}
public ICPPFunction getOverload(IASTNode point) {
@ -184,7 +183,8 @@ public class EvalFunctionCall extends CPPDependentEvaluation {
if (args[0] instanceof EvalFunctionSet && getOverload(context.getPoint()) == null) {
// Resolve the function using the parameters of the function call.
args[0] = ((EvalFunctionSet) args[0]).resolveFunction(Arrays.copyOfRange(args, 1, args.length), context.getPoint());
EvalFunctionSet functionSet = (EvalFunctionSet) args[0];
args[0] = functionSet.resolveFunction(Arrays.copyOfRange(args, 1, args.length), context.getPoint());
}
return new EvalFunctionCall(args, getTemplateDefinition());
}

View file

@ -165,8 +165,8 @@ public class EvalMemberAccess extends CPPDependentEvaluation {
return false;
}
public static IType getFieldOwnerType(IType fieldOwnerExpressionType, boolean isDeref, IASTNode point, Collection<ICPPFunction> functionBindings,
boolean returnDependent) {
public static IType getFieldOwnerType(IType fieldOwnerExpressionType, boolean isDeref, IASTNode point,
Collection<ICPPFunction> functionBindings, boolean returnDependent) {
IType type= fieldOwnerExpressionType;
if (!isDeref)
return type;

View file

@ -147,8 +147,8 @@ public class EvalTypeId extends CPPDependentEvaluation {
@Override
public boolean isConstantExpression(IASTNode point) {
return !fRepresentsNewExpression
&& areAllConstantExpressions(fArguments, point)
&& isNullOrConstexprFunc(getConstructor(point));
&& areAllConstantExpressions(fArguments, point)
&& isNullOrConstexprFunc(getConstructor(point));
}
@Override