public static string GetName(this AstType type)
        {
            var name = "<unknown>";

            if (type.TryCast <PrimitiveType>(pt => name = pt.Keyword))
            {
                return(name);
            }

            if (type.TryCast <SimpleType>(st => name = st.Identifier))
            {
                return(name);
            }

            if (type.TryCast <MemberType>(mt => name = mt.MemberName))
            {
                return(name);
            }

            if (type.TryCast <ComposedType>(ct => name = ct.ToString()))
            {
                return(name);
            }

            return(name);
        }