当前位置: 首页>>代码示例>>C#>>正文


C# Microsoft.Cci类代码示例

本文整理汇总了C#中Microsoft.Cci的典型用法代码示例。如果您正苦于以下问题:C# Microsoft.Cci类的具体用法?C# Microsoft.Cci怎么用?C# Microsoft.Cci使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Microsoft.Cci类属于命名空间,在下文中一共展示了Microsoft.Cci类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: MetadataNamedArgument

 public MetadataNamedArgument(ISymbol entity, Cci.ITypeReference type, Cci.IMetadataExpression value)
 {
     // entity must be one of INamedEntity or IFieldDefinition or IPropertyDefinition
     this.entity = entity;
     this.type = type;
     this.value = value;
 }
开发者ID:EkardNT,项目名称:Roslyn,代码行数:7,代码来源:MetadataNamedArgument.cs

示例2: MethodBody

 public MethodBody(
     byte[] ilBits,
     ushort maxStack,
     Cci.IMethodDefinition parent,
     ImmutableArray<LocalDefinition> locals,
     SequencePointList sequencePoints,
     DebugDocumentProvider debugDocumentProvider,
     ImmutableArray<Cci.ExceptionHandlerRegion> exceptionHandlers,
     ImmutableArray<LocalScope> localScopes,
     Cci.CustomDebugInfoKind customDebugInfoKind,
     bool hasDynamicLocalVariables,
     ImmutableArray<NamespaceScope> namespaceScopes = default(ImmutableArray<NamespaceScope>),
     string iteratorClassName = null,
     ImmutableArray<LocalScope> iteratorScopes = default(ImmutableArray<LocalScope>),
     Cci.AsyncMethodBodyDebugInfo asyncMethodDebugInfo = null)
 {
     this.ilBits = ilBits;
     this.asyncMethodDebugInfo = asyncMethodDebugInfo;
     this.maxStack = maxStack;
     this.parent = parent;
     this.locals = locals;
     this.sequencePoints = sequencePoints;
     this.debugDocumentProvider = debugDocumentProvider;
     this.exceptionHandlers = exceptionHandlers;
     this.localScopes = localScopes;
     this.customDebugInfoKind = customDebugInfoKind;
     this.hasDynamicLocalVariables = hasDynamicLocalVariables;
     this.namespaceScopes = namespaceScopes.IsDefault ? ImmutableArray<NamespaceScope>.Empty : namespaceScopes;
     this.iteratorClassName = iteratorClassName;
     this.iteratorScopes = iteratorScopes.IsDefault ? ImmutableArray<LocalScope>.Empty : iteratorScopes;
 }
开发者ID:riversky,项目名称:roslyn,代码行数:31,代码来源:MethodBody.cs

示例3:

        void Cci.IReference.Dispatch(Cci.MetadataVisitor visitor)
        {
            Debug.Assert(this.IsDefinitionOrDistinct());

            if (!this.IsDefinition)
            {
                if (this.IsGenericMethod)
                {
                    Debug.Assert(((Cci.IMethodReference)this).AsGenericMethodInstanceReference != null);
                    visitor.Visit((Cci.IGenericMethodInstanceReference)this);
                }
                else
                {
                    Debug.Assert(((Cci.IMethodReference)this).AsSpecializedMethodReference != null);
                    visitor.Visit((Cci.ISpecializedMethodReference)this);
                }
            }
            else
            {
                PEModuleBuilder moduleBeingBuilt = (PEModuleBuilder)visitor.Context.Module;
                if (object.ReferenceEquals(this.ContainingModule, moduleBeingBuilt.SourceModule))
                {
                    Debug.Assert(((Cci.IMethodReference)this).GetResolvedMethod(visitor.Context) != null);
                    visitor.Visit((Cci.IMethodDefinition)this);
                } 
                else
                {
                    visitor.Visit((Cci.IMethodReference)this);
                }
            }
        }
开发者ID:iolevel,项目名称:peachpie,代码行数:31,代码来源:MethodSymbolAdapter.cs

示例4: PermissionSetAttributeWithFileReference

        public PermissionSetAttributeWithFileReference(Cci.ICustomAttribute sourceAttribute, string resolvedPermissionSetFilePath)
        {
            Debug.Assert(!String.IsNullOrEmpty(resolvedPermissionSetFilePath));
            Debug.Assert(PathUtilities.IsAbsolute(resolvedPermissionSetFilePath));

            this.sourceAttribute = sourceAttribute;
            this.resolvedPermissionSetFilePath = resolvedPermissionSetFilePath;
        }
开发者ID:riversky,项目名称:roslyn,代码行数:8,代码来源:PermissionSetAttribute.cs

示例5: ExpandedVarargsMethodReference

        public ExpandedVarargsMethodReference(Cci.IMethodReference underlyingMethod, ImmutableArray<Cci.IParameterTypeInformation> argListParams)
        {
            Debug.Assert(underlyingMethod.AcceptsExtraArguments);
            Debug.Assert(!argListParams.IsEmpty);

            this.underlyingMethod = underlyingMethod;
            this.argListParams = argListParams;
        }
开发者ID:riversky,项目名称:roslyn,代码行数:8,代码来源:ExpandedVarargsMethodReference.cs

示例6: SetDllImport

 // used by DllImportAttribute
 public void SetDllImport(int attributeIndex, string moduleName, string entryPointName, Cci.PInvokeAttributes flags, bool preserveSig)
 {
     VerifySealed(expected: false);
     Debug.Assert(attributeIndex >= 0);
     platformInvokeInfo = new DllImportData(moduleName, entryPointName, flags);
     this.dllImportIndex = attributeIndex;
     this.dllImportPreserveSig = preserveSig;
     SetDataStored();
 }
