mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Cosmetics.
This commit is contained in:
parent
201e1243dd
commit
1e1afcf3ce
2 changed files with 7 additions and 8 deletions
|
@ -19,7 +19,6 @@ import org.eclipse.core.runtime.CoreException;
|
|||
|
||||
/**
|
||||
* Implementation of ICPPUnaryTypeTransformation.
|
||||
*
|
||||
*/
|
||||
public class CPPUnaryTypeTransformation implements ICPPUnaryTypeTransformation, ISerializableType {
|
||||
Operator fOperator;
|
||||
|
@ -65,9 +64,10 @@ public class CPPUnaryTypeTransformation implements ICPPUnaryTypeTransformation,
|
|||
|
||||
public static IType unmarshal(short firstBytes, ITypeMarshalBuffer buffer) throws CoreException {
|
||||
int operator = buffer.getByte();
|
||||
if (operator >= Operator.values().length)
|
||||
if (operator >= Operator.values().length) {
|
||||
throw new CoreException(CCorePlugin.createStatus(
|
||||
"Cannot unmarshal CPPUnaryTypeTransformation - unrecognized type transformation operator")); //$NON-NLS-1$
|
||||
}
|
||||
return new CPPUnaryTypeTransformation(Operator.values()[operator], buffer.unmarshalType());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -62,8 +62,7 @@ class PDOMCPPClassTemplatePartialSpecialization extends PDOMCPPClassTemplate
|
|||
linkage.new ConfigurePartialSpecialization(this, partial);
|
||||
}
|
||||
|
||||
public PDOMCPPClassTemplatePartialSpecialization(PDOMLinkage linkage,
|
||||
long bindingRecord) {
|
||||
public PDOMCPPClassTemplatePartialSpecialization(PDOMLinkage linkage, long bindingRecord) {
|
||||
super(linkage, bindingRecord);
|
||||
}
|
||||
|
||||
|
@ -133,15 +132,15 @@ class PDOMCPPClassTemplatePartialSpecialization extends PDOMCPPClassTemplate
|
|||
@Override
|
||||
public int pdomCompareTo(PDOMBinding other) {
|
||||
int cmp = super.pdomCompareTo(other);
|
||||
if(cmp == 0) {
|
||||
if(other instanceof PDOMCPPClassTemplatePartialSpecialization) {
|
||||
if (cmp == 0) {
|
||||
if (other instanceof PDOMCPPClassTemplatePartialSpecialization) {
|
||||
try {
|
||||
PDOMCPPClassTemplatePartialSpecialization otherSpec = (PDOMCPPClassTemplatePartialSpecialization) other;
|
||||
int mySM = getSignatureHash();
|
||||
int otherSM = otherSpec.getSignatureHash();
|
||||
return mySM == otherSM ? 0 : mySM < otherSM ? -1 : 1;
|
||||
} catch(CoreException ce) {
|
||||
CCorePlugin.log(ce);
|
||||
} catch (CoreException e) {
|
||||
CCorePlugin.log(e);
|
||||
}
|
||||
} else {
|
||||
assert false;
|
||||
|
|
Loading…
Add table
Reference in a new issue