mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-06 09:16:02 +02:00
Fixed a few compiler warnings.
This commit is contained in:
parent
90b40763b4
commit
6936409241
4 changed files with 7 additions and 22 deletions
|
@ -118,7 +118,7 @@ public class MacroExpansionHandler {
|
|||
int eOff = mName.getFileLocation().getNodeOffset();
|
||||
int eLength = mName.getFileLocation().getNodeLength();
|
||||
if(eOff < nOff && Math.abs((eOff+eLength-nOff)) < 3) {
|
||||
scribe.print(mName.toString() + " ");
|
||||
scribe.print(mName.toString() + " "); //$NON-NLS-1$
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -445,6 +445,9 @@ public class TrailNodeEqualityChecker implements EqualityChecker<IASTNode> {
|
|||
}else {
|
||||
IType oType = getType(trailName.getRealName().resolveBinding());
|
||||
IType nType = getType(name.resolveBinding());
|
||||
if (oType == null || nType == null)
|
||||
return false;
|
||||
|
||||
if(oType.isSameType(nType)) {
|
||||
return true;
|
||||
}
|
||||
|
@ -459,25 +462,7 @@ public class TrailNodeEqualityChecker implements EqualityChecker<IASTNode> {
|
|||
return var.getType();
|
||||
}
|
||||
} catch (DOMException e) {
|
||||
return new NullType();
|
||||
}
|
||||
return new NullType();
|
||||
}
|
||||
|
||||
private class NullType implements IType{
|
||||
|
||||
@Override
|
||||
public Object clone() {
|
||||
try {
|
||||
return super.clone();
|
||||
} catch (CloneNotSupportedException e) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isSameType(IType type) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -915,7 +915,7 @@ public class CUIPlugin extends AbstractUIPlugin {
|
|||
*/
|
||||
public ContextTypeRegistry getCodeTemplateContextRegistry() {
|
||||
if (fCodeTemplateContextTypeRegistry == null) {
|
||||
fCodeTemplateContextTypeRegistry= new ContributionContextTypeRegistry("org.eclipse.cdt.ui.codeTemplates");
|
||||
fCodeTemplateContextTypeRegistry= new ContributionContextTypeRegistry("org.eclipse.cdt.ui.codeTemplates"); //$NON-NLS-1$
|
||||
|
||||
CodeTemplateContextType.registerContextTypes(fCodeTemplateContextTypeRegistry);
|
||||
FileTemplateContextType.registerContextTypes(fCodeTemplateContextTypeRegistry);
|
||||
|
|
|
@ -227,7 +227,7 @@ public final class RegexErrorParserOptionPage extends AbstractCOptionPage {
|
|||
// TODO: remove the warning before 6.1
|
||||
MessageLine errorImageLabel = new MessageLine(composite, SWT.NONE);
|
||||
errorImageLabel.setImage(JFaceResources.getImage(Dialog.DLG_IMG_MESSAGE_WARNING));
|
||||
errorImageLabel.setText("Error Parser Options user entries may be lost on CDT update as persistence will be finalized with CDT 6.1 final release.");
|
||||
errorImageLabel.setText("Error Parser Options user entries may be lost on CDT update as persistence will be finalized with CDT 6.1 final release."); //$NON-NLS-1$
|
||||
}
|
||||
|
||||
setControl(group);
|
||||
|
|
Loading…
Add table
Reference in a new issue