當前位置: 首頁>>代碼示例>>C#>>正文


C# CSharp.ATypeNameExpression類代碼示例

本文整理匯總了C#中Mono.CSharp.ATypeNameExpression的典型用法代碼示例。如果您正苦於以下問題:C# ATypeNameExpression類的具體用法?C# ATypeNameExpression怎麽用?C# ATypeNameExpression使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


ATypeNameExpression類屬於Mono.CSharp命名空間,在下文中一共展示了ATypeNameExpression類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: AddTypeArguments

            void AddTypeArguments (ATypeNameExpression texpr, AstType result)
            {
                if (!texpr.HasTypeArguments)
                    return;
                foreach (var arg in texpr.TypeArguments.Args) {
                    result.AddChild (ConvertToType (arg), AstType.Roles.TypeArgument);
                }
            }
開發者ID:madkat,項目名稱:NRefactory,代碼行數:8,代碼來源:CSharpParser.cs

示例2: AddTypeArguments

            void AddTypeArguments (ATypeNameExpression texpr, AstType result)
            {
                if (texpr.TypeArguments == null || texpr.TypeArguments.Args == null)
                    return;
                var loc = LocationsBag.GetLocations (texpr.TypeArguments);
                if (loc != null && loc.Count >= 2)
                    result.AddChild (new CSharpTokenNode (Convert (loc [loc.Count - 2]), 1), AstType.Roles.LChevron);
                int i = 0;
                foreach (var arg in texpr.TypeArguments.Args) {
                    result.AddChild (ConvertToType (arg), AstType.Roles.TypeArgument);
                    if (loc != null && i < loc.Count - 2)
                        result.AddChild (new CSharpTokenNode (Convert (loc [i++]), 1), AstType.Roles.Comma);
                }
                if (loc != null && loc.Count >= 2)
                    result.AddChild (new CSharpTokenNode (Convert (loc [loc.Count - 1]), 1), AstType.Roles.RChevron);
            }
開發者ID:N3X15,項目名稱:ILSpy,代碼行數:16,代碼來源:CSharpParser.cs

示例3: DynamicInvocation

 public DynamicInvocation(ATypeNameExpression member, Arguments args, Location loc)
     : base(null, args, loc)
 {
     base.binder = this;
     this.member = member;
 }
開發者ID:speier,項目名稱:shake,代碼行數:6,代碼來源:dynamic.cs

示例4: AddTypeArguments

            void AddTypeArguments(AstNode parent, ATypeNameExpression memberName)
            {
                if (memberName == null || !memberName.HasTypeArguments)
                    return;
                var chevronLocs = LocationsBag.GetLocations(memberName.TypeArguments);
                if (chevronLocs != null)
                    parent.AddChild(new CSharpTokenNode(Convert(chevronLocs [chevronLocs.Count - 2]), Roles.LChevron), Roles.LChevron);
                
                for (int i = 0; i < memberName.TypeArguments.Count; i++) {
                    var arg = memberName.TypeArguments.Args [i];
                    if (arg == null)
                        continue;
                    parent.AddChild(ConvertToType(arg), Roles.TypeArgument);
                    if (chevronLocs != null && i < chevronLocs.Count - 2)
                        parent.AddChild(new CSharpTokenNode(Convert(chevronLocs [i]), Roles.Comma), Roles.Comma);
                }
                
                if (chevronLocs != null)
                    parent.AddChild(new CSharpTokenNode(Convert(chevronLocs [chevronLocs.Count - 1]), Roles.RChevron), Roles.RChevron);
            }
開發者ID:0xb1dd1e,項目名稱:NRefactory,代碼行數:20,代碼來源:CSharpParser.cs

示例5: AddTypeArguments

            void AddTypeArguments (ATypeNameExpression texpr, DomReturnType result)
            {
                if (!texpr.HasTypeArguments)
                    return;
                foreach (var arg in texpr.TypeArguments.Args) {
                    result.AddTypeParameter (ConvertReturnType (arg));
                }
            }
開發者ID:RainsSoft,項目名稱:playscript-monodevelop,代碼行數:8,代碼來源:McsParser.cs