开发者ID:modulexcite,项目名称:pattern-matching-csharp,代码行数:10,代码来源:CommonMethodWellKnownAttributeData.cs

示例7: LocalScope

        internal LocalScope(uint begin, uint end, Cci.IMethodDefinition parent, IEnumerable<Cci.ILocalDefinition> constantSymbols, IEnumerable<Cci.ILocalDefinition> localSymbols)
        {
            //we should not create 0-length scopes as they are useless.
            //however we will allow the case of "begin == end" as that is how edge inclusive scopes of length 1 are represented.
            System.Diagnostics.Debug.Assert(begin <= end);

            this.offset = begin;
            this.length = end - begin;
            this.parent = parent;
            this.constantSymbols = constantSymbols;
            this.localSymbols = localSymbols;
        }
开发者ID:riversky,项目名称:roslyn,代码行数:12,代码来源:LocalScope.cs

示例8: PEAssemblyBuilder

        public PEAssemblyBuilder(
            SourceAssemblySymbol sourceAssembly,
            Cci.ModulePropertiesForSerialization serializationProperties,
            IEnumerable<ResourceDescription> manifestResources,
            OutputKind outputKind,
            EmitOptions emitOptions)
            :base(sourceAssembly.DeclaringCompilation, (SourceModuleSymbol)sourceAssembly.Modules[0], serializationProperties, manifestResources, outputKind, emitOptions)
        {
            _sourceAssembly = sourceAssembly;
            _metadataName = (emitOptions.OutputNameOverride == null) ? sourceAssembly.MetadataName : FileNameUtilities.ChangeExtension(emitOptions.OutputNameOverride, extension: null);

            AssemblyOrModuleSymbolToModuleRefMap.Add(sourceAssembly, this);
        }
开发者ID:iolevel,项目名称:peachpie,代码行数:13,代码来源:PEAssemblyBuilder.cs

示例9: PEModuleBuilder

        protected PEModuleBuilder(
            PhpCompilation compilation,
            SourceModuleSymbol sourceModule,
            Cci.ModulePropertiesForSerialization serializationProperties,
            IEnumerable<ResourceDescription> manifestResources,
            OutputKind outputKind,
            EmitOptions emitOptions)
        {
            Debug.Assert(sourceModule != null);
            Debug.Assert(serializationProperties != null);

            _compilation = compilation;
            _sourceModule = sourceModule;
            _serializationProperties = serializationProperties;
            this.ManifestResources = manifestResources;
            _outputKind = outputKind;
            _emitOptions = emitOptions;
            this.CompilationState = new CommonModuleCompilationState();
            _debugDocuments = new ConcurrentDictionary<string, Cci.DebugSourceDocument>(compilation.IsCaseSensitive ? StringComparer.Ordinal : StringComparer.OrdinalIgnoreCase);
            _synthesized = new SynthesizedManager(this);

            AssemblyOrModuleSymbolToModuleRefMap.Add(sourceModule, this);
        }
开发者ID:iolevel,项目名称:peachpie,代码行数:23,代码来源:PEModuleBuilder.cs

示例10:

 void Cci.IMetadataExpression.Dispatch(Cci.MetadataVisitor visitor)
 {
     visitor.Visit(this);
 }
开发者ID:riversky,项目名称:roslyn,代码行数:4,代码来源:PermissionSetAttribute.cs

示例11: HexPropertyMetadataNamedArgument

 public HexPropertyMetadataNamedArgument(Cci.ITypeReference type, Cci.IMetadataExpression value)
 {
     this.type = type;
     this.value = value;
 }
开发者ID:riversky,项目名称:roslyn,代码行数:5,代码来源:PermissionSetAttribute.cs

示例12:

 void Cci.IReference.Dispatch(Cci.MetadataVisitor visitor)
 {
     visitor.Visit(this);
 }
开发者ID:iolevel,项目名称:peachpie,代码行数:4,代码来源:AssemblyReference.cs

示例13: if

 void Cci.IReference.Dispatch(Cci.MetadataVisitor visitor)
 {
     if (((Cci.IMethodReference)this).AsGenericMethodInstanceReference != null)
     {
         visitor.Visit((Cci.IGenericMethodInstanceReference)this);
     }
     else if (((Cci.IMethodReference)this).AsSpecializedMethodReference != null)
     {
         visitor.Visit((Cci.ISpecializedMethodReference)this);
     }
     else
     {
         visitor.Visit((Cci.IMethodReference)this);
     }
 }
开发者ID:riversky,项目名称:roslyn,代码行数:15,代码来源:ExpandedVarargsMethodReference.cs

示例14: Applicand

 public CCI.TypeNode BaseDefn(CCI.TypeNode typeDefn)
 {
     if (typeDefn.BaseType == null)
         return null;
     else
         return Applicand(typeDefn.BaseType);
 }
开发者ID:modulexcite,项目名称:IL2JS,代码行数:7,代码来源:InteropManager.cs

示例15: TypeArity

 public int TypeArity(CCI.Method methodDefn)
 {
     if (methodDefn.TemplateParameters != null)
         return methodDefn.TemplateParameters.Count;
     else
         return 0;
 }
开发者ID:modulexcite,项目名称:IL2JS,代码行数:7,代码来源:InteropManager.cs


注:本文中的Microsoft.Cci类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。