typeof
expression. A generic type is considered unbound
- if all of the type argument lists in its fully qualified name are empty.
- Note that the type arguments of an unbound generic type will be returned as error
- types because they do not really have type arguments. An unbound generic type
- yields null for its BaseType and an empty result for its Interfaces.
- - namespace NS - { - using o = System.Object; - partial class C : o {} - partial class C : object {} - partial class C : System.Object {} - } -- all three declarations for class C are equivalent and result in the same symbol table object - for C. However, these using alias symbols do appear in the results of certain SemanticModel - APIs. Specifically, for the base clause of the first of C's class declarations, the - following APIs may produce a result that contains an AliasSymbol: -
- SemanticInfo SemanticModel.GetSemanticInfo(ExpressionSyntax expression); - SemanticInfo SemanticModel.BindExpression(CSharpSyntaxNode location, ExpressionSyntax expression); - SemanticInfo SemanticModel.BindType(CSharpSyntaxNode location, ExpressionSyntax type); - SemanticInfo SemanticModel.BindNamespaceOrType(CSharpSyntaxNode location, ExpressionSyntax type); -- Also, the following are affected if container==null (and, for the latter, when arity==null - or arity==0): -
- IList<string> SemanticModel.LookupNames(CSharpSyntaxNode location, NamespaceOrTypeSymbol container = null, LookupOptions options = LookupOptions.Default, List<string> result = null); - IList<Symbol> SemanticModel.LookupSymbols(CSharpSyntaxNode location, NamespaceOrTypeSymbol container = null, string name = null, int? arity = null, LookupOptions options = LookupOptions.Default, List<Symbol> results = null); --
- using (var localVariable = new StreamReader("C:\\Temp\\MyFile.txt")) { ... }
-
- #line
).
- #line
).
- #line
,
- otherwise it's #line
directive that preceeds it and that
- either specifies an explicit file path or is #line default
exists and specifies an explicit path.
- System.Console.WriteLine();
- and if the statement is an expression statement of type void e.g,
- System.Console.WriteLine()
. However,
- #line
(C#) or #ExternalSource
(VB) directives.
- #line
in C# or #ExternalSource
in VB).
- #line
).
- #line
in C# or #ExternalSource
in VB).
- #line
,
- otherwise it's #line
directive that preceeds it and that
- either specifies an explicit file path or is #line default
exists and specifies an explicit path.
- GetType
expression. A generic type is considered unbound
- if all of the type argument lists in its fully qualified name are empty.
- Note that the type arguments of an unbound generic type will be returned as error
- types because they do not really have type arguments. An unbound generic type
- yields null for its BaseType and an empty result for its Interfaces.
- - Imports o = System.Object - Namespace NS - partial class C : Inherits o : End Class - partial class C : Inherits Object : End Class - partial class C : Inherits System.Object : End Class - End Namespace - -- all three declarations for class C are equivalent and result in the same symbol table object for C. - However, these alias symbols do appear in the results of certain SemanticModel APIs. - Specifically, for the base clause of the first of C's class declarations, the - following APIs may produce a result that contains an AliasSymbol: -
- SemanticInfo SemanticModel.GetSemanticInfo(ExpressionSyntax expression); - SemanticInfo SemanticModel.BindExpression(SyntaxNode location, ExpressionSyntax expression); - SemanticInfo SemanticModel.BindType(SyntaxNode location, ExpressionSyntax type); - SemanticInfo SemanticModel.BindNamespaceOrType(SyntaxNode location, ExpressionSyntax type); -- Also, the following are affected if container=Nothing (and, for the latter, when container=Nothing or arity=0): -
- Public Function LookupNames(position As Integer, Optional container As NamespaceOrTypeSymbol = Nothing, Optional options As LookupOptions = LookupOptions.Default, Optional results As List(Of String) = Nothing) As IList(Of String) - Public Function LookupSymbols(position As Integer, - Optional container As NamespaceOrTypeSymbol = Nothing, - Optional name As String = Nothing, - Optional arity As Integer? = Nothing, - Optional options As LookupOptions = LookupOptions.Default, - Optional results As List(Of Symbol) = Nothing) As IList(Of Symbol) --
- '''
- Class Clazz
- ...
-
-
- #ExternalSource
).
- #ExternalSource
).
-