示例6: UsingType

 public UsingType(ATypeNameExpression expr, Location loc)
     : base(expr, loc)
 {
 }
開發者ID:exodrifter,項目名稱:mcs-ICodeCompiler,代碼行數:4,代碼來源:namespace.cs

示例7: UsingClause

 public UsingClause(ATypeNameExpression expr, Location loc)
 {
     this.expr = expr;
     this.loc = loc;
 }
開發者ID:exodrifter,項目名稱:mcs-ICodeCompiler,代碼行數:5,代碼來源:namespace.cs

示例8: DynamicInvocation

        public DynamicInvocation (ATypeNameExpression member, Arguments args, Location loc)
            : base (null, args, loc)
        {
            base.binder = this;
            this.member = member;
            this.IsMemberAccess = (member is MemberAccess) || (member is SimpleName);
        }
開發者ID:rlfqudxo,項目名稱:playscript-mono,代碼行數:7,代碼來源:dynamic.cs

示例9: DynamicInvocation

        public DynamicInvocation (ATypeNameExpression member, Arguments args, bool conditionalAccessReceiver, Location loc)
            : base (null, args, loc)
        {
            base.binder = this;
            this.member = member;
            this.conditional_access_receiver = conditionalAccessReceiver;
        }
開發者ID:caomw,項目名稱:mono,代碼行數:7,代碼來源:dynamic.cs

示例10: DynamicInvocation

        //
        // When a return type is known not to be dynamic
        //
        public DynamicInvocation (ATypeNameExpression member, Arguments args, TypeSpec type, Location loc)
            : this (member, args, loc)
        {
            this.type = type;
        }
開發者ID:tgiphil,項目名稱:mono,代碼行數:8,代碼來源:dynamic.cs

示例11: ResolvePossibleAttributeType

        TypeSpec ResolvePossibleAttributeType (ATypeNameExpression expr, ref bool is_attr)
        {
            TypeExpr te = ResolveAsTypeTerminal (expr, context);
            if (te == null)
                return null;

            TypeSpec t = te.Type;
            if (t.IsAttribute) {
                is_attr = true;
            } else {
                Report.SymbolRelatedToPreviousError (t);
                Report.Error (616, Location, "`{0}': is not an attribute class", TypeManager.CSharpName (t));
            }
            return t;
        }
開發者ID:alisci01,項目名稱:mono,代碼行數:15,代碼來源:attribute.cs

示例12: GlobalAttribute

        public GlobalAttribute (NamespaceEntry ns, string target, ATypeNameExpression expression,
                    Arguments[] args, Location loc, bool nameEscaped):
            base (target, expression, args, loc, nameEscaped)
        {
            this.ns = ns;
        }
開發者ID:alisci01,項目名稱:mono,代碼行數:6,代碼來源:attribute.cs

示例13: Attribute

        public Attribute (string target, ATypeNameExpression expr, Arguments[] args, Location loc, bool nameEscaped)
        {
            this.expression = expr;
            if (args != null) {
                PosArguments = args [0];
                NamedArguments = args [1];				
            }
            this.loc = loc;
            ExplicitTarget = target;
            this.nameEscaped = nameEscaped;
        }
開發者ID:alisci01,項目名稱:mono,代碼行數:11,代碼來源:attribute.cs

示例14: CreateSpecialNameInvoke

 public static DynamicInvocation CreateSpecialNameInvoke(ATypeNameExpression member, Arguments args, Location loc)
 {
     return new DynamicInvocation (member, args, loc) {
         flags = CSharpBinderFlags.InvokeSpecialName
     };
 }
開發者ID:speier,項目名稱:shake,代碼行數:6,代碼來源:dynamic.cs

示例15: UsingAliasNamespace

 public UsingAliasNamespace(SimpleMemberName alias, ATypeNameExpression expr, Location loc)
     : base(expr, loc)
 {
     this.alias = alias;
 }
開發者ID:exodrifter,項目名稱:mcs-ICodeCompiler,代碼行數:5,代碼來源:namespace.cs


注:本文中的Mono.CSharp.ATypeNameExpression類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。