diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/EvalUnary.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/EvalUnary.java index 1fdbc79bf35..2ff6835f794 100644 --- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/EvalUnary.java +++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/EvalUnary.java @@ -282,7 +282,10 @@ public class EvalUnary extends CPPDependentEvaluation { ICPPFunction overload = getOverload(point); if (overload != null) { ICPPFunctionType functionType = overload.getType(); - IType targetType = functionType.getParameterTypes()[0]; + IType[] parameterTypes = functionType.getParameterTypes(); + if (parameterTypes.length == 0) + return Value.ERROR; + IType targetType = parameterTypes[0]; arg = maybeApplyConversion(arg, targetType, point); if (!(overload instanceof CPPImplicitFunction)) {