C# 클래스 Boo.Lang.Compiler.TypeSystem.GenericConstructionChecker

Checks a generic construction for several kinds of errors.
파일 보기 프로젝트 열기: boo/boo-lang 1 사용 예제들

공개 메소드들

메소드 설명
GenericConstructionChecker ( TypeSystemServices tss, Node constructionNode, IType typeArguments, CompilerErrorCollection errorCollection ) : System
IncorrectGenerity ( IEntity definition ) : bool

Checks if the number of generic parameters on a specified definition does not match the number of supplied type arguments.

NotGenericDefinition ( IEntity entity ) : bool

Checks if a specified entity is not a generic definition.

ViolatesParameterConstraints ( IEntity definition ) : bool

Checks if the given type arguments violate any constraints declared on the type parameters of a specified generic definition.

ViolatesParameterConstraints ( IGenericParameter parameter, IType argument ) : bool

Checks if a specified type argument violates the constraints declared on a specified type paramter.

비공개 메소드들

메소드 설명
HasDefaultConstructor ( IType argument ) : bool

Checks whether a given type has a default (parameterless) consructor.

메소드 상세

GenericConstructionChecker() 공개 메소드

public GenericConstructionChecker ( TypeSystemServices tss, Node constructionNode, IType typeArguments, CompilerErrorCollection errorCollection ) : System
tss TypeSystemServices
constructionNode Node
typeArguments IType
errorCollection CompilerErrorCollection
리턴 System

IncorrectGenerity() 공개 메소드

Checks if the number of generic parameters on a specified definition does not match the number of supplied type arguments.
public IncorrectGenerity ( IEntity definition ) : bool
definition IEntity
리턴 bool

NotGenericDefinition() 공개 메소드

Checks if a specified entity is not a generic definition.
public NotGenericDefinition ( IEntity entity ) : bool
entity IEntity
리턴 bool

ViolatesParameterConstraints() 공개 메소드

Checks if the given type arguments violate any constraints declared on the type parameters of a specified generic definition.
public ViolatesParameterConstraints ( IEntity definition ) : bool
definition IEntity
리턴 bool

ViolatesParameterConstraints() 공개 메소드

Checks if a specified type argument violates the constraints declared on a specified type paramter.
public ViolatesParameterConstraints ( IGenericParameter parameter, IType argument ) : bool
parameter IGenericParameter
argument IType
리턴 bool