mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-09 10:46:02 +02:00
Minor code simplification.
This commit is contained in:
parent
34c589670a
commit
4ed86bfe6c
1 changed files with 3 additions and 3 deletions
|
@ -94,7 +94,7 @@ public class SemanticUtil {
|
||||||
if (decs != null) {
|
if (decs != null) {
|
||||||
for (ICPPMethod method : decs) {
|
for (ICPPMethod method : decs) {
|
||||||
if (isConversionOperator(method)) {
|
if (isConversionOperator(method)) {
|
||||||
methods= (ICPPMethod[]) ArrayUtil.append(ICPPMethod.class, methods, method);
|
methods= ArrayUtil.append(methods, method);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -112,7 +112,7 @@ public class SemanticUtil {
|
||||||
ICPPMethod[] methods= ICPPMethod.EMPTY_CPPMETHOD_ARRAY;
|
ICPPMethod[] methods= ICPPMethod.EMPTY_CPPMETHOD_ARRAY;
|
||||||
ObjectSet<ICPPClassType> ancestry= inheritanceClosure(clazz);
|
ObjectSet<ICPPClassType> ancestry= inheritanceClosure(clazz);
|
||||||
for (int i = 0; i < ancestry.size(); i++) {
|
for (int i = 0; i < ancestry.size(); i++) {
|
||||||
methods= (ICPPMethod[]) ArrayUtil.addAll(ICPPMethod.class, methods, getDeclaredConversionOperators(ancestry.keyAt(i)));
|
methods= ArrayUtil.addAll(methods, getDeclaredConversionOperators(ancestry.keyAt(i)));
|
||||||
}
|
}
|
||||||
return methods;
|
return methods;
|
||||||
}
|
}
|
||||||
|
@ -162,7 +162,7 @@ public class SemanticUtil {
|
||||||
if (name.length > OPERATOR_CHARS.length + 1 &&
|
if (name.length > OPERATOR_CHARS.length + 1 &&
|
||||||
CharArrayUtils.equals(name, 0, OPERATOR_CHARS.length, OPERATOR_CHARS)) {
|
CharArrayUtils.equals(name, 0, OPERATOR_CHARS.length, OPERATOR_CHARS)) {
|
||||||
if (name[OPERATOR_CHARS.length] == ' ') {
|
if (name[OPERATOR_CHARS.length] == ' ') {
|
||||||
result= !cas.containsKey(name, OPERATOR_CHARS.length+1, name.length - (OPERATOR_CHARS.length+1));
|
result= !cas.containsKey(name, OPERATOR_CHARS.length + 1, name.length - (OPERATOR_CHARS.length+1));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue