1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-04 23:05:47 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2016-01-31 10:27:33 -08:00
parent 7b4ac5a6b7
commit 03fdc9525f
6 changed files with 9 additions and 13 deletions

View file

@ -121,7 +121,7 @@ public class CPPAliasTemplateInstance extends PlatformObject
public static IType unmarshal(short firstBytes, ITypeMarshalBuffer buffer) throws CoreException { public static IType unmarshal(short firstBytes, ITypeMarshalBuffer buffer) throws CoreException {
char[] name = buffer.getCharArray(); char[] name = buffer.getCharArray();
IType unmarshalledAliasedTypeInstance = buffer.unmarshalType(); IType unmarshalledAliasedTypeInstance = buffer.unmarshalType();
ICPPAliasTemplate unmarshalledAlias = (ICPPAliasTemplate)buffer.unmarshalBinding(); ICPPAliasTemplate unmarshalledAlias = (ICPPAliasTemplate) buffer.unmarshalBinding();
return new CPPAliasTemplateInstance(name, unmarshalledAlias, unmarshalledAliasedTypeInstance); return new CPPAliasTemplateInstance(name, unmarshalledAlias, unmarshalledAliasedTypeInstance);
} }

View file

@ -1,14 +1,13 @@
/******************************************************************************* /*******************************************************************************
* Copyright (c) 2012 Wind River Systems, Inc. and others. * Copyright (c) 2012, 2016 Wind River Systems, Inc. and others.
* All rights reserved. This program and the accompanying materials * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0 * are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at * which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html * http://www.eclipse.org/legal/epl-v10.html
* *
* Contributors: * Contributors:
* Markus Schorn - initial API and implementation * Markus Schorn - initial API and implementation
*******************************************************************************/ *******************************************************************************/
package org.eclipse.cdt.internal.core.pdom.dom.cpp; package org.eclipse.cdt.internal.core.pdom.dom.cpp;
import org.eclipse.cdt.core.dom.ast.DOMException; import org.eclipse.cdt.core.dom.ast.DOMException;

View file

@ -40,7 +40,7 @@ abstract class PDOMCPPSpecialization extends PDOMCPPBinding implements ICPPSpeci
@SuppressWarnings("hiding") @SuppressWarnings("hiding")
protected static final int RECORD_SIZE = PDOMCPPBinding.RECORD_SIZE + 12; protected static final int RECORD_SIZE = PDOMCPPBinding.RECORD_SIZE + 12;
private volatile IBinding fSpecializedCache= null; private volatile IBinding fSpecializedCache;
private volatile ICPPTemplateParameterMap fArgMap; private volatile ICPPTemplateParameterMap fArgMap;
public PDOMCPPSpecialization(PDOMCPPLinkage linkage, PDOMNode parent, ICPPSpecialization spec, public PDOMCPPSpecialization(PDOMCPPLinkage linkage, PDOMNode parent, ICPPSpecialization spec,

View file

@ -124,7 +124,7 @@ class PDOMCPPTypedef extends PDOMCPPBinding implements ITypedef, ITypeContainer,
return false; return false;
if (type instanceof ITypedef) { if (type instanceof ITypedef) {
type= ((ITypedef)type).getType(); type= ((ITypedef) type).getType();
if (type == null) { if (type == null) {
return false; return false;
} }

View file

@ -25,9 +25,8 @@ import org.eclipse.cdt.internal.core.pdom.dom.PDOMLinkage;
import org.eclipse.cdt.internal.core.pdom.dom.PDOMNode; import org.eclipse.cdt.internal.core.pdom.dom.PDOMNode;
import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.CoreException;
class PDOMCPPTypedefSpecialization extends PDOMCPPSpecialization implements ITypedef, ITypeContainer, class PDOMCPPTypedefSpecialization extends PDOMCPPSpecialization
IIndexType { implements ITypedef, ITypeContainer, IIndexType {
private static final int TYPE_OFFSET = PDOMCPPSpecialization.RECORD_SIZE + 0; private static final int TYPE_OFFSET = PDOMCPPSpecialization.RECORD_SIZE + 0;
@SuppressWarnings("hiding") @SuppressWarnings("hiding")
@ -89,9 +88,6 @@ class PDOMCPPTypedefSpecialization extends PDOMCPPSpecialization implements ITyp
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }
/* (non-Javadoc)
* @see java.lang.Object#clone()
*/
@Override @Override
public Object clone() { public Object clone() {
return new CPPTypedefClone(this); return new CPPTypedefClone(this);

View file

@ -88,7 +88,8 @@ public class PDOMCPPVariableTemplatePartialSpecialization extends PDOMCPPVariabl
@Override @Override
public ICPPTemplateArgument[] getTemplateArguments() { public ICPPTemplateArgument[] getTemplateArguments() {
try { try {
return PDOMCPPArgumentList.getArguments(this, getPDOM().getDB().getRecPtr(record + ARGUMENTS)); long rec = getPDOM().getDB().getRecPtr(record + ARGUMENTS);
return PDOMCPPArgumentList.getArguments(this, rec);
} catch (CoreException e) { } catch (CoreException e) {
CCorePlugin.log("Failed to load template arguments for " + getName(), e); //$NON-NLS-1$ CCorePlugin.log("Failed to load template arguments for " + getName(), e); //$NON-NLS-1$
return ICPPTemplateArgument.EMPTY_ARGUMENTS; return ICPPTemplateArgument.EMPTY_ARGUMENTS;