Boo.Lang.Compiler.Steps.BindBaseTypes.CheckBaseTypes C# (CSharp) Метод

CheckBaseTypes() публичный Метод

public CheckBaseTypes ( ClassDefinition node ) : void
node Boo.Lang.Compiler.Ast.ClassDefinition
Результат void
        void CheckBaseTypes(ClassDefinition node)
        {
            IType baseClass = null;
            foreach (TypeReference baseType in node.BaseTypes)
            {
                IType baseInfo = GetType(baseType);
                if (!baseInfo.IsInterface)
                {
                    if (null != baseClass)
                    {
                        Error(
                            CompilerErrorFactory.ClassAlreadyHasBaseType(baseType,
                                node.Name,
                                baseClass.FullName)
                            );
                    }
                    else
                    {
                        baseClass = baseInfo;
                        if (baseClass.IsFinal && !TypeSystemServices.IsError(baseClass))
                        {
                            Error(
                                CompilerErrorFactory.CannotExtendFinalType(
                                    baseType,
                                    baseClass.FullName));
                        }
                    }
                }
            }

            if (null == baseClass)
            {
                node.BaseTypes.Insert(0, CodeBuilder.CreateTypeReference(TypeSystemServices.ObjectType)	);
            }
        }