use of org.eclipse.titan.designer.AST.IReferenceChain in project titan.EclipsePlug-ins by eclipse.
the class Selection_Type method getTypeRefdLast.
@Override
public /**
* {@inheritDoc}
*/
IType getTypeRefdLast(final CompilationTimeStamp timestamp, final IReferenceChain referenceChain) {
final boolean newChain = null == referenceChain;
IReferenceChain tempReferenceChain;
if (newChain) {
tempReferenceChain = ReferenceChain.getInstance(IReferenceChain.CIRCULARREFERENCE, true);
} else {
tempReferenceChain = referenceChain;
}
IType type = this;
while (null != type && type instanceof IReferencingType && !type.getIsErroneous(timestamp)) {
type = ((IReferencingType) type).getTypeRefd(timestamp, tempReferenceChain);
}
if (newChain) {
tempReferenceChain.release();
}
return type;
}
use of org.eclipse.titan.designer.AST.IReferenceChain in project titan.EclipsePlug-ins by eclipse.
the class Selection_Type method checkThisValueRef.
@Override
public /**
* {@inheritDoc}
*/
IValue checkThisValueRef(final CompilationTimeStamp timestamp, final IValue value) {
if (Value_type.UNDEFINED_LOWERIDENTIFIER_VALUE.equals(value.getValuetype())) {
final IReferenceChain tempReferenceChain = ReferenceChain.getInstance(IReferenceChain.CIRCULARREFERENCE, true);
final IType refd = getTypeRefd(timestamp, tempReferenceChain);
tempReferenceChain.release();
if (null == refd) {
return value;
}
return refd.checkThisValueRef(timestamp, value);
}
return value;
}
use of org.eclipse.titan.designer.AST.IReferenceChain in project titan.EclipsePlug-ins by eclipse.
the class ASN1_Null_Value method checkEquality.
@Override
public /**
* {@inheritDoc}
*/
boolean checkEquality(final CompilationTimeStamp timestamp, final IValue other) {
final IReferenceChain referenceChain = ReferenceChain.getInstance(IReferenceChain.CIRCULARREFERENCE, true);
final IValue last = other.getValueRefdLast(timestamp, referenceChain);
referenceChain.release();
return getValuetype().equals(last.getValuetype());
}
use of org.eclipse.titan.designer.AST.IReferenceChain in project titan.EclipsePlug-ins by eclipse.
the class Charsymbols_Value method checkEquality.
@Override
public /**
* {@inheritDoc}
*/
boolean checkEquality(final CompilationTimeStamp timestamp, final IValue other) {
final IReferenceChain referenceChain = ReferenceChain.getInstance(IReferenceChain.CIRCULARREFERENCE, true);
final IValue last = other.getValueRefdLast(timestamp, referenceChain);
referenceChain.release();
return getValuetype().equals(last.getValuetype());
}
use of org.eclipse.titan.designer.AST.IReferenceChain in project titan.EclipsePlug-ins by eclipse.
the class External_Type method getTypeRefdLast.
@Override
public /**
* {@inheritDoc}
*/
IType getTypeRefdLast(final CompilationTimeStamp timestamp, final IReferenceChain referenceChain) {
final boolean newChain = null == referenceChain;
IReferenceChain tempReferenceChain;
if (newChain) {
tempReferenceChain = ReferenceChain.getInstance(IReferenceChain.CIRCULARREFERENCE, true);
} else {
tempReferenceChain = referenceChain;
}
IType t = this;
while (t != null && t instanceof IReferencingType && !t.getIsErroneous(timestamp)) {
t = ((IReferencingType) t).getTypeRefd(timestamp, tempReferenceChain);
}
if (newChain) {
tempReferenceChain.release();
}
if (t != null && t.getIsErroneous(timestamp)) {
setIsErroneous(true);
}
return t;
}
Aggregations