repo_name
stringclasses 6
values | pr_number
int64 512
78.9k
| pr_title
stringlengths 3
144
| pr_description
stringlengths 0
30.3k
| author
stringlengths 2
21
| date_created
unknown | date_merged
unknown | previous_commit
stringlengths 40
40
| pr_commit
stringlengths 40
40
| query
stringlengths 17
30.4k
| filepath
stringlengths 9
210
| before_content
stringlengths 0
112M
| after_content
stringlengths 0
112M
| label
int64 -1
1
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Portable/Compilation/VisualBasicCompilation.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Concurrent
Imports System.Collections.Immutable
Imports System.IO
Imports System.Reflection.Metadata
Imports System.Runtime.InteropServices
Imports System.Threading
Imports System.Threading.Tasks
Imports Microsoft.Cci
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.CodeGen
Imports Microsoft.CodeAnalysis.Diagnostics
Imports Microsoft.CodeAnalysis.Emit
Imports Microsoft.CodeAnalysis.InternalUtilities
Imports Microsoft.CodeAnalysis.Operations
Imports Microsoft.CodeAnalysis.PooledObjects
Imports Microsoft.CodeAnalysis.Symbols
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Emit
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic
''' <summary>
''' The Compilation object is an immutable representation of a single invocation of the
''' compiler. Although immutable, a Compilation is also on-demand, in that a compilation can be
''' created quickly, but will that compiler parts or all of the code in order to respond to
''' method or properties. Also, a compilation can produce a new compilation with a small change
''' from the current compilation. This is, in many cases, more efficient than creating a new
''' compilation from scratch, as the new compilation can share information from the old
''' compilation.
''' </summary>
Public NotInheritable Class VisualBasicCompilation
Inherits Compilation
' !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
'
' Changes to the public interface of this class should remain synchronized with the C#
' version. Do not make any changes to the public interface without making the corresponding
' change to the C# version.
'
' !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
''' <summary>
''' most of time all compilation would use same MyTemplate. no reason to create (reparse) one for each compilation
''' as long as its parse option is same
''' </summary>
Private Shared ReadOnly s_myTemplateCache As ConcurrentLruCache(Of VisualBasicParseOptions, SyntaxTree) =
New ConcurrentLruCache(Of VisualBasicParseOptions, SyntaxTree)(capacity:=5)
''' <summary>
''' The SourceAssemblySymbol for this compilation. Do not access directly, use Assembly
''' property instead. This field is lazily initialized by ReferenceManager,
''' ReferenceManager.CacheLockObject must be locked while ReferenceManager "calculates" the
''' value and assigns it, several threads must not perform duplicate "calculation"
''' simultaneously.
''' </summary>
Private _lazyAssemblySymbol As SourceAssemblySymbol
''' <summary>
''' Holds onto data related to reference binding.
''' The manager is shared among multiple compilations that we expect to have the same result of reference binding.
''' In most cases this can be determined without performing the binding. If the compilation however contains a circular
''' metadata reference (a metadata reference that refers back to the compilation) we need to avoid sharing of the binding results.
''' We do so by creating a new reference manager for such compilation.
''' </summary>
Private _referenceManager As ReferenceManager
''' <summary>
''' The options passed to the constructor of the Compilation
''' </summary>
Private ReadOnly _options As VisualBasicCompilationOptions
''' <summary>
''' The global namespace symbol. Lazily populated on first access.
''' </summary>
Private _lazyGlobalNamespace As NamespaceSymbol
''' <summary>
''' The syntax trees explicitly given to the compilation at creation, in ordinal order.
''' </summary>
Private ReadOnly _syntaxTrees As ImmutableArray(Of SyntaxTree)
Private ReadOnly _syntaxTreeOrdinalMap As ImmutableDictionary(Of SyntaxTree, Integer)
''' <summary>
''' The syntax trees of this compilation plus all 'hidden' trees
''' added to the compilation by compiler, e.g. Vb Core Runtime.
''' </summary>
Private _lazyAllSyntaxTrees As ImmutableArray(Of SyntaxTree)
''' <summary>
''' A map between syntax trees and the root declarations in the declaration table.
''' Incrementally updated between compilation versions when source changes are made.
''' </summary>
Private ReadOnly _rootNamespaces As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry)
''' <summary>
''' Imports appearing in <see cref="SyntaxTree"/>s in this compilation.
''' </summary>
''' <remarks>
''' Unlike in C#, we don't need to use a set because the <see cref="SourceFile"/> objects
''' that record the imports are persisted.
''' </remarks>
Private _lazyImportInfos As ConcurrentQueue(Of ImportInfo)
Private _lazyImportClauseDependencies As ConcurrentDictionary(Of (SyntaxTree As SyntaxTree, ImportsClausePosition As Integer), ImmutableArray(Of AssemblySymbol))
''' <summary>
''' Cache the CLS diagnostics for the whole compilation so they aren't computed repeatedly.
''' </summary>
''' <remarks>
''' NOTE: Presently, we do not cache the per-tree diagnostics.
''' </remarks>
Private _lazyClsComplianceDiagnostics As ImmutableArray(Of Diagnostic)
Private _lazyClsComplianceDependencies As ImmutableArray(Of AssemblySymbol)
''' <summary>
''' A SyntaxTree and the associated RootSingleNamespaceDeclaration for an embedded
''' syntax tree in the Compilation. Unlike the entries in m_rootNamespaces, the
''' SyntaxTree here is lazy since the tree cannot be evaluated until the references
''' have been resolved (as part of binding the source module), and at that point, the
''' SyntaxTree may be Nothing if the embedded tree is not needed for the Compilation.
''' </summary>
Private Structure EmbeddedTreeAndDeclaration
Public ReadOnly Tree As Lazy(Of SyntaxTree)
Public ReadOnly DeclarationEntry As DeclarationTableEntry
Public Sub New(treeOpt As Func(Of SyntaxTree), rootNamespaceOpt As Func(Of RootSingleNamespaceDeclaration))
Me.Tree = New Lazy(Of SyntaxTree)(treeOpt)
Me.DeclarationEntry = New DeclarationTableEntry(New Lazy(Of RootSingleNamespaceDeclaration)(rootNamespaceOpt), isEmbedded:=True)
End Sub
End Structure
Private ReadOnly _embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration)
''' <summary>
''' The declaration table that holds onto declarations from source. Incrementally updated
''' between compilation versions when source changes are made.
''' </summary>
''' <remarks></remarks>
Private ReadOnly _declarationTable As DeclarationTable
''' <summary>
''' Manages anonymous types declared in this compilation. Unifies types that are structurally equivalent.
''' </summary>
Private ReadOnly _anonymousTypeManager As AnonymousTypeManager
''' <summary>
''' Manages automatically embedded content.
''' </summary>
Private _lazyEmbeddedSymbolManager As EmbeddedSymbolManager
''' <summary>
''' MyTemplate automatically embedded from resource in the compiler.
''' It doesn't feel like it should be managed by EmbeddedSymbolManager
''' because MyTemplate is treated as user code, i.e. can be extended via
''' partial declarations, doesn't require "on-demand" metadata generation, etc.
'''
''' SyntaxTree.Dummy means uninitialized.
''' </summary>
Private _lazyMyTemplate As SyntaxTree = VisualBasicSyntaxTree.Dummy
Private ReadOnly _scriptClass As Lazy(Of ImplicitNamedTypeSymbol)
''' <summary>
''' Contains the main method of this assembly, if there is one.
''' </summary>
Private _lazyEntryPoint As EntryPoint
''' <summary>
''' The set of trees for which a <see cref="CompilationUnitCompletedEvent"/> has been added to the queue.
''' </summary>
Private _lazyCompilationUnitCompletedTrees As HashSet(Of SyntaxTree)
''' <summary>
''' The common language version among the trees of the compilation.
''' </summary>
Private ReadOnly _languageVersion As LanguageVersion
Public Overrides ReadOnly Property Language As String
Get
Return LanguageNames.VisualBasic
End Get
End Property
Public Overrides ReadOnly Property IsCaseSensitive As Boolean
Get
Return False
End Get
End Property
Friend ReadOnly Property Declarations As DeclarationTable
Get
Return _declarationTable
End Get
End Property
Friend ReadOnly Property MergedRootDeclaration As MergedNamespaceDeclaration
Get
Return Declarations.GetMergedRoot(Me)
End Get
End Property
Public Shadows ReadOnly Property Options As VisualBasicCompilationOptions
Get
Return _options
End Get
End Property
''' <summary>
''' The language version that was used to parse the syntax trees of this compilation.
''' </summary>
Public ReadOnly Property LanguageVersion As LanguageVersion
Get
Return _languageVersion
End Get
End Property
Friend ReadOnly Property AnonymousTypeManager As AnonymousTypeManager
Get
Return Me._anonymousTypeManager
End Get
End Property
Friend Overrides ReadOnly Property CommonAnonymousTypeManager As CommonAnonymousTypeManager
Get
Return Me._anonymousTypeManager
End Get
End Property
''' <summary>
''' SyntaxTree of MyTemplate for the compilation. Settable for testing purposes only.
''' </summary>
Friend Property MyTemplate As SyntaxTree
Get
If _lazyMyTemplate Is VisualBasicSyntaxTree.Dummy Then
Dim compilationOptions = Me.Options
If compilationOptions.EmbedVbCoreRuntime OrElse compilationOptions.SuppressEmbeddedDeclarations Then
_lazyMyTemplate = Nothing
Else
' first see whether we can use one from global cache
Dim parseOptions = If(compilationOptions.ParseOptions, VisualBasicParseOptions.Default)
Dim tree As SyntaxTree = Nothing
If s_myTemplateCache.TryGetValue(parseOptions, tree) Then
Debug.Assert(tree IsNot Nothing)
Debug.Assert(tree IsNot VisualBasicSyntaxTree.Dummy)
Debug.Assert(tree.IsMyTemplate)
Interlocked.CompareExchange(_lazyMyTemplate, tree, VisualBasicSyntaxTree.Dummy)
Else
' we need to make one.
Dim text As String = EmbeddedResources.VbMyTemplateText
' The My template regularly makes use of more recent language features. Care is
' taken to ensure these are compatible with 2.0 runtimes so there is no danger
' with allowing the newer syntax here.
Dim options = parseOptions.WithLanguageVersion(LanguageVersion.Default)
tree = VisualBasicSyntaxTree.ParseText(text, options:=options, isMyTemplate:=True)
If tree.GetDiagnostics().Any() Then
Throw ExceptionUtilities.Unreachable
End If
If Interlocked.CompareExchange(_lazyMyTemplate, tree, VisualBasicSyntaxTree.Dummy) Is VisualBasicSyntaxTree.Dummy Then
' set global cache
s_myTemplateCache(parseOptions) = tree
End If
End If
End If
Debug.Assert(_lazyMyTemplate Is Nothing OrElse _lazyMyTemplate.IsMyTemplate)
End If
Return _lazyMyTemplate
End Get
Set(value As SyntaxTree)
Debug.Assert(_lazyMyTemplate Is VisualBasicSyntaxTree.Dummy)
Debug.Assert(value IsNot VisualBasicSyntaxTree.Dummy)
Debug.Assert(value Is Nothing OrElse value.IsMyTemplate)
If value?.GetDiagnostics().Any() Then
Throw ExceptionUtilities.Unreachable
End If
_lazyMyTemplate = value
End Set
End Property
Friend ReadOnly Property EmbeddedSymbolManager As EmbeddedSymbolManager
Get
If _lazyEmbeddedSymbolManager Is Nothing Then
Dim embedded = If(Options.EmbedVbCoreRuntime, EmbeddedSymbolKind.VbCore, EmbeddedSymbolKind.None) Or
If(IncludeInternalXmlHelper(), EmbeddedSymbolKind.XmlHelper, EmbeddedSymbolKind.None)
If embedded <> EmbeddedSymbolKind.None Then
embedded = embedded Or EmbeddedSymbolKind.EmbeddedAttribute
End If
Interlocked.CompareExchange(_lazyEmbeddedSymbolManager, New EmbeddedSymbolManager(embedded), Nothing)
End If
Return _lazyEmbeddedSymbolManager
End Get
End Property
#Region "Constructors and Factories"
''' <summary>
''' Create a new compilation from scratch.
''' </summary>
''' <param name="assemblyName">Simple assembly name.</param>
''' <param name="syntaxTrees">The syntax trees with the source code for the new compilation.</param>
''' <param name="references">The references for the new compilation.</param>
''' <param name="options">The compiler options to use.</param>
''' <returns>A new compilation.</returns>
Public Shared Function Create(
assemblyName As String,
Optional syntaxTrees As IEnumerable(Of SyntaxTree) = Nothing,
Optional references As IEnumerable(Of MetadataReference) = Nothing,
Optional options As VisualBasicCompilationOptions = Nothing
) As VisualBasicCompilation
Return Create(assemblyName,
options,
If(syntaxTrees IsNot Nothing, syntaxTrees.Cast(Of SyntaxTree), Nothing),
references,
previousSubmission:=Nothing,
returnType:=Nothing,
hostObjectType:=Nothing,
isSubmission:=False)
End Function
''' <summary>
''' Creates a new compilation that can be used in scripting.
''' </summary>
Friend Shared Function CreateScriptCompilation(
assemblyName As String,
Optional syntaxTree As SyntaxTree = Nothing,
Optional references As IEnumerable(Of MetadataReference) = Nothing,
Optional options As VisualBasicCompilationOptions = Nothing,
Optional previousScriptCompilation As VisualBasicCompilation = Nothing,
Optional returnType As Type = Nothing,
Optional globalsType As Type = Nothing) As VisualBasicCompilation
CheckSubmissionOptions(options)
ValidateScriptCompilationParameters(previousScriptCompilation, returnType, globalsType)
Return Create(
assemblyName,
If(options, New VisualBasicCompilationOptions(OutputKind.DynamicallyLinkedLibrary)).WithReferencesSupersedeLowerVersions(True),
If((syntaxTree IsNot Nothing), {syntaxTree}, SpecializedCollections.EmptyEnumerable(Of SyntaxTree)()),
references,
previousScriptCompilation,
returnType,
globalsType,
isSubmission:=True)
End Function
Private Shared Function Create(
assemblyName As String,
options As VisualBasicCompilationOptions,
syntaxTrees As IEnumerable(Of SyntaxTree),
references As IEnumerable(Of MetadataReference),
previousSubmission As VisualBasicCompilation,
returnType As Type,
hostObjectType As Type,
isSubmission As Boolean
) As VisualBasicCompilation
Debug.Assert(Not isSubmission OrElse options.ReferencesSupersedeLowerVersions)
If options Is Nothing Then
options = New VisualBasicCompilationOptions(OutputKind.ConsoleApplication)
End If
Dim validatedReferences = ValidateReferences(Of VisualBasicCompilationReference)(references)
Dim c As VisualBasicCompilation = Nothing
Dim embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
Dim declMap = ImmutableDictionary.Create(Of SyntaxTree, DeclarationTableEntry)()
Dim declTable = AddEmbeddedTrees(DeclarationTable.Empty, embeddedTrees)
c = New VisualBasicCompilation(
assemblyName,
options,
validatedReferences,
ImmutableArray(Of SyntaxTree).Empty,
ImmutableDictionary.Create(Of SyntaxTree, Integer)(),
declMap,
embeddedTrees,
declTable,
previousSubmission,
returnType,
hostObjectType,
isSubmission,
referenceManager:=Nothing,
reuseReferenceManager:=False,
eventQueue:=Nothing,
semanticModelProvider:=Nothing)
If syntaxTrees IsNot Nothing Then
c = c.AddSyntaxTrees(syntaxTrees)
End If
Debug.Assert(c._lazyAssemblySymbol Is Nothing)
Return c
End Function
Private Sub New(
assemblyName As String,
options As VisualBasicCompilationOptions,
references As ImmutableArray(Of MetadataReference),
syntaxTrees As ImmutableArray(Of SyntaxTree),
syntaxTreeOrdinalMap As ImmutableDictionary(Of SyntaxTree, Integer),
rootNamespaces As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration),
declarationTable As DeclarationTable,
previousSubmission As VisualBasicCompilation,
submissionReturnType As Type,
hostObjectType As Type,
isSubmission As Boolean,
referenceManager As ReferenceManager,
reuseReferenceManager As Boolean,
semanticModelProvider As SemanticModelProvider,
Optional eventQueue As AsyncQueue(Of CompilationEvent) = Nothing
)
MyBase.New(assemblyName, references, SyntaxTreeCommonFeatures(syntaxTrees), isSubmission, semanticModelProvider, eventQueue)
Debug.Assert(rootNamespaces IsNot Nothing)
Debug.Assert(declarationTable IsNot Nothing)
Debug.Assert(syntaxTrees.All(Function(tree) syntaxTrees(syntaxTreeOrdinalMap(tree)) Is tree))
Debug.Assert(syntaxTrees.SetEquals(rootNamespaces.Keys.AsImmutable(), EqualityComparer(Of SyntaxTree).Default))
Debug.Assert(embeddedTrees.All(Function(treeAndDeclaration) declarationTable.Contains(treeAndDeclaration.DeclarationEntry)))
_options = options
_syntaxTrees = syntaxTrees
_syntaxTreeOrdinalMap = syntaxTreeOrdinalMap
_rootNamespaces = rootNamespaces
_embeddedTrees = embeddedTrees
_declarationTable = declarationTable
_anonymousTypeManager = New AnonymousTypeManager(Me)
_languageVersion = CommonLanguageVersion(syntaxTrees)
_scriptClass = New Lazy(Of ImplicitNamedTypeSymbol)(AddressOf BindScriptClass)
If isSubmission Then
Debug.Assert(previousSubmission Is Nothing OrElse previousSubmission.HostObjectType Is hostObjectType)
Me.ScriptCompilationInfo = New VisualBasicScriptCompilationInfo(previousSubmission, submissionReturnType, hostObjectType)
Else
Debug.Assert(previousSubmission Is Nothing AndAlso submissionReturnType Is Nothing AndAlso hostObjectType Is Nothing)
End If
If reuseReferenceManager Then
referenceManager.AssertCanReuseForCompilation(Me)
_referenceManager = referenceManager
Else
_referenceManager = New ReferenceManager(MakeSourceAssemblySimpleName(),
options.AssemblyIdentityComparer,
If(referenceManager IsNot Nothing, referenceManager.ObservedMetadata, Nothing))
End If
Debug.Assert(_lazyAssemblySymbol Is Nothing)
If Me.EventQueue IsNot Nothing Then
Me.EventQueue.TryEnqueue(New CompilationStartedEvent(Me))
End If
End Sub
Friend Overrides Sub ValidateDebugEntryPoint(debugEntryPoint As IMethodSymbol, diagnostics As DiagnosticBag)
Debug.Assert(debugEntryPoint IsNot Nothing)
' Debug entry point has to be a method definition from this compilation.
Dim methodSymbol = TryCast(debugEntryPoint, MethodSymbol)
If methodSymbol?.DeclaringCompilation IsNot Me OrElse Not methodSymbol.IsDefinition Then
diagnostics.Add(ERRID.ERR_DebugEntryPointNotSourceMethodDefinition, Location.None)
End If
End Sub
Private Function CommonLanguageVersion(syntaxTrees As ImmutableArray(Of SyntaxTree)) As LanguageVersion
' We don't check m_Options.ParseOptions.LanguageVersion for consistency, because
' it isn't consistent in practice. In fact sometimes m_Options.ParseOptions is Nothing.
Dim result As LanguageVersion? = Nothing
For Each tree In syntaxTrees
Dim version = CType(tree.Options, VisualBasicParseOptions).LanguageVersion
If result Is Nothing Then
result = version
ElseIf result <> version Then
Throw New ArgumentException(CodeAnalysisResources.InconsistentLanguageVersions, NameOf(syntaxTrees))
End If
Next
Return If(result, LanguageVersion.Default.MapSpecifiedToEffectiveVersion)
End Function
''' <summary>
''' Create a duplicate of this compilation with different symbol instances
''' </summary>
Public Shadows Function Clone() As VisualBasicCompilation
Return New VisualBasicCompilation(
Me.AssemblyName,
_options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=True,
Me.SemanticModelProvider,
eventQueue:=Nothing) ' no event queue when cloning
End Function
Private Function UpdateSyntaxTrees(
syntaxTrees As ImmutableArray(Of SyntaxTree),
syntaxTreeOrdinalMap As ImmutableDictionary(Of SyntaxTree, Integer),
rootNamespaces As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
declarationTable As DeclarationTable,
referenceDirectivesChanged As Boolean) As VisualBasicCompilation
Return New VisualBasicCompilation(
Me.AssemblyName,
_options,
Me.ExternalReferences,
syntaxTrees,
syntaxTreeOrdinalMap,
rootNamespaces,
_embeddedTrees,
declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=Not referenceDirectivesChanged,
Me.SemanticModelProvider)
End Function
''' <summary>
''' Creates a new compilation with the specified name.
''' </summary>
Public Shadows Function WithAssemblyName(assemblyName As String) As VisualBasicCompilation
' Can't reuse references since the source assembly name changed and the referenced symbols might
' have internals-visible-to relationship with this compilation or they might had a circular reference
' to this compilation.
Return New VisualBasicCompilation(
assemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=String.Equals(assemblyName, Me.AssemblyName, StringComparison.Ordinal),
Me.SemanticModelProvider)
End Function
Public Shadows Function WithReferences(ParamArray newReferences As MetadataReference()) As VisualBasicCompilation
Return WithReferences(DirectCast(newReferences, IEnumerable(Of MetadataReference)))
End Function
''' <summary>
''' Creates a new compilation with the specified references.
''' </summary>
''' <remarks>
''' The new <see cref="VisualBasicCompilation"/> will query the given <see cref="MetadataReference"/> for the underlying
''' metadata as soon as the are needed.
'''
''' The New compilation uses whatever metadata is currently being provided by the <see cref="MetadataReference"/>.
''' E.g. if the current compilation references a metadata file that has changed since the creation of the compilation
''' the New compilation is going to use the updated version, while the current compilation will be using the previous (it doesn't change).
''' </remarks>
Public Shadows Function WithReferences(newReferences As IEnumerable(Of MetadataReference)) As VisualBasicCompilation
Dim declTable = RemoveEmbeddedTrees(_declarationTable, _embeddedTrees)
Dim c As VisualBasicCompilation = Nothing
Dim embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
declTable = AddEmbeddedTrees(declTable, embeddedTrees)
' References might have changed, don't reuse reference manager.
' Don't even reuse observed metadata - let the manager query for the metadata again.
c = New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
ValidateReferences(Of VisualBasicCompilationReference)(newReferences),
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
embeddedTrees,
declTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
referenceManager:=Nothing,
reuseReferenceManager:=False,
Me.SemanticModelProvider)
Return c
End Function
Public Shadows Function WithOptions(newOptions As VisualBasicCompilationOptions) As VisualBasicCompilation
If newOptions Is Nothing Then
Throw New ArgumentNullException(NameOf(newOptions))
End If
Dim c As VisualBasicCompilation = Nothing
Dim embeddedTrees = _embeddedTrees
Dim declTable = _declarationTable
Dim declMap = Me._rootNamespaces
If Not String.Equals(Me.Options.RootNamespace, newOptions.RootNamespace, StringComparison.Ordinal) Then
' If the root namespace was updated we have to update declaration table
' entries for all the syntax trees of the compilation
'
' NOTE: we use case-sensitive comparison so that the new compilation
' gets a root namespace with correct casing
declMap = ImmutableDictionary.Create(Of SyntaxTree, DeclarationTableEntry)()
declTable = DeclarationTable.Empty
embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
declTable = AddEmbeddedTrees(declTable, embeddedTrees)
Dim discardedReferenceDirectivesChanged As Boolean = False
For Each tree In _syntaxTrees
AddSyntaxTreeToDeclarationMapAndTable(tree, newOptions, Me.IsSubmission, declMap, declTable, discardedReferenceDirectivesChanged) ' declMap and declTable passed ByRef
Next
ElseIf Me.Options.EmbedVbCoreRuntime <> newOptions.EmbedVbCoreRuntime OrElse Me.Options.ParseOptions <> newOptions.ParseOptions Then
declTable = RemoveEmbeddedTrees(declTable, _embeddedTrees)
embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
declTable = AddEmbeddedTrees(declTable, embeddedTrees)
End If
c = New VisualBasicCompilation(
Me.AssemblyName,
newOptions,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
declMap,
embeddedTrees,
declTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=_options.CanReuseCompilationReferenceManager(newOptions),
Me.SemanticModelProvider)
Return c
End Function
''' <summary>
''' Returns a new compilation with the given compilation set as the previous submission.
''' </summary>
Friend Shadows Function WithScriptCompilationInfo(info As VisualBasicScriptCompilationInfo) As VisualBasicCompilation
If info Is ScriptCompilationInfo Then
Return Me
End If
' Metadata references are inherited from the previous submission,
' so we can only reuse the manager if we can guarantee that these references are the same.
' Check if the previous script compilation doesn't change.
' TODO Consider comparing the metadata references if they have been bound already.
' https://github.com/dotnet/roslyn/issues/43397
Dim reuseReferenceManager = ScriptCompilationInfo?.PreviousScriptCompilation Is info?.PreviousScriptCompilation
Return New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
info?.PreviousScriptCompilation,
info?.ReturnTypeOpt,
info?.GlobalsType,
info IsNot Nothing,
_referenceManager,
reuseReferenceManager,
Me.SemanticModelProvider)
End Function
''' <summary>
''' Returns a new compilation with the given semantic model provider.
''' </summary>
Friend Overrides Function WithSemanticModelProvider(semanticModelProvider As SemanticModelProvider) As Compilation
If Me.SemanticModelProvider Is semanticModelProvider Then
Return Me
End If
Return New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=True,
semanticModelProvider)
End Function
''' <summary>
''' Returns a new compilation with a given event queue.
''' </summary>
Friend Overrides Function WithEventQueue(eventQueue As AsyncQueue(Of CompilationEvent)) As Compilation
Return New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=True,
Me.SemanticModelProvider,
eventQueue:=eventQueue)
End Function
Friend Overrides Sub SerializePdbEmbeddedCompilationOptions(builder As BlobBuilder)
' LanguageVersion should already be mapped to an effective version at this point
Debug.Assert(LanguageVersion.MapSpecifiedToEffectiveVersion() = LanguageVersion)
WriteValue(builder, CompilationOptionNames.LanguageVersion, LanguageVersion.ToDisplayString())
WriteValue(builder, CompilationOptionNames.Checked, Options.CheckOverflow.ToString())
WriteValue(builder, CompilationOptionNames.OptionStrict, Options.OptionStrict.ToString())
WriteValue(builder, CompilationOptionNames.OptionInfer, Options.OptionInfer.ToString())
WriteValue(builder, CompilationOptionNames.OptionCompareText, Options.OptionCompareText.ToString())
WriteValue(builder, CompilationOptionNames.OptionExplicit, Options.OptionExplicit.ToString())
WriteValue(builder, CompilationOptionNames.EmbedRuntime, Options.EmbedVbCoreRuntime.ToString())
If Options.GlobalImports.Length > 0 Then
WriteValue(builder, CompilationOptionNames.GlobalNamespaces, String.Join(";", Options.GlobalImports.Select(Function(x) x.Name)))
End If
If Not String.IsNullOrEmpty(Options.RootNamespace) Then
WriteValue(builder, CompilationOptionNames.RootNamespace, Options.RootNamespace)
End If
If Options.ParseOptions IsNot Nothing Then
Dim preprocessorStrings = Options.ParseOptions.PreprocessorSymbols.Select(
Function(p) As String
If TypeOf p.Value Is String Then
Return p.Key + "=""" + p.Value.ToString() + """"
ElseIf p.Value Is Nothing Then
Return p.Key
Else
Return p.Key + "=" + p.Value.ToString()
End If
End Function)
WriteValue(builder, CompilationOptionNames.Define, String.Join(",", preprocessorStrings))
End If
End Sub
Private Sub WriteValue(builder As BlobBuilder, key As String, value As String)
builder.WriteUTF8(key)
builder.WriteByte(0)
builder.WriteUTF8(value)
builder.WriteByte(0)
End Sub
#End Region
#Region "Submission"
Friend Shadows ReadOnly Property ScriptCompilationInfo As VisualBasicScriptCompilationInfo
Friend Overrides ReadOnly Property CommonScriptCompilationInfo As ScriptCompilationInfo
Get
Return ScriptCompilationInfo
End Get
End Property
Friend Shadows ReadOnly Property PreviousSubmission As VisualBasicCompilation
Get
Return ScriptCompilationInfo?.PreviousScriptCompilation
End Get
End Property
Friend Overrides Function HasSubmissionResult() As Boolean
Debug.Assert(IsSubmission)
' submission can be empty or comprise of a script file
Dim tree = SyntaxTrees.SingleOrDefault()
If tree Is Nothing Then
Return False
End If
Dim root = tree.GetCompilationUnitRoot()
If root.HasErrors Then
Return False
End If
' TODO: look for return statements
' https://github.com/dotnet/roslyn/issues/5773
Dim lastStatement = root.Members.LastOrDefault()
If lastStatement Is Nothing Then
Return False
End If
Dim model = GetSemanticModel(tree)
Select Case lastStatement.Kind
Case SyntaxKind.PrintStatement
Dim expression = DirectCast(lastStatement, PrintStatementSyntax).Expression
Dim info = model.GetTypeInfo(expression)
' always true, even for info.Type = Void
Return True
Case SyntaxKind.ExpressionStatement
Dim expression = DirectCast(lastStatement, ExpressionStatementSyntax).Expression
Dim info = model.GetTypeInfo(expression)
Return info.Type.SpecialType <> SpecialType.System_Void
Case SyntaxKind.CallStatement
Dim expression = DirectCast(lastStatement, CallStatementSyntax).Invocation
Dim info = model.GetTypeInfo(expression)
Return info.Type.SpecialType <> SpecialType.System_Void
Case Else
Return False
End Select
End Function
Friend Function GetSubmissionInitializer() As SynthesizedInteractiveInitializerMethod
Return If(IsSubmission AndAlso ScriptClass IsNot Nothing,
ScriptClass.GetScriptInitializer(),
Nothing)
End Function
Protected Overrides ReadOnly Property CommonScriptGlobalsType As ITypeSymbol
Get
Return Nothing
End Get
End Property
#End Region
#Region "Syntax Trees"
''' <summary>
''' Get a read-only list of the syntax trees that this compilation was created with.
''' </summary>
Public Shadows ReadOnly Property SyntaxTrees As ImmutableArray(Of SyntaxTree)
Get
Return _syntaxTrees
End Get
End Property
''' <summary>
''' Get a read-only list of the syntax trees that this compilation was created with PLUS
''' the trees that were automatically added to it, i.e. Vb Core Runtime tree.
''' </summary>
Friend Shadows ReadOnly Property AllSyntaxTrees As ImmutableArray(Of SyntaxTree)
Get
If _lazyAllSyntaxTrees.IsDefault Then
Dim builder = ArrayBuilder(Of SyntaxTree).GetInstance()
builder.AddRange(_syntaxTrees)
For Each embeddedTree In _embeddedTrees
Dim tree = embeddedTree.Tree.Value
If tree IsNot Nothing Then
builder.Add(tree)
End If
Next
ImmutableInterlocked.InterlockedInitialize(_lazyAllSyntaxTrees, builder.ToImmutableAndFree())
End If
Return _lazyAllSyntaxTrees
End Get
End Property
''' <summary>
''' Is the passed in syntax tree in this compilation?
''' </summary>
Public Shadows Function ContainsSyntaxTree(syntaxTree As SyntaxTree) As Boolean
Return syntaxTree IsNot Nothing AndAlso _rootNamespaces.ContainsKey(syntaxTree)
End Function
Public Shadows Function AddSyntaxTrees(ParamArray trees As SyntaxTree()) As VisualBasicCompilation
Return AddSyntaxTrees(DirectCast(trees, IEnumerable(Of SyntaxTree)))
End Function
Public Shadows Function AddSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As VisualBasicCompilation
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
If Not trees.Any() Then
Return Me
End If
' We're using a try-finally for this builder because there's a test that
' specifically checks for one or more of the argument exceptions below
' and we don't want to see console spew (even though we don't generally
' care about pool "leaks" in exceptional cases). Alternatively, we
' could create a new ArrayBuilder.
Dim builder = ArrayBuilder(Of SyntaxTree).GetInstance()
Try
builder.AddRange(_syntaxTrees)
Dim referenceDirectivesChanged = False
Dim oldTreeCount = _syntaxTrees.Length
Dim ordinalMap = _syntaxTreeOrdinalMap
Dim declMap = _rootNamespaces
Dim declTable = _declarationTable
Dim i = 0
For Each tree As SyntaxTree In trees
If tree Is Nothing Then
Throw New ArgumentNullException(String.Format(VBResources.Trees0, i))
End If
If Not tree.HasCompilationUnitRoot Then
Throw New ArgumentException(String.Format(VBResources.TreesMustHaveRootNode, i))
End If
If tree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotAddCompilerSpecialTree)
End If
If declMap.ContainsKey(tree) Then
Throw New ArgumentException(VBResources.SyntaxTreeAlreadyPresent, String.Format(VBResources.Trees0, i))
End If
AddSyntaxTreeToDeclarationMapAndTable(tree, _options, Me.IsSubmission, declMap, declTable, referenceDirectivesChanged) ' declMap and declTable passed ByRef
builder.Add(tree)
ordinalMap = ordinalMap.Add(tree, oldTreeCount + i)
i += 1
Next
If IsSubmission AndAlso declMap.Count > 1 Then
Throw New ArgumentException(VBResources.SubmissionCanHaveAtMostOneSyntaxTree, NameOf(trees))
End If
Return UpdateSyntaxTrees(builder.ToImmutable(), ordinalMap, declMap, declTable, referenceDirectivesChanged)
Finally
builder.Free()
End Try
End Function
Private Shared Sub AddSyntaxTreeToDeclarationMapAndTable(
tree As SyntaxTree,
compilationOptions As VisualBasicCompilationOptions,
isSubmission As Boolean,
ByRef declMap As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
ByRef declTable As DeclarationTable,
ByRef referenceDirectivesChanged As Boolean
)
Dim entry = New DeclarationTableEntry(New Lazy(Of RootSingleNamespaceDeclaration)(Function() ForTree(tree, compilationOptions, isSubmission)), isEmbedded:=False)
declMap = declMap.Add(tree, entry) ' Callers are responsible for checking for existing entries.
declTable = declTable.AddRootDeclaration(entry)
referenceDirectivesChanged = referenceDirectivesChanged OrElse tree.HasReferenceDirectives
End Sub
Private Shared Function ForTree(tree As SyntaxTree, options As VisualBasicCompilationOptions, isSubmission As Boolean) As RootSingleNamespaceDeclaration
Return DeclarationTreeBuilder.ForTree(tree, options.GetRootNamespaceParts(), If(options.ScriptClassName, ""), isSubmission)
End Function
Public Shadows Function RemoveSyntaxTrees(ParamArray trees As SyntaxTree()) As VisualBasicCompilation
Return RemoveSyntaxTrees(DirectCast(trees, IEnumerable(Of SyntaxTree)))
End Function
Public Shadows Function RemoveSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As VisualBasicCompilation
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
If Not trees.Any() Then
Return Me
End If
Dim referenceDirectivesChanged = False
Dim removeSet As New HashSet(Of SyntaxTree)()
Dim declMap = _rootNamespaces
Dim declTable = _declarationTable
For Each tree As SyntaxTree In trees
If tree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotRemoveCompilerSpecialTree)
End If
RemoveSyntaxTreeFromDeclarationMapAndTable(tree, declMap, declTable, referenceDirectivesChanged)
removeSet.Add(tree)
Next
Debug.Assert(removeSet.Count > 0)
' We're going to have to revise the ordinals of all
' trees after the first one removed, so just build
' a new map.
' CONSIDER: an alternative approach would be to set the map to empty and
' re-calculate it the next time we need it. This might save us time in the
' case where remove calls are made sequentially (rare?).
Dim ordinalMap = ImmutableDictionary.Create(Of SyntaxTree, Integer)()
Dim builder = ArrayBuilder(Of SyntaxTree).GetInstance()
Dim i = 0
For Each tree In _syntaxTrees
If Not removeSet.Contains(tree) Then
builder.Add(tree)
ordinalMap = ordinalMap.Add(tree, i)
i += 1
End If
Next
Return UpdateSyntaxTrees(builder.ToImmutableAndFree(), ordinalMap, declMap, declTable, referenceDirectivesChanged)
End Function
Private Shared Sub RemoveSyntaxTreeFromDeclarationMapAndTable(
tree As SyntaxTree,
ByRef declMap As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
ByRef declTable As DeclarationTable,
ByRef referenceDirectivesChanged As Boolean
)
Dim root As DeclarationTableEntry = Nothing
If Not declMap.TryGetValue(tree, root) Then
Throw New ArgumentException(String.Format(VBResources.SyntaxTreeNotFoundToRemove, tree))
End If
declTable = declTable.RemoveRootDeclaration(root)
declMap = declMap.Remove(tree)
referenceDirectivesChanged = referenceDirectivesChanged OrElse tree.HasReferenceDirectives
End Sub
Public Shadows Function RemoveAllSyntaxTrees() As VisualBasicCompilation
Return UpdateSyntaxTrees(ImmutableArray(Of SyntaxTree).Empty,
ImmutableDictionary.Create(Of SyntaxTree, Integer)(),
ImmutableDictionary.Create(Of SyntaxTree, DeclarationTableEntry)(),
AddEmbeddedTrees(DeclarationTable.Empty, _embeddedTrees),
referenceDirectivesChanged:=_declarationTable.ReferenceDirectives.Any())
End Function
Public Shadows Function ReplaceSyntaxTree(oldTree As SyntaxTree, newTree As SyntaxTree) As VisualBasicCompilation
If oldTree Is Nothing Then
Throw New ArgumentNullException(NameOf(oldTree))
End If
If newTree Is Nothing Then
Return Me.RemoveSyntaxTrees(oldTree)
ElseIf newTree Is oldTree Then
Return Me
End If
If Not newTree.HasCompilationUnitRoot Then
Throw New ArgumentException(VBResources.TreeMustHaveARootNodeWithCompilationUnit, NameOf(newTree))
End If
Dim vbOldTree = oldTree
Dim vbNewTree = newTree
If vbOldTree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotRemoveCompilerSpecialTree)
End If
If vbNewTree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotAddCompilerSpecialTree)
End If
Dim declMap = _rootNamespaces
If declMap.ContainsKey(vbNewTree) Then
Throw New ArgumentException(VBResources.SyntaxTreeAlreadyPresent, NameOf(newTree))
End If
Dim declTable = _declarationTable
Dim referenceDirectivesChanged = False
' TODO(tomat): Consider comparing #r's of the old and the new tree. If they are exactly the same we could still reuse.
' This could be a perf win when editing a script file in the IDE. The services create a new compilation every keystroke
' that replaces the tree with a new one.
RemoveSyntaxTreeFromDeclarationMapAndTable(vbOldTree, declMap, declTable, referenceDirectivesChanged)
AddSyntaxTreeToDeclarationMapAndTable(vbNewTree, _options, Me.IsSubmission, declMap, declTable, referenceDirectivesChanged)
Dim ordinalMap = _syntaxTreeOrdinalMap
Debug.Assert(ordinalMap.ContainsKey(oldTree)) ' Checked by RemoveSyntaxTreeFromDeclarationMapAndTable
Dim oldOrdinal = ordinalMap(oldTree)
Dim newArray = _syntaxTrees.ToArray()
newArray(oldOrdinal) = vbNewTree
' CONSIDER: should this be an operation on ImmutableDictionary?
ordinalMap = ordinalMap.Remove(oldTree)
ordinalMap = ordinalMap.Add(newTree, oldOrdinal)
Return UpdateSyntaxTrees(newArray.AsImmutableOrNull(), ordinalMap, declMap, declTable, referenceDirectivesChanged)
End Function
Private Shared Function CreateEmbeddedTrees(compReference As Lazy(Of VisualBasicCompilation)) As ImmutableArray(Of EmbeddedTreeAndDeclaration)
Return ImmutableArray.Create(
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime Or compilation.IncludeInternalXmlHelper,
EmbeddedSymbolManager.EmbeddedSyntax,
Nothing)
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime Or compilation.IncludeInternalXmlHelper,
ForTree(EmbeddedSymbolManager.EmbeddedSyntax, compilation.Options, isSubmission:=False),
Nothing)
End Function),
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime,
EmbeddedSymbolManager.VbCoreSyntaxTree,
Nothing)
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime,
ForTree(EmbeddedSymbolManager.VbCoreSyntaxTree, compilation.Options, isSubmission:=False),
Nothing)
End Function),
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return If(compilation.IncludeInternalXmlHelper(),
EmbeddedSymbolManager.InternalXmlHelperSyntax,
Nothing)
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.IncludeInternalXmlHelper(),
ForTree(EmbeddedSymbolManager.InternalXmlHelperSyntax, compilation.Options, isSubmission:=False),
Nothing)
End Function),
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return compilation.MyTemplate
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.MyTemplate IsNot Nothing,
ForTree(compilation.MyTemplate, compilation.Options, isSubmission:=False),
Nothing)
End Function))
End Function
Private Shared Function AddEmbeddedTrees(
declTable As DeclarationTable,
embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration)
) As DeclarationTable
For Each embeddedTree In embeddedTrees
declTable = declTable.AddRootDeclaration(embeddedTree.DeclarationEntry)
Next
Return declTable
End Function
Private Shared Function RemoveEmbeddedTrees(
declTable As DeclarationTable,
embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration)
) As DeclarationTable
For Each embeddedTree In embeddedTrees
declTable = declTable.RemoveRootDeclaration(embeddedTree.DeclarationEntry)
Next
Return declTable
End Function
''' <summary>
''' Returns True if the set of references contains those assemblies needed for XML
''' literals.
''' If those assemblies are included, we should include the InternalXmlHelper
''' SyntaxTree in the Compilation so the helper methods are available for binding XML.
''' </summary>
Private Function IncludeInternalXmlHelper() As Boolean
' In new flavors of the framework, types, that XML helpers depend upon, are
' defined in assemblies with different names. Let's not hardcode these names,
' let's check for presence of types instead.
Return Not Me.Options.SuppressEmbeddedDeclarations AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Linq_Enumerable) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XElement) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XName) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XAttribute) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XNamespace)
End Function
Private Function InternalXmlHelperDependencyIsSatisfied(type As WellKnownType) As Boolean
Dim metadataName = MetadataTypeName.FromFullName(WellKnownTypes.GetMetadataName(type), useCLSCompliantNameArityEncoding:=True)
Dim sourceAssembly = Me.SourceAssembly
' Lookup only in references. An attempt to lookup in assembly being built will get us in a cycle.
' We are explicitly ignoring scenario where the type might be defined in an added module.
For Each reference As AssemblySymbol In sourceAssembly.SourceModule.GetReferencedAssemblySymbols()
Debug.Assert(Not reference.IsMissing)
Dim candidate As NamedTypeSymbol = reference.LookupTopLevelMetadataType(metadataName, digThroughForwardedTypes:=False)
If sourceAssembly.IsValidWellKnownType(candidate) AndAlso AssemblySymbol.IsAcceptableMatchForGetTypeByNameAndArity(candidate) Then
Return True
End If
Next
Return False
End Function
' TODO: This comparison probably will change to compiler command line order, or at least needs
' TODO: to be resolved. See bug 8520.
''' <summary>
''' Compare two source locations, using their containing trees, and then by Span.First within a tree.
''' Can be used to get a total ordering on declarations, for example.
''' </summary>
Friend Overrides Function CompareSourceLocations(first As Location, second As Location) As Integer
Return LexicalSortKey.Compare(first, second, Me)
End Function
''' <summary>
''' Compare two source locations, using their containing trees, and then by Span.First within a tree.
''' Can be used to get a total ordering on declarations, for example.
''' </summary>
Friend Overrides Function CompareSourceLocations(first As SyntaxReference, second As SyntaxReference) As Integer
Return LexicalSortKey.Compare(first, second, Me)
End Function
Friend Overrides Function GetSyntaxTreeOrdinal(tree As SyntaxTree) As Integer
Debug.Assert(Me.ContainsSyntaxTree(tree))
Return _syntaxTreeOrdinalMap(tree)
End Function
#End Region
#Region "References"
Friend Overrides Function CommonGetBoundReferenceManager() As CommonReferenceManager
Return GetBoundReferenceManager()
End Function
Friend Shadows Function GetBoundReferenceManager() As ReferenceManager
If _lazyAssemblySymbol Is Nothing Then
_referenceManager.CreateSourceAssemblyForCompilation(Me)
Debug.Assert(_lazyAssemblySymbol IsNot Nothing)
End If
' referenceManager can only be accessed after we initialized the lazyAssemblySymbol.
' In fact, initialization of the assembly symbol might change the reference manager.
Return _referenceManager
End Function
' for testing only:
Friend Function ReferenceManagerEquals(other As VisualBasicCompilation) As Boolean
Return _referenceManager Is other._referenceManager
End Function
Public Overrides ReadOnly Property DirectiveReferences As ImmutableArray(Of MetadataReference)
Get
Return GetBoundReferenceManager().DirectiveReferences
End Get
End Property
Friend Overrides ReadOnly Property ReferenceDirectiveMap As IDictionary(Of (path As String, content As String), MetadataReference)
Get
Return GetBoundReferenceManager().ReferenceDirectiveMap
End Get
End Property
''' <summary>
''' Gets the <see cref="AssemblySymbol"/> or <see cref="ModuleSymbol"/> for a metadata reference used to create this compilation.
''' </summary>
''' <returns><see cref="AssemblySymbol"/> or <see cref="ModuleSymbol"/> corresponding to the given reference or Nothing if there is none.</returns>
''' <remarks>
''' Uses object identity when comparing two references.
''' </remarks>
Friend Shadows Function GetAssemblyOrModuleSymbol(reference As MetadataReference) As Symbol
If (reference Is Nothing) Then
Throw New ArgumentNullException(NameOf(reference))
End If
If reference.Properties.Kind = MetadataImageKind.Assembly Then
Return GetBoundReferenceManager().GetReferencedAssemblySymbol(reference)
Else
Debug.Assert(reference.Properties.Kind = MetadataImageKind.Module)
Dim index As Integer = GetBoundReferenceManager().GetReferencedModuleIndex(reference)
Return If(index < 0, Nothing, Me.Assembly.Modules(index))
End If
End Function
''' <summary>
''' Gets the <see cref="MetadataReference"/> that corresponds to the assembly symbol.
''' </summary>
Friend Shadows Function GetMetadataReference(assemblySymbol As AssemblySymbol) As MetadataReference
Return Me.GetBoundReferenceManager().GetMetadataReference(assemblySymbol)
End Function
Private Protected Overrides Function CommonGetMetadataReference(assemblySymbol As IAssemblySymbol) As MetadataReference
Dim symbol = TryCast(assemblySymbol, AssemblySymbol)
If symbol IsNot Nothing Then
Return GetMetadataReference(symbol)
End If
Return Nothing
End Function
Public Overrides ReadOnly Property ReferencedAssemblyNames As IEnumerable(Of AssemblyIdentity)
Get
Return [Assembly].Modules.SelectMany(Function(m) m.GetReferencedAssemblies())
End Get
End Property
Friend Overrides ReadOnly Property ReferenceDirectives As IEnumerable(Of ReferenceDirective)
Get
Return _declarationTable.ReferenceDirectives
End Get
End Property
Public Overrides Function ToMetadataReference(Optional aliases As ImmutableArray(Of String) = Nothing, Optional embedInteropTypes As Boolean = False) As CompilationReference
Return New VisualBasicCompilationReference(Me, aliases, embedInteropTypes)
End Function
Public Shadows Function AddReferences(ParamArray references As MetadataReference()) As VisualBasicCompilation
Return DirectCast(MyBase.AddReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function AddReferences(references As IEnumerable(Of MetadataReference)) As VisualBasicCompilation
Return DirectCast(MyBase.AddReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function RemoveReferences(ParamArray references As MetadataReference()) As VisualBasicCompilation
Return DirectCast(MyBase.RemoveReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function RemoveReferences(references As IEnumerable(Of MetadataReference)) As VisualBasicCompilation
Return DirectCast(MyBase.RemoveReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function RemoveAllReferences() As VisualBasicCompilation
Return DirectCast(MyBase.RemoveAllReferences(), VisualBasicCompilation)
End Function
Public Shadows Function ReplaceReference(oldReference As MetadataReference, newReference As MetadataReference) As VisualBasicCompilation
Return DirectCast(MyBase.ReplaceReference(oldReference, newReference), VisualBasicCompilation)
End Function
''' <summary>
''' Determine if enum arrays can be initialized using block initialization.
''' </summary>
''' <returns>True if it's safe to use block initialization for enum arrays.</returns>
''' <remarks>
''' In NetFx 4.0, block array initializers do not work on all combinations of {32/64 X Debug/Retail} when array elements are enums.
''' This is fixed in 4.5 thus enabling block array initialization for a very common case.
''' We look for the presence of <see cref="System.Runtime.GCLatencyMode.SustainedLowLatency"/> which was introduced in .NET Framework 4.5
''' </remarks>
Friend ReadOnly Property EnableEnumArrayBlockInitialization As Boolean
Get
Dim sustainedLowLatency = GetWellKnownTypeMember(WellKnownMember.System_Runtime_GCLatencyMode__SustainedLowLatency)
Return sustainedLowLatency IsNot Nothing AndAlso sustainedLowLatency.ContainingAssembly = Assembly.CorLibrary
End Get
End Property
#End Region
#Region "Symbols"
Friend ReadOnly Property SourceAssembly As SourceAssemblySymbol
Get
GetBoundReferenceManager()
Return _lazyAssemblySymbol
End Get
End Property
''' <summary>
''' Gets the AssemblySymbol that represents the assembly being created.
''' </summary>
Friend Shadows ReadOnly Property Assembly As AssemblySymbol
Get
Return Me.SourceAssembly
End Get
End Property
''' <summary>
''' Get a ModuleSymbol that refers to the module being created by compiling all of the code. By
''' getting the GlobalNamespace property of that module, all of the namespace and types defined in source code
''' can be obtained.
''' </summary>
Friend Shadows ReadOnly Property SourceModule As ModuleSymbol
Get
Return Me.Assembly.Modules(0)
End Get
End Property
''' <summary>
''' Gets the merged root namespace that contains all namespaces and types defined in source code or in
''' referenced metadata, merged into a single namespace hierarchy. This namespace hierarchy is how the compiler
''' binds types that are referenced in code.
''' </summary>
Friend Shadows ReadOnly Property GlobalNamespace As NamespaceSymbol
Get
If _lazyGlobalNamespace Is Nothing Then
Interlocked.CompareExchange(_lazyGlobalNamespace, MergedNamespaceSymbol.CreateGlobalNamespace(Me), Nothing)
End If
Return _lazyGlobalNamespace
End Get
End Property
''' <summary>
''' Get the "root" or default namespace that all source types are declared inside. This may be the
''' global namespace or may be another namespace.
''' </summary>
Friend ReadOnly Property RootNamespace As NamespaceSymbol
Get
Return DirectCast(Me.SourceModule, SourceModuleSymbol).RootNamespace
End Get
End Property
''' <summary>
''' Given a namespace symbol, returns the corresponding namespace symbol with Compilation extent
''' that refers to that namespace in this compilation. Returns Nothing if there is no corresponding
''' namespace. This should not occur if the namespace symbol came from an assembly referenced by this
''' compilation.
''' </summary>
Friend Shadows Function GetCompilationNamespace(namespaceSymbol As INamespaceSymbol) As NamespaceSymbol
If namespaceSymbol Is Nothing Then
Throw New ArgumentNullException(NameOf(namespaceSymbol))
End If
Dim vbNs = TryCast(namespaceSymbol, NamespaceSymbol)
If vbNs IsNot Nothing AndAlso vbNs.Extent.Kind = NamespaceKind.Compilation AndAlso vbNs.Extent.Compilation Is Me Then
' If we already have a namespace with the right extent, use that.
Return vbNs
ElseIf namespaceSymbol.ContainingNamespace Is Nothing Then
' If is the root namespace, return the merged root namespace
Debug.Assert(namespaceSymbol.Name = "", "Namespace with Nothing container should be root namespace with empty name")
Return GlobalNamespace
Else
Dim containingNs = GetCompilationNamespace(namespaceSymbol.ContainingNamespace)
If containingNs Is Nothing Then
Return Nothing
End If
' Get the child namespace of the given name, if any.
Return containingNs.GetMembers(namespaceSymbol.Name).OfType(Of NamespaceSymbol)().FirstOrDefault()
End If
End Function
Friend Shadows Function GetEntryPoint(cancellationToken As CancellationToken) As MethodSymbol
Dim entryPoint As EntryPoint = GetEntryPointAndDiagnostics(cancellationToken)
Return If(entryPoint Is Nothing, Nothing, entryPoint.MethodSymbol)
End Function
Friend Function GetEntryPointAndDiagnostics(cancellationToken As CancellationToken) As EntryPoint
If Not Me.Options.OutputKind.IsApplication() AndAlso ScriptClass Is Nothing Then
Return Nothing
End If
If Me.Options.MainTypeName IsNot Nothing AndAlso Not Me.Options.MainTypeName.IsValidClrTypeName() Then
Debug.Assert(Not Me.Options.Errors.IsDefaultOrEmpty)
Return New EntryPoint(Nothing, ImmutableArray(Of Diagnostic).Empty)
End If
If _lazyEntryPoint Is Nothing Then
Dim diagnostics As ImmutableArray(Of Diagnostic) = Nothing
Dim entryPoint = FindEntryPoint(cancellationToken, diagnostics)
Interlocked.CompareExchange(_lazyEntryPoint, New EntryPoint(entryPoint, diagnostics), Nothing)
End If
Return _lazyEntryPoint
End Function
Private Function FindEntryPoint(cancellationToken As CancellationToken, ByRef sealedDiagnostics As ImmutableArray(Of Diagnostic)) As MethodSymbol
Dim diagnostics = DiagnosticBag.GetInstance()
Dim entryPointCandidates = ArrayBuilder(Of MethodSymbol).GetInstance()
Try
Dim mainType As SourceMemberContainerTypeSymbol
Dim mainTypeName As String = Me.Options.MainTypeName
Dim globalNamespace As NamespaceSymbol = Me.SourceModule.GlobalNamespace
Dim errorTarget As Object
If mainTypeName IsNot Nothing Then
' Global code is the entry point, ignore all other Mains.
If ScriptClass IsNot Nothing Then
' CONSIDER: we could use the symbol instead of just the name.
diagnostics.Add(ERRID.WRN_MainIgnored, NoLocation.Singleton, mainTypeName)
Return ScriptClass.GetScriptEntryPoint()
End If
Dim mainTypeOrNamespace = globalNamespace.GetNamespaceOrTypeByQualifiedName(mainTypeName.Split("."c)).OfType(Of NamedTypeSymbol)().OfMinimalArity()
If mainTypeOrNamespace Is Nothing Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, mainTypeName)
Return Nothing
End If
mainType = TryCast(mainTypeOrNamespace, SourceMemberContainerTypeSymbol)
If mainType Is Nothing OrElse (mainType.TypeKind <> TYPEKIND.Class AndAlso mainType.TypeKind <> TYPEKIND.Structure AndAlso mainType.TypeKind <> TYPEKIND.Module) Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, mainType)
Return Nothing
End If
' Dev10 reports ERR_StartupCodeNotFound1 but that doesn't make much sense
If mainType.IsGenericType Then
diagnostics.Add(ERRID.ERR_GenericSubMainsFound1, NoLocation.Singleton, mainType)
Return Nothing
End If
errorTarget = mainType
' NOTE: unlike in C#, we're not going search the member list of mainType directly.
' Instead, we're going to mimic dev10's behavior by doing a lookup for "Main",
' starting in mainType. Among other things, this implies that the entrypoint
' could be in a base class and that it could be hidden by a non-method member
' named "Main".
Dim binder As Binder = BinderBuilder.CreateBinderForType(mainType.ContainingSourceModule, mainType.SyntaxReferences(0).SyntaxTree, mainType)
Dim lookupResult As LookupResult = lookupResult.GetInstance()
Dim entryPointLookupOptions As LookupOptions = LookupOptions.AllMethodsOfAnyArity Or LookupOptions.IgnoreExtensionMethods
binder.LookupMember(lookupResult, mainType, WellKnownMemberNames.EntryPointMethodName, arity:=0, options:=entryPointLookupOptions, useSiteInfo:=CompoundUseSiteInfo(Of AssemblySymbol).Discarded)
If (Not lookupResult.IsGoodOrAmbiguous) OrElse lookupResult.Symbols(0).Kind <> SymbolKind.Method Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, mainType)
lookupResult.Free()
Return Nothing
End If
For Each candidate In lookupResult.Symbols
' The entrypoint cannot be in another assembly.
' NOTE: filter these out here, rather than below, so that we
' report "not found", rather than "invalid", as in dev10.
If candidate.ContainingAssembly = Me.Assembly Then
entryPointCandidates.Add(DirectCast(candidate, MethodSymbol))
End If
Next
lookupResult.Free()
Else
mainType = Nothing
errorTarget = Me.AssemblyName
For Each candidate In Me.GetSymbolsWithName(WellKnownMemberNames.EntryPointMethodName, SymbolFilter.Member, cancellationToken)
Dim method = TryCast(candidate, MethodSymbol)
If method?.IsEntryPointCandidate = True Then
entryPointCandidates.Add(method)
End If
Next
' Global code is the entry point, ignore all other Mains.
If ScriptClass IsNot Nothing Then
For Each main In entryPointCandidates
diagnostics.Add(ERRID.WRN_MainIgnored, main.Locations.First(), main)
Next
Return ScriptClass.GetScriptEntryPoint()
End If
End If
If entryPointCandidates.Count = 0 Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, errorTarget)
Return Nothing
End If
Dim hasViableGenericEntryPoints As Boolean = False
Dim viableEntryPoints = ArrayBuilder(Of MethodSymbol).GetInstance()
For Each candidate In entryPointCandidates
If Not candidate.IsViableMainMethod Then
Continue For
End If
If candidate.IsGenericMethod OrElse candidate.ContainingType.IsGenericType Then
hasViableGenericEntryPoints = True
Else
viableEntryPoints.Add(candidate)
End If
Next
Dim entryPoint As MethodSymbol = Nothing
If viableEntryPoints.Count = 0 Then
If hasViableGenericEntryPoints Then
diagnostics.Add(ERRID.ERR_GenericSubMainsFound1, NoLocation.Singleton, errorTarget)
Else
diagnostics.Add(ERRID.ERR_InValidSubMainsFound1, NoLocation.Singleton, errorTarget)
End If
ElseIf viableEntryPoints.Count > 1 Then
viableEntryPoints.Sort(LexicalOrderSymbolComparer.Instance)
diagnostics.Add(ERRID.ERR_MoreThanOneValidMainWasFound2,
NoLocation.Singleton,
Me.AssemblyName,
New FormattedSymbolList(viableEntryPoints.ToArray(), CustomSymbolDisplayFormatter.ErrorMessageFormatNoModifiersNoReturnType))
Else
entryPoint = viableEntryPoints(0)
If entryPoint.IsAsync Then
' The rule we follow:
' First determine the Sub Main using pre-async rules, and give the pre-async errors if there were 0 or >1 results
' If there was exactly one result, but it was async, then give an error. Otherwise proceed.
' This doesn't follow the same pattern as "error due to being generic". That's because
' maybe one day we'll want to allow Async Sub Main but without breaking back-compat.
Dim sourceMethod = TryCast(entryPoint, SourceMemberMethodSymbol)
Debug.Assert(sourceMethod IsNot Nothing)
If sourceMethod IsNot Nothing Then
Dim location As Location = sourceMethod.NonMergedLocation
Debug.Assert(location IsNot Nothing)
If location IsNot Nothing Then
Binder.ReportDiagnostic(diagnostics, location, ERRID.ERR_AsyncSubMain)
End If
End If
End If
End If
viableEntryPoints.Free()
Return entryPoint
Finally
entryPointCandidates.Free()
sealedDiagnostics = diagnostics.ToReadOnlyAndFree()
End Try
End Function
Friend Class EntryPoint
Public ReadOnly MethodSymbol As MethodSymbol
Public ReadOnly Diagnostics As ImmutableArray(Of Diagnostic)
Public Sub New(methodSymbol As MethodSymbol, diagnostics As ImmutableArray(Of Diagnostic))
Me.MethodSymbol = methodSymbol
Me.Diagnostics = diagnostics
End Sub
End Class
''' <summary>
''' Returns the list of member imports that apply to all syntax trees in this compilation.
''' </summary>
Friend ReadOnly Property MemberImports As ImmutableArray(Of NamespaceOrTypeSymbol)
Get
Return DirectCast(Me.SourceModule, SourceModuleSymbol).MemberImports.SelectAsArray(Function(m) m.NamespaceOrType)
End Get
End Property
''' <summary>
''' Returns the list of alias imports that apply to all syntax trees in this compilation.
''' </summary>
Friend ReadOnly Property AliasImports As ImmutableArray(Of AliasSymbol)
Get
Return DirectCast(Me.SourceModule, SourceModuleSymbol).AliasImports.SelectAsArray(Function(a) a.Alias)
End Get
End Property
Friend Overrides Sub ReportUnusedImports(diagnostics As DiagnosticBag, cancellationToken As CancellationToken)
ReportUnusedImports(filterTree:=Nothing, New BindingDiagnosticBag(diagnostics), cancellationToken)
End Sub
Private Overloads Sub ReportUnusedImports(filterTree As SyntaxTree, diagnostics As BindingDiagnosticBag, cancellationToken As CancellationToken)
If _lazyImportInfos IsNot Nothing AndAlso (filterTree Is Nothing OrElse ReportUnusedImportsInTree(filterTree)) Then
Dim unusedBuilder As ArrayBuilder(Of TextSpan) = Nothing
For Each info As ImportInfo In _lazyImportInfos
cancellationToken.ThrowIfCancellationRequested()
Dim infoTree As SyntaxTree = info.Tree
If (filterTree Is Nothing OrElse filterTree Is infoTree) AndAlso ReportUnusedImportsInTree(infoTree) Then
Dim clauseSpans = info.ClauseSpans
Dim numClauseSpans = clauseSpans.Length
If numClauseSpans = 1 Then
' Do less work in common case (one clause per statement).
If Not Me.IsImportDirectiveUsed(infoTree, clauseSpans(0).Start) Then
diagnostics.Add(ERRID.HDN_UnusedImportStatement, infoTree.GetLocation(info.StatementSpan))
Else
AddImportsDependencies(diagnostics, infoTree, clauseSpans(0))
End If
Else
If unusedBuilder IsNot Nothing Then
unusedBuilder.Clear()
End If
For Each clauseSpan In info.ClauseSpans
If Not Me.IsImportDirectiveUsed(infoTree, clauseSpan.Start) Then
If unusedBuilder Is Nothing Then
unusedBuilder = ArrayBuilder(Of TextSpan).GetInstance()
End If
unusedBuilder.Add(clauseSpan)
Else
AddImportsDependencies(diagnostics, infoTree, clauseSpan)
End If
Next
If unusedBuilder IsNot Nothing AndAlso unusedBuilder.Count > 0 Then
If unusedBuilder.Count = numClauseSpans Then
diagnostics.Add(ERRID.HDN_UnusedImportStatement, infoTree.GetLocation(info.StatementSpan))
Else
For Each clauseSpan In unusedBuilder
diagnostics.Add(ERRID.HDN_UnusedImportClause, infoTree.GetLocation(clauseSpan))
Next
End If
End If
End If
End If
Next
If unusedBuilder IsNot Nothing Then
unusedBuilder.Free()
End If
End If
CompleteTrees(filterTree)
End Sub
Private Sub AddImportsDependencies(diagnostics As BindingDiagnosticBag, infoTree As SyntaxTree, clauseSpan As TextSpan)
Dim dependencies As ImmutableArray(Of AssemblySymbol) = Nothing
If diagnostics.AccumulatesDependencies AndAlso _lazyImportClauseDependencies IsNot Nothing AndAlso
_lazyImportClauseDependencies.TryGetValue((infoTree, clauseSpan.Start), dependencies) Then
diagnostics.AddDependencies(dependencies)
End If
End Sub
Friend Overrides Sub CompleteTrees(filterTree As SyntaxTree)
' By definition, a tree Is complete when all of its compiler diagnostics have been reported.
' Since unused imports are the last thing we compute And report, a tree Is complete when
' the unused imports have been reported.
If EventQueue IsNot Nothing Then
If filterTree IsNot Nothing Then
CompleteTree(filterTree)
Else
For Each tree As SyntaxTree In SyntaxTrees
CompleteTree(tree)
Next
End If
End If
End Sub
Private Sub CompleteTree(tree As SyntaxTree)
If tree.IsEmbeddedOrMyTemplateTree Then
' The syntax trees added to AllSyntaxTrees by the compiler
' do not count toward completion.
Return
End If
Debug.Assert(AllSyntaxTrees.Contains(tree))
If _lazyCompilationUnitCompletedTrees Is Nothing Then
Interlocked.CompareExchange(_lazyCompilationUnitCompletedTrees, New HashSet(Of SyntaxTree)(), Nothing)
End If
SyncLock _lazyCompilationUnitCompletedTrees
If _lazyCompilationUnitCompletedTrees.Add(tree) Then
' signal the end of the compilation unit
EventQueue.TryEnqueue(New CompilationUnitCompletedEvent(Me, tree))
If _lazyCompilationUnitCompletedTrees.Count = SyntaxTrees.Length Then
' if that was the last tree, signal the end of compilation
CompleteCompilationEventQueue_NoLock()
End If
End If
End SyncLock
End Sub
Friend Function ShouldAddEvent(symbol As Symbol) As Boolean
Return EventQueue IsNot Nothing AndAlso symbol.IsInSource()
End Function
Friend Sub SymbolDeclaredEvent(symbol As Symbol)
If ShouldAddEvent(symbol) Then
EventQueue.TryEnqueue(New SymbolDeclaredCompilationEvent(Me, symbol))
End If
End Sub
Friend Sub RecordImportsClauseDependencies(syntaxTree As SyntaxTree, importsClausePosition As Integer, dependencies As ImmutableArray(Of AssemblySymbol))
If Not dependencies.IsDefaultOrEmpty Then
LazyInitializer.EnsureInitialized(_lazyImportClauseDependencies).TryAdd((syntaxTree, importsClausePosition), dependencies)
End If
End Sub
Friend Sub RecordImports(syntax As ImportsStatementSyntax)
LazyInitializer.EnsureInitialized(_lazyImportInfos).Enqueue(New ImportInfo(syntax))
End Sub
Private Structure ImportInfo
Public ReadOnly Tree As SyntaxTree
Public ReadOnly StatementSpan As TextSpan
Public ReadOnly ClauseSpans As ImmutableArray(Of TextSpan)
' CONSIDER: ClauseSpans will usually be a singleton. If we're
' creating too much garbage, it might be worthwhile to store
' a single clause span in a separate field.
Public Sub New(syntax As ImportsStatementSyntax)
Me.Tree = syntax.SyntaxTree
Me.StatementSpan = syntax.Span
Dim builder = ArrayBuilder(Of TextSpan).GetInstance()
For Each clause In syntax.ImportsClauses
builder.Add(clause.Span)
Next
Me.ClauseSpans = builder.ToImmutableAndFree()
End Sub
End Structure
Friend ReadOnly Property DeclaresTheObjectClass As Boolean
Get
Return SourceAssembly.DeclaresTheObjectClass
End Get
End Property
Friend Function MightContainNoPiaLocalTypes() As Boolean
Return SourceAssembly.MightContainNoPiaLocalTypes()
End Function
' NOTE(cyrusn): There is a bit of a discoverability problem with this method and the same
' named method in SyntaxTreeSemanticModel. Technically, i believe these are the appropriate
' locations for these methods. This method has no dependencies on anything but the
' compilation, while the other method needs a bindings object to determine what bound node
' an expression syntax binds to. Perhaps when we document these methods we should explain
' where a user can find the other.
''' <summary>
''' Determine what kind of conversion, if any, there is between the types
''' "source" and "destination".
''' </summary>
Public Shadows Function ClassifyConversion(source As ITypeSymbol, destination As ITypeSymbol) As Conversion
If source Is Nothing Then
Throw New ArgumentNullException(NameOf(source))
End If
If destination Is Nothing Then
Throw New ArgumentNullException(NameOf(destination))
End If
Dim vbsource = source.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(source))
Dim vbdest = destination.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(destination))
If vbsource.IsErrorType() OrElse vbdest.IsErrorType() Then
Return New Conversion(Nothing) ' No conversion
End If
Return New Conversion(Conversions.ClassifyConversion(vbsource, vbdest, CompoundUseSiteInfo(Of AssemblySymbol).Discarded))
End Function
Public Overrides Function ClassifyCommonConversion(source As ITypeSymbol, destination As ITypeSymbol) As CommonConversion
Return ClassifyConversion(source, destination).ToCommonConversion()
End Function
Friend Overrides Function ClassifyConvertibleConversion(source As IOperation, destination As ITypeSymbol, ByRef constantValue As ConstantValue) As IConvertibleConversion
constantValue = Nothing
If destination Is Nothing Then
Return New Conversion(Nothing) ' No conversion
End If
Dim sourceType As ITypeSymbol = source.Type
Dim sourceConstantValue As ConstantValue = source.GetConstantValue()
If sourceType Is Nothing Then
If sourceConstantValue IsNot Nothing AndAlso sourceConstantValue.IsNothing AndAlso destination.IsReferenceType Then
constantValue = sourceConstantValue
Return New Conversion(New KeyValuePair(Of ConversionKind, MethodSymbol)(ConversionKind.WideningNothingLiteral, Nothing))
End If
Return New Conversion(Nothing) ' No conversion
End If
Dim result As Conversion = ClassifyConversion(sourceType, destination)
If result.IsReference AndAlso sourceConstantValue IsNot Nothing AndAlso sourceConstantValue.IsNothing Then
constantValue = sourceConstantValue
End If
Return result
End Function
''' <summary>
''' A symbol representing the implicit Script class. This is null if the class is not
''' defined in the compilation.
''' </summary>
Friend Shadows ReadOnly Property ScriptClass As NamedTypeSymbol
Get
Return SourceScriptClass
End Get
End Property
Friend ReadOnly Property SourceScriptClass As ImplicitNamedTypeSymbol
Get
Return _scriptClass.Value
End Get
End Property
''' <summary>
''' Resolves a symbol that represents script container (Script class).
''' Uses the full name of the container class stored in <see cref="CompilationOptions.ScriptClassName"/> to find the symbol.
''' </summary>
''' <returns>
''' The Script class symbol or null if it is not defined.
''' </returns>
Private Function BindScriptClass() As ImplicitNamedTypeSymbol
Return DirectCast(CommonBindScriptClass(), ImplicitNamedTypeSymbol)
End Function
''' <summary>
''' Get symbol for predefined type from Cor Library referenced by this compilation.
''' </summary>
Friend Shadows Function GetSpecialType(typeId As SpecialType) As NamedTypeSymbol
Dim result = Assembly.GetSpecialType(typeId)
Debug.Assert(result.SpecialType = typeId)
Return result
End Function
''' <summary>
''' Get symbol for predefined type member from Cor Library referenced by this compilation.
''' </summary>
Friend Shadows Function GetSpecialTypeMember(memberId As SpecialMember) As Symbol
Return Assembly.GetSpecialTypeMember(memberId)
End Function
Friend Overrides Function CommonGetSpecialTypeMember(specialMember As SpecialMember) As ISymbolInternal
Return GetSpecialTypeMember(specialMember)
End Function
Friend Function GetTypeByReflectionType(type As Type) As TypeSymbol
' TODO: See CSharpCompilation.GetTypeByReflectionType
Return GetSpecialType(SpecialType.System_Object)
End Function
''' <summary>
''' Lookup a type within the compilation's assembly and all referenced assemblies
''' using its canonical CLR metadata name (names are compared case-sensitively).
''' </summary>
''' <param name="fullyQualifiedMetadataName">
''' </param>
''' <returns>
''' Symbol for the type or null if type cannot be found or is ambiguous.
''' </returns>
Friend Shadows Function GetTypeByMetadataName(fullyQualifiedMetadataName As String) As NamedTypeSymbol
Return Me.Assembly.GetTypeByMetadataName(fullyQualifiedMetadataName, includeReferences:=True, isWellKnownType:=False, conflicts:=Nothing)
End Function
Friend Shadows ReadOnly Property ObjectType As NamedTypeSymbol
Get
Return Assembly.ObjectType
End Get
End Property
Friend Shadows Function CreateArrayTypeSymbol(elementType As TypeSymbol, Optional rank As Integer = 1) As ArrayTypeSymbol
If elementType Is Nothing Then
Throw New ArgumentNullException(NameOf(elementType))
End If
If rank < 1 Then
Throw New ArgumentException(NameOf(rank))
End If
Return ArrayTypeSymbol.CreateVBArray(elementType, Nothing, rank, Me)
End Function
Friend ReadOnly Property HasTupleNamesAttributes As Boolean
Get
Dim constructorSymbol = TryCast(GetWellKnownTypeMember(WellKnownMember.System_Runtime_CompilerServices_TupleElementNamesAttribute__ctorTransformNames), MethodSymbol)
Return constructorSymbol IsNot Nothing AndAlso
Binder.GetUseSiteInfoForWellKnownTypeMember(constructorSymbol, WellKnownMember.System_Runtime_CompilerServices_TupleElementNamesAttribute__ctorTransformNames,
embedVBRuntimeUsed:=False).DiagnosticInfo Is Nothing
End Get
End Property
Private Protected Overrides Function IsSymbolAccessibleWithinCore(symbol As ISymbol, within As ISymbol, throughType As ITypeSymbol) As Boolean
Dim symbol0 = symbol.EnsureVbSymbolOrNothing(Of Symbol)(NameOf(symbol))
Dim within0 = within.EnsureVbSymbolOrNothing(Of Symbol)(NameOf(within))
Dim throughType0 = throughType.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(throughType))
Return If(within0.Kind = SymbolKind.Assembly,
AccessCheck.IsSymbolAccessible(symbol0, DirectCast(within0, AssemblySymbol), useSiteInfo:=CompoundUseSiteInfo(Of AssemblySymbol).Discarded),
AccessCheck.IsSymbolAccessible(symbol0, DirectCast(within0, NamedTypeSymbol), throughType0, useSiteInfo:=CompoundUseSiteInfo(Of AssemblySymbol).Discarded))
End Function
<Obsolete("Compilation.IsSymbolAccessibleWithin is not designed for use within the compilers", True)>
Friend Shadows Function IsSymbolAccessibleWithin(symbol As ISymbol, within As ISymbol, Optional throughType As ITypeSymbol = Nothing) As Boolean
Throw New NotImplementedException
End Function
#End Region
#Region "Binding"
'''<summary>
''' Get a fresh SemanticModel. Note that each invocation gets a fresh SemanticModel, each of
''' which has a cache. Therefore, one effectively clears the cache by discarding the
''' SemanticModel.
'''</summary>
Public Shadows Function GetSemanticModel(syntaxTree As SyntaxTree, Optional ignoreAccessibility As Boolean = False) As SemanticModel
Dim model As SemanticModel = Nothing
If SemanticModelProvider IsNot Nothing Then
model = SemanticModelProvider.GetSemanticModel(syntaxTree, Me, ignoreAccessibility)
Debug.Assert(model IsNot Nothing)
End If
Return If(model, CreateSemanticModel(syntaxTree, ignoreAccessibility))
End Function
Friend Overrides Function CreateSemanticModel(syntaxTree As SyntaxTree, ignoreAccessibility As Boolean) As SemanticModel
Return New SyntaxTreeSemanticModel(Me, DirectCast(Me.SourceModule, SourceModuleSymbol), syntaxTree, ignoreAccessibility)
End Function
Friend ReadOnly Property FeatureStrictEnabled As Boolean
Get
Return Me.Feature("strict") IsNot Nothing
End Get
End Property
#End Region
#Region "Diagnostics"
Friend Overrides ReadOnly Property MessageProvider As CommonMessageProvider
Get
Return VisualBasic.MessageProvider.Instance
End Get
End Property
''' <summary>
''' Get all diagnostics for the entire compilation. This includes diagnostics from parsing, declarations, and
''' the bodies of methods. Getting all the diagnostics is potentially a length operations, as it requires parsing and
''' compiling all the code. The set of diagnostics is not caches, so each call to this method will recompile all
''' methods.
''' </summary>
''' <param name="cancellationToken">Cancellation token to allow cancelling the operation.</param>
Public Overrides Function GetDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(DefaultDiagnosticsStage, True, cancellationToken)
End Function
''' <summary>
''' Get parse diagnostics for the entire compilation. This includes diagnostics from parsing BUT NOT from declarations and
''' the bodies of methods or initializers. The set of parse diagnostics is cached, so calling this method a second time
''' should be fast.
''' </summary>
Public Overrides Function GetParseDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(CompilationStage.Parse, False, cancellationToken)
End Function
''' <summary>
''' Get declarations diagnostics for the entire compilation. This includes diagnostics from declarations, BUT NOT
''' the bodies of methods or initializers. The set of declaration diagnostics is cached, so calling this method a second time
''' should be fast.
''' </summary>
''' <param name="cancellationToken">Cancellation token to allow cancelling the operation.</param>
Public Overrides Function GetDeclarationDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(CompilationStage.Declare, False, cancellationToken)
End Function
''' <summary>
''' Get method body diagnostics for the entire compilation. This includes diagnostics only from
''' the bodies of methods and initializers. These diagnostics are NOT cached, so calling this method a second time
''' repeats significant work.
''' </summary>
''' <param name="cancellationToken">Cancellation token to allow cancelling the operation.</param>
Public Overrides Function GetMethodBodyDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(CompilationStage.Compile, False, cancellationToken)
End Function
''' <summary>
''' Get all errors in the compilation, up through the given compilation stage. Note that this may
''' require significant work by the compiler, as all source code must be compiled to the given
''' level in order to get the errors. Errors on Options should be inspected by the user prior to constructing the compilation.
''' </summary>
''' <returns>
''' Returns all errors. The errors are not sorted in any particular order, and the client
''' should sort the errors as desired.
''' </returns>
Friend Overloads Function GetDiagnostics(stage As CompilationStage, Optional includeEarlierStages As Boolean = True, Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Dim diagnostics = DiagnosticBag.GetInstance()
GetDiagnostics(stage, includeEarlierStages, diagnostics, cancellationToken)
Return diagnostics.ToReadOnlyAndFree()
End Function
Friend Overrides Sub GetDiagnostics(stage As CompilationStage,
includeEarlierStages As Boolean,
diagnostics As DiagnosticBag,
Optional cancellationToken As CancellationToken = Nothing)
Dim builder = DiagnosticBag.GetInstance()
GetDiagnosticsWithoutFiltering(stage, includeEarlierStages, New BindingDiagnosticBag(builder), cancellationToken)
' Before returning diagnostics, we filter some of them
' to honor the compiler options (e.g., /nowarn and /warnaserror)
FilterAndAppendAndFreeDiagnostics(diagnostics, builder, cancellationToken)
End Sub
Private Sub GetDiagnosticsWithoutFiltering(stage As CompilationStage,
includeEarlierStages As Boolean,
builder As BindingDiagnosticBag,
Optional cancellationToken As CancellationToken = Nothing)
Debug.Assert(builder.AccumulatesDiagnostics)
' Add all parsing errors.
If (stage = CompilationStage.Parse OrElse stage > CompilationStage.Parse AndAlso includeEarlierStages) Then
' Embedded trees shouldn't have any errors, let's avoid making decision if they should be added too early.
' Otherwise IDE performance might be affect.
If Options.ConcurrentBuild Then
RoslynParallel.For(
0,
SyntaxTrees.Length,
UICultureUtilities.WithCurrentUICulture(
Sub(i As Integer)
builder.AddRange(SyntaxTrees(i).GetDiagnostics(cancellationToken))
End Sub),
cancellationToken)
Else
For Each tree In SyntaxTrees
cancellationToken.ThrowIfCancellationRequested()
builder.AddRange(tree.GetDiagnostics(cancellationToken))
Next
End If
Dim parseOptionsReported = New HashSet(Of ParseOptions)
If Options.ParseOptions IsNot Nothing Then
parseOptionsReported.Add(Options.ParseOptions) ' This is reported in Options.Errors at CompilationStage.Declare
End If
For Each tree In SyntaxTrees
cancellationToken.ThrowIfCancellationRequested()
If Not tree.Options.Errors.IsDefaultOrEmpty AndAlso parseOptionsReported.Add(tree.Options) Then
Dim location = tree.GetLocation(TextSpan.FromBounds(0, 0))
For Each err In tree.Options.Errors
builder.Add(err.WithLocation(location))
Next
End If
Next
End If
' Add declaration errors
If (stage = CompilationStage.Declare OrElse stage > CompilationStage.Declare AndAlso includeEarlierStages) Then
CheckAssemblyName(builder.DiagnosticBag)
builder.AddRange(Options.Errors)
builder.AddRange(GetBoundReferenceManager().Diagnostics)
SourceAssembly.GetAllDeclarationErrors(builder, cancellationToken)
AddClsComplianceDiagnostics(builder, cancellationToken)
If EventQueue IsNot Nothing AndAlso SyntaxTrees.Length = 0 Then
EnsureCompilationEventQueueCompleted()
End If
End If
' Add method body compilation errors.
If (stage = CompilationStage.Compile OrElse stage > CompilationStage.Compile AndAlso includeEarlierStages) Then
' Note: this phase does not need to be parallelized because
' it is already implemented in method compiler
Dim methodBodyDiagnostics = New BindingDiagnosticBag(DiagnosticBag.GetInstance(),
If(builder.AccumulatesDependencies, New ConcurrentSet(Of AssemblySymbol), Nothing))
GetDiagnosticsForAllMethodBodies(builder.HasAnyErrors(), methodBodyDiagnostics, doLowering:=False, cancellationToken)
builder.AddRange(methodBodyDiagnostics)
methodBodyDiagnostics.DiagnosticBag.Free()
End If
End Sub
Private Sub AddClsComplianceDiagnostics(diagnostics As BindingDiagnosticBag, cancellationToken As CancellationToken, Optional filterTree As SyntaxTree = Nothing, Optional filterSpanWithinTree As TextSpan? = Nothing)
If filterTree IsNot Nothing Then
ClsComplianceChecker.CheckCompliance(Me, diagnostics, cancellationToken, filterTree, filterSpanWithinTree)
Return
End If
Debug.Assert(filterSpanWithinTree Is Nothing)
If _lazyClsComplianceDiagnostics.IsDefault OrElse _lazyClsComplianceDependencies.IsDefault Then
Dim builder = BindingDiagnosticBag.GetInstance()
ClsComplianceChecker.CheckCompliance(Me, builder, cancellationToken)
Dim result As ImmutableBindingDiagnostic(Of AssemblySymbol) = builder.ToReadOnlyAndFree()
ImmutableInterlocked.InterlockedInitialize(_lazyClsComplianceDependencies, result.Dependencies)
ImmutableInterlocked.InterlockedInitialize(_lazyClsComplianceDiagnostics, result.Diagnostics)
End If
Debug.Assert(Not _lazyClsComplianceDependencies.IsDefault)
Debug.Assert(Not _lazyClsComplianceDiagnostics.IsDefault)
diagnostics.AddRange(New ImmutableBindingDiagnostic(Of AssemblySymbol)(_lazyClsComplianceDiagnostics, _lazyClsComplianceDependencies), allowMismatchInDependencyAccumulation:=True)
End Sub
Private Shared Iterator Function FilterDiagnosticsByLocation(diagnostics As IEnumerable(Of Diagnostic), tree As SyntaxTree, filterSpanWithinTree As TextSpan?) As IEnumerable(Of Diagnostic)
For Each diagnostic In diagnostics
If diagnostic.HasIntersectingLocation(tree, filterSpanWithinTree) Then
Yield diagnostic
End If
Next
End Function
Friend Function GetDiagnosticsForSyntaxTree(stage As CompilationStage,
tree As SyntaxTree,
filterSpanWithinTree As TextSpan?,
includeEarlierStages As Boolean,
Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
If Not SyntaxTrees.Contains(tree) Then
Throw New ArgumentException("Cannot GetDiagnosticsForSyntax for a tree that is not part of the compilation", NameOf(tree))
End If
Dim builder = New BindingDiagnosticBag(DiagnosticBag.GetInstance())
If (stage = CompilationStage.Parse OrElse stage > CompilationStage.Parse AndAlso includeEarlierStages) Then
' Add all parsing errors.
cancellationToken.ThrowIfCancellationRequested()
Dim syntaxDiagnostics = tree.GetDiagnostics(cancellationToken)
syntaxDiagnostics = FilterDiagnosticsByLocation(syntaxDiagnostics, tree, filterSpanWithinTree)
builder.AddRange(syntaxDiagnostics)
End If
' Add declaring errors
If (stage = CompilationStage.Declare OrElse stage > CompilationStage.Declare AndAlso includeEarlierStages) Then
Dim declarationDiags = DirectCast(SourceModule, SourceModuleSymbol).GetDeclarationErrorsInTree(tree, filterSpanWithinTree, AddressOf FilterDiagnosticsByLocation, cancellationToken)
Dim filteredDiags = FilterDiagnosticsByLocation(declarationDiags, tree, filterSpanWithinTree)
builder.AddRange(filteredDiags)
AddClsComplianceDiagnostics(builder, cancellationToken, tree, filterSpanWithinTree)
End If
' Add method body declaring errors.
If (stage = CompilationStage.Compile OrElse stage > CompilationStage.Compile AndAlso includeEarlierStages) Then
Dim methodBodyDiagnostics = New BindingDiagnosticBag(DiagnosticBag.GetInstance())
GetDiagnosticsForMethodBodiesInTree(tree, filterSpanWithinTree, builder.HasAnyErrors(), methodBodyDiagnostics, cancellationToken)
' This diagnostics can include diagnostics for initializers that do not belong to the tree.
' Let's filter them out.
If Not methodBodyDiagnostics.DiagnosticBag.IsEmptyWithoutResolution Then
Dim allDiags = methodBodyDiagnostics.DiagnosticBag.AsEnumerableWithoutResolution()
Dim filteredDiags = FilterDiagnosticsByLocation(allDiags, tree, filterSpanWithinTree)
For Each diag In filteredDiags
builder.Add(diag)
Next
End If
End If
Dim result = DiagnosticBag.GetInstance()
FilterAndAppendAndFreeDiagnostics(result, builder.DiagnosticBag, cancellationToken)
Return result.ToReadOnlyAndFree(Of Diagnostic)()
End Function
' Get diagnostics by compiling all method bodies.
Private Sub GetDiagnosticsForAllMethodBodies(hasDeclarationErrors As Boolean, diagnostics As BindingDiagnosticBag, doLowering As Boolean, cancellationToken As CancellationToken)
MethodCompiler.GetCompileDiagnostics(Me, SourceModule.GlobalNamespace, Nothing, Nothing, hasDeclarationErrors, diagnostics, doLowering, cancellationToken)
DocumentationCommentCompiler.WriteDocumentationCommentXml(Me, Nothing, Nothing, diagnostics, cancellationToken)
Me.ReportUnusedImports(Nothing, diagnostics, cancellationToken)
End Sub
' Get diagnostics by compiling all method bodies in the given tree.
Private Sub GetDiagnosticsForMethodBodiesInTree(tree As SyntaxTree, filterSpanWithinTree As TextSpan?, hasDeclarationErrors As Boolean, diagnostics As BindingDiagnosticBag, cancellationToken As CancellationToken)
Dim sourceMod = DirectCast(SourceModule, SourceModuleSymbol)
MethodCompiler.GetCompileDiagnostics(Me,
SourceModule.GlobalNamespace,
tree,
filterSpanWithinTree,
hasDeclarationErrors,
diagnostics,
doLoweringPhase:=False,
cancellationToken)
DocumentationCommentCompiler.WriteDocumentationCommentXml(Me, Nothing, Nothing, diagnostics, cancellationToken, tree, filterSpanWithinTree)
' Report unused import diagnostics only if computing diagnostics for the entire tree.
' Otherwise we cannot determine if a particular directive is used outside of the given sub-span within the tree.
If Not filterSpanWithinTree.HasValue OrElse filterSpanWithinTree.Value = tree.GetRoot(cancellationToken).FullSpan Then
Me.ReportUnusedImports(tree, diagnostics, cancellationToken)
End If
End Sub
Friend Overrides Function CreateAnalyzerDriver(analyzers As ImmutableArray(Of DiagnosticAnalyzer), analyzerManager As AnalyzerManager, severityFilter As SeverityFilter) As AnalyzerDriver
Dim getKind As Func(Of SyntaxNode, SyntaxKind) = Function(node As SyntaxNode) node.Kind
Dim isComment As Func(Of SyntaxTrivia, Boolean) = Function(trivia As SyntaxTrivia) trivia.Kind() = SyntaxKind.CommentTrivia
Return New AnalyzerDriver(Of SyntaxKind)(analyzers, getKind, analyzerManager, severityFilter, isComment)
End Function
#End Region
#Region "Resources"
Protected Overrides Sub AppendDefaultVersionResource(resourceStream As Stream)
Dim fileVersion As String = If(SourceAssembly.FileVersion, SourceAssembly.Identity.Version.ToString())
'for some parameters, alink used to supply whitespace instead of null.
Win32ResourceConversions.AppendVersionToResourceStream(resourceStream,
Not Me.Options.OutputKind.IsApplication(),
fileVersion:=fileVersion,
originalFileName:=Me.SourceModule.Name,
internalName:=Me.SourceModule.Name,
productVersion:=If(SourceAssembly.InformationalVersion, fileVersion),
assemblyVersion:=SourceAssembly.Identity.Version,
fileDescription:=If(SourceAssembly.Title, " "),
legalCopyright:=If(SourceAssembly.Copyright, " "),
legalTrademarks:=SourceAssembly.Trademark,
productName:=SourceAssembly.Product,
comments:=SourceAssembly.Description,
companyName:=SourceAssembly.Company)
End Sub
#End Region
#Region "Emit"
Friend Overrides ReadOnly Property LinkerMajorVersion As Byte
Get
Return &H50
End Get
End Property
Friend Overrides ReadOnly Property IsDelaySigned As Boolean
Get
Return SourceAssembly.IsDelaySigned
End Get
End Property
Friend Overrides ReadOnly Property StrongNameKeys As StrongNameKeys
Get
Return SourceAssembly.StrongNameKeys
End Get
End Property
Friend Overrides Function CreateModuleBuilder(
emitOptions As EmitOptions,
debugEntryPoint As IMethodSymbol,
sourceLinkStream As Stream,
embeddedTexts As IEnumerable(Of EmbeddedText),
manifestResources As IEnumerable(Of ResourceDescription),
testData As CompilationTestData,
diagnostics As DiagnosticBag,
cancellationToken As CancellationToken) As CommonPEModuleBuilder
Return CreateModuleBuilder(
emitOptions,
debugEntryPoint,
sourceLinkStream,
embeddedTexts,
manifestResources,
testData,
diagnostics,
ImmutableArray(Of NamedTypeSymbol).Empty,
cancellationToken)
End Function
Friend Overloads Function CreateModuleBuilder(
emitOptions As EmitOptions,
debugEntryPoint As IMethodSymbol,
sourceLinkStream As Stream,
embeddedTexts As IEnumerable(Of EmbeddedText),
manifestResources As IEnumerable(Of ResourceDescription),
testData As CompilationTestData,
diagnostics As DiagnosticBag,
additionalTypes As ImmutableArray(Of NamedTypeSymbol),
cancellationToken As CancellationToken) As CommonPEModuleBuilder
Debug.Assert(Not IsSubmission OrElse HasCodeToEmit() OrElse
(emitOptions = EmitOptions.Default AndAlso debugEntryPoint Is Nothing AndAlso sourceLinkStream Is Nothing AndAlso
embeddedTexts Is Nothing AndAlso manifestResources Is Nothing AndAlso testData Is Nothing))
' Get the runtime metadata version from the cor library. If this fails we have no reasonable value to give.
Dim runtimeMetadataVersion = GetRuntimeMetadataVersion()
Dim moduleSerializationProperties = ConstructModuleSerializationProperties(emitOptions, runtimeMetadataVersion)
If manifestResources Is Nothing Then
manifestResources = SpecializedCollections.EmptyEnumerable(Of ResourceDescription)()
End If
' if there is no stream to write to, then there is no need for a module
Dim moduleBeingBuilt As PEModuleBuilder
If Options.OutputKind.IsNetModule() Then
Debug.Assert(additionalTypes.IsEmpty)
moduleBeingBuilt = New PENetModuleBuilder(
DirectCast(Me.SourceModule, SourceModuleSymbol),
emitOptions,
moduleSerializationProperties,
manifestResources)
Else
Dim kind = If(Options.OutputKind.IsValid(), Options.OutputKind, OutputKind.DynamicallyLinkedLibrary)
moduleBeingBuilt = New PEAssemblyBuilder(
SourceAssembly,
emitOptions,
kind,
moduleSerializationProperties,
manifestResources,
additionalTypes)
End If
If debugEntryPoint IsNot Nothing Then
moduleBeingBuilt.SetDebugEntryPoint(DirectCast(debugEntryPoint, MethodSymbol), diagnostics)
End If
moduleBeingBuilt.SourceLinkStreamOpt = sourceLinkStream
If embeddedTexts IsNot Nothing Then
moduleBeingBuilt.EmbeddedTexts = embeddedTexts
End If
If testData IsNot Nothing Then
moduleBeingBuilt.SetMethodTestData(testData.Methods)
testData.Module = moduleBeingBuilt
End If
Return moduleBeingBuilt
End Function
Friend Overrides Function CompileMethods(
moduleBuilder As CommonPEModuleBuilder,
emittingPdb As Boolean,
emitMetadataOnly As Boolean,
emitTestCoverageData As Boolean,
diagnostics As DiagnosticBag,
filterOpt As Predicate(Of ISymbolInternal),
cancellationToken As CancellationToken) As Boolean
' The diagnostics should include syntax and declaration errors. We insert these before calling Emitter.Emit, so that we don't emit
' metadata if there are declaration errors or method body errors (but we do insert all errors from method body binding...)
Dim hasDeclarationErrors = Not FilterAndAppendDiagnostics(diagnostics, GetDiagnostics(CompilationStage.Declare, True, cancellationToken), exclude:=Nothing, cancellationToken)
Dim moduleBeingBuilt = DirectCast(moduleBuilder, PEModuleBuilder)
Me.EmbeddedSymbolManager.MarkAllDeferredSymbolsAsReferenced(Me)
' The translation of global imports assumes absence of error symbols.
' We don't need to translate them if there are any declaration errors since
' we are not going to emit the metadata.
If Not hasDeclarationErrors Then
moduleBeingBuilt.TranslateImports(diagnostics)
End If
If emitMetadataOnly Then
If hasDeclarationErrors Then
Return False
End If
If moduleBeingBuilt.SourceModule.HasBadAttributes Then
' If there were errors but no declaration diagnostics, explicitly add a "Failed to emit module" error.
diagnostics.Add(ERRID.ERR_ModuleEmitFailure, NoLocation.Singleton, moduleBeingBuilt.SourceModule.Name,
New LocalizableResourceString(NameOf(CodeAnalysisResources.ModuleHasInvalidAttributes), CodeAnalysisResources.ResourceManager, GetType(CodeAnalysisResources)))
Return False
End If
SynthesizedMetadataCompiler.ProcessSynthesizedMembers(Me, moduleBeingBuilt, cancellationToken)
Else
' start generating PDB checksums if we need to emit PDBs
If (emittingPdb OrElse emitTestCoverageData) AndAlso
Not CreateDebugDocuments(moduleBeingBuilt.DebugDocumentsBuilder, moduleBeingBuilt.EmbeddedTexts, diagnostics) Then
Return False
End If
' Perform initial bind of method bodies in spite of earlier errors. This is the same
' behavior as when calling GetDiagnostics()
' Use a temporary bag so we don't have to refilter pre-existing diagnostics.
Dim methodBodyDiagnosticBag = DiagnosticBag.GetInstance()
MethodCompiler.CompileMethodBodies(
Me,
moduleBeingBuilt,
emittingPdb,
emitTestCoverageData,
hasDeclarationErrors,
filterOpt,
New BindingDiagnosticBag(methodBodyDiagnosticBag),
cancellationToken)
Dim hasMethodBodyErrors As Boolean = Not FilterAndAppendAndFreeDiagnostics(diagnostics, methodBodyDiagnosticBag, cancellationToken)
If hasDeclarationErrors OrElse hasMethodBodyErrors Then
Return False
End If
End If
cancellationToken.ThrowIfCancellationRequested()
' TODO (tomat): XML doc comments diagnostics
Return True
End Function
Friend Overrides Function GenerateResourcesAndDocumentationComments(
moduleBuilder As CommonPEModuleBuilder,
xmlDocStream As Stream,
win32Resources As Stream,
useRawWin32Resources As Boolean,
outputNameOverride As String,
diagnostics As DiagnosticBag,
cancellationToken As CancellationToken) As Boolean
' Use a temporary bag so we don't have to refilter pre-existing diagnostics.
Dim resourceDiagnostics = DiagnosticBag.GetInstance()
SetupWin32Resources(moduleBuilder, win32Resources, useRawWin32Resources, resourceDiagnostics)
' give the name of any added modules, but not the name of the primary module.
ReportManifestResourceDuplicates(
moduleBuilder.ManifestResources,
SourceAssembly.Modules.Skip(1).Select(Function(x) x.Name),
AddedModulesResourceNames(resourceDiagnostics),
resourceDiagnostics)
If Not FilterAndAppendAndFreeDiagnostics(diagnostics, resourceDiagnostics, cancellationToken) Then
Return False
End If
cancellationToken.ThrowIfCancellationRequested()
' Use a temporary bag so we don't have to refilter pre-existing diagnostics.
Dim xmlDiagnostics = DiagnosticBag.GetInstance()
Dim assemblyName = FileNameUtilities.ChangeExtension(outputNameOverride, extension:=Nothing)
DocumentationCommentCompiler.WriteDocumentationCommentXml(Me, assemblyName, xmlDocStream, New BindingDiagnosticBag(xmlDiagnostics), cancellationToken)
Return FilterAndAppendAndFreeDiagnostics(diagnostics, xmlDiagnostics, cancellationToken)
End Function
Private Iterator Function AddedModulesResourceNames(diagnostics As DiagnosticBag) As IEnumerable(Of String)
Dim modules As ImmutableArray(Of ModuleSymbol) = SourceAssembly.Modules
For i As Integer = 1 To modules.Length - 1
Dim m = DirectCast(modules(i), Symbols.Metadata.PE.PEModuleSymbol)
Try
For Each resource In m.Module.GetEmbeddedResourcesOrThrow()
Yield resource.Name
Next
Catch mrEx As BadImageFormatException
diagnostics.Add(ERRID.ERR_UnsupportedModule1, NoLocation.Singleton, m)
End Try
Next
End Function
Friend Overrides Function EmitDifference(
baseline As EmitBaseline,
edits As IEnumerable(Of SemanticEdit),
isAddedSymbol As Func(Of ISymbol, Boolean),
metadataStream As Stream,
ilStream As Stream,
pdbStream As Stream,
testData As CompilationTestData,
cancellationToken As CancellationToken) As EmitDifferenceResult
Return EmitHelpers.EmitDifference(
Me,
baseline,
edits,
isAddedSymbol,
metadataStream,
ilStream,
pdbStream,
testData,
cancellationToken)
End Function
Friend Function GetRuntimeMetadataVersion() As String
Dim corLibrary = TryCast(Assembly.CorLibrary, Symbols.Metadata.PE.PEAssemblySymbol)
Return If(corLibrary Is Nothing, String.Empty, corLibrary.Assembly.ManifestModule.MetadataVersion)
End Function
Friend Overrides Sub AddDebugSourceDocumentsForChecksumDirectives(
documentsBuilder As DebugDocumentsBuilder,
tree As SyntaxTree,
diagnosticBag As DiagnosticBag)
Dim checksumDirectives = tree.GetRoot().GetDirectives(Function(d) d.Kind = SyntaxKind.ExternalChecksumDirectiveTrivia AndAlso
Not d.ContainsDiagnostics)
For Each directive In checksumDirectives
Dim checksumDirective As ExternalChecksumDirectiveTriviaSyntax = DirectCast(directive, ExternalChecksumDirectiveTriviaSyntax)
Dim path = checksumDirective.ExternalSource.ValueText
Dim checkSumText = checksumDirective.Checksum.ValueText
Dim normalizedPath = documentsBuilder.NormalizeDebugDocumentPath(path, basePath:=tree.FilePath)
Dim existingDoc = documentsBuilder.TryGetDebugDocumentForNormalizedPath(normalizedPath)
If existingDoc IsNot Nothing Then
' directive matches a file path on an actual tree.
' Dev12 compiler just ignores the directive in this case which means that
' checksum of the actual tree always wins and no warning is given.
' We will continue doing the same.
If existingDoc.IsComputedChecksum Then
Continue For
End If
Dim sourceInfo = existingDoc.GetSourceInfo()
If CheckSumMatches(checkSumText, sourceInfo.Checksum) Then
Dim guid As Guid = guid.Parse(checksumDirective.Guid.ValueText)
If guid = sourceInfo.ChecksumAlgorithmId Then
' all parts match, nothing to do
Continue For
End If
End If
' did not match to an existing document
' produce a warning and ignore the directive
diagnosticBag.Add(ERRID.WRN_MultipleDeclFileExtChecksum, New SourceLocation(checksumDirective), path)
Else
Dim newDocument = New DebugSourceDocument(
normalizedPath,
DebugSourceDocument.CorSymLanguageTypeBasic,
MakeCheckSumBytes(checksumDirective.Checksum.ValueText),
Guid.Parse(checksumDirective.Guid.ValueText))
documentsBuilder.AddDebugDocument(newDocument)
End If
Next
End Sub
Private Shared Function CheckSumMatches(bytesText As String, bytes As ImmutableArray(Of Byte)) As Boolean
If bytesText.Length <> bytes.Length * 2 Then
Return False
End If
For i As Integer = 0 To bytesText.Length \ 2 - 1
' 1A in text becomes 0x1A
Dim b As Integer = SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2)) * 16 +
SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2 + 1))
If b <> bytes(i) Then
Return False
End If
Next
Return True
End Function
Private Shared Function MakeCheckSumBytes(bytesText As String) As ImmutableArray(Of Byte)
Dim builder As ArrayBuilder(Of Byte) = ArrayBuilder(Of Byte).GetInstance()
For i As Integer = 0 To bytesText.Length \ 2 - 1
' 1A in text becomes 0x1A
Dim b As Byte = CByte(SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2)) * 16 +
SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2 + 1)))
builder.Add(b)
Next
Return builder.ToImmutableAndFree()
End Function
Friend Overrides ReadOnly Property DebugSourceDocumentLanguageId As Guid
Get
Return DebugSourceDocument.CorSymLanguageTypeBasic
End Get
End Property
Friend Overrides Function HasCodeToEmit() As Boolean
For Each syntaxTree In SyntaxTrees
Dim unit = syntaxTree.GetCompilationUnitRoot()
If unit.Members.Count > 0 Then
Return True
End If
Next
Return False
End Function
#End Region
#Region "Common Members"
Protected Overrides Function CommonWithReferences(newReferences As IEnumerable(Of MetadataReference)) As Compilation
Return WithReferences(newReferences)
End Function
Protected Overrides Function CommonWithAssemblyName(assemblyName As String) As Compilation
Return WithAssemblyName(assemblyName)
End Function
Protected Overrides Function CommonWithScriptCompilationInfo(info As ScriptCompilationInfo) As Compilation
Return WithScriptCompilationInfo(DirectCast(info, VisualBasicScriptCompilationInfo))
End Function
Protected Overrides ReadOnly Property CommonAssembly As IAssemblySymbol
Get
Return Me.Assembly
End Get
End Property
Protected Overrides ReadOnly Property CommonGlobalNamespace As INamespaceSymbol
Get
Return Me.GlobalNamespace
End Get
End Property
Protected Overrides ReadOnly Property CommonOptions As CompilationOptions
Get
Return Options
End Get
End Property
Protected Overrides Function CommonGetSemanticModel(syntaxTree As SyntaxTree, ignoreAccessibility As Boolean) As SemanticModel
Return Me.GetSemanticModel(syntaxTree, ignoreAccessibility)
End Function
Protected Overrides ReadOnly Property CommonSyntaxTrees As ImmutableArray(Of SyntaxTree)
Get
Return Me.SyntaxTrees
End Get
End Property
Protected Overrides Function CommonAddSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As Compilation
Dim array = TryCast(trees, SyntaxTree())
If array IsNot Nothing Then
Return Me.AddSyntaxTrees(array)
End If
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
Return Me.AddSyntaxTrees(trees.Cast(Of SyntaxTree)())
End Function
Protected Overrides Function CommonRemoveSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As Compilation
Dim array = TryCast(trees, SyntaxTree())
If array IsNot Nothing Then
Return Me.RemoveSyntaxTrees(array)
End If
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
Return Me.RemoveSyntaxTrees(trees.Cast(Of SyntaxTree)())
End Function
Protected Overrides Function CommonRemoveAllSyntaxTrees() As Compilation
Return Me.RemoveAllSyntaxTrees()
End Function
Protected Overrides Function CommonReplaceSyntaxTree(oldTree As SyntaxTree, newTree As SyntaxTree) As Compilation
Return Me.ReplaceSyntaxTree(oldTree, newTree)
End Function
Protected Overrides Function CommonWithOptions(options As CompilationOptions) As Compilation
Return Me.WithOptions(DirectCast(options, VisualBasicCompilationOptions))
End Function
Protected Overrides Function CommonContainsSyntaxTree(syntaxTree As SyntaxTree) As Boolean
Return Me.ContainsSyntaxTree(syntaxTree)
End Function
Protected Overrides Function CommonGetAssemblyOrModuleSymbol(reference As MetadataReference) As ISymbol
Return Me.GetAssemblyOrModuleSymbol(reference)
End Function
Protected Overrides Function CommonClone() As Compilation
Return Me.Clone()
End Function
Protected Overrides ReadOnly Property CommonSourceModule As IModuleSymbol
Get
Return Me.SourceModule
End Get
End Property
Private Protected Overrides Function CommonGetSpecialType(specialType As SpecialType) As INamedTypeSymbolInternal
Return Me.GetSpecialType(specialType)
End Function
Protected Overrides Function CommonGetCompilationNamespace(namespaceSymbol As INamespaceSymbol) As INamespaceSymbol
Return Me.GetCompilationNamespace(namespaceSymbol)
End Function
Protected Overrides Function CommonGetTypeByMetadataName(metadataName As String) As INamedTypeSymbol
Return Me.GetTypeByMetadataName(metadataName)
End Function
Protected Overrides ReadOnly Property CommonScriptClass As INamedTypeSymbol
Get
Return Me.ScriptClass
End Get
End Property
Protected Overrides Function CommonCreateErrorTypeSymbol(container As INamespaceOrTypeSymbol, name As String, arity As Integer) As INamedTypeSymbol
Return New ExtendedErrorTypeSymbol(
container.EnsureVbSymbolOrNothing(Of NamespaceOrTypeSymbol)(NameOf(container)),
name, arity)
End Function
Protected Overrides Function CommonCreateErrorNamespaceSymbol(container As INamespaceSymbol, name As String) As INamespaceSymbol
Return New MissingNamespaceSymbol(
container.EnsureVbSymbolOrNothing(Of NamespaceSymbol)(NameOf(container)),
name)
End Function
Protected Overrides Function CommonCreateArrayTypeSymbol(elementType As ITypeSymbol, rank As Integer, elementNullableAnnotation As NullableAnnotation) As IArrayTypeSymbol
Return CreateArrayTypeSymbol(elementType.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(elementType)), rank)
End Function
Protected Overrides Function CommonCreateTupleTypeSymbol(elementTypes As ImmutableArray(Of ITypeSymbol),
elementNames As ImmutableArray(Of String),
elementLocations As ImmutableArray(Of Location),
elementNullableAnnotations As ImmutableArray(Of NullableAnnotation)) As INamedTypeSymbol
Dim typesBuilder = ArrayBuilder(Of TypeSymbol).GetInstance(elementTypes.Length)
For i As Integer = 0 To elementTypes.Length - 1
typesBuilder.Add(elementTypes(i).EnsureVbSymbolOrNothing(Of TypeSymbol)($"{NameOf(elementTypes)}[{i}]"))
Next
'no location for the type declaration
Return TupleTypeSymbol.Create(locationOpt:=Nothing,
elementTypes:=typesBuilder.ToImmutableAndFree(),
elementLocations:=elementLocations,
elementNames:=elementNames, compilation:=Me,
shouldCheckConstraints:=False, errorPositions:=Nothing)
End Function
Protected Overrides Function CommonCreateTupleTypeSymbol(
underlyingType As INamedTypeSymbol,
elementNames As ImmutableArray(Of String),
elementLocations As ImmutableArray(Of Location),
elementNullableAnnotations As ImmutableArray(Of NullableAnnotation)) As INamedTypeSymbol
Dim csharpUnderlyingTuple = underlyingType.EnsureVbSymbolOrNothing(Of NamedTypeSymbol)(NameOf(underlyingType))
Dim cardinality As Integer
If Not csharpUnderlyingTuple.IsTupleCompatible(cardinality) Then
Throw New ArgumentException(CodeAnalysisResources.TupleUnderlyingTypeMustBeTupleCompatible, NameOf(underlyingType))
End If
elementNames = CheckTupleElementNames(cardinality, elementNames)
CheckTupleElementLocations(cardinality, elementLocations)
CheckTupleElementNullableAnnotations(cardinality, elementNullableAnnotations)
Return TupleTypeSymbol.Create(
locationOpt:=Nothing,
tupleCompatibleType:=underlyingType.EnsureVbSymbolOrNothing(Of NamedTypeSymbol)(NameOf(underlyingType)),
elementLocations:=elementLocations,
elementNames:=elementNames,
errorPositions:=Nothing)
End Function
Protected Overrides Function CommonCreatePointerTypeSymbol(elementType As ITypeSymbol) As IPointerTypeSymbol
Throw New NotSupportedException(VBResources.ThereAreNoPointerTypesInVB)
End Function
Protected Overrides Function CommonCreateFunctionPointerTypeSymbol(
returnType As ITypeSymbol,
refKind As RefKind,
parameterTypes As ImmutableArray(Of ITypeSymbol),
parameterRefKinds As ImmutableArray(Of RefKind),
callingConvention As System.Reflection.Metadata.SignatureCallingConvention,
callingConventionTypes As ImmutableArray(Of INamedTypeSymbol)) As IFunctionPointerTypeSymbol
Throw New NotSupportedException(VBResources.ThereAreNoFunctionPointerTypesInVB)
End Function
Protected Overrides Function CommonCreateNativeIntegerTypeSymbol(signed As Boolean) As INamedTypeSymbol
Throw New NotSupportedException(VBResources.ThereAreNoNativeIntegerTypesInVB)
End Function
Protected Overrides Function CommonCreateAnonymousTypeSymbol(
memberTypes As ImmutableArray(Of ITypeSymbol),
memberNames As ImmutableArray(Of String),
memberLocations As ImmutableArray(Of Location),
memberIsReadOnly As ImmutableArray(Of Boolean),
memberNullableAnnotations As ImmutableArray(Of CodeAnalysis.NullableAnnotation)) As INamedTypeSymbol
Dim i = 0
For Each t In memberTypes
t.EnsureVbSymbolOrNothing(Of TypeSymbol)($"{NameOf(memberTypes)}({i})")
i = i + 1
Next
Dim fields = ArrayBuilder(Of AnonymousTypeField).GetInstance()
For i = 0 To memberTypes.Length - 1
Dim type = memberTypes(i)
Dim name = memberNames(i)
Dim loc = If(memberLocations.IsDefault, Location.None, memberLocations(i))
Dim isReadOnly = memberIsReadOnly.IsDefault OrElse memberIsReadOnly(i)
fields.Add(New AnonymousTypeField(name, DirectCast(type, TypeSymbol), loc, isReadOnly))
Next
Dim descriptor = New AnonymousTypeDescriptor(
fields.ToImmutableAndFree(), Location.None, isImplicitlyDeclared:=False)
Return Me.AnonymousTypeManager.ConstructAnonymousTypeSymbol(descriptor)
End Function
Protected Overrides ReadOnly Property CommonDynamicType As ITypeSymbol
Get
Throw New NotSupportedException(VBResources.ThereIsNoDynamicTypeInVB)
End Get
End Property
Protected Overrides ReadOnly Property CommonObjectType As INamedTypeSymbol
Get
Return Me.ObjectType
End Get
End Property
Protected Overrides Function CommonGetEntryPoint(cancellationToken As CancellationToken) As IMethodSymbol
Return Me.GetEntryPoint(cancellationToken)
End Function
''' <summary>
''' Return true if there is a source declaration symbol name that meets given predicate.
''' </summary>
Public Overrides Function ContainsSymbolsWithName(predicate As Func(Of String, Boolean), Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As Boolean
If predicate Is Nothing Then
Throw New ArgumentNullException(NameOf(predicate))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return DeclarationTable.ContainsName(MergedRootDeclaration, predicate, filter, cancellationToken)
End Function
''' <summary>
''' Return source declaration symbols whose name meets given predicate.
''' </summary>
Public Overrides Function GetSymbolsWithName(predicate As Func(Of String, Boolean), Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As IEnumerable(Of ISymbol)
If predicate Is Nothing Then
Throw New ArgumentNullException(NameOf(predicate))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return New PredicateSymbolSearcher(Me, filter, predicate, cancellationToken).GetSymbolsWithName()
End Function
#Disable Warning RS0026 ' Do not add multiple public overloads with optional parameters
''' <summary>
''' Return true if there is a source declaration symbol name that matches the provided name.
''' This may be faster than <see cref="ContainsSymbolsWithName(Func(Of String, Boolean),
''' SymbolFilter, CancellationToken)"/> when predicate is just a simple string check.
''' <paramref name="name"/> is case insensitive.
''' </summary>
Public Overrides Function ContainsSymbolsWithName(name As String, Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As Boolean
If name Is Nothing Then
Throw New ArgumentNullException(NameOf(name))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return DeclarationTable.ContainsName(MergedRootDeclaration, name, filter, cancellationToken)
End Function
Public Overrides Function GetSymbolsWithName(name As String, Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As IEnumerable(Of ISymbol)
If name Is Nothing Then
Throw New ArgumentNullException(NameOf(name))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return New NameSymbolSearcher(Me, filter, name, cancellationToken).GetSymbolsWithName()
End Function
#Enable Warning RS0026 ' Do not add multiple public overloads with optional parameters
Friend Overrides Function IsUnreferencedAssemblyIdentityDiagnosticCode(code As Integer) As Boolean
Select Case code
Case ERRID.ERR_UnreferencedAssemblyEvent3,
ERRID.ERR_UnreferencedAssembly3
Return True
Case Else
Return False
End Select
End Function
#End Region
Private MustInherit Class AbstractSymbolSearcher
Private ReadOnly _cache As PooledDictionary(Of Declaration, NamespaceOrTypeSymbol)
Private ReadOnly _compilation As VisualBasicCompilation
Private ReadOnly _includeNamespace As Boolean
Private ReadOnly _includeType As Boolean
Private ReadOnly _includeMember As Boolean
Private ReadOnly _cancellationToken As CancellationToken
Public Sub New(compilation As VisualBasicCompilation, filter As SymbolFilter, cancellationToken As CancellationToken)
_cache = PooledDictionary(Of Declaration, NamespaceOrTypeSymbol).GetInstance()
_compilation = compilation
_includeNamespace = (filter And SymbolFilter.Namespace) = SymbolFilter.Namespace
_includeType = (filter And SymbolFilter.Type) = SymbolFilter.Type
_includeMember = (filter And SymbolFilter.Member) = SymbolFilter.Member
_cancellationToken = cancellationToken
End Sub
Protected MustOverride Function Matches(name As String) As Boolean
Protected MustOverride Function ShouldCheckTypeForMembers(typeDeclaration As MergedTypeDeclaration) As Boolean
Public Function GetSymbolsWithName() As IEnumerable(Of ISymbol)
Dim result = New HashSet(Of ISymbol)()
Dim spine = ArrayBuilder(Of MergedNamespaceOrTypeDeclaration).GetInstance()
AppendSymbolsWithName(spine, _compilation.MergedRootDeclaration, result)
spine.Free()
_cache.Free()
Return result
End Function
Private Sub AppendSymbolsWithName(
spine As ArrayBuilder(Of MergedNamespaceOrTypeDeclaration), current As MergedNamespaceOrTypeDeclaration, [set] As HashSet(Of ISymbol))
If current.Kind = DeclarationKind.Namespace Then
If _includeNamespace AndAlso Matches(current.Name) Then
Dim container = GetSpineSymbol(spine)
Dim symbol = GetSymbol(container, current)
If symbol IsNot Nothing Then
[set].Add(symbol)
End If
End If
Else
If _includeType AndAlso Matches(current.Name) Then
Dim container = GetSpineSymbol(spine)
Dim symbol = GetSymbol(container, current)
If symbol IsNot Nothing Then
[set].Add(symbol)
End If
End If
If _includeMember Then
Dim typeDeclaration = DirectCast(current, MergedTypeDeclaration)
If ShouldCheckTypeForMembers(typeDeclaration) Then
AppendMemberSymbolsWithName(spine, typeDeclaration, [set])
End If
End If
End If
spine.Add(current)
For Each child In current.Children
Dim mergedNamespaceOrType = TryCast(child, MergedNamespaceOrTypeDeclaration)
If mergedNamespaceOrType IsNot Nothing Then
If _includeMember OrElse _includeType OrElse child.Kind = DeclarationKind.Namespace Then
AppendSymbolsWithName(spine, mergedNamespaceOrType, [set])
End If
End If
Next
spine.RemoveAt(spine.Count - 1)
End Sub
Private Sub AppendMemberSymbolsWithName(
spine As ArrayBuilder(Of MergedNamespaceOrTypeDeclaration), mergedType As MergedTypeDeclaration, [set] As HashSet(Of ISymbol))
_cancellationToken.ThrowIfCancellationRequested()
spine.Add(mergedType)
Dim container As NamespaceOrTypeSymbol = Nothing
For Each name In mergedType.MemberNames
If Matches(name) Then
container = If(container, GetSpineSymbol(spine))
If container IsNot Nothing Then
[set].UnionWith(container.GetMembers(name))
End If
End If
Next
spine.RemoveAt(spine.Count - 1)
End Sub
Private Function GetSpineSymbol(spine As ArrayBuilder(Of MergedNamespaceOrTypeDeclaration)) As NamespaceOrTypeSymbol
If spine.Count = 0 Then
Return Nothing
End If
Dim symbol = GetCachedSymbol(spine(spine.Count - 1))
If symbol IsNot Nothing Then
Return symbol
End If
Dim current = TryCast(Me._compilation.GlobalNamespace, NamespaceOrTypeSymbol)
For i = 1 To spine.Count - 1
current = GetSymbol(current, spine(i))
Next
Return current
End Function
Private Function GetCachedSymbol(declaration As MergedNamespaceOrTypeDeclaration) As NamespaceOrTypeSymbol
Dim symbol As NamespaceOrTypeSymbol = Nothing
If Me._cache.TryGetValue(declaration, symbol) Then
Return symbol
End If
Return Nothing
End Function
Private Function GetSymbol(container As NamespaceOrTypeSymbol, declaration As MergedNamespaceOrTypeDeclaration) As NamespaceOrTypeSymbol
If container Is Nothing Then
Return Me._compilation.GlobalNamespace
End If
Dim symbol = GetCachedSymbol(declaration)
If symbol IsNot Nothing Then
Return symbol
End If
If declaration.Kind = DeclarationKind.Namespace Then
AddCache(container.GetMembers(declaration.Name).OfType(Of NamespaceOrTypeSymbol)())
Else
AddCache(container.GetTypeMembers(declaration.Name))
End If
Return GetCachedSymbol(declaration)
End Function
Private Sub AddCache(symbols As IEnumerable(Of NamespaceOrTypeSymbol))
For Each symbol In symbols
Dim mergedNamespace = TryCast(symbol, MergedNamespaceSymbol)
If mergedNamespace IsNot Nothing Then
Me._cache(mergedNamespace.ConstituentNamespaces.OfType(Of SourceNamespaceSymbol).First().MergedDeclaration) = symbol
Continue For
End If
Dim sourceNamespace = TryCast(symbol, SourceNamespaceSymbol)
If sourceNamespace IsNot Nothing Then
Me._cache(sourceNamespace.MergedDeclaration) = sourceNamespace
Continue For
End If
Dim sourceType = TryCast(symbol, SourceMemberContainerTypeSymbol)
If sourceType IsNot Nothing Then
Me._cache(sourceType.TypeDeclaration) = sourceType
End If
Next
End Sub
End Class
Private Class PredicateSymbolSearcher
Inherits AbstractSymbolSearcher
Private ReadOnly _predicate As Func(Of String, Boolean)
Public Sub New(
compilation As VisualBasicCompilation, filter As SymbolFilter, predicate As Func(Of String, Boolean), cancellationToken As CancellationToken)
MyBase.New(compilation, filter, cancellationToken)
_predicate = predicate
End Sub
Protected Overrides Function ShouldCheckTypeForMembers(current As MergedTypeDeclaration) As Boolean
Return True
End Function
Protected Overrides Function Matches(name As String) As Boolean
Return _predicate(name)
End Function
End Class
Private Class NameSymbolSearcher
Inherits AbstractSymbolSearcher
Private ReadOnly _name As String
Public Sub New(
compilation As VisualBasicCompilation, filter As SymbolFilter, name As String, cancellationToken As CancellationToken)
MyBase.New(compilation, filter, cancellationToken)
_name = name
End Sub
Protected Overrides Function ShouldCheckTypeForMembers(current As MergedTypeDeclaration) As Boolean
For Each typeDecl In current.Declarations
If typeDecl.MemberNames.Contains(_name) Then
Return True
End If
Next
Return False
End Function
Protected Overrides Function Matches(name As String) As Boolean
Return IdentifierComparison.Equals(_name, name)
End Function
End Class
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Concurrent
Imports System.Collections.Immutable
Imports System.IO
Imports System.Reflection.Metadata
Imports System.Runtime.InteropServices
Imports System.Threading
Imports System.Threading.Tasks
Imports Microsoft.Cci
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.CodeGen
Imports Microsoft.CodeAnalysis.Diagnostics
Imports Microsoft.CodeAnalysis.Emit
Imports Microsoft.CodeAnalysis.InternalUtilities
Imports Microsoft.CodeAnalysis.Operations
Imports Microsoft.CodeAnalysis.PooledObjects
Imports Microsoft.CodeAnalysis.Symbols
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Emit
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic
''' <summary>
''' The Compilation object is an immutable representation of a single invocation of the
''' compiler. Although immutable, a Compilation is also on-demand, in that a compilation can be
''' created quickly, but will that compiler parts or all of the code in order to respond to
''' method or properties. Also, a compilation can produce a new compilation with a small change
''' from the current compilation. This is, in many cases, more efficient than creating a new
''' compilation from scratch, as the new compilation can share information from the old
''' compilation.
''' </summary>
Public NotInheritable Class VisualBasicCompilation
Inherits Compilation
' !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
'
' Changes to the public interface of this class should remain synchronized with the C#
' version. Do not make any changes to the public interface without making the corresponding
' change to the C# version.
'
' !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
''' <summary>
''' most of time all compilation would use same MyTemplate. no reason to create (reparse) one for each compilation
''' as long as its parse option is same
''' </summary>
Private Shared ReadOnly s_myTemplateCache As ConcurrentLruCache(Of VisualBasicParseOptions, SyntaxTree) =
New ConcurrentLruCache(Of VisualBasicParseOptions, SyntaxTree)(capacity:=5)
''' <summary>
''' The SourceAssemblySymbol for this compilation. Do not access directly, use Assembly
''' property instead. This field is lazily initialized by ReferenceManager,
''' ReferenceManager.CacheLockObject must be locked while ReferenceManager "calculates" the
''' value and assigns it, several threads must not perform duplicate "calculation"
''' simultaneously.
''' </summary>
Private _lazyAssemblySymbol As SourceAssemblySymbol
''' <summary>
''' Holds onto data related to reference binding.
''' The manager is shared among multiple compilations that we expect to have the same result of reference binding.
''' In most cases this can be determined without performing the binding. If the compilation however contains a circular
''' metadata reference (a metadata reference that refers back to the compilation) we need to avoid sharing of the binding results.
''' We do so by creating a new reference manager for such compilation.
''' </summary>
Private _referenceManager As ReferenceManager
''' <summary>
''' The options passed to the constructor of the Compilation
''' </summary>
Private ReadOnly _options As VisualBasicCompilationOptions
''' <summary>
''' The global namespace symbol. Lazily populated on first access.
''' </summary>
Private _lazyGlobalNamespace As NamespaceSymbol
''' <summary>
''' The syntax trees explicitly given to the compilation at creation, in ordinal order.
''' </summary>
Private ReadOnly _syntaxTrees As ImmutableArray(Of SyntaxTree)
Private ReadOnly _syntaxTreeOrdinalMap As ImmutableDictionary(Of SyntaxTree, Integer)
''' <summary>
''' The syntax trees of this compilation plus all 'hidden' trees
''' added to the compilation by compiler, e.g. Vb Core Runtime.
''' </summary>
Private _lazyAllSyntaxTrees As ImmutableArray(Of SyntaxTree)
''' <summary>
''' A map between syntax trees and the root declarations in the declaration table.
''' Incrementally updated between compilation versions when source changes are made.
''' </summary>
Private ReadOnly _rootNamespaces As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry)
''' <summary>
''' Imports appearing in <see cref="SyntaxTree"/>s in this compilation.
''' </summary>
''' <remarks>
''' Unlike in C#, we don't need to use a set because the <see cref="SourceFile"/> objects
''' that record the imports are persisted.
''' </remarks>
Private _lazyImportInfos As ConcurrentQueue(Of ImportInfo)
Private _lazyImportClauseDependencies As ConcurrentDictionary(Of (SyntaxTree As SyntaxTree, ImportsClausePosition As Integer), ImmutableArray(Of AssemblySymbol))
''' <summary>
''' Cache the CLS diagnostics for the whole compilation so they aren't computed repeatedly.
''' </summary>
''' <remarks>
''' NOTE: Presently, we do not cache the per-tree diagnostics.
''' </remarks>
Private _lazyClsComplianceDiagnostics As ImmutableArray(Of Diagnostic)
Private _lazyClsComplianceDependencies As ImmutableArray(Of AssemblySymbol)
''' <summary>
''' A SyntaxTree and the associated RootSingleNamespaceDeclaration for an embedded
''' syntax tree in the Compilation. Unlike the entries in m_rootNamespaces, the
''' SyntaxTree here is lazy since the tree cannot be evaluated until the references
''' have been resolved (as part of binding the source module), and at that point, the
''' SyntaxTree may be Nothing if the embedded tree is not needed for the Compilation.
''' </summary>
Private Structure EmbeddedTreeAndDeclaration
Public ReadOnly Tree As Lazy(Of SyntaxTree)
Public ReadOnly DeclarationEntry As DeclarationTableEntry
Public Sub New(treeOpt As Func(Of SyntaxTree), rootNamespaceOpt As Func(Of RootSingleNamespaceDeclaration))
Me.Tree = New Lazy(Of SyntaxTree)(treeOpt)
Me.DeclarationEntry = New DeclarationTableEntry(New Lazy(Of RootSingleNamespaceDeclaration)(rootNamespaceOpt), isEmbedded:=True)
End Sub
End Structure
Private ReadOnly _embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration)
''' <summary>
''' The declaration table that holds onto declarations from source. Incrementally updated
''' between compilation versions when source changes are made.
''' </summary>
''' <remarks></remarks>
Private ReadOnly _declarationTable As DeclarationTable
''' <summary>
''' Manages anonymous types declared in this compilation. Unifies types that are structurally equivalent.
''' </summary>
Private ReadOnly _anonymousTypeManager As AnonymousTypeManager
''' <summary>
''' Manages automatically embedded content.
''' </summary>
Private _lazyEmbeddedSymbolManager As EmbeddedSymbolManager
''' <summary>
''' MyTemplate automatically embedded from resource in the compiler.
''' It doesn't feel like it should be managed by EmbeddedSymbolManager
''' because MyTemplate is treated as user code, i.e. can be extended via
''' partial declarations, doesn't require "on-demand" metadata generation, etc.
'''
''' SyntaxTree.Dummy means uninitialized.
''' </summary>
Private _lazyMyTemplate As SyntaxTree = VisualBasicSyntaxTree.Dummy
Private ReadOnly _scriptClass As Lazy(Of ImplicitNamedTypeSymbol)
''' <summary>
''' Contains the main method of this assembly, if there is one.
''' </summary>
Private _lazyEntryPoint As EntryPoint
''' <summary>
''' The set of trees for which a <see cref="CompilationUnitCompletedEvent"/> has been added to the queue.
''' </summary>
Private _lazyCompilationUnitCompletedTrees As HashSet(Of SyntaxTree)
''' <summary>
''' The common language version among the trees of the compilation.
''' </summary>
Private ReadOnly _languageVersion As LanguageVersion
Public Overrides ReadOnly Property Language As String
Get
Return LanguageNames.VisualBasic
End Get
End Property
Public Overrides ReadOnly Property IsCaseSensitive As Boolean
Get
Return False
End Get
End Property
Friend ReadOnly Property Declarations As DeclarationTable
Get
Return _declarationTable
End Get
End Property
Friend ReadOnly Property MergedRootDeclaration As MergedNamespaceDeclaration
Get
Return Declarations.GetMergedRoot(Me)
End Get
End Property
Public Shadows ReadOnly Property Options As VisualBasicCompilationOptions
Get
Return _options
End Get
End Property
''' <summary>
''' The language version that was used to parse the syntax trees of this compilation.
''' </summary>
Public ReadOnly Property LanguageVersion As LanguageVersion
Get
Return _languageVersion
End Get
End Property
Friend ReadOnly Property AnonymousTypeManager As AnonymousTypeManager
Get
Return Me._anonymousTypeManager
End Get
End Property
Friend Overrides ReadOnly Property CommonAnonymousTypeManager As CommonAnonymousTypeManager
Get
Return Me._anonymousTypeManager
End Get
End Property
''' <summary>
''' SyntaxTree of MyTemplate for the compilation. Settable for testing purposes only.
''' </summary>
Friend Property MyTemplate As SyntaxTree
Get
If _lazyMyTemplate Is VisualBasicSyntaxTree.Dummy Then
Dim compilationOptions = Me.Options
If compilationOptions.EmbedVbCoreRuntime OrElse compilationOptions.SuppressEmbeddedDeclarations Then
_lazyMyTemplate = Nothing
Else
' first see whether we can use one from global cache
Dim parseOptions = If(compilationOptions.ParseOptions, VisualBasicParseOptions.Default)
Dim tree As SyntaxTree = Nothing
If s_myTemplateCache.TryGetValue(parseOptions, tree) Then
Debug.Assert(tree IsNot Nothing)
Debug.Assert(tree IsNot VisualBasicSyntaxTree.Dummy)
Debug.Assert(tree.IsMyTemplate)
Interlocked.CompareExchange(_lazyMyTemplate, tree, VisualBasicSyntaxTree.Dummy)
Else
' we need to make one.
Dim text As String = EmbeddedResources.VbMyTemplateText
' The My template regularly makes use of more recent language features. Care is
' taken to ensure these are compatible with 2.0 runtimes so there is no danger
' with allowing the newer syntax here.
Dim options = parseOptions.WithLanguageVersion(LanguageVersion.Default)
tree = VisualBasicSyntaxTree.ParseText(text, options:=options, isMyTemplate:=True)
If tree.GetDiagnostics().Any() Then
Throw ExceptionUtilities.Unreachable
End If
If Interlocked.CompareExchange(_lazyMyTemplate, tree, VisualBasicSyntaxTree.Dummy) Is VisualBasicSyntaxTree.Dummy Then
' set global cache
s_myTemplateCache(parseOptions) = tree
End If
End If
End If
Debug.Assert(_lazyMyTemplate Is Nothing OrElse _lazyMyTemplate.IsMyTemplate)
End If
Return _lazyMyTemplate
End Get
Set(value As SyntaxTree)
Debug.Assert(_lazyMyTemplate Is VisualBasicSyntaxTree.Dummy)
Debug.Assert(value IsNot VisualBasicSyntaxTree.Dummy)
Debug.Assert(value Is Nothing OrElse value.IsMyTemplate)
If value?.GetDiagnostics().Any() Then
Throw ExceptionUtilities.Unreachable
End If
_lazyMyTemplate = value
End Set
End Property
Friend ReadOnly Property EmbeddedSymbolManager As EmbeddedSymbolManager
Get
If _lazyEmbeddedSymbolManager Is Nothing Then
Dim embedded = If(Options.EmbedVbCoreRuntime, EmbeddedSymbolKind.VbCore, EmbeddedSymbolKind.None) Or
If(IncludeInternalXmlHelper(), EmbeddedSymbolKind.XmlHelper, EmbeddedSymbolKind.None)
If embedded <> EmbeddedSymbolKind.None Then
embedded = embedded Or EmbeddedSymbolKind.EmbeddedAttribute
End If
Interlocked.CompareExchange(_lazyEmbeddedSymbolManager, New EmbeddedSymbolManager(embedded), Nothing)
End If
Return _lazyEmbeddedSymbolManager
End Get
End Property
#Region "Constructors and Factories"
''' <summary>
''' Create a new compilation from scratch.
''' </summary>
''' <param name="assemblyName">Simple assembly name.</param>
''' <param name="syntaxTrees">The syntax trees with the source code for the new compilation.</param>
''' <param name="references">The references for the new compilation.</param>
''' <param name="options">The compiler options to use.</param>
''' <returns>A new compilation.</returns>
Public Shared Function Create(
assemblyName As String,
Optional syntaxTrees As IEnumerable(Of SyntaxTree) = Nothing,
Optional references As IEnumerable(Of MetadataReference) = Nothing,
Optional options As VisualBasicCompilationOptions = Nothing
) As VisualBasicCompilation
Return Create(assemblyName,
options,
If(syntaxTrees IsNot Nothing, syntaxTrees.Cast(Of SyntaxTree), Nothing),
references,
previousSubmission:=Nothing,
returnType:=Nothing,
hostObjectType:=Nothing,
isSubmission:=False)
End Function
''' <summary>
''' Creates a new compilation that can be used in scripting.
''' </summary>
Friend Shared Function CreateScriptCompilation(
assemblyName As String,
Optional syntaxTree As SyntaxTree = Nothing,
Optional references As IEnumerable(Of MetadataReference) = Nothing,
Optional options As VisualBasicCompilationOptions = Nothing,
Optional previousScriptCompilation As VisualBasicCompilation = Nothing,
Optional returnType As Type = Nothing,
Optional globalsType As Type = Nothing) As VisualBasicCompilation
CheckSubmissionOptions(options)
ValidateScriptCompilationParameters(previousScriptCompilation, returnType, globalsType)
Return Create(
assemblyName,
If(options, New VisualBasicCompilationOptions(OutputKind.DynamicallyLinkedLibrary)).WithReferencesSupersedeLowerVersions(True),
If((syntaxTree IsNot Nothing), {syntaxTree}, SpecializedCollections.EmptyEnumerable(Of SyntaxTree)()),
references,
previousScriptCompilation,
returnType,
globalsType,
isSubmission:=True)
End Function
Private Shared Function Create(
assemblyName As String,
options As VisualBasicCompilationOptions,
syntaxTrees As IEnumerable(Of SyntaxTree),
references As IEnumerable(Of MetadataReference),
previousSubmission As VisualBasicCompilation,
returnType As Type,
hostObjectType As Type,
isSubmission As Boolean
) As VisualBasicCompilation
Debug.Assert(Not isSubmission OrElse options.ReferencesSupersedeLowerVersions)
If options Is Nothing Then
options = New VisualBasicCompilationOptions(OutputKind.ConsoleApplication)
End If
Dim validatedReferences = ValidateReferences(Of VisualBasicCompilationReference)(references)
Dim c As VisualBasicCompilation = Nothing
Dim embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
Dim declMap = ImmutableDictionary.Create(Of SyntaxTree, DeclarationTableEntry)()
Dim declTable = AddEmbeddedTrees(DeclarationTable.Empty, embeddedTrees)
c = New VisualBasicCompilation(
assemblyName,
options,
validatedReferences,
ImmutableArray(Of SyntaxTree).Empty,
ImmutableDictionary.Create(Of SyntaxTree, Integer)(),
declMap,
embeddedTrees,
declTable,
previousSubmission,
returnType,
hostObjectType,
isSubmission,
referenceManager:=Nothing,
reuseReferenceManager:=False,
eventQueue:=Nothing,
semanticModelProvider:=Nothing)
If syntaxTrees IsNot Nothing Then
c = c.AddSyntaxTrees(syntaxTrees)
End If
Debug.Assert(c._lazyAssemblySymbol Is Nothing)
Return c
End Function
Private Sub New(
assemblyName As String,
options As VisualBasicCompilationOptions,
references As ImmutableArray(Of MetadataReference),
syntaxTrees As ImmutableArray(Of SyntaxTree),
syntaxTreeOrdinalMap As ImmutableDictionary(Of SyntaxTree, Integer),
rootNamespaces As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration),
declarationTable As DeclarationTable,
previousSubmission As VisualBasicCompilation,
submissionReturnType As Type,
hostObjectType As Type,
isSubmission As Boolean,
referenceManager As ReferenceManager,
reuseReferenceManager As Boolean,
semanticModelProvider As SemanticModelProvider,
Optional eventQueue As AsyncQueue(Of CompilationEvent) = Nothing
)
MyBase.New(assemblyName, references, SyntaxTreeCommonFeatures(syntaxTrees), isSubmission, semanticModelProvider, eventQueue)
Debug.Assert(rootNamespaces IsNot Nothing)
Debug.Assert(declarationTable IsNot Nothing)
Debug.Assert(syntaxTrees.All(Function(tree) syntaxTrees(syntaxTreeOrdinalMap(tree)) Is tree))
Debug.Assert(syntaxTrees.SetEquals(rootNamespaces.Keys.AsImmutable(), EqualityComparer(Of SyntaxTree).Default))
Debug.Assert(embeddedTrees.All(Function(treeAndDeclaration) declarationTable.Contains(treeAndDeclaration.DeclarationEntry)))
_options = options
_syntaxTrees = syntaxTrees
_syntaxTreeOrdinalMap = syntaxTreeOrdinalMap
_rootNamespaces = rootNamespaces
_embeddedTrees = embeddedTrees
_declarationTable = declarationTable
_anonymousTypeManager = New AnonymousTypeManager(Me)
_languageVersion = CommonLanguageVersion(syntaxTrees)
_scriptClass = New Lazy(Of ImplicitNamedTypeSymbol)(AddressOf BindScriptClass)
If isSubmission Then
Debug.Assert(previousSubmission Is Nothing OrElse previousSubmission.HostObjectType Is hostObjectType)
Me.ScriptCompilationInfo = New VisualBasicScriptCompilationInfo(previousSubmission, submissionReturnType, hostObjectType)
Else
Debug.Assert(previousSubmission Is Nothing AndAlso submissionReturnType Is Nothing AndAlso hostObjectType Is Nothing)
End If
If reuseReferenceManager Then
referenceManager.AssertCanReuseForCompilation(Me)
_referenceManager = referenceManager
Else
_referenceManager = New ReferenceManager(MakeSourceAssemblySimpleName(),
options.AssemblyIdentityComparer,
If(referenceManager IsNot Nothing, referenceManager.ObservedMetadata, Nothing))
End If
Debug.Assert(_lazyAssemblySymbol Is Nothing)
If Me.EventQueue IsNot Nothing Then
Me.EventQueue.TryEnqueue(New CompilationStartedEvent(Me))
End If
End Sub
Friend Overrides Sub ValidateDebugEntryPoint(debugEntryPoint As IMethodSymbol, diagnostics As DiagnosticBag)
Debug.Assert(debugEntryPoint IsNot Nothing)
' Debug entry point has to be a method definition from this compilation.
Dim methodSymbol = TryCast(debugEntryPoint, MethodSymbol)
If methodSymbol?.DeclaringCompilation IsNot Me OrElse Not methodSymbol.IsDefinition Then
diagnostics.Add(ERRID.ERR_DebugEntryPointNotSourceMethodDefinition, Location.None)
End If
End Sub
Private Function CommonLanguageVersion(syntaxTrees As ImmutableArray(Of SyntaxTree)) As LanguageVersion
' We don't check m_Options.ParseOptions.LanguageVersion for consistency, because
' it isn't consistent in practice. In fact sometimes m_Options.ParseOptions is Nothing.
Dim result As LanguageVersion? = Nothing
For Each tree In syntaxTrees
Dim version = CType(tree.Options, VisualBasicParseOptions).LanguageVersion
If result Is Nothing Then
result = version
ElseIf result <> version Then
Throw New ArgumentException(CodeAnalysisResources.InconsistentLanguageVersions, NameOf(syntaxTrees))
End If
Next
Return If(result, LanguageVersion.Default.MapSpecifiedToEffectiveVersion)
End Function
''' <summary>
''' Create a duplicate of this compilation with different symbol instances
''' </summary>
Public Shadows Function Clone() As VisualBasicCompilation
Return New VisualBasicCompilation(
Me.AssemblyName,
_options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=True,
Me.SemanticModelProvider,
eventQueue:=Nothing) ' no event queue when cloning
End Function
Private Function UpdateSyntaxTrees(
syntaxTrees As ImmutableArray(Of SyntaxTree),
syntaxTreeOrdinalMap As ImmutableDictionary(Of SyntaxTree, Integer),
rootNamespaces As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
declarationTable As DeclarationTable,
referenceDirectivesChanged As Boolean) As VisualBasicCompilation
Return New VisualBasicCompilation(
Me.AssemblyName,
_options,
Me.ExternalReferences,
syntaxTrees,
syntaxTreeOrdinalMap,
rootNamespaces,
_embeddedTrees,
declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=Not referenceDirectivesChanged,
Me.SemanticModelProvider)
End Function
''' <summary>
''' Creates a new compilation with the specified name.
''' </summary>
Public Shadows Function WithAssemblyName(assemblyName As String) As VisualBasicCompilation
' Can't reuse references since the source assembly name changed and the referenced symbols might
' have internals-visible-to relationship with this compilation or they might had a circular reference
' to this compilation.
Return New VisualBasicCompilation(
assemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=String.Equals(assemblyName, Me.AssemblyName, StringComparison.Ordinal),
Me.SemanticModelProvider)
End Function
Public Shadows Function WithReferences(ParamArray newReferences As MetadataReference()) As VisualBasicCompilation
Return WithReferences(DirectCast(newReferences, IEnumerable(Of MetadataReference)))
End Function
''' <summary>
''' Creates a new compilation with the specified references.
''' </summary>
''' <remarks>
''' The new <see cref="VisualBasicCompilation"/> will query the given <see cref="MetadataReference"/> for the underlying
''' metadata as soon as the are needed.
'''
''' The New compilation uses whatever metadata is currently being provided by the <see cref="MetadataReference"/>.
''' E.g. if the current compilation references a metadata file that has changed since the creation of the compilation
''' the New compilation is going to use the updated version, while the current compilation will be using the previous (it doesn't change).
''' </remarks>
Public Shadows Function WithReferences(newReferences As IEnumerable(Of MetadataReference)) As VisualBasicCompilation
Dim declTable = RemoveEmbeddedTrees(_declarationTable, _embeddedTrees)
Dim c As VisualBasicCompilation = Nothing
Dim embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
declTable = AddEmbeddedTrees(declTable, embeddedTrees)
' References might have changed, don't reuse reference manager.
' Don't even reuse observed metadata - let the manager query for the metadata again.
c = New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
ValidateReferences(Of VisualBasicCompilationReference)(newReferences),
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
embeddedTrees,
declTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
referenceManager:=Nothing,
reuseReferenceManager:=False,
Me.SemanticModelProvider)
Return c
End Function
Public Shadows Function WithOptions(newOptions As VisualBasicCompilationOptions) As VisualBasicCompilation
If newOptions Is Nothing Then
Throw New ArgumentNullException(NameOf(newOptions))
End If
Dim c As VisualBasicCompilation = Nothing
Dim embeddedTrees = _embeddedTrees
Dim declTable = _declarationTable
Dim declMap = Me._rootNamespaces
If Not String.Equals(Me.Options.RootNamespace, newOptions.RootNamespace, StringComparison.Ordinal) Then
' If the root namespace was updated we have to update declaration table
' entries for all the syntax trees of the compilation
'
' NOTE: we use case-sensitive comparison so that the new compilation
' gets a root namespace with correct casing
declMap = ImmutableDictionary.Create(Of SyntaxTree, DeclarationTableEntry)()
declTable = DeclarationTable.Empty
embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
declTable = AddEmbeddedTrees(declTable, embeddedTrees)
Dim discardedReferenceDirectivesChanged As Boolean = False
For Each tree In _syntaxTrees
AddSyntaxTreeToDeclarationMapAndTable(tree, newOptions, Me.IsSubmission, declMap, declTable, discardedReferenceDirectivesChanged) ' declMap and declTable passed ByRef
Next
ElseIf Me.Options.EmbedVbCoreRuntime <> newOptions.EmbedVbCoreRuntime OrElse Me.Options.ParseOptions <> newOptions.ParseOptions Then
declTable = RemoveEmbeddedTrees(declTable, _embeddedTrees)
embeddedTrees = CreateEmbeddedTrees(New Lazy(Of VisualBasicCompilation)(Function() c))
declTable = AddEmbeddedTrees(declTable, embeddedTrees)
End If
c = New VisualBasicCompilation(
Me.AssemblyName,
newOptions,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
declMap,
embeddedTrees,
declTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=_options.CanReuseCompilationReferenceManager(newOptions),
Me.SemanticModelProvider)
Return c
End Function
''' <summary>
''' Returns a new compilation with the given compilation set as the previous submission.
''' </summary>
Friend Shadows Function WithScriptCompilationInfo(info As VisualBasicScriptCompilationInfo) As VisualBasicCompilation
If info Is ScriptCompilationInfo Then
Return Me
End If
' Metadata references are inherited from the previous submission,
' so we can only reuse the manager if we can guarantee that these references are the same.
' Check if the previous script compilation doesn't change.
' TODO Consider comparing the metadata references if they have been bound already.
' https://github.com/dotnet/roslyn/issues/43397
Dim reuseReferenceManager = ScriptCompilationInfo?.PreviousScriptCompilation Is info?.PreviousScriptCompilation
Return New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
info?.PreviousScriptCompilation,
info?.ReturnTypeOpt,
info?.GlobalsType,
info IsNot Nothing,
_referenceManager,
reuseReferenceManager,
Me.SemanticModelProvider)
End Function
''' <summary>
''' Returns a new compilation with the given semantic model provider.
''' </summary>
Friend Overrides Function WithSemanticModelProvider(semanticModelProvider As SemanticModelProvider) As Compilation
If Me.SemanticModelProvider Is semanticModelProvider Then
Return Me
End If
Return New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=True,
semanticModelProvider)
End Function
''' <summary>
''' Returns a new compilation with a given event queue.
''' </summary>
Friend Overrides Function WithEventQueue(eventQueue As AsyncQueue(Of CompilationEvent)) As Compilation
Return New VisualBasicCompilation(
Me.AssemblyName,
Me.Options,
Me.ExternalReferences,
_syntaxTrees,
_syntaxTreeOrdinalMap,
_rootNamespaces,
_embeddedTrees,
_declarationTable,
Me.PreviousSubmission,
Me.SubmissionReturnType,
Me.HostObjectType,
Me.IsSubmission,
_referenceManager,
reuseReferenceManager:=True,
Me.SemanticModelProvider,
eventQueue:=eventQueue)
End Function
Friend Overrides Sub SerializePdbEmbeddedCompilationOptions(builder As BlobBuilder)
' LanguageVersion should already be mapped to an effective version at this point
Debug.Assert(LanguageVersion.MapSpecifiedToEffectiveVersion() = LanguageVersion)
WriteValue(builder, CompilationOptionNames.LanguageVersion, LanguageVersion.ToDisplayString())
WriteValue(builder, CompilationOptionNames.Checked, Options.CheckOverflow.ToString())
WriteValue(builder, CompilationOptionNames.OptionStrict, Options.OptionStrict.ToString())
WriteValue(builder, CompilationOptionNames.OptionInfer, Options.OptionInfer.ToString())
WriteValue(builder, CompilationOptionNames.OptionCompareText, Options.OptionCompareText.ToString())
WriteValue(builder, CompilationOptionNames.OptionExplicit, Options.OptionExplicit.ToString())
WriteValue(builder, CompilationOptionNames.EmbedRuntime, Options.EmbedVbCoreRuntime.ToString())
If Options.GlobalImports.Length > 0 Then
WriteValue(builder, CompilationOptionNames.GlobalNamespaces, String.Join(";", Options.GlobalImports.Select(Function(x) x.Name)))
End If
If Not String.IsNullOrEmpty(Options.RootNamespace) Then
WriteValue(builder, CompilationOptionNames.RootNamespace, Options.RootNamespace)
End If
If Options.ParseOptions IsNot Nothing Then
Dim preprocessorStrings = Options.ParseOptions.PreprocessorSymbols.Select(
Function(p) As String
If TypeOf p.Value Is String Then
Return p.Key + "=""" + p.Value.ToString() + """"
ElseIf p.Value Is Nothing Then
Return p.Key
Else
Return p.Key + "=" + p.Value.ToString()
End If
End Function)
WriteValue(builder, CompilationOptionNames.Define, String.Join(",", preprocessorStrings))
End If
End Sub
Private Sub WriteValue(builder As BlobBuilder, key As String, value As String)
builder.WriteUTF8(key)
builder.WriteByte(0)
builder.WriteUTF8(value)
builder.WriteByte(0)
End Sub
#End Region
#Region "Submission"
Friend Shadows ReadOnly Property ScriptCompilationInfo As VisualBasicScriptCompilationInfo
Friend Overrides ReadOnly Property CommonScriptCompilationInfo As ScriptCompilationInfo
Get
Return ScriptCompilationInfo
End Get
End Property
Friend Shadows ReadOnly Property PreviousSubmission As VisualBasicCompilation
Get
Return ScriptCompilationInfo?.PreviousScriptCompilation
End Get
End Property
Friend Overrides Function HasSubmissionResult() As Boolean
Debug.Assert(IsSubmission)
' submission can be empty or comprise of a script file
Dim tree = SyntaxTrees.SingleOrDefault()
If tree Is Nothing Then
Return False
End If
Dim root = tree.GetCompilationUnitRoot()
If root.HasErrors Then
Return False
End If
' TODO: look for return statements
' https://github.com/dotnet/roslyn/issues/5773
Dim lastStatement = root.Members.LastOrDefault()
If lastStatement Is Nothing Then
Return False
End If
Dim model = GetSemanticModel(tree)
Select Case lastStatement.Kind
Case SyntaxKind.PrintStatement
Dim expression = DirectCast(lastStatement, PrintStatementSyntax).Expression
Dim info = model.GetTypeInfo(expression)
' always true, even for info.Type = Void
Return True
Case SyntaxKind.ExpressionStatement
Dim expression = DirectCast(lastStatement, ExpressionStatementSyntax).Expression
Dim info = model.GetTypeInfo(expression)
Return info.Type.SpecialType <> SpecialType.System_Void
Case SyntaxKind.CallStatement
Dim expression = DirectCast(lastStatement, CallStatementSyntax).Invocation
Dim info = model.GetTypeInfo(expression)
Return info.Type.SpecialType <> SpecialType.System_Void
Case Else
Return False
End Select
End Function
Friend Function GetSubmissionInitializer() As SynthesizedInteractiveInitializerMethod
Return If(IsSubmission AndAlso ScriptClass IsNot Nothing,
ScriptClass.GetScriptInitializer(),
Nothing)
End Function
Protected Overrides ReadOnly Property CommonScriptGlobalsType As ITypeSymbol
Get
Return Nothing
End Get
End Property
#End Region
#Region "Syntax Trees"
''' <summary>
''' Get a read-only list of the syntax trees that this compilation was created with.
''' </summary>
Public Shadows ReadOnly Property SyntaxTrees As ImmutableArray(Of SyntaxTree)
Get
Return _syntaxTrees
End Get
End Property
''' <summary>
''' Get a read-only list of the syntax trees that this compilation was created with PLUS
''' the trees that were automatically added to it, i.e. Vb Core Runtime tree.
''' </summary>
Friend Shadows ReadOnly Property AllSyntaxTrees As ImmutableArray(Of SyntaxTree)
Get
If _lazyAllSyntaxTrees.IsDefault Then
Dim builder = ArrayBuilder(Of SyntaxTree).GetInstance()
builder.AddRange(_syntaxTrees)
For Each embeddedTree In _embeddedTrees
Dim tree = embeddedTree.Tree.Value
If tree IsNot Nothing Then
builder.Add(tree)
End If
Next
ImmutableInterlocked.InterlockedInitialize(_lazyAllSyntaxTrees, builder.ToImmutableAndFree())
End If
Return _lazyAllSyntaxTrees
End Get
End Property
''' <summary>
''' Is the passed in syntax tree in this compilation?
''' </summary>
Public Shadows Function ContainsSyntaxTree(syntaxTree As SyntaxTree) As Boolean
Return syntaxTree IsNot Nothing AndAlso _rootNamespaces.ContainsKey(syntaxTree)
End Function
Public Shadows Function AddSyntaxTrees(ParamArray trees As SyntaxTree()) As VisualBasicCompilation
Return AddSyntaxTrees(DirectCast(trees, IEnumerable(Of SyntaxTree)))
End Function
Public Shadows Function AddSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As VisualBasicCompilation
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
If Not trees.Any() Then
Return Me
End If
' We're using a try-finally for this builder because there's a test that
' specifically checks for one or more of the argument exceptions below
' and we don't want to see console spew (even though we don't generally
' care about pool "leaks" in exceptional cases). Alternatively, we
' could create a new ArrayBuilder.
Dim builder = ArrayBuilder(Of SyntaxTree).GetInstance()
Try
builder.AddRange(_syntaxTrees)
Dim referenceDirectivesChanged = False
Dim oldTreeCount = _syntaxTrees.Length
Dim ordinalMap = _syntaxTreeOrdinalMap
Dim declMap = _rootNamespaces
Dim declTable = _declarationTable
Dim i = 0
For Each tree As SyntaxTree In trees
If tree Is Nothing Then
Throw New ArgumentNullException(String.Format(VBResources.Trees0, i))
End If
If Not tree.HasCompilationUnitRoot Then
Throw New ArgumentException(String.Format(VBResources.TreesMustHaveRootNode, i))
End If
If tree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotAddCompilerSpecialTree)
End If
If declMap.ContainsKey(tree) Then
Throw New ArgumentException(VBResources.SyntaxTreeAlreadyPresent, String.Format(VBResources.Trees0, i))
End If
AddSyntaxTreeToDeclarationMapAndTable(tree, _options, Me.IsSubmission, declMap, declTable, referenceDirectivesChanged) ' declMap and declTable passed ByRef
builder.Add(tree)
ordinalMap = ordinalMap.Add(tree, oldTreeCount + i)
i += 1
Next
If IsSubmission AndAlso declMap.Count > 1 Then
Throw New ArgumentException(VBResources.SubmissionCanHaveAtMostOneSyntaxTree, NameOf(trees))
End If
Return UpdateSyntaxTrees(builder.ToImmutable(), ordinalMap, declMap, declTable, referenceDirectivesChanged)
Finally
builder.Free()
End Try
End Function
Private Shared Sub AddSyntaxTreeToDeclarationMapAndTable(
tree As SyntaxTree,
compilationOptions As VisualBasicCompilationOptions,
isSubmission As Boolean,
ByRef declMap As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
ByRef declTable As DeclarationTable,
ByRef referenceDirectivesChanged As Boolean
)
Dim entry = New DeclarationTableEntry(New Lazy(Of RootSingleNamespaceDeclaration)(Function() ForTree(tree, compilationOptions, isSubmission)), isEmbedded:=False)
declMap = declMap.Add(tree, entry) ' Callers are responsible for checking for existing entries.
declTable = declTable.AddRootDeclaration(entry)
referenceDirectivesChanged = referenceDirectivesChanged OrElse tree.HasReferenceDirectives
End Sub
Private Shared Function ForTree(tree As SyntaxTree, options As VisualBasicCompilationOptions, isSubmission As Boolean) As RootSingleNamespaceDeclaration
Return DeclarationTreeBuilder.ForTree(tree, options.GetRootNamespaceParts(), If(options.ScriptClassName, ""), isSubmission)
End Function
Public Shadows Function RemoveSyntaxTrees(ParamArray trees As SyntaxTree()) As VisualBasicCompilation
Return RemoveSyntaxTrees(DirectCast(trees, IEnumerable(Of SyntaxTree)))
End Function
Public Shadows Function RemoveSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As VisualBasicCompilation
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
If Not trees.Any() Then
Return Me
End If
Dim referenceDirectivesChanged = False
Dim removeSet As New HashSet(Of SyntaxTree)()
Dim declMap = _rootNamespaces
Dim declTable = _declarationTable
For Each tree As SyntaxTree In trees
If tree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotRemoveCompilerSpecialTree)
End If
RemoveSyntaxTreeFromDeclarationMapAndTable(tree, declMap, declTable, referenceDirectivesChanged)
removeSet.Add(tree)
Next
Debug.Assert(removeSet.Count > 0)
' We're going to have to revise the ordinals of all
' trees after the first one removed, so just build
' a new map.
' CONSIDER: an alternative approach would be to set the map to empty and
' re-calculate it the next time we need it. This might save us time in the
' case where remove calls are made sequentially (rare?).
Dim ordinalMap = ImmutableDictionary.Create(Of SyntaxTree, Integer)()
Dim builder = ArrayBuilder(Of SyntaxTree).GetInstance()
Dim i = 0
For Each tree In _syntaxTrees
If Not removeSet.Contains(tree) Then
builder.Add(tree)
ordinalMap = ordinalMap.Add(tree, i)
i += 1
End If
Next
Return UpdateSyntaxTrees(builder.ToImmutableAndFree(), ordinalMap, declMap, declTable, referenceDirectivesChanged)
End Function
Private Shared Sub RemoveSyntaxTreeFromDeclarationMapAndTable(
tree As SyntaxTree,
ByRef declMap As ImmutableDictionary(Of SyntaxTree, DeclarationTableEntry),
ByRef declTable As DeclarationTable,
ByRef referenceDirectivesChanged As Boolean
)
Dim root As DeclarationTableEntry = Nothing
If Not declMap.TryGetValue(tree, root) Then
Throw New ArgumentException(String.Format(VBResources.SyntaxTreeNotFoundToRemove, tree))
End If
declTable = declTable.RemoveRootDeclaration(root)
declMap = declMap.Remove(tree)
referenceDirectivesChanged = referenceDirectivesChanged OrElse tree.HasReferenceDirectives
End Sub
Public Shadows Function RemoveAllSyntaxTrees() As VisualBasicCompilation
Return UpdateSyntaxTrees(ImmutableArray(Of SyntaxTree).Empty,
ImmutableDictionary.Create(Of SyntaxTree, Integer)(),
ImmutableDictionary.Create(Of SyntaxTree, DeclarationTableEntry)(),
AddEmbeddedTrees(DeclarationTable.Empty, _embeddedTrees),
referenceDirectivesChanged:=_declarationTable.ReferenceDirectives.Any())
End Function
Public Shadows Function ReplaceSyntaxTree(oldTree As SyntaxTree, newTree As SyntaxTree) As VisualBasicCompilation
If oldTree Is Nothing Then
Throw New ArgumentNullException(NameOf(oldTree))
End If
If newTree Is Nothing Then
Return Me.RemoveSyntaxTrees(oldTree)
ElseIf newTree Is oldTree Then
Return Me
End If
If Not newTree.HasCompilationUnitRoot Then
Throw New ArgumentException(VBResources.TreeMustHaveARootNodeWithCompilationUnit, NameOf(newTree))
End If
Dim vbOldTree = oldTree
Dim vbNewTree = newTree
If vbOldTree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotRemoveCompilerSpecialTree)
End If
If vbNewTree.IsEmbeddedOrMyTemplateTree() Then
Throw New ArgumentException(VBResources.CannotAddCompilerSpecialTree)
End If
Dim declMap = _rootNamespaces
If declMap.ContainsKey(vbNewTree) Then
Throw New ArgumentException(VBResources.SyntaxTreeAlreadyPresent, NameOf(newTree))
End If
Dim declTable = _declarationTable
Dim referenceDirectivesChanged = False
' TODO(tomat): Consider comparing #r's of the old and the new tree. If they are exactly the same we could still reuse.
' This could be a perf win when editing a script file in the IDE. The services create a new compilation every keystroke
' that replaces the tree with a new one.
RemoveSyntaxTreeFromDeclarationMapAndTable(vbOldTree, declMap, declTable, referenceDirectivesChanged)
AddSyntaxTreeToDeclarationMapAndTable(vbNewTree, _options, Me.IsSubmission, declMap, declTable, referenceDirectivesChanged)
Dim ordinalMap = _syntaxTreeOrdinalMap
Debug.Assert(ordinalMap.ContainsKey(oldTree)) ' Checked by RemoveSyntaxTreeFromDeclarationMapAndTable
Dim oldOrdinal = ordinalMap(oldTree)
Dim newArray = _syntaxTrees.ToArray()
newArray(oldOrdinal) = vbNewTree
' CONSIDER: should this be an operation on ImmutableDictionary?
ordinalMap = ordinalMap.Remove(oldTree)
ordinalMap = ordinalMap.Add(newTree, oldOrdinal)
Return UpdateSyntaxTrees(newArray.AsImmutableOrNull(), ordinalMap, declMap, declTable, referenceDirectivesChanged)
End Function
Private Shared Function CreateEmbeddedTrees(compReference As Lazy(Of VisualBasicCompilation)) As ImmutableArray(Of EmbeddedTreeAndDeclaration)
Return ImmutableArray.Create(
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime Or compilation.IncludeInternalXmlHelper,
EmbeddedSymbolManager.EmbeddedSyntax,
Nothing)
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime Or compilation.IncludeInternalXmlHelper,
ForTree(EmbeddedSymbolManager.EmbeddedSyntax, compilation.Options, isSubmission:=False),
Nothing)
End Function),
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime,
EmbeddedSymbolManager.VbCoreSyntaxTree,
Nothing)
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.Options.EmbedVbCoreRuntime,
ForTree(EmbeddedSymbolManager.VbCoreSyntaxTree, compilation.Options, isSubmission:=False),
Nothing)
End Function),
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return If(compilation.IncludeInternalXmlHelper(),
EmbeddedSymbolManager.InternalXmlHelperSyntax,
Nothing)
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.IncludeInternalXmlHelper(),
ForTree(EmbeddedSymbolManager.InternalXmlHelperSyntax, compilation.Options, isSubmission:=False),
Nothing)
End Function),
New EmbeddedTreeAndDeclaration(
Function()
Dim compilation = compReference.Value
Return compilation.MyTemplate
End Function,
Function()
Dim compilation = compReference.Value
Return If(compilation.MyTemplate IsNot Nothing,
ForTree(compilation.MyTemplate, compilation.Options, isSubmission:=False),
Nothing)
End Function))
End Function
Private Shared Function AddEmbeddedTrees(
declTable As DeclarationTable,
embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration)
) As DeclarationTable
For Each embeddedTree In embeddedTrees
declTable = declTable.AddRootDeclaration(embeddedTree.DeclarationEntry)
Next
Return declTable
End Function
Private Shared Function RemoveEmbeddedTrees(
declTable As DeclarationTable,
embeddedTrees As ImmutableArray(Of EmbeddedTreeAndDeclaration)
) As DeclarationTable
For Each embeddedTree In embeddedTrees
declTable = declTable.RemoveRootDeclaration(embeddedTree.DeclarationEntry)
Next
Return declTable
End Function
''' <summary>
''' Returns True if the set of references contains those assemblies needed for XML
''' literals.
''' If those assemblies are included, we should include the InternalXmlHelper
''' SyntaxTree in the Compilation so the helper methods are available for binding XML.
''' </summary>
Private Function IncludeInternalXmlHelper() As Boolean
' In new flavors of the framework, types, that XML helpers depend upon, are
' defined in assemblies with different names. Let's not hardcode these names,
' let's check for presence of types instead.
Return Not Me.Options.SuppressEmbeddedDeclarations AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Linq_Enumerable) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XElement) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XName) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XAttribute) AndAlso
InternalXmlHelperDependencyIsSatisfied(WellKnownType.System_Xml_Linq_XNamespace)
End Function
Private Function InternalXmlHelperDependencyIsSatisfied(type As WellKnownType) As Boolean
Dim metadataName = MetadataTypeName.FromFullName(WellKnownTypes.GetMetadataName(type), useCLSCompliantNameArityEncoding:=True)
Dim sourceAssembly = Me.SourceAssembly
' Lookup only in references. An attempt to lookup in assembly being built will get us in a cycle.
' We are explicitly ignoring scenario where the type might be defined in an added module.
For Each reference As AssemblySymbol In sourceAssembly.SourceModule.GetReferencedAssemblySymbols()
Debug.Assert(Not reference.IsMissing)
Dim candidate As NamedTypeSymbol = reference.LookupTopLevelMetadataType(metadataName, digThroughForwardedTypes:=False)
If sourceAssembly.IsValidWellKnownType(candidate) AndAlso AssemblySymbol.IsAcceptableMatchForGetTypeByNameAndArity(candidate) Then
Return True
End If
Next
Return False
End Function
' TODO: This comparison probably will change to compiler command line order, or at least needs
' TODO: to be resolved. See bug 8520.
''' <summary>
''' Compare two source locations, using their containing trees, and then by Span.First within a tree.
''' Can be used to get a total ordering on declarations, for example.
''' </summary>
Friend Overrides Function CompareSourceLocations(first As Location, second As Location) As Integer
Return LexicalSortKey.Compare(first, second, Me)
End Function
''' <summary>
''' Compare two source locations, using their containing trees, and then by Span.First within a tree.
''' Can be used to get a total ordering on declarations, for example.
''' </summary>
Friend Overrides Function CompareSourceLocations(first As SyntaxReference, second As SyntaxReference) As Integer
Return LexicalSortKey.Compare(first, second, Me)
End Function
''' <summary>
''' Compare two source locations, using their containing trees, and then by Span.First within a tree.
''' Can be used to get a total ordering on declarations, for example.
''' </summary>
Friend Overrides Function CompareSourceLocations(first As SyntaxNode, second As SyntaxNode) As Integer
Return LexicalSortKey.Compare(first, second, Me)
End Function
Friend Overrides Function GetSyntaxTreeOrdinal(tree As SyntaxTree) As Integer
Debug.Assert(Me.ContainsSyntaxTree(tree))
Return _syntaxTreeOrdinalMap(tree)
End Function
#End Region
#Region "References"
Friend Overrides Function CommonGetBoundReferenceManager() As CommonReferenceManager
Return GetBoundReferenceManager()
End Function
Friend Shadows Function GetBoundReferenceManager() As ReferenceManager
If _lazyAssemblySymbol Is Nothing Then
_referenceManager.CreateSourceAssemblyForCompilation(Me)
Debug.Assert(_lazyAssemblySymbol IsNot Nothing)
End If
' referenceManager can only be accessed after we initialized the lazyAssemblySymbol.
' In fact, initialization of the assembly symbol might change the reference manager.
Return _referenceManager
End Function
' for testing only:
Friend Function ReferenceManagerEquals(other As VisualBasicCompilation) As Boolean
Return _referenceManager Is other._referenceManager
End Function
Public Overrides ReadOnly Property DirectiveReferences As ImmutableArray(Of MetadataReference)
Get
Return GetBoundReferenceManager().DirectiveReferences
End Get
End Property
Friend Overrides ReadOnly Property ReferenceDirectiveMap As IDictionary(Of (path As String, content As String), MetadataReference)
Get
Return GetBoundReferenceManager().ReferenceDirectiveMap
End Get
End Property
''' <summary>
''' Gets the <see cref="AssemblySymbol"/> or <see cref="ModuleSymbol"/> for a metadata reference used to create this compilation.
''' </summary>
''' <returns><see cref="AssemblySymbol"/> or <see cref="ModuleSymbol"/> corresponding to the given reference or Nothing if there is none.</returns>
''' <remarks>
''' Uses object identity when comparing two references.
''' </remarks>
Friend Shadows Function GetAssemblyOrModuleSymbol(reference As MetadataReference) As Symbol
If (reference Is Nothing) Then
Throw New ArgumentNullException(NameOf(reference))
End If
If reference.Properties.Kind = MetadataImageKind.Assembly Then
Return GetBoundReferenceManager().GetReferencedAssemblySymbol(reference)
Else
Debug.Assert(reference.Properties.Kind = MetadataImageKind.Module)
Dim index As Integer = GetBoundReferenceManager().GetReferencedModuleIndex(reference)
Return If(index < 0, Nothing, Me.Assembly.Modules(index))
End If
End Function
''' <summary>
''' Gets the <see cref="MetadataReference"/> that corresponds to the assembly symbol.
''' </summary>
Friend Shadows Function GetMetadataReference(assemblySymbol As AssemblySymbol) As MetadataReference
Return Me.GetBoundReferenceManager().GetMetadataReference(assemblySymbol)
End Function
Private Protected Overrides Function CommonGetMetadataReference(assemblySymbol As IAssemblySymbol) As MetadataReference
Dim symbol = TryCast(assemblySymbol, AssemblySymbol)
If symbol IsNot Nothing Then
Return GetMetadataReference(symbol)
End If
Return Nothing
End Function
Public Overrides ReadOnly Property ReferencedAssemblyNames As IEnumerable(Of AssemblyIdentity)
Get
Return [Assembly].Modules.SelectMany(Function(m) m.GetReferencedAssemblies())
End Get
End Property
Friend Overrides ReadOnly Property ReferenceDirectives As IEnumerable(Of ReferenceDirective)
Get
Return _declarationTable.ReferenceDirectives
End Get
End Property
Public Overrides Function ToMetadataReference(Optional aliases As ImmutableArray(Of String) = Nothing, Optional embedInteropTypes As Boolean = False) As CompilationReference
Return New VisualBasicCompilationReference(Me, aliases, embedInteropTypes)
End Function
Public Shadows Function AddReferences(ParamArray references As MetadataReference()) As VisualBasicCompilation
Return DirectCast(MyBase.AddReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function AddReferences(references As IEnumerable(Of MetadataReference)) As VisualBasicCompilation
Return DirectCast(MyBase.AddReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function RemoveReferences(ParamArray references As MetadataReference()) As VisualBasicCompilation
Return DirectCast(MyBase.RemoveReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function RemoveReferences(references As IEnumerable(Of MetadataReference)) As VisualBasicCompilation
Return DirectCast(MyBase.RemoveReferences(references), VisualBasicCompilation)
End Function
Public Shadows Function RemoveAllReferences() As VisualBasicCompilation
Return DirectCast(MyBase.RemoveAllReferences(), VisualBasicCompilation)
End Function
Public Shadows Function ReplaceReference(oldReference As MetadataReference, newReference As MetadataReference) As VisualBasicCompilation
Return DirectCast(MyBase.ReplaceReference(oldReference, newReference), VisualBasicCompilation)
End Function
''' <summary>
''' Determine if enum arrays can be initialized using block initialization.
''' </summary>
''' <returns>True if it's safe to use block initialization for enum arrays.</returns>
''' <remarks>
''' In NetFx 4.0, block array initializers do not work on all combinations of {32/64 X Debug/Retail} when array elements are enums.
''' This is fixed in 4.5 thus enabling block array initialization for a very common case.
''' We look for the presence of <see cref="System.Runtime.GCLatencyMode.SustainedLowLatency"/> which was introduced in .NET Framework 4.5
''' </remarks>
Friend ReadOnly Property EnableEnumArrayBlockInitialization As Boolean
Get
Dim sustainedLowLatency = GetWellKnownTypeMember(WellKnownMember.System_Runtime_GCLatencyMode__SustainedLowLatency)
Return sustainedLowLatency IsNot Nothing AndAlso sustainedLowLatency.ContainingAssembly = Assembly.CorLibrary
End Get
End Property
#End Region
#Region "Symbols"
Friend ReadOnly Property SourceAssembly As SourceAssemblySymbol
Get
GetBoundReferenceManager()
Return _lazyAssemblySymbol
End Get
End Property
''' <summary>
''' Gets the AssemblySymbol that represents the assembly being created.
''' </summary>
Friend Shadows ReadOnly Property Assembly As AssemblySymbol
Get
Return Me.SourceAssembly
End Get
End Property
''' <summary>
''' Get a ModuleSymbol that refers to the module being created by compiling all of the code. By
''' getting the GlobalNamespace property of that module, all of the namespace and types defined in source code
''' can be obtained.
''' </summary>
Friend Shadows ReadOnly Property SourceModule As ModuleSymbol
Get
Return Me.Assembly.Modules(0)
End Get
End Property
''' <summary>
''' Gets the merged root namespace that contains all namespaces and types defined in source code or in
''' referenced metadata, merged into a single namespace hierarchy. This namespace hierarchy is how the compiler
''' binds types that are referenced in code.
''' </summary>
Friend Shadows ReadOnly Property GlobalNamespace As NamespaceSymbol
Get
If _lazyGlobalNamespace Is Nothing Then
Interlocked.CompareExchange(_lazyGlobalNamespace, MergedNamespaceSymbol.CreateGlobalNamespace(Me), Nothing)
End If
Return _lazyGlobalNamespace
End Get
End Property
''' <summary>
''' Get the "root" or default namespace that all source types are declared inside. This may be the
''' global namespace or may be another namespace.
''' </summary>
Friend ReadOnly Property RootNamespace As NamespaceSymbol
Get
Return DirectCast(Me.SourceModule, SourceModuleSymbol).RootNamespace
End Get
End Property
''' <summary>
''' Given a namespace symbol, returns the corresponding namespace symbol with Compilation extent
''' that refers to that namespace in this compilation. Returns Nothing if there is no corresponding
''' namespace. This should not occur if the namespace symbol came from an assembly referenced by this
''' compilation.
''' </summary>
Friend Shadows Function GetCompilationNamespace(namespaceSymbol As INamespaceSymbol) As NamespaceSymbol
If namespaceSymbol Is Nothing Then
Throw New ArgumentNullException(NameOf(namespaceSymbol))
End If
Dim vbNs = TryCast(namespaceSymbol, NamespaceSymbol)
If vbNs IsNot Nothing AndAlso vbNs.Extent.Kind = NamespaceKind.Compilation AndAlso vbNs.Extent.Compilation Is Me Then
' If we already have a namespace with the right extent, use that.
Return vbNs
ElseIf namespaceSymbol.ContainingNamespace Is Nothing Then
' If is the root namespace, return the merged root namespace
Debug.Assert(namespaceSymbol.Name = "", "Namespace with Nothing container should be root namespace with empty name")
Return GlobalNamespace
Else
Dim containingNs = GetCompilationNamespace(namespaceSymbol.ContainingNamespace)
If containingNs Is Nothing Then
Return Nothing
End If
' Get the child namespace of the given name, if any.
Return containingNs.GetMembers(namespaceSymbol.Name).OfType(Of NamespaceSymbol)().FirstOrDefault()
End If
End Function
Friend Shadows Function GetEntryPoint(cancellationToken As CancellationToken) As MethodSymbol
Dim entryPoint As EntryPoint = GetEntryPointAndDiagnostics(cancellationToken)
Return If(entryPoint Is Nothing, Nothing, entryPoint.MethodSymbol)
End Function
Friend Function GetEntryPointAndDiagnostics(cancellationToken As CancellationToken) As EntryPoint
If Not Me.Options.OutputKind.IsApplication() AndAlso ScriptClass Is Nothing Then
Return Nothing
End If
If Me.Options.MainTypeName IsNot Nothing AndAlso Not Me.Options.MainTypeName.IsValidClrTypeName() Then
Debug.Assert(Not Me.Options.Errors.IsDefaultOrEmpty)
Return New EntryPoint(Nothing, ImmutableArray(Of Diagnostic).Empty)
End If
If _lazyEntryPoint Is Nothing Then
Dim diagnostics As ImmutableArray(Of Diagnostic) = Nothing
Dim entryPoint = FindEntryPoint(cancellationToken, diagnostics)
Interlocked.CompareExchange(_lazyEntryPoint, New EntryPoint(entryPoint, diagnostics), Nothing)
End If
Return _lazyEntryPoint
End Function
Private Function FindEntryPoint(cancellationToken As CancellationToken, ByRef sealedDiagnostics As ImmutableArray(Of Diagnostic)) As MethodSymbol
Dim diagnostics = DiagnosticBag.GetInstance()
Dim entryPointCandidates = ArrayBuilder(Of MethodSymbol).GetInstance()
Try
Dim mainType As SourceMemberContainerTypeSymbol
Dim mainTypeName As String = Me.Options.MainTypeName
Dim globalNamespace As NamespaceSymbol = Me.SourceModule.GlobalNamespace
Dim errorTarget As Object
If mainTypeName IsNot Nothing Then
' Global code is the entry point, ignore all other Mains.
If ScriptClass IsNot Nothing Then
' CONSIDER: we could use the symbol instead of just the name.
diagnostics.Add(ERRID.WRN_MainIgnored, NoLocation.Singleton, mainTypeName)
Return ScriptClass.GetScriptEntryPoint()
End If
Dim mainTypeOrNamespace = globalNamespace.GetNamespaceOrTypeByQualifiedName(mainTypeName.Split("."c)).OfType(Of NamedTypeSymbol)().OfMinimalArity()
If mainTypeOrNamespace Is Nothing Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, mainTypeName)
Return Nothing
End If
mainType = TryCast(mainTypeOrNamespace, SourceMemberContainerTypeSymbol)
If mainType Is Nothing OrElse (mainType.TypeKind <> TYPEKIND.Class AndAlso mainType.TypeKind <> TYPEKIND.Structure AndAlso mainType.TypeKind <> TYPEKIND.Module) Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, mainType)
Return Nothing
End If
' Dev10 reports ERR_StartupCodeNotFound1 but that doesn't make much sense
If mainType.IsGenericType Then
diagnostics.Add(ERRID.ERR_GenericSubMainsFound1, NoLocation.Singleton, mainType)
Return Nothing
End If
errorTarget = mainType
' NOTE: unlike in C#, we're not going search the member list of mainType directly.
' Instead, we're going to mimic dev10's behavior by doing a lookup for "Main",
' starting in mainType. Among other things, this implies that the entrypoint
' could be in a base class and that it could be hidden by a non-method member
' named "Main".
Dim binder As Binder = BinderBuilder.CreateBinderForType(mainType.ContainingSourceModule, mainType.SyntaxReferences(0).SyntaxTree, mainType)
Dim lookupResult As LookupResult = lookupResult.GetInstance()
Dim entryPointLookupOptions As LookupOptions = LookupOptions.AllMethodsOfAnyArity Or LookupOptions.IgnoreExtensionMethods
binder.LookupMember(lookupResult, mainType, WellKnownMemberNames.EntryPointMethodName, arity:=0, options:=entryPointLookupOptions, useSiteInfo:=CompoundUseSiteInfo(Of AssemblySymbol).Discarded)
If (Not lookupResult.IsGoodOrAmbiguous) OrElse lookupResult.Symbols(0).Kind <> SymbolKind.Method Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, mainType)
lookupResult.Free()
Return Nothing
End If
For Each candidate In lookupResult.Symbols
' The entrypoint cannot be in another assembly.
' NOTE: filter these out here, rather than below, so that we
' report "not found", rather than "invalid", as in dev10.
If candidate.ContainingAssembly = Me.Assembly Then
entryPointCandidates.Add(DirectCast(candidate, MethodSymbol))
End If
Next
lookupResult.Free()
Else
mainType = Nothing
errorTarget = Me.AssemblyName
For Each candidate In Me.GetSymbolsWithName(WellKnownMemberNames.EntryPointMethodName, SymbolFilter.Member, cancellationToken)
Dim method = TryCast(candidate, MethodSymbol)
If method?.IsEntryPointCandidate = True Then
entryPointCandidates.Add(method)
End If
Next
' Global code is the entry point, ignore all other Mains.
If ScriptClass IsNot Nothing Then
For Each main In entryPointCandidates
diagnostics.Add(ERRID.WRN_MainIgnored, main.Locations.First(), main)
Next
Return ScriptClass.GetScriptEntryPoint()
End If
End If
If entryPointCandidates.Count = 0 Then
diagnostics.Add(ERRID.ERR_StartupCodeNotFound1, NoLocation.Singleton, errorTarget)
Return Nothing
End If
Dim hasViableGenericEntryPoints As Boolean = False
Dim viableEntryPoints = ArrayBuilder(Of MethodSymbol).GetInstance()
For Each candidate In entryPointCandidates
If Not candidate.IsViableMainMethod Then
Continue For
End If
If candidate.IsGenericMethod OrElse candidate.ContainingType.IsGenericType Then
hasViableGenericEntryPoints = True
Else
viableEntryPoints.Add(candidate)
End If
Next
Dim entryPoint As MethodSymbol = Nothing
If viableEntryPoints.Count = 0 Then
If hasViableGenericEntryPoints Then
diagnostics.Add(ERRID.ERR_GenericSubMainsFound1, NoLocation.Singleton, errorTarget)
Else
diagnostics.Add(ERRID.ERR_InValidSubMainsFound1, NoLocation.Singleton, errorTarget)
End If
ElseIf viableEntryPoints.Count > 1 Then
viableEntryPoints.Sort(LexicalOrderSymbolComparer.Instance)
diagnostics.Add(ERRID.ERR_MoreThanOneValidMainWasFound2,
NoLocation.Singleton,
Me.AssemblyName,
New FormattedSymbolList(viableEntryPoints.ToArray(), CustomSymbolDisplayFormatter.ErrorMessageFormatNoModifiersNoReturnType))
Else
entryPoint = viableEntryPoints(0)
If entryPoint.IsAsync Then
' The rule we follow:
' First determine the Sub Main using pre-async rules, and give the pre-async errors if there were 0 or >1 results
' If there was exactly one result, but it was async, then give an error. Otherwise proceed.
' This doesn't follow the same pattern as "error due to being generic". That's because
' maybe one day we'll want to allow Async Sub Main but without breaking back-compat.
Dim sourceMethod = TryCast(entryPoint, SourceMemberMethodSymbol)
Debug.Assert(sourceMethod IsNot Nothing)
If sourceMethod IsNot Nothing Then
Dim location As Location = sourceMethod.NonMergedLocation
Debug.Assert(location IsNot Nothing)
If location IsNot Nothing Then
Binder.ReportDiagnostic(diagnostics, location, ERRID.ERR_AsyncSubMain)
End If
End If
End If
End If
viableEntryPoints.Free()
Return entryPoint
Finally
entryPointCandidates.Free()
sealedDiagnostics = diagnostics.ToReadOnlyAndFree()
End Try
End Function
Friend Class EntryPoint
Public ReadOnly MethodSymbol As MethodSymbol
Public ReadOnly Diagnostics As ImmutableArray(Of Diagnostic)
Public Sub New(methodSymbol As MethodSymbol, diagnostics As ImmutableArray(Of Diagnostic))
Me.MethodSymbol = methodSymbol
Me.Diagnostics = diagnostics
End Sub
End Class
''' <summary>
''' Returns the list of member imports that apply to all syntax trees in this compilation.
''' </summary>
Friend ReadOnly Property MemberImports As ImmutableArray(Of NamespaceOrTypeSymbol)
Get
Return DirectCast(Me.SourceModule, SourceModuleSymbol).MemberImports.SelectAsArray(Function(m) m.NamespaceOrType)
End Get
End Property
''' <summary>
''' Returns the list of alias imports that apply to all syntax trees in this compilation.
''' </summary>
Friend ReadOnly Property AliasImports As ImmutableArray(Of AliasSymbol)
Get
Return DirectCast(Me.SourceModule, SourceModuleSymbol).AliasImports.SelectAsArray(Function(a) a.Alias)
End Get
End Property
Friend Overrides Sub ReportUnusedImports(diagnostics As DiagnosticBag, cancellationToken As CancellationToken)
ReportUnusedImports(filterTree:=Nothing, New BindingDiagnosticBag(diagnostics), cancellationToken)
End Sub
Private Overloads Sub ReportUnusedImports(filterTree As SyntaxTree, diagnostics As BindingDiagnosticBag, cancellationToken As CancellationToken)
If _lazyImportInfos IsNot Nothing AndAlso (filterTree Is Nothing OrElse ReportUnusedImportsInTree(filterTree)) Then
Dim unusedBuilder As ArrayBuilder(Of TextSpan) = Nothing
For Each info As ImportInfo In _lazyImportInfos
cancellationToken.ThrowIfCancellationRequested()
Dim infoTree As SyntaxTree = info.Tree
If (filterTree Is Nothing OrElse filterTree Is infoTree) AndAlso ReportUnusedImportsInTree(infoTree) Then
Dim clauseSpans = info.ClauseSpans
Dim numClauseSpans = clauseSpans.Length
If numClauseSpans = 1 Then
' Do less work in common case (one clause per statement).
If Not Me.IsImportDirectiveUsed(infoTree, clauseSpans(0).Start) Then
diagnostics.Add(ERRID.HDN_UnusedImportStatement, infoTree.GetLocation(info.StatementSpan))
Else
AddImportsDependencies(diagnostics, infoTree, clauseSpans(0))
End If
Else
If unusedBuilder IsNot Nothing Then
unusedBuilder.Clear()
End If
For Each clauseSpan In info.ClauseSpans
If Not Me.IsImportDirectiveUsed(infoTree, clauseSpan.Start) Then
If unusedBuilder Is Nothing Then
unusedBuilder = ArrayBuilder(Of TextSpan).GetInstance()
End If
unusedBuilder.Add(clauseSpan)
Else
AddImportsDependencies(diagnostics, infoTree, clauseSpan)
End If
Next
If unusedBuilder IsNot Nothing AndAlso unusedBuilder.Count > 0 Then
If unusedBuilder.Count = numClauseSpans Then
diagnostics.Add(ERRID.HDN_UnusedImportStatement, infoTree.GetLocation(info.StatementSpan))
Else
For Each clauseSpan In unusedBuilder
diagnostics.Add(ERRID.HDN_UnusedImportClause, infoTree.GetLocation(clauseSpan))
Next
End If
End If
End If
End If
Next
If unusedBuilder IsNot Nothing Then
unusedBuilder.Free()
End If
End If
CompleteTrees(filterTree)
End Sub
Private Sub AddImportsDependencies(diagnostics As BindingDiagnosticBag, infoTree As SyntaxTree, clauseSpan As TextSpan)
Dim dependencies As ImmutableArray(Of AssemblySymbol) = Nothing
If diagnostics.AccumulatesDependencies AndAlso _lazyImportClauseDependencies IsNot Nothing AndAlso
_lazyImportClauseDependencies.TryGetValue((infoTree, clauseSpan.Start), dependencies) Then
diagnostics.AddDependencies(dependencies)
End If
End Sub
Friend Overrides Sub CompleteTrees(filterTree As SyntaxTree)
' By definition, a tree Is complete when all of its compiler diagnostics have been reported.
' Since unused imports are the last thing we compute And report, a tree Is complete when
' the unused imports have been reported.
If EventQueue IsNot Nothing Then
If filterTree IsNot Nothing Then
CompleteTree(filterTree)
Else
For Each tree As SyntaxTree In SyntaxTrees
CompleteTree(tree)
Next
End If
End If
End Sub
Private Sub CompleteTree(tree As SyntaxTree)
If tree.IsEmbeddedOrMyTemplateTree Then
' The syntax trees added to AllSyntaxTrees by the compiler
' do not count toward completion.
Return
End If
Debug.Assert(AllSyntaxTrees.Contains(tree))
If _lazyCompilationUnitCompletedTrees Is Nothing Then
Interlocked.CompareExchange(_lazyCompilationUnitCompletedTrees, New HashSet(Of SyntaxTree)(), Nothing)
End If
SyncLock _lazyCompilationUnitCompletedTrees
If _lazyCompilationUnitCompletedTrees.Add(tree) Then
' signal the end of the compilation unit
EventQueue.TryEnqueue(New CompilationUnitCompletedEvent(Me, tree))
If _lazyCompilationUnitCompletedTrees.Count = SyntaxTrees.Length Then
' if that was the last tree, signal the end of compilation
CompleteCompilationEventQueue_NoLock()
End If
End If
End SyncLock
End Sub
Friend Function ShouldAddEvent(symbol As Symbol) As Boolean
Return EventQueue IsNot Nothing AndAlso symbol.IsInSource()
End Function
Friend Sub SymbolDeclaredEvent(symbol As Symbol)
If ShouldAddEvent(symbol) Then
EventQueue.TryEnqueue(New SymbolDeclaredCompilationEvent(Me, symbol))
End If
End Sub
Friend Sub RecordImportsClauseDependencies(syntaxTree As SyntaxTree, importsClausePosition As Integer, dependencies As ImmutableArray(Of AssemblySymbol))
If Not dependencies.IsDefaultOrEmpty Then
LazyInitializer.EnsureInitialized(_lazyImportClauseDependencies).TryAdd((syntaxTree, importsClausePosition), dependencies)
End If
End Sub
Friend Sub RecordImports(syntax As ImportsStatementSyntax)
LazyInitializer.EnsureInitialized(_lazyImportInfos).Enqueue(New ImportInfo(syntax))
End Sub
Private Structure ImportInfo
Public ReadOnly Tree As SyntaxTree
Public ReadOnly StatementSpan As TextSpan
Public ReadOnly ClauseSpans As ImmutableArray(Of TextSpan)
' CONSIDER: ClauseSpans will usually be a singleton. If we're
' creating too much garbage, it might be worthwhile to store
' a single clause span in a separate field.
Public Sub New(syntax As ImportsStatementSyntax)
Me.Tree = syntax.SyntaxTree
Me.StatementSpan = syntax.Span
Dim builder = ArrayBuilder(Of TextSpan).GetInstance()
For Each clause In syntax.ImportsClauses
builder.Add(clause.Span)
Next
Me.ClauseSpans = builder.ToImmutableAndFree()
End Sub
End Structure
Friend ReadOnly Property DeclaresTheObjectClass As Boolean
Get
Return SourceAssembly.DeclaresTheObjectClass
End Get
End Property
Friend Function MightContainNoPiaLocalTypes() As Boolean
Return SourceAssembly.MightContainNoPiaLocalTypes()
End Function
' NOTE(cyrusn): There is a bit of a discoverability problem with this method and the same
' named method in SyntaxTreeSemanticModel. Technically, i believe these are the appropriate
' locations for these methods. This method has no dependencies on anything but the
' compilation, while the other method needs a bindings object to determine what bound node
' an expression syntax binds to. Perhaps when we document these methods we should explain
' where a user can find the other.
''' <summary>
''' Determine what kind of conversion, if any, there is between the types
''' "source" and "destination".
''' </summary>
Public Shadows Function ClassifyConversion(source As ITypeSymbol, destination As ITypeSymbol) As Conversion
If source Is Nothing Then
Throw New ArgumentNullException(NameOf(source))
End If
If destination Is Nothing Then
Throw New ArgumentNullException(NameOf(destination))
End If
Dim vbsource = source.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(source))
Dim vbdest = destination.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(destination))
If vbsource.IsErrorType() OrElse vbdest.IsErrorType() Then
Return New Conversion(Nothing) ' No conversion
End If
Return New Conversion(Conversions.ClassifyConversion(vbsource, vbdest, CompoundUseSiteInfo(Of AssemblySymbol).Discarded))
End Function
Public Overrides Function ClassifyCommonConversion(source As ITypeSymbol, destination As ITypeSymbol) As CommonConversion
Return ClassifyConversion(source, destination).ToCommonConversion()
End Function
Friend Overrides Function ClassifyConvertibleConversion(source As IOperation, destination As ITypeSymbol, ByRef constantValue As ConstantValue) As IConvertibleConversion
constantValue = Nothing
If destination Is Nothing Then
Return New Conversion(Nothing) ' No conversion
End If
Dim sourceType As ITypeSymbol = source.Type
Dim sourceConstantValue As ConstantValue = source.GetConstantValue()
If sourceType Is Nothing Then
If sourceConstantValue IsNot Nothing AndAlso sourceConstantValue.IsNothing AndAlso destination.IsReferenceType Then
constantValue = sourceConstantValue
Return New Conversion(New KeyValuePair(Of ConversionKind, MethodSymbol)(ConversionKind.WideningNothingLiteral, Nothing))
End If
Return New Conversion(Nothing) ' No conversion
End If
Dim result As Conversion = ClassifyConversion(sourceType, destination)
If result.IsReference AndAlso sourceConstantValue IsNot Nothing AndAlso sourceConstantValue.IsNothing Then
constantValue = sourceConstantValue
End If
Return result
End Function
''' <summary>
''' A symbol representing the implicit Script class. This is null if the class is not
''' defined in the compilation.
''' </summary>
Friend Shadows ReadOnly Property ScriptClass As NamedTypeSymbol
Get
Return SourceScriptClass
End Get
End Property
Friend ReadOnly Property SourceScriptClass As ImplicitNamedTypeSymbol
Get
Return _scriptClass.Value
End Get
End Property
''' <summary>
''' Resolves a symbol that represents script container (Script class).
''' Uses the full name of the container class stored in <see cref="CompilationOptions.ScriptClassName"/> to find the symbol.
''' </summary>
''' <returns>
''' The Script class symbol or null if it is not defined.
''' </returns>
Private Function BindScriptClass() As ImplicitNamedTypeSymbol
Return DirectCast(CommonBindScriptClass(), ImplicitNamedTypeSymbol)
End Function
''' <summary>
''' Get symbol for predefined type from Cor Library referenced by this compilation.
''' </summary>
Friend Shadows Function GetSpecialType(typeId As SpecialType) As NamedTypeSymbol
Dim result = Assembly.GetSpecialType(typeId)
Debug.Assert(result.SpecialType = typeId)
Return result
End Function
''' <summary>
''' Get symbol for predefined type member from Cor Library referenced by this compilation.
''' </summary>
Friend Shadows Function GetSpecialTypeMember(memberId As SpecialMember) As Symbol
Return Assembly.GetSpecialTypeMember(memberId)
End Function
Friend Overrides Function CommonGetSpecialTypeMember(specialMember As SpecialMember) As ISymbolInternal
Return GetSpecialTypeMember(specialMember)
End Function
Friend Function GetTypeByReflectionType(type As Type) As TypeSymbol
' TODO: See CSharpCompilation.GetTypeByReflectionType
Return GetSpecialType(SpecialType.System_Object)
End Function
''' <summary>
''' Lookup a type within the compilation's assembly and all referenced assemblies
''' using its canonical CLR metadata name (names are compared case-sensitively).
''' </summary>
''' <param name="fullyQualifiedMetadataName">
''' </param>
''' <returns>
''' Symbol for the type or null if type cannot be found or is ambiguous.
''' </returns>
Friend Shadows Function GetTypeByMetadataName(fullyQualifiedMetadataName As String) As NamedTypeSymbol
Return Me.Assembly.GetTypeByMetadataName(fullyQualifiedMetadataName, includeReferences:=True, isWellKnownType:=False, conflicts:=Nothing)
End Function
Friend Shadows ReadOnly Property ObjectType As NamedTypeSymbol
Get
Return Assembly.ObjectType
End Get
End Property
Friend Shadows Function CreateArrayTypeSymbol(elementType As TypeSymbol, Optional rank As Integer = 1) As ArrayTypeSymbol
If elementType Is Nothing Then
Throw New ArgumentNullException(NameOf(elementType))
End If
If rank < 1 Then
Throw New ArgumentException(NameOf(rank))
End If
Return ArrayTypeSymbol.CreateVBArray(elementType, Nothing, rank, Me)
End Function
Friend ReadOnly Property HasTupleNamesAttributes As Boolean
Get
Dim constructorSymbol = TryCast(GetWellKnownTypeMember(WellKnownMember.System_Runtime_CompilerServices_TupleElementNamesAttribute__ctorTransformNames), MethodSymbol)
Return constructorSymbol IsNot Nothing AndAlso
Binder.GetUseSiteInfoForWellKnownTypeMember(constructorSymbol, WellKnownMember.System_Runtime_CompilerServices_TupleElementNamesAttribute__ctorTransformNames,
embedVBRuntimeUsed:=False).DiagnosticInfo Is Nothing
End Get
End Property
Private Protected Overrides Function IsSymbolAccessibleWithinCore(symbol As ISymbol, within As ISymbol, throughType As ITypeSymbol) As Boolean
Dim symbol0 = symbol.EnsureVbSymbolOrNothing(Of Symbol)(NameOf(symbol))
Dim within0 = within.EnsureVbSymbolOrNothing(Of Symbol)(NameOf(within))
Dim throughType0 = throughType.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(throughType))
Return If(within0.Kind = SymbolKind.Assembly,
AccessCheck.IsSymbolAccessible(symbol0, DirectCast(within0, AssemblySymbol), useSiteInfo:=CompoundUseSiteInfo(Of AssemblySymbol).Discarded),
AccessCheck.IsSymbolAccessible(symbol0, DirectCast(within0, NamedTypeSymbol), throughType0, useSiteInfo:=CompoundUseSiteInfo(Of AssemblySymbol).Discarded))
End Function
<Obsolete("Compilation.IsSymbolAccessibleWithin is not designed for use within the compilers", True)>
Friend Shadows Function IsSymbolAccessibleWithin(symbol As ISymbol, within As ISymbol, Optional throughType As ITypeSymbol = Nothing) As Boolean
Throw New NotImplementedException
End Function
#End Region
#Region "Binding"
'''<summary>
''' Get a fresh SemanticModel. Note that each invocation gets a fresh SemanticModel, each of
''' which has a cache. Therefore, one effectively clears the cache by discarding the
''' SemanticModel.
'''</summary>
Public Shadows Function GetSemanticModel(syntaxTree As SyntaxTree, Optional ignoreAccessibility As Boolean = False) As SemanticModel
Dim model As SemanticModel = Nothing
If SemanticModelProvider IsNot Nothing Then
model = SemanticModelProvider.GetSemanticModel(syntaxTree, Me, ignoreAccessibility)
Debug.Assert(model IsNot Nothing)
End If
Return If(model, CreateSemanticModel(syntaxTree, ignoreAccessibility))
End Function
Friend Overrides Function CreateSemanticModel(syntaxTree As SyntaxTree, ignoreAccessibility As Boolean) As SemanticModel
Return New SyntaxTreeSemanticModel(Me, DirectCast(Me.SourceModule, SourceModuleSymbol), syntaxTree, ignoreAccessibility)
End Function
Friend ReadOnly Property FeatureStrictEnabled As Boolean
Get
Return Me.Feature("strict") IsNot Nothing
End Get
End Property
#End Region
#Region "Diagnostics"
Friend Overrides ReadOnly Property MessageProvider As CommonMessageProvider
Get
Return VisualBasic.MessageProvider.Instance
End Get
End Property
''' <summary>
''' Get all diagnostics for the entire compilation. This includes diagnostics from parsing, declarations, and
''' the bodies of methods. Getting all the diagnostics is potentially a length operations, as it requires parsing and
''' compiling all the code. The set of diagnostics is not caches, so each call to this method will recompile all
''' methods.
''' </summary>
''' <param name="cancellationToken">Cancellation token to allow cancelling the operation.</param>
Public Overrides Function GetDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(DefaultDiagnosticsStage, True, cancellationToken)
End Function
''' <summary>
''' Get parse diagnostics for the entire compilation. This includes diagnostics from parsing BUT NOT from declarations and
''' the bodies of methods or initializers. The set of parse diagnostics is cached, so calling this method a second time
''' should be fast.
''' </summary>
Public Overrides Function GetParseDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(CompilationStage.Parse, False, cancellationToken)
End Function
''' <summary>
''' Get declarations diagnostics for the entire compilation. This includes diagnostics from declarations, BUT NOT
''' the bodies of methods or initializers. The set of declaration diagnostics is cached, so calling this method a second time
''' should be fast.
''' </summary>
''' <param name="cancellationToken">Cancellation token to allow cancelling the operation.</param>
Public Overrides Function GetDeclarationDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(CompilationStage.Declare, False, cancellationToken)
End Function
''' <summary>
''' Get method body diagnostics for the entire compilation. This includes diagnostics only from
''' the bodies of methods and initializers. These diagnostics are NOT cached, so calling this method a second time
''' repeats significant work.
''' </summary>
''' <param name="cancellationToken">Cancellation token to allow cancelling the operation.</param>
Public Overrides Function GetMethodBodyDiagnostics(Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Return GetDiagnostics(CompilationStage.Compile, False, cancellationToken)
End Function
''' <summary>
''' Get all errors in the compilation, up through the given compilation stage. Note that this may
''' require significant work by the compiler, as all source code must be compiled to the given
''' level in order to get the errors. Errors on Options should be inspected by the user prior to constructing the compilation.
''' </summary>
''' <returns>
''' Returns all errors. The errors are not sorted in any particular order, and the client
''' should sort the errors as desired.
''' </returns>
Friend Overloads Function GetDiagnostics(stage As CompilationStage, Optional includeEarlierStages As Boolean = True, Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
Dim diagnostics = DiagnosticBag.GetInstance()
GetDiagnostics(stage, includeEarlierStages, diagnostics, cancellationToken)
Return diagnostics.ToReadOnlyAndFree()
End Function
Friend Overrides Sub GetDiagnostics(stage As CompilationStage,
includeEarlierStages As Boolean,
diagnostics As DiagnosticBag,
Optional cancellationToken As CancellationToken = Nothing)
Dim builder = DiagnosticBag.GetInstance()
GetDiagnosticsWithoutFiltering(stage, includeEarlierStages, New BindingDiagnosticBag(builder), cancellationToken)
' Before returning diagnostics, we filter some of them
' to honor the compiler options (e.g., /nowarn and /warnaserror)
FilterAndAppendAndFreeDiagnostics(diagnostics, builder, cancellationToken)
End Sub
Private Sub GetDiagnosticsWithoutFiltering(stage As CompilationStage,
includeEarlierStages As Boolean,
builder As BindingDiagnosticBag,
Optional cancellationToken As CancellationToken = Nothing)
Debug.Assert(builder.AccumulatesDiagnostics)
' Add all parsing errors.
If (stage = CompilationStage.Parse OrElse stage > CompilationStage.Parse AndAlso includeEarlierStages) Then
' Embedded trees shouldn't have any errors, let's avoid making decision if they should be added too early.
' Otherwise IDE performance might be affect.
If Options.ConcurrentBuild Then
RoslynParallel.For(
0,
SyntaxTrees.Length,
UICultureUtilities.WithCurrentUICulture(
Sub(i As Integer)
builder.AddRange(SyntaxTrees(i).GetDiagnostics(cancellationToken))
End Sub),
cancellationToken)
Else
For Each tree In SyntaxTrees
cancellationToken.ThrowIfCancellationRequested()
builder.AddRange(tree.GetDiagnostics(cancellationToken))
Next
End If
Dim parseOptionsReported = New HashSet(Of ParseOptions)
If Options.ParseOptions IsNot Nothing Then
parseOptionsReported.Add(Options.ParseOptions) ' This is reported in Options.Errors at CompilationStage.Declare
End If
For Each tree In SyntaxTrees
cancellationToken.ThrowIfCancellationRequested()
If Not tree.Options.Errors.IsDefaultOrEmpty AndAlso parseOptionsReported.Add(tree.Options) Then
Dim location = tree.GetLocation(TextSpan.FromBounds(0, 0))
For Each err In tree.Options.Errors
builder.Add(err.WithLocation(location))
Next
End If
Next
End If
' Add declaration errors
If (stage = CompilationStage.Declare OrElse stage > CompilationStage.Declare AndAlso includeEarlierStages) Then
CheckAssemblyName(builder.DiagnosticBag)
builder.AddRange(Options.Errors)
builder.AddRange(GetBoundReferenceManager().Diagnostics)
SourceAssembly.GetAllDeclarationErrors(builder, cancellationToken)
AddClsComplianceDiagnostics(builder, cancellationToken)
If EventQueue IsNot Nothing AndAlso SyntaxTrees.Length = 0 Then
EnsureCompilationEventQueueCompleted()
End If
End If
' Add method body compilation errors.
If (stage = CompilationStage.Compile OrElse stage > CompilationStage.Compile AndAlso includeEarlierStages) Then
' Note: this phase does not need to be parallelized because
' it is already implemented in method compiler
Dim methodBodyDiagnostics = New BindingDiagnosticBag(DiagnosticBag.GetInstance(),
If(builder.AccumulatesDependencies, New ConcurrentSet(Of AssemblySymbol), Nothing))
GetDiagnosticsForAllMethodBodies(builder.HasAnyErrors(), methodBodyDiagnostics, doLowering:=False, cancellationToken)
builder.AddRange(methodBodyDiagnostics)
methodBodyDiagnostics.DiagnosticBag.Free()
End If
End Sub
Private Sub AddClsComplianceDiagnostics(diagnostics As BindingDiagnosticBag, cancellationToken As CancellationToken, Optional filterTree As SyntaxTree = Nothing, Optional filterSpanWithinTree As TextSpan? = Nothing)
If filterTree IsNot Nothing Then
ClsComplianceChecker.CheckCompliance(Me, diagnostics, cancellationToken, filterTree, filterSpanWithinTree)
Return
End If
Debug.Assert(filterSpanWithinTree Is Nothing)
If _lazyClsComplianceDiagnostics.IsDefault OrElse _lazyClsComplianceDependencies.IsDefault Then
Dim builder = BindingDiagnosticBag.GetInstance()
ClsComplianceChecker.CheckCompliance(Me, builder, cancellationToken)
Dim result As ImmutableBindingDiagnostic(Of AssemblySymbol) = builder.ToReadOnlyAndFree()
ImmutableInterlocked.InterlockedInitialize(_lazyClsComplianceDependencies, result.Dependencies)
ImmutableInterlocked.InterlockedInitialize(_lazyClsComplianceDiagnostics, result.Diagnostics)
End If
Debug.Assert(Not _lazyClsComplianceDependencies.IsDefault)
Debug.Assert(Not _lazyClsComplianceDiagnostics.IsDefault)
diagnostics.AddRange(New ImmutableBindingDiagnostic(Of AssemblySymbol)(_lazyClsComplianceDiagnostics, _lazyClsComplianceDependencies), allowMismatchInDependencyAccumulation:=True)
End Sub
Private Shared Iterator Function FilterDiagnosticsByLocation(diagnostics As IEnumerable(Of Diagnostic), tree As SyntaxTree, filterSpanWithinTree As TextSpan?) As IEnumerable(Of Diagnostic)
For Each diagnostic In diagnostics
If diagnostic.HasIntersectingLocation(tree, filterSpanWithinTree) Then
Yield diagnostic
End If
Next
End Function
Friend Function GetDiagnosticsForSyntaxTree(stage As CompilationStage,
tree As SyntaxTree,
filterSpanWithinTree As TextSpan?,
includeEarlierStages As Boolean,
Optional cancellationToken As CancellationToken = Nothing) As ImmutableArray(Of Diagnostic)
If Not SyntaxTrees.Contains(tree) Then
Throw New ArgumentException("Cannot GetDiagnosticsForSyntax for a tree that is not part of the compilation", NameOf(tree))
End If
Dim builder = New BindingDiagnosticBag(DiagnosticBag.GetInstance())
If (stage = CompilationStage.Parse OrElse stage > CompilationStage.Parse AndAlso includeEarlierStages) Then
' Add all parsing errors.
cancellationToken.ThrowIfCancellationRequested()
Dim syntaxDiagnostics = tree.GetDiagnostics(cancellationToken)
syntaxDiagnostics = FilterDiagnosticsByLocation(syntaxDiagnostics, tree, filterSpanWithinTree)
builder.AddRange(syntaxDiagnostics)
End If
' Add declaring errors
If (stage = CompilationStage.Declare OrElse stage > CompilationStage.Declare AndAlso includeEarlierStages) Then
Dim declarationDiags = DirectCast(SourceModule, SourceModuleSymbol).GetDeclarationErrorsInTree(tree, filterSpanWithinTree, AddressOf FilterDiagnosticsByLocation, cancellationToken)
Dim filteredDiags = FilterDiagnosticsByLocation(declarationDiags, tree, filterSpanWithinTree)
builder.AddRange(filteredDiags)
AddClsComplianceDiagnostics(builder, cancellationToken, tree, filterSpanWithinTree)
End If
' Add method body declaring errors.
If (stage = CompilationStage.Compile OrElse stage > CompilationStage.Compile AndAlso includeEarlierStages) Then
Dim methodBodyDiagnostics = New BindingDiagnosticBag(DiagnosticBag.GetInstance())
GetDiagnosticsForMethodBodiesInTree(tree, filterSpanWithinTree, builder.HasAnyErrors(), methodBodyDiagnostics, cancellationToken)
' This diagnostics can include diagnostics for initializers that do not belong to the tree.
' Let's filter them out.
If Not methodBodyDiagnostics.DiagnosticBag.IsEmptyWithoutResolution Then
Dim allDiags = methodBodyDiagnostics.DiagnosticBag.AsEnumerableWithoutResolution()
Dim filteredDiags = FilterDiagnosticsByLocation(allDiags, tree, filterSpanWithinTree)
For Each diag In filteredDiags
builder.Add(diag)
Next
End If
End If
Dim result = DiagnosticBag.GetInstance()
FilterAndAppendAndFreeDiagnostics(result, builder.DiagnosticBag, cancellationToken)
Return result.ToReadOnlyAndFree(Of Diagnostic)()
End Function
' Get diagnostics by compiling all method bodies.
Private Sub GetDiagnosticsForAllMethodBodies(hasDeclarationErrors As Boolean, diagnostics As BindingDiagnosticBag, doLowering As Boolean, cancellationToken As CancellationToken)
MethodCompiler.GetCompileDiagnostics(Me, SourceModule.GlobalNamespace, Nothing, Nothing, hasDeclarationErrors, diagnostics, doLowering, cancellationToken)
DocumentationCommentCompiler.WriteDocumentationCommentXml(Me, Nothing, Nothing, diagnostics, cancellationToken)
Me.ReportUnusedImports(Nothing, diagnostics, cancellationToken)
End Sub
' Get diagnostics by compiling all method bodies in the given tree.
Private Sub GetDiagnosticsForMethodBodiesInTree(tree As SyntaxTree, filterSpanWithinTree As TextSpan?, hasDeclarationErrors As Boolean, diagnostics As BindingDiagnosticBag, cancellationToken As CancellationToken)
Dim sourceMod = DirectCast(SourceModule, SourceModuleSymbol)
MethodCompiler.GetCompileDiagnostics(Me,
SourceModule.GlobalNamespace,
tree,
filterSpanWithinTree,
hasDeclarationErrors,
diagnostics,
doLoweringPhase:=False,
cancellationToken)
DocumentationCommentCompiler.WriteDocumentationCommentXml(Me, Nothing, Nothing, diagnostics, cancellationToken, tree, filterSpanWithinTree)
' Report unused import diagnostics only if computing diagnostics for the entire tree.
' Otherwise we cannot determine if a particular directive is used outside of the given sub-span within the tree.
If Not filterSpanWithinTree.HasValue OrElse filterSpanWithinTree.Value = tree.GetRoot(cancellationToken).FullSpan Then
Me.ReportUnusedImports(tree, diagnostics, cancellationToken)
End If
End Sub
Friend Overrides Function CreateAnalyzerDriver(analyzers As ImmutableArray(Of DiagnosticAnalyzer), analyzerManager As AnalyzerManager, severityFilter As SeverityFilter) As AnalyzerDriver
Dim getKind As Func(Of SyntaxNode, SyntaxKind) = Function(node As SyntaxNode) node.Kind
Dim isComment As Func(Of SyntaxTrivia, Boolean) = Function(trivia As SyntaxTrivia) trivia.Kind() = SyntaxKind.CommentTrivia
Return New AnalyzerDriver(Of SyntaxKind)(analyzers, getKind, analyzerManager, severityFilter, isComment)
End Function
#End Region
#Region "Resources"
Protected Overrides Sub AppendDefaultVersionResource(resourceStream As Stream)
Dim fileVersion As String = If(SourceAssembly.FileVersion, SourceAssembly.Identity.Version.ToString())
'for some parameters, alink used to supply whitespace instead of null.
Win32ResourceConversions.AppendVersionToResourceStream(resourceStream,
Not Me.Options.OutputKind.IsApplication(),
fileVersion:=fileVersion,
originalFileName:=Me.SourceModule.Name,
internalName:=Me.SourceModule.Name,
productVersion:=If(SourceAssembly.InformationalVersion, fileVersion),
assemblyVersion:=SourceAssembly.Identity.Version,
fileDescription:=If(SourceAssembly.Title, " "),
legalCopyright:=If(SourceAssembly.Copyright, " "),
legalTrademarks:=SourceAssembly.Trademark,
productName:=SourceAssembly.Product,
comments:=SourceAssembly.Description,
companyName:=SourceAssembly.Company)
End Sub
#End Region
#Region "Emit"
Friend Overrides ReadOnly Property LinkerMajorVersion As Byte
Get
Return &H50
End Get
End Property
Friend Overrides ReadOnly Property IsDelaySigned As Boolean
Get
Return SourceAssembly.IsDelaySigned
End Get
End Property
Friend Overrides ReadOnly Property StrongNameKeys As StrongNameKeys
Get
Return SourceAssembly.StrongNameKeys
End Get
End Property
Friend Overrides Function CreateModuleBuilder(
emitOptions As EmitOptions,
debugEntryPoint As IMethodSymbol,
sourceLinkStream As Stream,
embeddedTexts As IEnumerable(Of EmbeddedText),
manifestResources As IEnumerable(Of ResourceDescription),
testData As CompilationTestData,
diagnostics As DiagnosticBag,
cancellationToken As CancellationToken) As CommonPEModuleBuilder
Return CreateModuleBuilder(
emitOptions,
debugEntryPoint,
sourceLinkStream,
embeddedTexts,
manifestResources,
testData,
diagnostics,
ImmutableArray(Of NamedTypeSymbol).Empty,
cancellationToken)
End Function
Friend Overloads Function CreateModuleBuilder(
emitOptions As EmitOptions,
debugEntryPoint As IMethodSymbol,
sourceLinkStream As Stream,
embeddedTexts As IEnumerable(Of EmbeddedText),
manifestResources As IEnumerable(Of ResourceDescription),
testData As CompilationTestData,
diagnostics As DiagnosticBag,
additionalTypes As ImmutableArray(Of NamedTypeSymbol),
cancellationToken As CancellationToken) As CommonPEModuleBuilder
Debug.Assert(Not IsSubmission OrElse HasCodeToEmit() OrElse
(emitOptions = EmitOptions.Default AndAlso debugEntryPoint Is Nothing AndAlso sourceLinkStream Is Nothing AndAlso
embeddedTexts Is Nothing AndAlso manifestResources Is Nothing AndAlso testData Is Nothing))
' Get the runtime metadata version from the cor library. If this fails we have no reasonable value to give.
Dim runtimeMetadataVersion = GetRuntimeMetadataVersion()
Dim moduleSerializationProperties = ConstructModuleSerializationProperties(emitOptions, runtimeMetadataVersion)
If manifestResources Is Nothing Then
manifestResources = SpecializedCollections.EmptyEnumerable(Of ResourceDescription)()
End If
' if there is no stream to write to, then there is no need for a module
Dim moduleBeingBuilt As PEModuleBuilder
If Options.OutputKind.IsNetModule() Then
Debug.Assert(additionalTypes.IsEmpty)
moduleBeingBuilt = New PENetModuleBuilder(
DirectCast(Me.SourceModule, SourceModuleSymbol),
emitOptions,
moduleSerializationProperties,
manifestResources)
Else
Dim kind = If(Options.OutputKind.IsValid(), Options.OutputKind, OutputKind.DynamicallyLinkedLibrary)
moduleBeingBuilt = New PEAssemblyBuilder(
SourceAssembly,
emitOptions,
kind,
moduleSerializationProperties,
manifestResources,
additionalTypes)
End If
If debugEntryPoint IsNot Nothing Then
moduleBeingBuilt.SetDebugEntryPoint(DirectCast(debugEntryPoint, MethodSymbol), diagnostics)
End If
moduleBeingBuilt.SourceLinkStreamOpt = sourceLinkStream
If embeddedTexts IsNot Nothing Then
moduleBeingBuilt.EmbeddedTexts = embeddedTexts
End If
If testData IsNot Nothing Then
moduleBeingBuilt.SetMethodTestData(testData.Methods)
testData.Module = moduleBeingBuilt
End If
Return moduleBeingBuilt
End Function
Friend Overrides Function CompileMethods(
moduleBuilder As CommonPEModuleBuilder,
emittingPdb As Boolean,
emitMetadataOnly As Boolean,
emitTestCoverageData As Boolean,
diagnostics As DiagnosticBag,
filterOpt As Predicate(Of ISymbolInternal),
cancellationToken As CancellationToken) As Boolean
' The diagnostics should include syntax and declaration errors. We insert these before calling Emitter.Emit, so that we don't emit
' metadata if there are declaration errors or method body errors (but we do insert all errors from method body binding...)
Dim hasDeclarationErrors = Not FilterAndAppendDiagnostics(diagnostics, GetDiagnostics(CompilationStage.Declare, True, cancellationToken), exclude:=Nothing, cancellationToken)
Dim moduleBeingBuilt = DirectCast(moduleBuilder, PEModuleBuilder)
Me.EmbeddedSymbolManager.MarkAllDeferredSymbolsAsReferenced(Me)
' The translation of global imports assumes absence of error symbols.
' We don't need to translate them if there are any declaration errors since
' we are not going to emit the metadata.
If Not hasDeclarationErrors Then
moduleBeingBuilt.TranslateImports(diagnostics)
End If
If emitMetadataOnly Then
If hasDeclarationErrors Then
Return False
End If
If moduleBeingBuilt.SourceModule.HasBadAttributes Then
' If there were errors but no declaration diagnostics, explicitly add a "Failed to emit module" error.
diagnostics.Add(ERRID.ERR_ModuleEmitFailure, NoLocation.Singleton, moduleBeingBuilt.SourceModule.Name,
New LocalizableResourceString(NameOf(CodeAnalysisResources.ModuleHasInvalidAttributes), CodeAnalysisResources.ResourceManager, GetType(CodeAnalysisResources)))
Return False
End If
SynthesizedMetadataCompiler.ProcessSynthesizedMembers(Me, moduleBeingBuilt, cancellationToken)
Else
' start generating PDB checksums if we need to emit PDBs
If (emittingPdb OrElse emitTestCoverageData) AndAlso
Not CreateDebugDocuments(moduleBeingBuilt.DebugDocumentsBuilder, moduleBeingBuilt.EmbeddedTexts, diagnostics) Then
Return False
End If
' Perform initial bind of method bodies in spite of earlier errors. This is the same
' behavior as when calling GetDiagnostics()
' Use a temporary bag so we don't have to refilter pre-existing diagnostics.
Dim methodBodyDiagnosticBag = DiagnosticBag.GetInstance()
MethodCompiler.CompileMethodBodies(
Me,
moduleBeingBuilt,
emittingPdb,
emitTestCoverageData,
hasDeclarationErrors,
filterOpt,
New BindingDiagnosticBag(methodBodyDiagnosticBag),
cancellationToken)
Dim hasMethodBodyErrors As Boolean = Not FilterAndAppendAndFreeDiagnostics(diagnostics, methodBodyDiagnosticBag, cancellationToken)
If hasDeclarationErrors OrElse hasMethodBodyErrors Then
Return False
End If
End If
cancellationToken.ThrowIfCancellationRequested()
' TODO (tomat): XML doc comments diagnostics
Return True
End Function
Friend Overrides Function GenerateResourcesAndDocumentationComments(
moduleBuilder As CommonPEModuleBuilder,
xmlDocStream As Stream,
win32Resources As Stream,
useRawWin32Resources As Boolean,
outputNameOverride As String,
diagnostics As DiagnosticBag,
cancellationToken As CancellationToken) As Boolean
' Use a temporary bag so we don't have to refilter pre-existing diagnostics.
Dim resourceDiagnostics = DiagnosticBag.GetInstance()
SetupWin32Resources(moduleBuilder, win32Resources, useRawWin32Resources, resourceDiagnostics)
' give the name of any added modules, but not the name of the primary module.
ReportManifestResourceDuplicates(
moduleBuilder.ManifestResources,
SourceAssembly.Modules.Skip(1).Select(Function(x) x.Name),
AddedModulesResourceNames(resourceDiagnostics),
resourceDiagnostics)
If Not FilterAndAppendAndFreeDiagnostics(diagnostics, resourceDiagnostics, cancellationToken) Then
Return False
End If
cancellationToken.ThrowIfCancellationRequested()
' Use a temporary bag so we don't have to refilter pre-existing diagnostics.
Dim xmlDiagnostics = DiagnosticBag.GetInstance()
Dim assemblyName = FileNameUtilities.ChangeExtension(outputNameOverride, extension:=Nothing)
DocumentationCommentCompiler.WriteDocumentationCommentXml(Me, assemblyName, xmlDocStream, New BindingDiagnosticBag(xmlDiagnostics), cancellationToken)
Return FilterAndAppendAndFreeDiagnostics(diagnostics, xmlDiagnostics, cancellationToken)
End Function
Private Iterator Function AddedModulesResourceNames(diagnostics As DiagnosticBag) As IEnumerable(Of String)
Dim modules As ImmutableArray(Of ModuleSymbol) = SourceAssembly.Modules
For i As Integer = 1 To modules.Length - 1
Dim m = DirectCast(modules(i), Symbols.Metadata.PE.PEModuleSymbol)
Try
For Each resource In m.Module.GetEmbeddedResourcesOrThrow()
Yield resource.Name
Next
Catch mrEx As BadImageFormatException
diagnostics.Add(ERRID.ERR_UnsupportedModule1, NoLocation.Singleton, m)
End Try
Next
End Function
Friend Overrides Function EmitDifference(
baseline As EmitBaseline,
edits As IEnumerable(Of SemanticEdit),
isAddedSymbol As Func(Of ISymbol, Boolean),
metadataStream As Stream,
ilStream As Stream,
pdbStream As Stream,
testData As CompilationTestData,
cancellationToken As CancellationToken) As EmitDifferenceResult
Return EmitHelpers.EmitDifference(
Me,
baseline,
edits,
isAddedSymbol,
metadataStream,
ilStream,
pdbStream,
testData,
cancellationToken)
End Function
Friend Function GetRuntimeMetadataVersion() As String
Dim corLibrary = TryCast(Assembly.CorLibrary, Symbols.Metadata.PE.PEAssemblySymbol)
Return If(corLibrary Is Nothing, String.Empty, corLibrary.Assembly.ManifestModule.MetadataVersion)
End Function
Friend Overrides Sub AddDebugSourceDocumentsForChecksumDirectives(
documentsBuilder As DebugDocumentsBuilder,
tree As SyntaxTree,
diagnosticBag As DiagnosticBag)
Dim checksumDirectives = tree.GetRoot().GetDirectives(Function(d) d.Kind = SyntaxKind.ExternalChecksumDirectiveTrivia AndAlso
Not d.ContainsDiagnostics)
For Each directive In checksumDirectives
Dim checksumDirective As ExternalChecksumDirectiveTriviaSyntax = DirectCast(directive, ExternalChecksumDirectiveTriviaSyntax)
Dim path = checksumDirective.ExternalSource.ValueText
Dim checkSumText = checksumDirective.Checksum.ValueText
Dim normalizedPath = documentsBuilder.NormalizeDebugDocumentPath(path, basePath:=tree.FilePath)
Dim existingDoc = documentsBuilder.TryGetDebugDocumentForNormalizedPath(normalizedPath)
If existingDoc IsNot Nothing Then
' directive matches a file path on an actual tree.
' Dev12 compiler just ignores the directive in this case which means that
' checksum of the actual tree always wins and no warning is given.
' We will continue doing the same.
If existingDoc.IsComputedChecksum Then
Continue For
End If
Dim sourceInfo = existingDoc.GetSourceInfo()
If CheckSumMatches(checkSumText, sourceInfo.Checksum) Then
Dim guid As Guid = guid.Parse(checksumDirective.Guid.ValueText)
If guid = sourceInfo.ChecksumAlgorithmId Then
' all parts match, nothing to do
Continue For
End If
End If
' did not match to an existing document
' produce a warning and ignore the directive
diagnosticBag.Add(ERRID.WRN_MultipleDeclFileExtChecksum, New SourceLocation(checksumDirective), path)
Else
Dim newDocument = New DebugSourceDocument(
normalizedPath,
DebugSourceDocument.CorSymLanguageTypeBasic,
MakeCheckSumBytes(checksumDirective.Checksum.ValueText),
Guid.Parse(checksumDirective.Guid.ValueText))
documentsBuilder.AddDebugDocument(newDocument)
End If
Next
End Sub
Private Shared Function CheckSumMatches(bytesText As String, bytes As ImmutableArray(Of Byte)) As Boolean
If bytesText.Length <> bytes.Length * 2 Then
Return False
End If
For i As Integer = 0 To bytesText.Length \ 2 - 1
' 1A in text becomes 0x1A
Dim b As Integer = SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2)) * 16 +
SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2 + 1))
If b <> bytes(i) Then
Return False
End If
Next
Return True
End Function
Private Shared Function MakeCheckSumBytes(bytesText As String) As ImmutableArray(Of Byte)
Dim builder As ArrayBuilder(Of Byte) = ArrayBuilder(Of Byte).GetInstance()
For i As Integer = 0 To bytesText.Length \ 2 - 1
' 1A in text becomes 0x1A
Dim b As Byte = CByte(SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2)) * 16 +
SyntaxFacts.IntegralLiteralCharacterValue(bytesText(i * 2 + 1)))
builder.Add(b)
Next
Return builder.ToImmutableAndFree()
End Function
Friend Overrides ReadOnly Property DebugSourceDocumentLanguageId As Guid
Get
Return DebugSourceDocument.CorSymLanguageTypeBasic
End Get
End Property
Friend Overrides Function HasCodeToEmit() As Boolean
For Each syntaxTree In SyntaxTrees
Dim unit = syntaxTree.GetCompilationUnitRoot()
If unit.Members.Count > 0 Then
Return True
End If
Next
Return False
End Function
#End Region
#Region "Common Members"
Protected Overrides Function CommonWithReferences(newReferences As IEnumerable(Of MetadataReference)) As Compilation
Return WithReferences(newReferences)
End Function
Protected Overrides Function CommonWithAssemblyName(assemblyName As String) As Compilation
Return WithAssemblyName(assemblyName)
End Function
Protected Overrides Function CommonWithScriptCompilationInfo(info As ScriptCompilationInfo) As Compilation
Return WithScriptCompilationInfo(DirectCast(info, VisualBasicScriptCompilationInfo))
End Function
Protected Overrides ReadOnly Property CommonAssembly As IAssemblySymbol
Get
Return Me.Assembly
End Get
End Property
Protected Overrides ReadOnly Property CommonGlobalNamespace As INamespaceSymbol
Get
Return Me.GlobalNamespace
End Get
End Property
Protected Overrides ReadOnly Property CommonOptions As CompilationOptions
Get
Return Options
End Get
End Property
Protected Overrides Function CommonGetSemanticModel(syntaxTree As SyntaxTree, ignoreAccessibility As Boolean) As SemanticModel
Return Me.GetSemanticModel(syntaxTree, ignoreAccessibility)
End Function
Protected Overrides ReadOnly Property CommonSyntaxTrees As ImmutableArray(Of SyntaxTree)
Get
Return Me.SyntaxTrees
End Get
End Property
Protected Overrides Function CommonAddSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As Compilation
Dim array = TryCast(trees, SyntaxTree())
If array IsNot Nothing Then
Return Me.AddSyntaxTrees(array)
End If
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
Return Me.AddSyntaxTrees(trees.Cast(Of SyntaxTree)())
End Function
Protected Overrides Function CommonRemoveSyntaxTrees(trees As IEnumerable(Of SyntaxTree)) As Compilation
Dim array = TryCast(trees, SyntaxTree())
If array IsNot Nothing Then
Return Me.RemoveSyntaxTrees(array)
End If
If trees Is Nothing Then
Throw New ArgumentNullException(NameOf(trees))
End If
Return Me.RemoveSyntaxTrees(trees.Cast(Of SyntaxTree)())
End Function
Protected Overrides Function CommonRemoveAllSyntaxTrees() As Compilation
Return Me.RemoveAllSyntaxTrees()
End Function
Protected Overrides Function CommonReplaceSyntaxTree(oldTree As SyntaxTree, newTree As SyntaxTree) As Compilation
Return Me.ReplaceSyntaxTree(oldTree, newTree)
End Function
Protected Overrides Function CommonWithOptions(options As CompilationOptions) As Compilation
Return Me.WithOptions(DirectCast(options, VisualBasicCompilationOptions))
End Function
Protected Overrides Function CommonContainsSyntaxTree(syntaxTree As SyntaxTree) As Boolean
Return Me.ContainsSyntaxTree(syntaxTree)
End Function
Protected Overrides Function CommonGetAssemblyOrModuleSymbol(reference As MetadataReference) As ISymbol
Return Me.GetAssemblyOrModuleSymbol(reference)
End Function
Protected Overrides Function CommonClone() As Compilation
Return Me.Clone()
End Function
Protected Overrides ReadOnly Property CommonSourceModule As IModuleSymbol
Get
Return Me.SourceModule
End Get
End Property
Private Protected Overrides Function CommonGetSpecialType(specialType As SpecialType) As INamedTypeSymbolInternal
Return Me.GetSpecialType(specialType)
End Function
Protected Overrides Function CommonGetCompilationNamespace(namespaceSymbol As INamespaceSymbol) As INamespaceSymbol
Return Me.GetCompilationNamespace(namespaceSymbol)
End Function
Protected Overrides Function CommonGetTypeByMetadataName(metadataName As String) As INamedTypeSymbol
Return Me.GetTypeByMetadataName(metadataName)
End Function
Protected Overrides ReadOnly Property CommonScriptClass As INamedTypeSymbol
Get
Return Me.ScriptClass
End Get
End Property
Protected Overrides Function CommonCreateErrorTypeSymbol(container As INamespaceOrTypeSymbol, name As String, arity As Integer) As INamedTypeSymbol
Return New ExtendedErrorTypeSymbol(
container.EnsureVbSymbolOrNothing(Of NamespaceOrTypeSymbol)(NameOf(container)),
name, arity)
End Function
Protected Overrides Function CommonCreateErrorNamespaceSymbol(container As INamespaceSymbol, name As String) As INamespaceSymbol
Return New MissingNamespaceSymbol(
container.EnsureVbSymbolOrNothing(Of NamespaceSymbol)(NameOf(container)),
name)
End Function
Protected Overrides Function CommonCreateArrayTypeSymbol(elementType As ITypeSymbol, rank As Integer, elementNullableAnnotation As NullableAnnotation) As IArrayTypeSymbol
Return CreateArrayTypeSymbol(elementType.EnsureVbSymbolOrNothing(Of TypeSymbol)(NameOf(elementType)), rank)
End Function
Protected Overrides Function CommonCreateTupleTypeSymbol(elementTypes As ImmutableArray(Of ITypeSymbol),
elementNames As ImmutableArray(Of String),
elementLocations As ImmutableArray(Of Location),
elementNullableAnnotations As ImmutableArray(Of NullableAnnotation)) As INamedTypeSymbol
Dim typesBuilder = ArrayBuilder(Of TypeSymbol).GetInstance(elementTypes.Length)
For i As Integer = 0 To elementTypes.Length - 1
typesBuilder.Add(elementTypes(i).EnsureVbSymbolOrNothing(Of TypeSymbol)($"{NameOf(elementTypes)}[{i}]"))
Next
'no location for the type declaration
Return TupleTypeSymbol.Create(locationOpt:=Nothing,
elementTypes:=typesBuilder.ToImmutableAndFree(),
elementLocations:=elementLocations,
elementNames:=elementNames, compilation:=Me,
shouldCheckConstraints:=False, errorPositions:=Nothing)
End Function
Protected Overrides Function CommonCreateTupleTypeSymbol(
underlyingType As INamedTypeSymbol,
elementNames As ImmutableArray(Of String),
elementLocations As ImmutableArray(Of Location),
elementNullableAnnotations As ImmutableArray(Of NullableAnnotation)) As INamedTypeSymbol
Dim csharpUnderlyingTuple = underlyingType.EnsureVbSymbolOrNothing(Of NamedTypeSymbol)(NameOf(underlyingType))
Dim cardinality As Integer
If Not csharpUnderlyingTuple.IsTupleCompatible(cardinality) Then
Throw New ArgumentException(CodeAnalysisResources.TupleUnderlyingTypeMustBeTupleCompatible, NameOf(underlyingType))
End If
elementNames = CheckTupleElementNames(cardinality, elementNames)
CheckTupleElementLocations(cardinality, elementLocations)
CheckTupleElementNullableAnnotations(cardinality, elementNullableAnnotations)
Return TupleTypeSymbol.Create(
locationOpt:=Nothing,
tupleCompatibleType:=underlyingType.EnsureVbSymbolOrNothing(Of NamedTypeSymbol)(NameOf(underlyingType)),
elementLocations:=elementLocations,
elementNames:=elementNames,
errorPositions:=Nothing)
End Function
Protected Overrides Function CommonCreatePointerTypeSymbol(elementType As ITypeSymbol) As IPointerTypeSymbol
Throw New NotSupportedException(VBResources.ThereAreNoPointerTypesInVB)
End Function
Protected Overrides Function CommonCreateFunctionPointerTypeSymbol(
returnType As ITypeSymbol,
refKind As RefKind,
parameterTypes As ImmutableArray(Of ITypeSymbol),
parameterRefKinds As ImmutableArray(Of RefKind),
callingConvention As System.Reflection.Metadata.SignatureCallingConvention,
callingConventionTypes As ImmutableArray(Of INamedTypeSymbol)) As IFunctionPointerTypeSymbol
Throw New NotSupportedException(VBResources.ThereAreNoFunctionPointerTypesInVB)
End Function
Protected Overrides Function CommonCreateNativeIntegerTypeSymbol(signed As Boolean) As INamedTypeSymbol
Throw New NotSupportedException(VBResources.ThereAreNoNativeIntegerTypesInVB)
End Function
Protected Overrides Function CommonCreateAnonymousTypeSymbol(
memberTypes As ImmutableArray(Of ITypeSymbol),
memberNames As ImmutableArray(Of String),
memberLocations As ImmutableArray(Of Location),
memberIsReadOnly As ImmutableArray(Of Boolean),
memberNullableAnnotations As ImmutableArray(Of CodeAnalysis.NullableAnnotation)) As INamedTypeSymbol
Dim i = 0
For Each t In memberTypes
t.EnsureVbSymbolOrNothing(Of TypeSymbol)($"{NameOf(memberTypes)}({i})")
i = i + 1
Next
Dim fields = ArrayBuilder(Of AnonymousTypeField).GetInstance()
For i = 0 To memberTypes.Length - 1
Dim type = memberTypes(i)
Dim name = memberNames(i)
Dim loc = If(memberLocations.IsDefault, Location.None, memberLocations(i))
Dim isReadOnly = memberIsReadOnly.IsDefault OrElse memberIsReadOnly(i)
fields.Add(New AnonymousTypeField(name, DirectCast(type, TypeSymbol), loc, isReadOnly))
Next
Dim descriptor = New AnonymousTypeDescriptor(
fields.ToImmutableAndFree(), Location.None, isImplicitlyDeclared:=False)
Return Me.AnonymousTypeManager.ConstructAnonymousTypeSymbol(descriptor)
End Function
Protected Overrides ReadOnly Property CommonDynamicType As ITypeSymbol
Get
Throw New NotSupportedException(VBResources.ThereIsNoDynamicTypeInVB)
End Get
End Property
Protected Overrides ReadOnly Property CommonObjectType As INamedTypeSymbol
Get
Return Me.ObjectType
End Get
End Property
Protected Overrides Function CommonGetEntryPoint(cancellationToken As CancellationToken) As IMethodSymbol
Return Me.GetEntryPoint(cancellationToken)
End Function
''' <summary>
''' Return true if there is a source declaration symbol name that meets given predicate.
''' </summary>
Public Overrides Function ContainsSymbolsWithName(predicate As Func(Of String, Boolean), Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As Boolean
If predicate Is Nothing Then
Throw New ArgumentNullException(NameOf(predicate))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return DeclarationTable.ContainsName(MergedRootDeclaration, predicate, filter, cancellationToken)
End Function
''' <summary>
''' Return source declaration symbols whose name meets given predicate.
''' </summary>
Public Overrides Function GetSymbolsWithName(predicate As Func(Of String, Boolean), Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As IEnumerable(Of ISymbol)
If predicate Is Nothing Then
Throw New ArgumentNullException(NameOf(predicate))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return New PredicateSymbolSearcher(Me, filter, predicate, cancellationToken).GetSymbolsWithName()
End Function
#Disable Warning RS0026 ' Do not add multiple public overloads with optional parameters
''' <summary>
''' Return true if there is a source declaration symbol name that matches the provided name.
''' This may be faster than <see cref="ContainsSymbolsWithName(Func(Of String, Boolean),
''' SymbolFilter, CancellationToken)"/> when predicate is just a simple string check.
''' <paramref name="name"/> is case insensitive.
''' </summary>
Public Overrides Function ContainsSymbolsWithName(name As String, Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As Boolean
If name Is Nothing Then
Throw New ArgumentNullException(NameOf(name))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return DeclarationTable.ContainsName(MergedRootDeclaration, name, filter, cancellationToken)
End Function
Public Overrides Function GetSymbolsWithName(name As String, Optional filter As SymbolFilter = SymbolFilter.TypeAndMember, Optional cancellationToken As CancellationToken = Nothing) As IEnumerable(Of ISymbol)
If name Is Nothing Then
Throw New ArgumentNullException(NameOf(name))
End If
If filter = SymbolFilter.None Then
Throw New ArgumentException(VBResources.NoNoneSearchCriteria, NameOf(filter))
End If
Return New NameSymbolSearcher(Me, filter, name, cancellationToken).GetSymbolsWithName()
End Function
#Enable Warning RS0026 ' Do not add multiple public overloads with optional parameters
Friend Overrides Function IsUnreferencedAssemblyIdentityDiagnosticCode(code As Integer) As Boolean
Select Case code
Case ERRID.ERR_UnreferencedAssemblyEvent3,
ERRID.ERR_UnreferencedAssembly3
Return True
Case Else
Return False
End Select
End Function
#End Region
Private MustInherit Class AbstractSymbolSearcher
Private ReadOnly _cache As PooledDictionary(Of Declaration, NamespaceOrTypeSymbol)
Private ReadOnly _compilation As VisualBasicCompilation
Private ReadOnly _includeNamespace As Boolean
Private ReadOnly _includeType As Boolean
Private ReadOnly _includeMember As Boolean
Private ReadOnly _cancellationToken As CancellationToken
Public Sub New(compilation As VisualBasicCompilation, filter As SymbolFilter, cancellationToken As CancellationToken)
_cache = PooledDictionary(Of Declaration, NamespaceOrTypeSymbol).GetInstance()
_compilation = compilation
_includeNamespace = (filter And SymbolFilter.Namespace) = SymbolFilter.Namespace
_includeType = (filter And SymbolFilter.Type) = SymbolFilter.Type
_includeMember = (filter And SymbolFilter.Member) = SymbolFilter.Member
_cancellationToken = cancellationToken
End Sub
Protected MustOverride Function Matches(name As String) As Boolean
Protected MustOverride Function ShouldCheckTypeForMembers(typeDeclaration As MergedTypeDeclaration) As Boolean
Public Function GetSymbolsWithName() As IEnumerable(Of ISymbol)
Dim result = New HashSet(Of ISymbol)()
Dim spine = ArrayBuilder(Of MergedNamespaceOrTypeDeclaration).GetInstance()
AppendSymbolsWithName(spine, _compilation.MergedRootDeclaration, result)
spine.Free()
_cache.Free()
Return result
End Function
Private Sub AppendSymbolsWithName(
spine As ArrayBuilder(Of MergedNamespaceOrTypeDeclaration), current As MergedNamespaceOrTypeDeclaration, [set] As HashSet(Of ISymbol))
If current.Kind = DeclarationKind.Namespace Then
If _includeNamespace AndAlso Matches(current.Name) Then
Dim container = GetSpineSymbol(spine)
Dim symbol = GetSymbol(container, current)
If symbol IsNot Nothing Then
[set].Add(symbol)
End If
End If
Else
If _includeType AndAlso Matches(current.Name) Then
Dim container = GetSpineSymbol(spine)
Dim symbol = GetSymbol(container, current)
If symbol IsNot Nothing Then
[set].Add(symbol)
End If
End If
If _includeMember Then
Dim typeDeclaration = DirectCast(current, MergedTypeDeclaration)
If ShouldCheckTypeForMembers(typeDeclaration) Then
AppendMemberSymbolsWithName(spine, typeDeclaration, [set])
End If
End If
End If
spine.Add(current)
For Each child In current.Children
Dim mergedNamespaceOrType = TryCast(child, MergedNamespaceOrTypeDeclaration)
If mergedNamespaceOrType IsNot Nothing Then
If _includeMember OrElse _includeType OrElse child.Kind = DeclarationKind.Namespace Then
AppendSymbolsWithName(spine, mergedNamespaceOrType, [set])
End If
End If
Next
spine.RemoveAt(spine.Count - 1)
End Sub
Private Sub AppendMemberSymbolsWithName(
spine As ArrayBuilder(Of MergedNamespaceOrTypeDeclaration), mergedType As MergedTypeDeclaration, [set] As HashSet(Of ISymbol))
_cancellationToken.ThrowIfCancellationRequested()
spine.Add(mergedType)
Dim container As NamespaceOrTypeSymbol = Nothing
For Each name In mergedType.MemberNames
If Matches(name) Then
container = If(container, GetSpineSymbol(spine))
If container IsNot Nothing Then
[set].UnionWith(container.GetMembers(name))
End If
End If
Next
spine.RemoveAt(spine.Count - 1)
End Sub
Private Function GetSpineSymbol(spine As ArrayBuilder(Of MergedNamespaceOrTypeDeclaration)) As NamespaceOrTypeSymbol
If spine.Count = 0 Then
Return Nothing
End If
Dim symbol = GetCachedSymbol(spine(spine.Count - 1))
If symbol IsNot Nothing Then
Return symbol
End If
Dim current = TryCast(Me._compilation.GlobalNamespace, NamespaceOrTypeSymbol)
For i = 1 To spine.Count - 1
current = GetSymbol(current, spine(i))
Next
Return current
End Function
Private Function GetCachedSymbol(declaration As MergedNamespaceOrTypeDeclaration) As NamespaceOrTypeSymbol
Dim symbol As NamespaceOrTypeSymbol = Nothing
If Me._cache.TryGetValue(declaration, symbol) Then
Return symbol
End If
Return Nothing
End Function
Private Function GetSymbol(container As NamespaceOrTypeSymbol, declaration As MergedNamespaceOrTypeDeclaration) As NamespaceOrTypeSymbol
If container Is Nothing Then
Return Me._compilation.GlobalNamespace
End If
Dim symbol = GetCachedSymbol(declaration)
If symbol IsNot Nothing Then
Return symbol
End If
If declaration.Kind = DeclarationKind.Namespace Then
AddCache(container.GetMembers(declaration.Name).OfType(Of NamespaceOrTypeSymbol)())
Else
AddCache(container.GetTypeMembers(declaration.Name))
End If
Return GetCachedSymbol(declaration)
End Function
Private Sub AddCache(symbols As IEnumerable(Of NamespaceOrTypeSymbol))
For Each symbol In symbols
Dim mergedNamespace = TryCast(symbol, MergedNamespaceSymbol)
If mergedNamespace IsNot Nothing Then
Me._cache(mergedNamespace.ConstituentNamespaces.OfType(Of SourceNamespaceSymbol).First().MergedDeclaration) = symbol
Continue For
End If
Dim sourceNamespace = TryCast(symbol, SourceNamespaceSymbol)
If sourceNamespace IsNot Nothing Then
Me._cache(sourceNamespace.MergedDeclaration) = sourceNamespace
Continue For
End If
Dim sourceType = TryCast(symbol, SourceMemberContainerTypeSymbol)
If sourceType IsNot Nothing Then
Me._cache(sourceType.TypeDeclaration) = sourceType
End If
Next
End Sub
End Class
Private Class PredicateSymbolSearcher
Inherits AbstractSymbolSearcher
Private ReadOnly _predicate As Func(Of String, Boolean)
Public Sub New(
compilation As VisualBasicCompilation, filter As SymbolFilter, predicate As Func(Of String, Boolean), cancellationToken As CancellationToken)
MyBase.New(compilation, filter, cancellationToken)
_predicate = predicate
End Sub
Protected Overrides Function ShouldCheckTypeForMembers(current As MergedTypeDeclaration) As Boolean
Return True
End Function
Protected Overrides Function Matches(name As String) As Boolean
Return _predicate(name)
End Function
End Class
Private Class NameSymbolSearcher
Inherits AbstractSymbolSearcher
Private ReadOnly _name As String
Public Sub New(
compilation As VisualBasicCompilation, filter As SymbolFilter, name As String, cancellationToken As CancellationToken)
MyBase.New(compilation, filter, cancellationToken)
_name = name
End Sub
Protected Overrides Function ShouldCheckTypeForMembers(current As MergedTypeDeclaration) As Boolean
For Each typeDecl In current.Declarations
If typeDecl.MemberNames.Contains(_name) Then
Return True
End If
Next
Return False
End Function
Protected Overrides Function Matches(name As String) As Boolean
Return IdentifierComparison.Equals(_name, name)
End Function
End Class
End Class
End Namespace
| 1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Portable/Symbols/LexicalSortKey.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Generic
Imports System.Threading
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic.Symbols
''' <summary>
''' A structure used to lexically order symbols. For performance, it's important that this be
''' a STRUCTURE, and be able to be returned from a symbol without doing any additional allocations (even
''' if nothing is cached yet.)
''' </summary>
Friend Structure LexicalSortKey
<Flags()>
Private Enum SyntaxTreeKind As Byte
None = EmbeddedSymbolKind.None
Unset = EmbeddedSymbolKind.Unset
EmbeddedAttribute = EmbeddedSymbolKind.EmbeddedAttribute
VbCore = EmbeddedSymbolKind.VbCore
XmlHelper = EmbeddedSymbolKind.XmlHelper
MyTemplate = EmbeddedSymbolKind.LastValue << 1
End Enum
Private _embeddedKind As SyntaxTreeKind
Private _treeOrdinal As Integer
Private _position As Integer
''' <summary>
''' Embedded kind of the tree.
''' </summary>
Private ReadOnly Property EmbeddedKind As SyntaxTreeKind
Get
Return Me._embeddedKind
End Get
End Property
''' <summary>
''' If -1, symbol is in metadata or embedded or otherwise not it source.
''' Note that TreeOrdinal is only used for EmbeddedSymbolKind.None trees, thus
''' negative ordinals of embedded trees do not interfere
''' </summary>
Public ReadOnly Property TreeOrdinal As Integer
Get
Return Me._treeOrdinal
End Get
End Property
''' <summary>
''' Position within the tree. Doesn't need to exactly match the span returned by Locations, just
''' be good enough to sort. In other words, we don't need to go to extra work to return the location of the identifier,
''' just some syntax location is fine.
'''
''' Negative value indicates that the structure was not initialized yet, is used for lazy
''' initializations only along with LexicalSortKey.NotInitialized
''' </summary>
Public ReadOnly Property Position As Integer
Get
Return Me._position
End Get
End Property
' A location not in source.
Public Shared ReadOnly NotInSource As LexicalSortKey = New LexicalSortKey(SyntaxTreeKind.None, -1, 0)
' A lexical sort key is not initialized yet
Public Shared ReadOnly NotInitialized As LexicalSortKey = New LexicalSortKey() With {._embeddedKind = SyntaxTreeKind.None, ._treeOrdinal = -1, ._position = -1}
Private Sub New(embeddedKind As SyntaxTreeKind, treeOrdinal As Integer, location As Integer)
Debug.Assert(location >= 0)
Debug.Assert(treeOrdinal >= -1)
Debug.Assert(embeddedKind = EmbeddedSymbolKind.None OrElse treeOrdinal = -1)
Me._embeddedKind = embeddedKind
Me._treeOrdinal = treeOrdinal
Me._position = location
End Sub
Private Sub New(embeddedKind As SyntaxTreeKind, tree As SyntaxTree, location As Integer, compilation As VisualBasicCompilation)
Me.New(embeddedKind, If(tree Is Nothing OrElse embeddedKind <> SyntaxTreeKind.None, -1, compilation.GetSyntaxTreeOrdinal(tree)), location)
End Sub
Private Shared Function GetEmbeddedKind(tree As SyntaxTree) As SyntaxTreeKind
Return If(tree Is Nothing,
SyntaxTreeKind.None,
If(tree.IsMyTemplate,
SyntaxTreeKind.MyTemplate,
CType(tree.GetEmbeddedKind(), SyntaxTreeKind)))
End Function
Public Sub New(tree As SyntaxTree, position As Integer, compilation As VisualBasicCompilation)
Me.New(GetEmbeddedKind(tree), tree, position, compilation)
End Sub
Public Sub New(syntaxRef As SyntaxReference, compilation As VisualBasicCompilation)
Me.New(syntaxRef.SyntaxTree, syntaxRef.Span.Start, compilation)
End Sub
''' <summary>
''' WARNING: Only use this if the location is obtainable without allocating it (even if cached later). E.g., only
''' if the location object is stored in the constructor of the symbol.
''' </summary>
Public Sub New(location As Location, compilation As VisualBasicCompilation)
If location Is Nothing Then
Me._embeddedKind = SyntaxTreeKind.None
Me._treeOrdinal = -1
Me._position = 0
Else
Debug.Assert(location.PossiblyEmbeddedOrMySourceSpan.Start >= 0)
Dim tree = DirectCast(location.PossiblyEmbeddedOrMySourceTree, VisualBasicSyntaxTree)
Debug.Assert(tree Is Nothing OrElse tree.GetEmbeddedKind = location.EmbeddedKind)
Dim treeKind As SyntaxTreeKind = GetEmbeddedKind(tree)
If treeKind <> SyntaxTreeKind.None Then
Me._embeddedKind = treeKind
Me._treeOrdinal = -1
Else
Me._embeddedKind = SyntaxTreeKind.None
Me._treeOrdinal = If(tree Is Nothing, -1, compilation.GetSyntaxTreeOrdinal(tree))
End If
Me._position = location.PossiblyEmbeddedOrMySourceSpan.Start
End If
End Sub
''' <summary>
''' WARNING: Only use this if the node is obtainable without allocating it (even if cached later). E.g., only
''' if the node is stored in the constructor of the symbol. In particular, do not call this on the result of a GetSyntax()
''' call on a SyntaxReference.
''' </summary>
Public Sub New(node As VisualBasicSyntaxNode, compilation As VisualBasicCompilation)
Me.New(node.SyntaxTree, node.SpanStart, compilation)
End Sub
''' <summary>
''' WARNING: Only use this if the token is obtainable without allocating it (even if cached later). E.g., only
''' if the node is stored in the constructor of the symbol. In particular, do not call this on the result of a GetSyntax()
''' call on a SyntaxReference.
''' </summary>
Public Sub New(token As SyntaxToken, compilation As VisualBasicCompilation)
Me.New(DirectCast(token.SyntaxTree, VisualBasicSyntaxTree), token.SpanStart, compilation)
End Sub
''' <summary>
''' Compare two lexical sort keys in a compilation.
''' </summary>
Public Shared Function Compare(ByRef xSortKey As LexicalSortKey, ByRef ySortKey As LexicalSortKey) As Integer
Debug.Assert(xSortKey.EmbeddedKind <> EmbeddedSymbolKind.Unset)
Debug.Assert(ySortKey.EmbeddedKind <> EmbeddedSymbolKind.Unset)
Dim comparison As Integer
If xSortKey.EmbeddedKind <> ySortKey.EmbeddedKind Then
' Embedded sort before non-embedded.
Return If(ySortKey.EmbeddedKind > xSortKey.EmbeddedKind, 1, -1)
End If
If xSortKey.EmbeddedKind = EmbeddedSymbolKind.None AndAlso xSortKey.TreeOrdinal <> ySortKey.TreeOrdinal Then
If xSortKey.TreeOrdinal < 0 Then
Return 1
ElseIf ySortKey.TreeOrdinal < 0 Then
Return -1
End If
comparison = xSortKey.TreeOrdinal - ySortKey.TreeOrdinal
Debug.Assert(comparison <> 0)
Return comparison
End If
Return xSortKey.Position - ySortKey.Position
End Function
Public Shared Function Compare(first As Location, second As Location, compilation As VisualBasicCompilation) As Integer
Debug.Assert(first.IsInSource OrElse first.IsEmbeddedOrMyTemplateLocation())
Debug.Assert(second.IsInSource OrElse second.IsEmbeddedOrMyTemplateLocation())
' This is a shortcut to avoid building complete keys for the case when both locations belong to the same tree.
' Also saves us in some speculative SemanticModel scenarios when the tree we are dealing with doesn't belong to
' the compilation and an attempt of building the LexicalSortKey will simply assert and crash.
If first.SourceTree IsNot Nothing AndAlso first.SourceTree Is second.SourceTree Then
Return first.PossiblyEmbeddedOrMySourceSpan.Start - second.PossiblyEmbeddedOrMySourceSpan.Start
End If
Dim firstKey = New LexicalSortKey(first, compilation)
Dim secondKey = New LexicalSortKey(second, compilation)
Return LexicalSortKey.Compare(firstKey, secondKey)
End Function
Public Shared Function Compare(first As SyntaxReference, second As SyntaxReference, compilation As VisualBasicCompilation) As Integer
' This is a shortcut to avoid building complete keys for the case when both locations belong to the same tree.
' Also saves us in some speculative SemanticModel scenarios when the tree we are dealing with doesn't belong to
' the compilation and an attempt of building the LexicalSortKey will simply assert and crash.
If first.SyntaxTree IsNot Nothing AndAlso first.SyntaxTree Is second.SyntaxTree Then
Return first.Span.Start - second.Span.Start
End If
Dim firstKey = New LexicalSortKey(first, compilation)
Dim secondKey = New LexicalSortKey(second, compilation)
Return LexicalSortKey.Compare(firstKey, secondKey)
End Function
Public Shared Function First(xSortKey As LexicalSortKey, ySortKey As LexicalSortKey) As LexicalSortKey
Dim comparison As Integer = Compare(xSortKey, ySortKey)
Return If(comparison > 0, ySortKey, xSortKey)
End Function
Public ReadOnly Property IsInitialized As Boolean
Get
Return Volatile.Read(Me._position) >= 0
End Get
End Property
Public Sub SetFrom(ByRef other As LexicalSortKey)
Debug.Assert(other.IsInitialized)
Me._embeddedKind = other._embeddedKind
Me._treeOrdinal = other._treeOrdinal
Volatile.Write(Me._position, other._position)
End Sub
End Structure
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Generic
Imports System.Threading
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic.Symbols
''' <summary>
''' A structure used to lexically order symbols. For performance, it's important that this be
''' a STRUCTURE, and be able to be returned from a symbol without doing any additional allocations (even
''' if nothing is cached yet.)
''' </summary>
Friend Structure LexicalSortKey
<Flags()>
Private Enum SyntaxTreeKind As Byte
None = EmbeddedSymbolKind.None
Unset = EmbeddedSymbolKind.Unset
EmbeddedAttribute = EmbeddedSymbolKind.EmbeddedAttribute
VbCore = EmbeddedSymbolKind.VbCore
XmlHelper = EmbeddedSymbolKind.XmlHelper
MyTemplate = EmbeddedSymbolKind.LastValue << 1
End Enum
Private _embeddedKind As SyntaxTreeKind
Private _treeOrdinal As Integer
Private _position As Integer
''' <summary>
''' Embedded kind of the tree.
''' </summary>
Private ReadOnly Property EmbeddedKind As SyntaxTreeKind
Get
Return Me._embeddedKind
End Get
End Property
''' <summary>
''' If -1, symbol is in metadata or embedded or otherwise not it source.
''' Note that TreeOrdinal is only used for EmbeddedSymbolKind.None trees, thus
''' negative ordinals of embedded trees do not interfere
''' </summary>
Public ReadOnly Property TreeOrdinal As Integer
Get
Return Me._treeOrdinal
End Get
End Property
''' <summary>
''' Position within the tree. Doesn't need to exactly match the span returned by Locations, just
''' be good enough to sort. In other words, we don't need to go to extra work to return the location of the identifier,
''' just some syntax location is fine.
'''
''' Negative value indicates that the structure was not initialized yet, is used for lazy
''' initializations only along with LexicalSortKey.NotInitialized
''' </summary>
Public ReadOnly Property Position As Integer
Get
Return Me._position
End Get
End Property
' A location not in source.
Public Shared ReadOnly NotInSource As LexicalSortKey = New LexicalSortKey(SyntaxTreeKind.None, -1, 0)
' A lexical sort key is not initialized yet
Public Shared ReadOnly NotInitialized As LexicalSortKey = New LexicalSortKey() With {._embeddedKind = SyntaxTreeKind.None, ._treeOrdinal = -1, ._position = -1}
Private Sub New(embeddedKind As SyntaxTreeKind, treeOrdinal As Integer, location As Integer)
Debug.Assert(location >= 0)
Debug.Assert(treeOrdinal >= -1)
Debug.Assert(embeddedKind = EmbeddedSymbolKind.None OrElse treeOrdinal = -1)
Me._embeddedKind = embeddedKind
Me._treeOrdinal = treeOrdinal
Me._position = location
End Sub
Private Sub New(embeddedKind As SyntaxTreeKind, tree As SyntaxTree, location As Integer, compilation As VisualBasicCompilation)
Me.New(embeddedKind, If(tree Is Nothing OrElse embeddedKind <> SyntaxTreeKind.None, -1, compilation.GetSyntaxTreeOrdinal(tree)), location)
End Sub
Private Shared Function GetEmbeddedKind(tree As SyntaxTree) As SyntaxTreeKind
Return If(tree Is Nothing,
SyntaxTreeKind.None,
If(tree.IsMyTemplate,
SyntaxTreeKind.MyTemplate,
CType(tree.GetEmbeddedKind(), SyntaxTreeKind)))
End Function
Public Sub New(tree As SyntaxTree, position As Integer, compilation As VisualBasicCompilation)
Me.New(GetEmbeddedKind(tree), tree, position, compilation)
End Sub
Public Sub New(syntaxRef As SyntaxReference, compilation As VisualBasicCompilation)
Me.New(syntaxRef.SyntaxTree, syntaxRef.Span.Start, compilation)
End Sub
''' <summary>
''' WARNING: Only use this if the location is obtainable without allocating it (even if cached later). E.g., only
''' if the location object is stored in the constructor of the symbol.
''' </summary>
Public Sub New(location As Location, compilation As VisualBasicCompilation)
If location Is Nothing Then
Me._embeddedKind = SyntaxTreeKind.None
Me._treeOrdinal = -1
Me._position = 0
Else
Debug.Assert(location.PossiblyEmbeddedOrMySourceSpan.Start >= 0)
Dim tree = DirectCast(location.PossiblyEmbeddedOrMySourceTree, VisualBasicSyntaxTree)
Debug.Assert(tree Is Nothing OrElse tree.GetEmbeddedKind = location.EmbeddedKind)
Dim treeKind As SyntaxTreeKind = GetEmbeddedKind(tree)
If treeKind <> SyntaxTreeKind.None Then
Me._embeddedKind = treeKind
Me._treeOrdinal = -1
Else
Me._embeddedKind = SyntaxTreeKind.None
Me._treeOrdinal = If(tree Is Nothing, -1, compilation.GetSyntaxTreeOrdinal(tree))
End If
Me._position = location.PossiblyEmbeddedOrMySourceSpan.Start
End If
End Sub
''' <summary>
''' WARNING: Only use this if the node is obtainable without allocating it (even if cached later). E.g., only
''' if the node is stored in the constructor of the symbol. In particular, do not call this on the result of a GetSyntax()
''' call on a SyntaxReference.
''' </summary>
Public Sub New(node As VisualBasicSyntaxNode, compilation As VisualBasicCompilation)
Me.New(node.SyntaxTree, node.SpanStart, compilation)
End Sub
''' <summary>
''' WARNING: Only use this if the token is obtainable without allocating it (even if cached later). E.g., only
''' if the node is stored in the constructor of the symbol. In particular, do not call this on the result of a GetSyntax()
''' call on a SyntaxReference.
''' </summary>
Public Sub New(token As SyntaxToken, compilation As VisualBasicCompilation)
Me.New(DirectCast(token.SyntaxTree, VisualBasicSyntaxTree), token.SpanStart, compilation)
End Sub
''' <summary>
''' Compare two lexical sort keys in a compilation.
''' </summary>
Public Shared Function Compare(ByRef xSortKey As LexicalSortKey, ByRef ySortKey As LexicalSortKey) As Integer
Debug.Assert(xSortKey.EmbeddedKind <> EmbeddedSymbolKind.Unset)
Debug.Assert(ySortKey.EmbeddedKind <> EmbeddedSymbolKind.Unset)
Dim comparison As Integer
If xSortKey.EmbeddedKind <> ySortKey.EmbeddedKind Then
' Embedded sort before non-embedded.
Return If(ySortKey.EmbeddedKind > xSortKey.EmbeddedKind, 1, -1)
End If
If xSortKey.EmbeddedKind = EmbeddedSymbolKind.None AndAlso xSortKey.TreeOrdinal <> ySortKey.TreeOrdinal Then
If xSortKey.TreeOrdinal < 0 Then
Return 1
ElseIf ySortKey.TreeOrdinal < 0 Then
Return -1
End If
comparison = xSortKey.TreeOrdinal - ySortKey.TreeOrdinal
Debug.Assert(comparison <> 0)
Return comparison
End If
Return xSortKey.Position - ySortKey.Position
End Function
Public Shared Function Compare(first As Location, second As Location, compilation As VisualBasicCompilation) As Integer
Debug.Assert(first.IsInSource OrElse first.IsEmbeddedOrMyTemplateLocation())
Debug.Assert(second.IsInSource OrElse second.IsEmbeddedOrMyTemplateLocation())
' This is a shortcut to avoid building complete keys for the case when both locations belong to the same tree.
' Also saves us in some speculative SemanticModel scenarios when the tree we are dealing with doesn't belong to
' the compilation and an attempt of building the LexicalSortKey will simply assert and crash.
If first.SourceTree IsNot Nothing AndAlso first.SourceTree Is second.SourceTree Then
Return first.PossiblyEmbeddedOrMySourceSpan.Start - second.PossiblyEmbeddedOrMySourceSpan.Start
End If
Dim firstKey = New LexicalSortKey(first, compilation)
Dim secondKey = New LexicalSortKey(second, compilation)
Return LexicalSortKey.Compare(firstKey, secondKey)
End Function
Public Shared Function Compare(first As SyntaxReference, second As SyntaxReference, compilation As VisualBasicCompilation) As Integer
' This is a shortcut to avoid building complete keys for the case when both locations belong to the same tree.
' Also saves us in some speculative SemanticModel scenarios when the tree we are dealing with doesn't belong to
' the compilation and an attempt of building the LexicalSortKey will simply assert and crash.
If first.SyntaxTree IsNot Nothing AndAlso first.SyntaxTree Is second.SyntaxTree Then
Return first.Span.Start - second.Span.Start
End If
Dim firstKey = New LexicalSortKey(first, compilation)
Dim secondKey = New LexicalSortKey(second, compilation)
Return LexicalSortKey.Compare(firstKey, secondKey)
End Function
Public Shared Function Compare(first As SyntaxNode, second As SyntaxNode, compilation As VisualBasicCompilation) As Integer
' This is a shortcut to avoid building complete keys for the case when both locations belong to the same tree.
' Also saves us in some speculative SemanticModel scenarios when the tree we are dealing with doesn't belong to
' the compilation and an attempt of building the LexicalSortKey will simply assert and crash.
If first.SyntaxTree IsNot Nothing AndAlso first.SyntaxTree Is second.SyntaxTree Then
Return first.Span.Start - second.Span.Start
End If
Dim firstKey = New LexicalSortKey(first.SyntaxTree, first.SpanStart, compilation)
Dim secondKey = New LexicalSortKey(second.SyntaxTree, second.SpanStart, compilation)
Return LexicalSortKey.Compare(firstKey, secondKey)
End Function
Public Shared Function First(xSortKey As LexicalSortKey, ySortKey As LexicalSortKey) As LexicalSortKey
Dim comparison As Integer = Compare(xSortKey, ySortKey)
Return If(comparison > 0, ySortKey, xSortKey)
End Function
Public ReadOnly Property IsInitialized As Boolean
Get
Return Volatile.Read(Me._position) >= 0
End Get
End Property
Public Sub SetFrom(ByRef other As LexicalSortKey)
Debug.Assert(other.IsInitialized)
Me._embeddedKind = other._embeddedKind
Me._treeOrdinal = other._treeOrdinal
Volatile.Write(Me._position, other._position)
End Sub
End Structure
End Namespace
| 1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Core/Portable/CodeGen/LambdaDebugInfo.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Diagnostics;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CodeGen
{
/// <summary>
/// Debug information maintained for each lambda.
/// </summary>
/// <remarks>
/// The information is emitted to PDB in Custom Debug Information record for a method containing the lambda.
/// </remarks>
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
internal struct LambdaDebugInfo : IEquatable<LambdaDebugInfo>
{
/// <summary>
/// The syntax offset of the syntax node declaring the lambda (lambda expression) or its body (lambda in a query).
/// </summary>
public readonly int SyntaxOffset;
/// <summary>
/// The ordinal of the closure frame the lambda belongs to, or
/// <see cref="StaticClosureOrdinal"/> if the lambda is static, or
/// <see cref="ThisOnlyClosureOrdinal"/> if the lambda is closed over "this" pointer only.
/// </summary>
public readonly int ClosureOrdinal;
public readonly DebugId LambdaId;
public const int StaticClosureOrdinal = -1;
public const int ThisOnlyClosureOrdinal = -2;
public const int MinClosureOrdinal = ThisOnlyClosureOrdinal;
public LambdaDebugInfo(int syntaxOffset, DebugId lambdaId, int closureOrdinal)
{
Debug.Assert(closureOrdinal >= MinClosureOrdinal);
SyntaxOffset = syntaxOffset;
ClosureOrdinal = closureOrdinal;
LambdaId = lambdaId;
}
public bool Equals(LambdaDebugInfo other)
{
return SyntaxOffset == other.SyntaxOffset
&& ClosureOrdinal == other.ClosureOrdinal
&& LambdaId.Equals(other.LambdaId);
}
public override bool Equals(object? obj)
{
return obj is LambdaDebugInfo && Equals((LambdaDebugInfo)obj);
}
public override int GetHashCode()
{
return Hash.Combine(ClosureOrdinal,
Hash.Combine(SyntaxOffset, LambdaId.GetHashCode()));
}
internal string GetDebuggerDisplay()
{
return
ClosureOrdinal == StaticClosureOrdinal ? $"({LambdaId.GetDebuggerDisplay()} @{SyntaxOffset}, static)" :
ClosureOrdinal == ThisOnlyClosureOrdinal ? $"(#{LambdaId.GetDebuggerDisplay()} @{SyntaxOffset}, this)" :
$"({LambdaId.GetDebuggerDisplay()} @{SyntaxOffset} in {ClosureOrdinal})";
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Diagnostics;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CodeGen
{
/// <summary>
/// Debug information maintained for each lambda.
/// </summary>
/// <remarks>
/// The information is emitted to PDB in Custom Debug Information record for a method containing the lambda.
/// </remarks>
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
internal struct LambdaDebugInfo : IEquatable<LambdaDebugInfo>
{
/// <summary>
/// The syntax offset of the syntax node declaring the lambda (lambda expression) or its body (lambda in a query).
/// </summary>
public readonly int SyntaxOffset;
/// <summary>
/// The ordinal of the closure frame the lambda belongs to, or
/// <see cref="StaticClosureOrdinal"/> if the lambda is static, or
/// <see cref="ThisOnlyClosureOrdinal"/> if the lambda is closed over "this" pointer only.
/// </summary>
public readonly int ClosureOrdinal;
public readonly DebugId LambdaId;
public const int StaticClosureOrdinal = -1;
public const int ThisOnlyClosureOrdinal = -2;
public const int MinClosureOrdinal = ThisOnlyClosureOrdinal;
public LambdaDebugInfo(int syntaxOffset, DebugId lambdaId, int closureOrdinal)
{
Debug.Assert(closureOrdinal >= MinClosureOrdinal);
SyntaxOffset = syntaxOffset;
ClosureOrdinal = closureOrdinal;
LambdaId = lambdaId;
}
public bool Equals(LambdaDebugInfo other)
{
return SyntaxOffset == other.SyntaxOffset
&& ClosureOrdinal == other.ClosureOrdinal
&& LambdaId.Equals(other.LambdaId);
}
public override bool Equals(object? obj)
{
return obj is LambdaDebugInfo && Equals((LambdaDebugInfo)obj);
}
public override int GetHashCode()
{
return Hash.Combine(ClosureOrdinal,
Hash.Combine(SyntaxOffset, LambdaId.GetHashCode()));
}
internal string GetDebuggerDisplay()
{
return
ClosureOrdinal == StaticClosureOrdinal ? $"({LambdaId.GetDebuggerDisplay()} @{SyntaxOffset}, static)" :
ClosureOrdinal == ThisOnlyClosureOrdinal ? $"(#{LambdaId.GetDebuggerDisplay()} @{SyntaxOffset}, this)" :
$"({LambdaId.GetDebuggerDisplay()} @{SyntaxOffset} in {ClosureOrdinal})";
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Core/Def/Implementation/TableDataSource/MiscellaneousDiagnosticListTable.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Composition;
using System.Linq;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Host.Mef;
using Microsoft.CodeAnalysis.Options;
using Microsoft.VisualStudio.Shell.TableManager;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.TableDataSource
{
[ExportEventListener(WellKnownEventListeners.DiagnosticService, WorkspaceKind.MiscellaneousFiles), Shared]
internal sealed class MiscellaneousDiagnosticListTableWorkspaceEventListener : IEventListener<IDiagnosticService>
{
internal const string IdentifierString = nameof(MiscellaneousDiagnosticListTable);
private readonly ITableManagerProvider _tableManagerProvider;
private readonly IGlobalOptionService _globalOptions;
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public MiscellaneousDiagnosticListTableWorkspaceEventListener(
ITableManagerProvider tableManagerProvider,
IGlobalOptionService globalOptions)
{
_tableManagerProvider = tableManagerProvider;
_globalOptions = globalOptions;
}
public void StartListening(Workspace workspace, IDiagnosticService diagnosticService)
=> new MiscellaneousDiagnosticListTable(workspace, _globalOptions, diagnosticService, _tableManagerProvider);
private sealed class MiscellaneousDiagnosticListTable : VisualStudioBaseDiagnosticListTable
{
private readonly LiveTableDataSource _source;
public MiscellaneousDiagnosticListTable(Workspace workspace, IGlobalOptionService globalOptions, IDiagnosticService diagnosticService, ITableManagerProvider provider)
: base(workspace, provider)
{
_source = new LiveTableDataSource(workspace, globalOptions, diagnosticService, IdentifierString);
AddInitialTableSource(workspace.CurrentSolution, _source);
ConnectWorkspaceEvents();
}
protected override void AddTableSourceIfNecessary(Solution solution)
{
if (solution.ProjectIds.Count == 0 || this.TableManager.Sources.Any(s => s == _source))
{
return;
}
AddTableSource(_source);
}
protected override void RemoveTableSourceIfNecessary(Solution solution)
{
if (solution.ProjectIds.Count > 0 || !this.TableManager.Sources.Any(s => s == _source))
{
return;
}
this.TableManager.RemoveSource(_source);
}
protected override void ShutdownSource()
=> _source.Shutdown();
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Composition;
using System.Linq;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Host.Mef;
using Microsoft.CodeAnalysis.Options;
using Microsoft.VisualStudio.Shell.TableManager;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.TableDataSource
{
[ExportEventListener(WellKnownEventListeners.DiagnosticService, WorkspaceKind.MiscellaneousFiles), Shared]
internal sealed class MiscellaneousDiagnosticListTableWorkspaceEventListener : IEventListener<IDiagnosticService>
{
internal const string IdentifierString = nameof(MiscellaneousDiagnosticListTable);
private readonly ITableManagerProvider _tableManagerProvider;
private readonly IGlobalOptionService _globalOptions;
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public MiscellaneousDiagnosticListTableWorkspaceEventListener(
ITableManagerProvider tableManagerProvider,
IGlobalOptionService globalOptions)
{
_tableManagerProvider = tableManagerProvider;
_globalOptions = globalOptions;
}
public void StartListening(Workspace workspace, IDiagnosticService diagnosticService)
=> new MiscellaneousDiagnosticListTable(workspace, _globalOptions, diagnosticService, _tableManagerProvider);
private sealed class MiscellaneousDiagnosticListTable : VisualStudioBaseDiagnosticListTable
{
private readonly LiveTableDataSource _source;
public MiscellaneousDiagnosticListTable(Workspace workspace, IGlobalOptionService globalOptions, IDiagnosticService diagnosticService, ITableManagerProvider provider)
: base(workspace, provider)
{
_source = new LiveTableDataSource(workspace, globalOptions, diagnosticService, IdentifierString);
AddInitialTableSource(workspace.CurrentSolution, _source);
ConnectWorkspaceEvents();
}
protected override void AddTableSourceIfNecessary(Solution solution)
{
if (solution.ProjectIds.Count == 0 || this.TableManager.Sources.Any(s => s == _source))
{
return;
}
AddTableSource(_source);
}
protected override void RemoveTableSourceIfNecessary(Solution solution)
{
if (solution.ProjectIds.Count > 0 || !this.TableManager.Sources.Any(s => s == _source))
{
return;
}
this.TableManager.RemoveSource(_source);
}
protected override void ShutdownSource()
=> _source.Shutdown();
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Core/Portable/InternalUtilities/CommandLineUtilities.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Text;
namespace Roslyn.Utilities
{
internal static class CommandLineUtilities
{
/// <summary>
/// Split a command line by the same rules as Main would get the commands except the original
/// state of backslashes and quotes are preserved. For example in normal Windows command line
/// parsing the following command lines would produce equivalent Main arguments:
///
/// - /r:a,b
/// - /r:"a,b"
///
/// This method will differ as the latter will have the quotes preserved. The only case where
/// quotes are removed is when the entire argument is surrounded by quotes without any inner
/// quotes.
/// </summary>
/// <remarks>
/// Rules for command line parsing, according to MSDN:
///
/// Arguments are delimited by white space, which is either a space or a tab.
///
/// A string surrounded by double quotation marks ("string") is interpreted
/// as a single argument, regardless of white space contained within.
/// A quoted string can be embedded in an argument.
///
/// A double quotation mark preceded by a backslash (\") is interpreted as a
/// literal double quotation mark character (").
///
/// Backslashes are interpreted literally, unless they immediately precede a
/// double quotation mark.
///
/// If an even number of backslashes is followed by a double quotation mark,
/// one backslash is placed in the argv array for every pair of backslashes,
/// and the double quotation mark is interpreted as a string delimiter.
///
/// If an odd number of backslashes is followed by a double quotation mark,
/// one backslash is placed in the argv array for every pair of backslashes,
/// and the double quotation mark is "escaped" by the remaining backslash,
/// causing a literal double quotation mark (") to be placed in argv.
/// </remarks>
public static List<string> SplitCommandLineIntoArguments(string commandLine, bool removeHashComments)
{
return SplitCommandLineIntoArguments(commandLine, removeHashComments, out _);
}
public static List<string> SplitCommandLineIntoArguments(string commandLine, bool removeHashComments, out char? illegalChar)
{
var list = new List<string>();
SplitCommandLineIntoArguments(commandLine.AsSpan(), removeHashComments, new StringBuilder(), list, out illegalChar);
return list;
}
public static void SplitCommandLineIntoArguments(ReadOnlySpan<char> commandLine, bool removeHashComments, StringBuilder builder, List<string> list, out char? illegalChar)
{
var i = 0;
builder.Length = 0;
illegalChar = null;
while (i < commandLine.Length)
{
while (i < commandLine.Length && char.IsWhiteSpace(commandLine[i]))
{
i++;
}
if (i == commandLine.Length)
{
break;
}
if (commandLine[i] == '#' && removeHashComments)
{
break;
}
var quoteCount = 0;
builder.Length = 0;
while (i < commandLine.Length && (!char.IsWhiteSpace(commandLine[i]) || (quoteCount % 2 != 0)))
{
var current = commandLine[i];
switch (current)
{
case '\\':
{
var slashCount = 0;
do
{
builder.Append(commandLine[i]);
i++;
slashCount++;
} while (i < commandLine.Length && commandLine[i] == '\\');
// Slashes not followed by a quote character can be ignored for now
if (i >= commandLine.Length || commandLine[i] != '"')
{
break;
}
// If there is an odd number of slashes then it is escaping the quote
// otherwise it is just a quote.
if (slashCount % 2 == 0)
{
quoteCount++;
}
builder.Append('"');
i++;
break;
}
case '"':
builder.Append(current);
quoteCount++;
i++;
break;
default:
if ((current >= 0x1 && current <= 0x1f) || current == '|')
{
if (illegalChar == null)
{
illegalChar = current;
}
}
else
{
builder.Append(current);
}
i++;
break;
}
}
// If the quote string is surrounded by quotes with no interior quotes then
// remove the quotes here.
if (quoteCount == 2 && builder[0] == '"' && builder[builder.Length - 1] == '"')
{
builder.Remove(0, length: 1);
builder.Remove(builder.Length - 1, length: 1);
}
if (builder.Length > 0)
{
list.Add(builder.ToString());
}
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Text;
namespace Roslyn.Utilities
{
internal static class CommandLineUtilities
{
/// <summary>
/// Split a command line by the same rules as Main would get the commands except the original
/// state of backslashes and quotes are preserved. For example in normal Windows command line
/// parsing the following command lines would produce equivalent Main arguments:
///
/// - /r:a,b
/// - /r:"a,b"
///
/// This method will differ as the latter will have the quotes preserved. The only case where
/// quotes are removed is when the entire argument is surrounded by quotes without any inner
/// quotes.
/// </summary>
/// <remarks>
/// Rules for command line parsing, according to MSDN:
///
/// Arguments are delimited by white space, which is either a space or a tab.
///
/// A string surrounded by double quotation marks ("string") is interpreted
/// as a single argument, regardless of white space contained within.
/// A quoted string can be embedded in an argument.
///
/// A double quotation mark preceded by a backslash (\") is interpreted as a
/// literal double quotation mark character (").
///
/// Backslashes are interpreted literally, unless they immediately precede a
/// double quotation mark.
///
/// If an even number of backslashes is followed by a double quotation mark,
/// one backslash is placed in the argv array for every pair of backslashes,
/// and the double quotation mark is interpreted as a string delimiter.
///
/// If an odd number of backslashes is followed by a double quotation mark,
/// one backslash is placed in the argv array for every pair of backslashes,
/// and the double quotation mark is "escaped" by the remaining backslash,
/// causing a literal double quotation mark (") to be placed in argv.
/// </remarks>
public static List<string> SplitCommandLineIntoArguments(string commandLine, bool removeHashComments)
{
return SplitCommandLineIntoArguments(commandLine, removeHashComments, out _);
}
public static List<string> SplitCommandLineIntoArguments(string commandLine, bool removeHashComments, out char? illegalChar)
{
var list = new List<string>();
SplitCommandLineIntoArguments(commandLine.AsSpan(), removeHashComments, new StringBuilder(), list, out illegalChar);
return list;
}
public static void SplitCommandLineIntoArguments(ReadOnlySpan<char> commandLine, bool removeHashComments, StringBuilder builder, List<string> list, out char? illegalChar)
{
var i = 0;
builder.Length = 0;
illegalChar = null;
while (i < commandLine.Length)
{
while (i < commandLine.Length && char.IsWhiteSpace(commandLine[i]))
{
i++;
}
if (i == commandLine.Length)
{
break;
}
if (commandLine[i] == '#' && removeHashComments)
{
break;
}
var quoteCount = 0;
builder.Length = 0;
while (i < commandLine.Length && (!char.IsWhiteSpace(commandLine[i]) || (quoteCount % 2 != 0)))
{
var current = commandLine[i];
switch (current)
{
case '\\':
{
var slashCount = 0;
do
{
builder.Append(commandLine[i]);
i++;
slashCount++;
} while (i < commandLine.Length && commandLine[i] == '\\');
// Slashes not followed by a quote character can be ignored for now
if (i >= commandLine.Length || commandLine[i] != '"')
{
break;
}
// If there is an odd number of slashes then it is escaping the quote
// otherwise it is just a quote.
if (slashCount % 2 == 0)
{
quoteCount++;
}
builder.Append('"');
i++;
break;
}
case '"':
builder.Append(current);
quoteCount++;
i++;
break;
default:
if ((current >= 0x1 && current <= 0x1f) || current == '|')
{
if (illegalChar == null)
{
illegalChar = current;
}
}
else
{
builder.Append(current);
}
i++;
break;
}
}
// If the quote string is surrounded by quotes with no interior quotes then
// remove the quotes here.
if (quoteCount == 2 && builder[0] == '"' && builder[builder.Length - 1] == '"')
{
builder.Remove(0, length: 1);
builder.Remove(builder.Length - 1, length: 1);
}
if (builder.Length > 0)
{
list.Add(builder.ToString());
}
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/CoreTestUtilities/SolutionUtilities.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Xunit;
namespace Microsoft.CodeAnalysis.UnitTests
{
public class SolutionUtilities
{
public static ProjectChanges GetSingleChangedProjectChanges(Solution oldSolution, Solution newSolution)
{
var solutionDifferences = newSolution.GetChanges(oldSolution);
var projectChanges = solutionDifferences.GetProjectChanges();
Assert.NotNull(projectChanges);
Assert.NotEmpty(projectChanges);
var projectId = projectChanges.Single().ProjectId;
var oldProject = oldSolution.GetRequiredProject(projectId);
var newProject = newSolution.GetRequiredProject(projectId);
return newProject.GetChanges(oldProject);
}
private static IEnumerable<ProjectChanges> GetChangedProjectChanges(Solution oldSolution, Solution newSolution)
{
var solutionDifferences = newSolution.GetChanges(oldSolution);
return solutionDifferences.GetProjectChanges().Select(n => n.NewProject.GetChanges(n.OldProject));
}
public static Document GetSingleChangedDocument(Solution oldSolution, Solution newSolution)
{
var projectDifferences = GetSingleChangedProjectChanges(oldSolution, newSolution);
var documentId = projectDifferences.GetChangedDocuments().Single();
return newSolution.GetDocument(documentId)!;
}
public static TextDocument GetSingleChangedAdditionalDocument(Solution oldSolution, Solution newSolution)
{
var projectDifferences = GetSingleChangedProjectChanges(oldSolution, newSolution);
var documentId = projectDifferences.GetChangedAdditionalDocuments().Single();
return newSolution.GetAdditionalDocument(documentId)!;
}
public static IEnumerable<DocumentId> GetChangedDocuments(Solution oldSolution, Solution newSolution)
{
var changedDocuments = new List<DocumentId>();
var projectsDifference = GetChangedProjectChanges(oldSolution, newSolution);
foreach (var projectDifference in projectsDifference)
{
changedDocuments.AddRange(projectDifference.GetChangedDocuments());
}
return changedDocuments;
}
public static Document GetSingleAddedDocument(Solution oldSolution, Solution newSolution)
{
var projectDifferences = GetSingleChangedProjectChanges(oldSolution, newSolution);
var documentId = projectDifferences.GetAddedDocuments().Single();
return newSolution.GetDocument(documentId)!;
}
public static IEnumerable<DocumentId> GetTextChangedDocuments(Solution oldSolution, Solution newSolution)
{
var changedDocuments = new List<DocumentId>();
var projectsDifference = GetChangedProjectChanges(oldSolution, newSolution);
foreach (var projectDifference in projectsDifference)
{
changedDocuments.AddRange(projectDifference.GetChangedDocuments(onlyGetDocumentsWithTextChanges: true));
}
return changedDocuments;
}
public static IEnumerable<DocumentId> GetAddedDocuments(Solution oldSolution, Solution newSolution)
{
var addedDocuments = new List<DocumentId>();
var projectsDifference = GetChangedProjectChanges(oldSolution, newSolution);
foreach (var projectDifference in projectsDifference)
{
addedDocuments.AddRange(projectDifference.GetAddedDocuments());
}
return addedDocuments;
}
public static Tuple<Project, ProjectReference> GetSingleAddedProjectReference(Solution oldSolution, Solution newSolution)
{
var projectChanges = GetSingleChangedProjectChanges(oldSolution, newSolution);
return Tuple.Create(projectChanges.NewProject, projectChanges.GetAddedProjectReferences().Single());
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Xunit;
namespace Microsoft.CodeAnalysis.UnitTests
{
public class SolutionUtilities
{
public static ProjectChanges GetSingleChangedProjectChanges(Solution oldSolution, Solution newSolution)
{
var solutionDifferences = newSolution.GetChanges(oldSolution);
var projectChanges = solutionDifferences.GetProjectChanges();
Assert.NotNull(projectChanges);
Assert.NotEmpty(projectChanges);
var projectId = projectChanges.Single().ProjectId;
var oldProject = oldSolution.GetRequiredProject(projectId);
var newProject = newSolution.GetRequiredProject(projectId);
return newProject.GetChanges(oldProject);
}
private static IEnumerable<ProjectChanges> GetChangedProjectChanges(Solution oldSolution, Solution newSolution)
{
var solutionDifferences = newSolution.GetChanges(oldSolution);
return solutionDifferences.GetProjectChanges().Select(n => n.NewProject.GetChanges(n.OldProject));
}
public static Document GetSingleChangedDocument(Solution oldSolution, Solution newSolution)
{
var projectDifferences = GetSingleChangedProjectChanges(oldSolution, newSolution);
var documentId = projectDifferences.GetChangedDocuments().Single();
return newSolution.GetDocument(documentId)!;
}
public static TextDocument GetSingleChangedAdditionalDocument(Solution oldSolution, Solution newSolution)
{
var projectDifferences = GetSingleChangedProjectChanges(oldSolution, newSolution);
var documentId = projectDifferences.GetChangedAdditionalDocuments().Single();
return newSolution.GetAdditionalDocument(documentId)!;
}
public static IEnumerable<DocumentId> GetChangedDocuments(Solution oldSolution, Solution newSolution)
{
var changedDocuments = new List<DocumentId>();
var projectsDifference = GetChangedProjectChanges(oldSolution, newSolution);
foreach (var projectDifference in projectsDifference)
{
changedDocuments.AddRange(projectDifference.GetChangedDocuments());
}
return changedDocuments;
}
public static Document GetSingleAddedDocument(Solution oldSolution, Solution newSolution)
{
var projectDifferences = GetSingleChangedProjectChanges(oldSolution, newSolution);
var documentId = projectDifferences.GetAddedDocuments().Single();
return newSolution.GetDocument(documentId)!;
}
public static IEnumerable<DocumentId> GetTextChangedDocuments(Solution oldSolution, Solution newSolution)
{
var changedDocuments = new List<DocumentId>();
var projectsDifference = GetChangedProjectChanges(oldSolution, newSolution);
foreach (var projectDifference in projectsDifference)
{
changedDocuments.AddRange(projectDifference.GetChangedDocuments(onlyGetDocumentsWithTextChanges: true));
}
return changedDocuments;
}
public static IEnumerable<DocumentId> GetAddedDocuments(Solution oldSolution, Solution newSolution)
{
var addedDocuments = new List<DocumentId>();
var projectsDifference = GetChangedProjectChanges(oldSolution, newSolution);
foreach (var projectDifference in projectsDifference)
{
addedDocuments.AddRange(projectDifference.GetAddedDocuments());
}
return addedDocuments;
}
public static Tuple<Project, ProjectReference> GetSingleAddedProjectReference(Solution oldSolution, Solution newSolution)
{
var projectChanges = GetSingleChangedProjectChanges(oldSolution, newSolution);
return Tuple.Create(projectChanges.NewProject, projectChanges.GetAddedProjectReferences().Single());
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/SharedUtilitiesAndExtensions/Compiler/Core/Simplification/SpecialTypeAnnotation.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Concurrent;
namespace Microsoft.CodeAnalysis.Simplification
{
internal class SpecialTypeAnnotation
{
public const string Kind = "SpecialType";
private static readonly ConcurrentDictionary<SpecialType, string> s_fromSpecialTypes = new();
private static readonly ConcurrentDictionary<string, SpecialType> s_toSpecialTypes = new();
public static SyntaxAnnotation Create(SpecialType specialType)
=> new(Kind, s_fromSpecialTypes.GetOrAdd(specialType, CreateFromSpecialTypes));
public static SpecialType GetSpecialType(SyntaxAnnotation annotation)
=> s_toSpecialTypes.GetOrAdd(annotation.Data!, CreateToSpecialTypes);
private static string CreateFromSpecialTypes(SpecialType arg)
=> arg.ToString();
private static SpecialType CreateToSpecialTypes(string arg)
=> (SpecialType)Enum.Parse(typeof(SpecialType), arg);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Concurrent;
namespace Microsoft.CodeAnalysis.Simplification
{
internal class SpecialTypeAnnotation
{
public const string Kind = "SpecialType";
private static readonly ConcurrentDictionary<SpecialType, string> s_fromSpecialTypes = new();
private static readonly ConcurrentDictionary<string, SpecialType> s_toSpecialTypes = new();
public static SyntaxAnnotation Create(SpecialType specialType)
=> new(Kind, s_fromSpecialTypes.GetOrAdd(specialType, CreateFromSpecialTypes));
public static SpecialType GetSpecialType(SyntaxAnnotation annotation)
=> s_toSpecialTypes.GetOrAdd(annotation.Data!, CreateToSpecialTypes);
private static string CreateFromSpecialTypes(SpecialType arg)
=> arg.ToString();
private static SpecialType CreateToSpecialTypes(string arg)
=> (SpecialType)Enum.Parse(typeof(SpecialType), arg);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/CSharp/Impl/Snippets/SnippetFunctions/SnippetFunctionClassName.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Threading;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.VisualStudio.LanguageServices.Implementation.Snippets;
using Microsoft.VisualStudio.Text;
namespace Microsoft.VisualStudio.LanguageServices.CSharp.Snippets.SnippetFunctions
{
internal sealed class SnippetFunctionClassName : AbstractSnippetFunctionClassName
{
public SnippetFunctionClassName(SnippetExpansionClient snippetExpansionClient, ITextBuffer subjectBuffer, string fieldName)
: base(snippetExpansionClient, subjectBuffer, fieldName)
{
}
protected override int GetContainingClassName(Document document, SnapshotSpan fieldSpan, CancellationToken cancellationToken, ref string value, ref int hasDefaultValue)
{
// Find the nearest enclosing type declaration and use its name
var syntaxTree = document.GetSyntaxTreeSynchronously(cancellationToken);
var type = syntaxTree.FindTokenOnLeftOfPosition(fieldSpan.Start.Position, cancellationToken).GetAncestor<TypeDeclarationSyntax>();
if (type != null)
{
value = type.Identifier.ToString();
if (!string.IsNullOrWhiteSpace(value))
{
hasDefaultValue = 1;
}
}
return VSConstants.S_OK;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Threading;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.VisualStudio.LanguageServices.Implementation.Snippets;
using Microsoft.VisualStudio.Text;
namespace Microsoft.VisualStudio.LanguageServices.CSharp.Snippets.SnippetFunctions
{
internal sealed class SnippetFunctionClassName : AbstractSnippetFunctionClassName
{
public SnippetFunctionClassName(SnippetExpansionClient snippetExpansionClient, ITextBuffer subjectBuffer, string fieldName)
: base(snippetExpansionClient, subjectBuffer, fieldName)
{
}
protected override int GetContainingClassName(Document document, SnapshotSpan fieldSpan, CancellationToken cancellationToken, ref string value, ref int hasDefaultValue)
{
// Find the nearest enclosing type declaration and use its name
var syntaxTree = document.GetSyntaxTreeSynchronously(cancellationToken);
var type = syntaxTree.FindTokenOnLeftOfPosition(fieldSpan.Start.Position, cancellationToken).GetAncestor<TypeDeclarationSyntax>();
if (type != null)
{
value = type.Identifier.ToString();
if (!string.IsNullOrWhiteSpace(value))
{
hasDefaultValue = 1;
}
}
return VSConstants.S_OK;
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/Core/ExternalAccess/VSTypeScript/Api/VSTypeScriptInlineRenameInfo.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Editor;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.ExternalAccess.VSTypeScript.Api
{
internal sealed class VSTypeScriptInlineRenameInfo : IInlineRenameInfo
{
private readonly IVSTypeScriptInlineRenameInfo _info;
public VSTypeScriptInlineRenameInfo(IVSTypeScriptInlineRenameInfo info)
{
Contract.ThrowIfNull(info);
_info = info;
}
public bool CanRename => _info.CanRename;
public string LocalizedErrorMessage => _info.LocalizedErrorMessage;
public TextSpan TriggerSpan => _info.TriggerSpan;
public bool HasOverloads => _info.HasOverloads;
public bool ForceRenameOverloads => _info.ForceRenameOverloads;
public string DisplayName => _info.DisplayName;
public string FullDisplayName => _info.FullDisplayName;
public Glyph Glyph => VSTypeScriptGlyphHelpers.ConvertTo(_info.Glyph);
public ImmutableArray<DocumentSpan> DefinitionLocations => _info.DefinitionLocations;
public async Task<IInlineRenameLocationSet> FindRenameLocationsAsync(OptionSet optionSet, CancellationToken cancellationToken)
{
var set = await _info.FindRenameLocationsAsync(optionSet, cancellationToken).ConfigureAwait(false);
if (set != null)
{
return new VSTypeScriptInlineRenameLocationSet(set);
}
else
{
return null;
}
}
public TextSpan? GetConflictEditSpan(InlineRenameLocation location, string triggerText, string replacementText, CancellationToken cancellationToken)
{
return _info.GetConflictEditSpan(new VSTypeScriptInlineRenameLocationWrapper(
new InlineRenameLocation(location.Document, location.TextSpan)), replacementText, cancellationToken);
}
public string GetFinalSymbolName(string replacementText)
=> _info.GetFinalSymbolName(replacementText);
public TextSpan GetReferenceEditSpan(InlineRenameLocation location, string triggerText, CancellationToken cancellationToken)
{
return _info.GetReferenceEditSpan(new VSTypeScriptInlineRenameLocationWrapper(
new InlineRenameLocation(location.Document, location.TextSpan)), cancellationToken);
}
public bool TryOnAfterGlobalSymbolRenamed(Workspace workspace, IEnumerable<DocumentId> changedDocumentIDs, string replacementText)
=> _info.TryOnAfterGlobalSymbolRenamed(workspace, changedDocumentIDs, replacementText);
public bool TryOnBeforeGlobalSymbolRenamed(Workspace workspace, IEnumerable<DocumentId> changedDocumentIDs, string replacementText)
=> _info.TryOnBeforeGlobalSymbolRenamed(workspace, changedDocumentIDs, replacementText);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Editor;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.ExternalAccess.VSTypeScript.Api
{
internal sealed class VSTypeScriptInlineRenameInfo : IInlineRenameInfo
{
private readonly IVSTypeScriptInlineRenameInfo _info;
public VSTypeScriptInlineRenameInfo(IVSTypeScriptInlineRenameInfo info)
{
Contract.ThrowIfNull(info);
_info = info;
}
public bool CanRename => _info.CanRename;
public string LocalizedErrorMessage => _info.LocalizedErrorMessage;
public TextSpan TriggerSpan => _info.TriggerSpan;
public bool HasOverloads => _info.HasOverloads;
public bool ForceRenameOverloads => _info.ForceRenameOverloads;
public string DisplayName => _info.DisplayName;
public string FullDisplayName => _info.FullDisplayName;
public Glyph Glyph => VSTypeScriptGlyphHelpers.ConvertTo(_info.Glyph);
public ImmutableArray<DocumentSpan> DefinitionLocations => _info.DefinitionLocations;
public async Task<IInlineRenameLocationSet> FindRenameLocationsAsync(OptionSet optionSet, CancellationToken cancellationToken)
{
var set = await _info.FindRenameLocationsAsync(optionSet, cancellationToken).ConfigureAwait(false);
if (set != null)
{
return new VSTypeScriptInlineRenameLocationSet(set);
}
else
{
return null;
}
}
public TextSpan? GetConflictEditSpan(InlineRenameLocation location, string triggerText, string replacementText, CancellationToken cancellationToken)
{
return _info.GetConflictEditSpan(new VSTypeScriptInlineRenameLocationWrapper(
new InlineRenameLocation(location.Document, location.TextSpan)), replacementText, cancellationToken);
}
public string GetFinalSymbolName(string replacementText)
=> _info.GetFinalSymbolName(replacementText);
public TextSpan GetReferenceEditSpan(InlineRenameLocation location, string triggerText, CancellationToken cancellationToken)
{
return _info.GetReferenceEditSpan(new VSTypeScriptInlineRenameLocationWrapper(
new InlineRenameLocation(location.Document, location.TextSpan)), cancellationToken);
}
public bool TryOnAfterGlobalSymbolRenamed(Workspace workspace, IEnumerable<DocumentId> changedDocumentIDs, string replacementText)
=> _info.TryOnAfterGlobalSymbolRenamed(workspace, changedDocumentIDs, replacementText);
public bool TryOnBeforeGlobalSymbolRenamed(Workspace workspace, IEnumerable<DocumentId> changedDocumentIDs, string replacementText)
=> _info.TryOnBeforeGlobalSymbolRenamed(workspace, changedDocumentIDs, replacementText);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Core/Test/Venus/VisualBasicContainedLanguageSupportTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.Editor
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Extensions
Imports Microsoft.CodeAnalysis.Editor.VisualBasic.Utilities
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.VisualStudio.LanguageServices.Implementation.Venus
Imports Microsoft.VisualStudio.TextManager.Interop
Imports Roslyn.Test.Utilities
Imports Roslyn.Utilities
Imports TextSpan = Microsoft.VisualStudio.TextManager.Interop.TextSpan
Namespace Microsoft.VisualStudio.LanguageServices.UnitTests.Venus
Public Class VisualBasicContainedLanguageCodeSupportTests
Inherits AbstractContainedLanguageCodeSupportTests
#Region "IsValid Tests"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_1()
AssertValidId("field")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_Escaped()
AssertValidId("[field]")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_EscapedKeyword()
AssertValidId("[Class]")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_ContainsNumbers()
AssertValidId("abc123")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_Keyword()
AssertNotValidId("Class")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_StartsWithNumber()
AssertNotValidId("123abc")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_Punctuation()
AssertNotValidId("abc.abc")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_TypeChar()
AssertValidId("abc$")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_TypeCharInMiddle()
AssertNotValidId("abc$abc")
End Sub
#End Region
#Region "GetBaseClassName Tests"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_NonexistingClass()
Dim code As String = <text>Class c
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.False(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "A",
CancellationToken.None, baseClassName))
Assert.Null(baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_DerivedFromObject()
Dim code As String = <text>Class C
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "C",
CancellationToken.None, baseClassName))
Assert.Equal("Object", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_DerivedFromFrameworkType()
Dim code As String = <text>
Imports System
Class C
Inherits Exception
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "C",
CancellationToken.None, baseClassName))
Assert.Equal("System.Exception", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_DerivedFromUserDefinedType()
Dim code As String = <text>
Class B
End Class
Class C
Inherits B
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "C",
CancellationToken.None, baseClassName))
Assert.Equal("B", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_FullyQualifiedNames()
Dim code As String = <text>
Namespace N
Class B
End Class
Class C
Inherits B
End Class
End Namespace</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "N.C",
CancellationToken.None, baseClassName))
Assert.Equal("N.B", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_MinimallyQualifiedNames()
Dim code As String = <text>
Namespace N
Class B
End Class
Class C
Inherits B
End Class
End Namespace</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "N.C",
CancellationToken.None, baseClassName))
Assert.Equal("N.B", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_EscapedKeyword()
Dim code As String = <text>
Class [Class]
End Class
Class Derived
Inherits [Class]
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "Derived",
CancellationToken.None, baseClassName))
Assert.Equal("[Class]", baseClassName)
End Using
End Sub
#End Region
#Region "CreateUniqueEventName Tests"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_ButtonClick()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionWithEventHandler()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionWithOtherMembers()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Public Property Button1_Click As String
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionFromPartialClass()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class
Public Partial Class _Default
Public Property Button1_Click As String
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionFromBaseClass()
Dim code As String = <text>
Public Partial Class _Default
Inherits MyBaseClass
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class
Public Class MyBaseClass
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
#End Region
#Region "GetCompatibleEventHandlers"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_EventDoesntExist()
Dim code As String = <text>
Imports System
Public Class Button
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Assert.Throws(Of InvalidOperationException)(
Sub()
ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
cancellationToken:=Nothing)
End Sub)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_ObjTypeNameIsWrong()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Assert.Throws(Of InvalidOperationException)(
Sub()
ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="CheckBox",
nameOfEvent:="Click",
cancellationToken:=Nothing)
End Sub)
End Using
End Sub
' To Do: Investigate - this feels wrong. when Handles Clause exists
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_MatchExists()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlers = ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal(1, eventHandlers.Count())
Assert.Equal("Page_Load", eventHandlers.Single().Item1)
Assert.Equal("Page_Load(Object,System.EventArgs)", eventHandlers.Single().Item2)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_MatchesExist()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlers = ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal(2, eventHandlers.Count())
' It has to be page_load and button click, but are they always ordered in the same way?
End Using
End Sub
' add tests for CompatibleSignatureToDelegate (#params, return type)
#End Region
#Region "GetEventHandlerMemberId"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetEventHandlerMemberId_HandlerExists()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerId = ContainedLanguageCodeSupport.GetEventHandlerMemberId(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click(Object,System.EventArgs)", eventHandlerId)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetEventHandlerMemberId_CantFindHandler()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerId = ContainedLanguageCodeSupport.GetEventHandlerMemberId(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
cancellationToken:=Nothing)
Assert.Equal(Nothing, eventHandlerId)
End Using
End Sub
#End Region
#Region "EnsureEventHandler"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestEnsureEventHandler_HandlerExists()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs)
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerIdTextPosition = ContainedLanguageCodeSupport.EnsureEventHandler(
thisDocument:=document,
targetDocument:=document,
className:="_Default",
objectName:="Button1",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
itemidInsertionPoint:=0,
useHandlesClause:=True,
additionalFormattingRule:=LineAdjustmentFormattingRule.Instance,
cancellationToken:=Nothing)
' Since a valid handler exists, item2 and item3 of the tuple returned must be nothing
Assert.Equal("Button1_Click(Object,System.EventArgs)", eventHandlerIdTextPosition.Item1)
Assert.Equal(Nothing, eventHandlerIdTextPosition.Item2)
Assert.Equal(New TextSpan(), eventHandlerIdTextPosition.Item3)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestEnsureEventHandler_GenerateNewHandler()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs)
End Sub
End Class</text>.NormalizedValue
Dim generatedCode As String = <text>
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub</text>.NormalizedValue
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerIdTextPosition = ContainedLanguageCodeSupport.EnsureEventHandler(
thisDocument:=document,
targetDocument:=document,
className:="_Default",
objectName:="Button1",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
itemidInsertionPoint:=0,
useHandlesClause:=True,
additionalFormattingRule:=LineAdjustmentFormattingRule.Instance,
cancellationToken:=Nothing)
Assert.Equal("Button1_Click(Object,System.EventArgs)", eventHandlerIdTextPosition.Item1)
TokenUtilities.AssertTokensEqual(generatedCode, eventHandlerIdTextPosition.Item2, Language)
Assert.Equal(New TextSpan With {.iStartLine = 12, .iEndLine = 12}, eventHandlerIdTextPosition.Item3)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
<WorkItem(850035, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/850035")>
Public Sub TestEnsureEventHandler_WithHandlesAndNullObjectName()
Dim code As String = "
Imports System
Namespace System.Web.UI
Public Class Page
Public Event Load as EventHandler
End Class
End Namespace
Public Class _Default
Inherits System.Web.UI.Page
End Class"
Dim generatedCode As String = "
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub"
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerIdTextPosition = ContainedLanguageCodeSupport.EnsureEventHandler(
thisDocument:=document,
targetDocument:=document,
className:="_Default",
objectName:=Nothing,
objectTypeName:="System.Web.UI.Page",
nameOfEvent:="Load",
eventHandlerName:="Page_Load",
itemidInsertionPoint:=0,
useHandlesClause:=True,
additionalFormattingRule:=LineAdjustmentFormattingRule.Instance,
cancellationToken:=Nothing)
Assert.Equal("Page_Load(Object,System.EventArgs)", eventHandlerIdTextPosition.Item1)
TokenUtilities.AssertTokensEqual(generatedCode, eventHandlerIdTextPosition.Item2, Language)
Assert.Equal(New TextSpan With {.iStartLine = 12, .iEndLine = 12}, eventHandlerIdTextPosition.Item3)
End Using
End Sub
#End Region
#Region "GetMemberNavigationPoint"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMemberNavigationPoint()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
' Expect the cursor to be inside the method body of Button1_Click, line 14 column 8
Dim expectedSpan As New Microsoft.VisualStudio.TextManager.Interop.TextSpan() With
{
.iStartLine = 14,
.iStartIndex = 8,
.iEndLine = 14,
.iEndIndex = 8
}
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim targetDocument As Document = Nothing
Dim actualSpan As TextSpan = Nothing
If Not ContainedLanguageCodeSupport.TryGetMemberNavigationPoint(
thisDocument:=document,
className:="_Default",
uniqueMemberID:="Button1_Click(Object,System.EventArgs)",
textSpan:=actualSpan,
targetDocument:=targetDocument,
cancellationToken:=Nothing) Then
Assert.True(False, "should have succeeded")
End If
Assert.Equal(expectedSpan, actualSpan)
End Using
End Sub
#End Region
#Region "GetMembers"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlersWrongParamType()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As Object)
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(0, members.Count())
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlersWrongParamCount()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object)
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(0, members.Count())
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlersWrongReturnType()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Function Page_Load(sender As Object, e As EventArgs) As Integer
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(0, members.Count())
End Using
End Sub
' To Do: Investigate, this returns the method even if handles is missing. that ok?
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlers()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(1, members.Count())
Dim userFunction = members.First()
Assert.Equal("Page_Load", userFunction.Item1)
Assert.Equal("Page_Load(Object,System.EventArgs)", userFunction.Item2)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_UserFunctions()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Test(x as String)
End Sub
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_USER_FUNCTIONS,
cancellationToken:=Nothing)
Assert.Equal(1, members.Count())
Dim userFunction = members.First()
Assert.Equal("Test", userFunction.Item1)
Assert.Equal("Test(String)", userFunction.Item2)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_Events()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="Button",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENTS,
cancellationToken:=Nothing)
Assert.Equal(1, members.Count())
Dim userFunction = members.First()
Assert.Equal("Click", userFunction.Item1)
Assert.Equal("Click(EVENT)", userFunction.Item2)
End Using
End Sub
#End Region
#Region "OnRenamed (TryRenameElement)"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_ResolvableMembers()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASSMEMBER,
oldFullyQualifiedName:="_Default.Page_Load",
newFullyQualifiedName:="_Default.Page_Load1",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
' To Do: Who tests the fully qualified names and their absence?
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_UnresolvableMembers()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASSMEMBER,
oldFullyQualifiedName:="_Default.Fictional",
newFullyQualifiedName:="_Default.Fictional1",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.False(renameSucceeded)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_ResolvableClass()
Dim code As String = <text>Public Partial Class Goo
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASS,
oldFullyQualifiedName:="Goo",
newFullyQualifiedName:="Bar",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_ResolvableNamespace()
Dim code As String = <text>Namespace Goo
End Namespace</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_NAMESPACE,
oldFullyQualifiedName:="Goo",
newFullyQualifiedName:="Bar",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_Button()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASSMEMBER,
oldFullyQualifiedName:="_Default.button",
newFullyQualifiedName:="_Default.button1",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
#End Region
' TODO: Does Dev10 cover more here, like conflicts with existing members?
Protected Overrides ReadOnly Property DefaultCode As String
Get
Return <text>
Class C
End Class
</text>.Value
End Get
End Property
Protected Overrides ReadOnly Property Language As String
Get
Return Microsoft.CodeAnalysis.LanguageNames.VisualBasic
End Get
End Property
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.Editor
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Extensions
Imports Microsoft.CodeAnalysis.Editor.VisualBasic.Utilities
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.VisualStudio.LanguageServices.Implementation.Venus
Imports Microsoft.VisualStudio.TextManager.Interop
Imports Roslyn.Test.Utilities
Imports Roslyn.Utilities
Imports TextSpan = Microsoft.VisualStudio.TextManager.Interop.TextSpan
Namespace Microsoft.VisualStudio.LanguageServices.UnitTests.Venus
Public Class VisualBasicContainedLanguageCodeSupportTests
Inherits AbstractContainedLanguageCodeSupportTests
#Region "IsValid Tests"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_1()
AssertValidId("field")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_Escaped()
AssertValidId("[field]")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_EscapedKeyword()
AssertValidId("[Class]")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_ContainsNumbers()
AssertValidId("abc123")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_Keyword()
AssertNotValidId("Class")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_StartsWithNumber()
AssertNotValidId("123abc")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_Punctuation()
AssertNotValidId("abc.abc")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_TypeChar()
AssertValidId("abc$")
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestIsValidId_TypeCharInMiddle()
AssertNotValidId("abc$abc")
End Sub
#End Region
#Region "GetBaseClassName Tests"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_NonexistingClass()
Dim code As String = <text>Class c
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.False(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "A",
CancellationToken.None, baseClassName))
Assert.Null(baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_DerivedFromObject()
Dim code As String = <text>Class C
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "C",
CancellationToken.None, baseClassName))
Assert.Equal("Object", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_DerivedFromFrameworkType()
Dim code As String = <text>
Imports System
Class C
Inherits Exception
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "C",
CancellationToken.None, baseClassName))
Assert.Equal("System.Exception", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_DerivedFromUserDefinedType()
Dim code As String = <text>
Class B
End Class
Class C
Inherits B
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "C",
CancellationToken.None, baseClassName))
Assert.Equal("B", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_FullyQualifiedNames()
Dim code As String = <text>
Namespace N
Class B
End Class
Class C
Inherits B
End Class
End Namespace</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "N.C",
CancellationToken.None, baseClassName))
Assert.Equal("N.B", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_MinimallyQualifiedNames()
Dim code As String = <text>
Namespace N
Class B
End Class
Class C
Inherits B
End Class
End Namespace</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "N.C",
CancellationToken.None, baseClassName))
Assert.Equal("N.B", baseClassName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetBaseClassName_EscapedKeyword()
Dim code As String = <text>
Class [Class]
End Class
Class Derived
Inherits [Class]
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim baseClassName As String = Nothing
Assert.True(ContainedLanguageCodeSupport.TryGetBaseClassName(document, "Derived",
CancellationToken.None, baseClassName))
Assert.Equal("[Class]", baseClassName)
End Using
End Sub
#End Region
#Region "CreateUniqueEventName Tests"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_ButtonClick()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionWithEventHandler()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionWithOtherMembers()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Public Property Button1_Click As String
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionFromPartialClass()
Dim code As String = <text>
Public Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class
Public Partial Class _Default
Public Property Button1_Click As String
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestCreateUniqueEventName_NameCollisionFromBaseClass()
Dim code As String = <text>
Public Partial Class _Default
Inherits MyBaseClass
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class
Public Class MyBaseClass
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventName = ContainedLanguageCodeSupport.CreateUniqueEventName(
document:=document,
className:="_Default",
objectName:="Button1",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click1", eventName)
End Using
End Sub
#End Region
#Region "GetCompatibleEventHandlers"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_EventDoesntExist()
Dim code As String = <text>
Imports System
Public Class Button
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Assert.Throws(Of InvalidOperationException)(
Sub()
ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
cancellationToken:=Nothing)
End Sub)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_ObjTypeNameIsWrong()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Assert.Throws(Of InvalidOperationException)(
Sub()
ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="CheckBox",
nameOfEvent:="Click",
cancellationToken:=Nothing)
End Sub)
End Using
End Sub
' To Do: Investigate - this feels wrong. when Handles Clause exists
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_MatchExists()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlers = ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal(1, eventHandlers.Count())
Assert.Equal("Page_Load", eventHandlers.Single().Item1)
Assert.Equal("Page_Load(Object,System.EventArgs)", eventHandlers.Single().Item2)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetCompatibleEventHandlers_MatchesExist()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlers = ContainedLanguageCodeSupport.GetCompatibleEventHandlers(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
cancellationToken:=Nothing)
Assert.Equal(2, eventHandlers.Count())
' It has to be page_load and button click, but are they always ordered in the same way?
End Using
End Sub
' add tests for CompatibleSignatureToDelegate (#params, return type)
#End Region
#Region "GetEventHandlerMemberId"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetEventHandlerMemberId_HandlerExists()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerId = ContainedLanguageCodeSupport.GetEventHandlerMemberId(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
cancellationToken:=Nothing)
Assert.Equal("Button1_Click(Object,System.EventArgs)", eventHandlerId)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetEventHandlerMemberId_CantFindHandler()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerId = ContainedLanguageCodeSupport.GetEventHandlerMemberId(
document:=document,
className:="_Default",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
cancellationToken:=Nothing)
Assert.Equal(Nothing, eventHandlerId)
End Using
End Sub
#End Region
#Region "EnsureEventHandler"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestEnsureEventHandler_HandlerExists()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs)
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerIdTextPosition = ContainedLanguageCodeSupport.EnsureEventHandler(
thisDocument:=document,
targetDocument:=document,
className:="_Default",
objectName:="Button1",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
itemidInsertionPoint:=0,
useHandlesClause:=True,
additionalFormattingRule:=LineAdjustmentFormattingRule.Instance,
cancellationToken:=Nothing)
' Since a valid handler exists, item2 and item3 of the tuple returned must be nothing
Assert.Equal("Button1_Click(Object,System.EventArgs)", eventHandlerIdTextPosition.Item1)
Assert.Equal(Nothing, eventHandlerIdTextPosition.Item2)
Assert.Equal(New TextSpan(), eventHandlerIdTextPosition.Item3)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestEnsureEventHandler_GenerateNewHandler()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs)
End Sub
End Class</text>.NormalizedValue
Dim generatedCode As String = <text>
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub</text>.NormalizedValue
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerIdTextPosition = ContainedLanguageCodeSupport.EnsureEventHandler(
thisDocument:=document,
targetDocument:=document,
className:="_Default",
objectName:="Button1",
objectTypeName:="Button",
nameOfEvent:="Click",
eventHandlerName:="Button1_Click",
itemidInsertionPoint:=0,
useHandlesClause:=True,
additionalFormattingRule:=LineAdjustmentFormattingRule.Instance,
cancellationToken:=Nothing)
Assert.Equal("Button1_Click(Object,System.EventArgs)", eventHandlerIdTextPosition.Item1)
TokenUtilities.AssertTokensEqual(generatedCode, eventHandlerIdTextPosition.Item2, Language)
Assert.Equal(New TextSpan With {.iStartLine = 12, .iEndLine = 12}, eventHandlerIdTextPosition.Item3)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
<WorkItem(850035, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/850035")>
Public Sub TestEnsureEventHandler_WithHandlesAndNullObjectName()
Dim code As String = "
Imports System
Namespace System.Web.UI
Public Class Page
Public Event Load as EventHandler
End Class
End Namespace
Public Class _Default
Inherits System.Web.UI.Page
End Class"
Dim generatedCode As String = "
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub"
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim eventHandlerIdTextPosition = ContainedLanguageCodeSupport.EnsureEventHandler(
thisDocument:=document,
targetDocument:=document,
className:="_Default",
objectName:=Nothing,
objectTypeName:="System.Web.UI.Page",
nameOfEvent:="Load",
eventHandlerName:="Page_Load",
itemidInsertionPoint:=0,
useHandlesClause:=True,
additionalFormattingRule:=LineAdjustmentFormattingRule.Instance,
cancellationToken:=Nothing)
Assert.Equal("Page_Load(Object,System.EventArgs)", eventHandlerIdTextPosition.Item1)
TokenUtilities.AssertTokensEqual(generatedCode, eventHandlerIdTextPosition.Item2, Language)
Assert.Equal(New TextSpan With {.iStartLine = 12, .iEndLine = 12}, eventHandlerIdTextPosition.Item3)
End Using
End Sub
#End Region
#Region "GetMemberNavigationPoint"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMemberNavigationPoint()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
' Expect the cursor to be inside the method body of Button1_Click, line 14 column 8
Dim expectedSpan As New Microsoft.VisualStudio.TextManager.Interop.TextSpan() With
{
.iStartLine = 14,
.iStartIndex = 8,
.iEndLine = 14,
.iEndIndex = 8
}
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim targetDocument As Document = Nothing
Dim actualSpan As TextSpan = Nothing
If Not ContainedLanguageCodeSupport.TryGetMemberNavigationPoint(
thisDocument:=document,
className:="_Default",
uniqueMemberID:="Button1_Click(Object,System.EventArgs)",
textSpan:=actualSpan,
targetDocument:=targetDocument,
cancellationToken:=Nothing) Then
Assert.True(False, "should have succeeded")
End If
Assert.Equal(expectedSpan, actualSpan)
End Using
End Sub
#End Region
#Region "GetMembers"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlersWrongParamType()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As Object)
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(0, members.Count())
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlersWrongParamCount()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object)
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(0, members.Count())
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlersWrongReturnType()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Function Page_Load(sender As Object, e As EventArgs) As Integer
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(0, members.Count())
End Using
End Sub
' To Do: Investigate, this returns the method even if handles is missing. that ok?
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_EventHandlers()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENT_HANDLERS,
cancellationToken:=Nothing)
Assert.Equal(1, members.Count())
Dim userFunction = members.First()
Assert.Equal("Page_Load", userFunction.Item1)
Assert.Equal("Page_Load(Object,System.EventArgs)", userFunction.Item2)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_UserFunctions()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Test(x as String)
End Sub
End Class
</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="_Default",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_USER_FUNCTIONS,
cancellationToken:=Nothing)
Assert.Equal(1, members.Count())
Dim userFunction = members.First()
Assert.Equal("Test", userFunction.Item1)
Assert.Equal("Test(String)", userFunction.Item2)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestGetMembers_Events()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim members = ContainedLanguageCodeSupport.GetMembers(
document:=document,
className:="Button",
codeMemberType:=CODEMEMBERTYPE.CODEMEMBERTYPE_EVENTS,
cancellationToken:=Nothing)
Assert.Equal(1, members.Count())
Dim userFunction = members.First()
Assert.Equal("Click", userFunction.Item1)
Assert.Equal("Click(EVENT)", userFunction.Item2)
End Using
End Sub
#End Region
#Region "OnRenamed (TryRenameElement)"
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_ResolvableMembers()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASSMEMBER,
oldFullyQualifiedName:="_Default.Page_Load",
newFullyQualifiedName:="_Default.Page_Load1",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
' To Do: Who tests the fully qualified names and their absence?
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_UnresolvableMembers()
Dim code As String = <text>
Imports System
Public Partial Class _Default
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASSMEMBER,
oldFullyQualifiedName:="_Default.Fictional",
newFullyQualifiedName:="_Default.Fictional1",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.False(renameSucceeded)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_ResolvableClass()
Dim code As String = <text>Public Partial Class Goo
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASS,
oldFullyQualifiedName:="Goo",
newFullyQualifiedName:="Bar",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_ResolvableNamespace()
Dim code As String = <text>Namespace Goo
End Namespace</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_NAMESPACE,
oldFullyQualifiedName:="Goo",
newFullyQualifiedName:="Bar",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
<WpfFact, Trait(Traits.Feature, Traits.Features.Venus)>
Public Sub TestTryRenameElement_Button()
Dim code As String = <text>
Imports System
Public Class Button
Public Event Click As EventHandler
End Class
Public Class _Default
Private button As Button
Protected Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
End Sub
End Class</text>.Value
Using workspace = GetWorkspace(code)
Dim document = GetDocument(workspace)
Dim renameSucceeded = ContainedLanguageCodeSupport.TryRenameElement(
document:=document,
clrt:=ContainedLanguageRenameType.CLRT_CLASSMEMBER,
oldFullyQualifiedName:="_Default.button",
newFullyQualifiedName:="_Default.button1",
refactorNotifyServices:=SpecializedCollections.EmptyEnumerable(Of IRefactorNotifyService),
cancellationToken:=Nothing)
Assert.True(renameSucceeded)
End Using
End Sub
#End Region
' TODO: Does Dev10 cover more here, like conflicts with existing members?
Protected Overrides ReadOnly Property DefaultCode As String
Get
Return <text>
Class C
End Class
</text>.Value
End Get
End Property
Protected Overrides ReadOnly Property Language As String
Get
Return Microsoft.CodeAnalysis.LanguageNames.VisualBasic
End Get
End Property
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/VisualBasicTest/Recommendations/Statements/LoopKeywordRecommenderTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.Recommendations.Statements
Public Class LoopKeywordRecommenderTests
Inherits RecommenderTests
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotInMethodBodyTest()
VerifyRecommendationsMissing(<MethodBody>|</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotInLambdaTest()
VerifyRecommendationsMissing(<MethodBody>
Dim x = Sub()
|
End Sub</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotAfterStatementTest()
VerifyRecommendationsMissing(<MethodBody>
Dim x
|</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopAfterDoStatementTest()
VerifyRecommendationsContain(<MethodBody>
Do
|</MethodBody>, "Loop", "Loop Until", "Loop While")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopAfterDoUntilStatementTest()
VerifyRecommendationsContain(<MethodBody>
Do Until True
|</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopUntilNotAfterDoUntilStatementTest()
VerifyRecommendationsMissing(<MethodBody>
Do Until True
|</MethodBody>, "Loop Until", "Loop While")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotInDoLoopUntilBlockTest()
VerifyRecommendationsMissing(<MethodBody>
Do
|
Loop Until True</MethodBody>, "Loop")
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.Recommendations.Statements
Public Class LoopKeywordRecommenderTests
Inherits RecommenderTests
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotInMethodBodyTest()
VerifyRecommendationsMissing(<MethodBody>|</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotInLambdaTest()
VerifyRecommendationsMissing(<MethodBody>
Dim x = Sub()
|
End Sub</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotAfterStatementTest()
VerifyRecommendationsMissing(<MethodBody>
Dim x
|</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopAfterDoStatementTest()
VerifyRecommendationsContain(<MethodBody>
Do
|</MethodBody>, "Loop", "Loop Until", "Loop While")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopAfterDoUntilStatementTest()
VerifyRecommendationsContain(<MethodBody>
Do Until True
|</MethodBody>, "Loop")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopUntilNotAfterDoUntilStatementTest()
VerifyRecommendationsMissing(<MethodBody>
Do Until True
|</MethodBody>, "Loop Until", "Loop While")
End Sub
<Fact>
<Trait(Traits.Feature, Traits.Features.KeywordRecommending)>
Public Sub LoopNotInDoLoopUntilBlockTest()
VerifyRecommendationsMissing(<MethodBody>
Do
|
Loop Until True</MethodBody>, "Loop")
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Xaml/Impl/Features/Completion/XamlEventDescription.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
namespace Microsoft.VisualStudio.LanguageServices.Xaml.Features.Completion
{
internal struct XamlEventDescription
{
public string ClassName { get; set; }
public string EventName { get; set; }
public string ReturnType { get; set; }
public ImmutableArray<(string Name, string ParameterType, string Modifier)> Parameters { get; set; }
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
namespace Microsoft.VisualStudio.LanguageServices.Xaml.Features.Completion
{
internal struct XamlEventDescription
{
public string ClassName { get; set; }
public string EventName { get; set; }
public string ReturnType { get; set; }
public ImmutableArray<(string Name, string ParameterType, string Modifier)> Parameters { get; set; }
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Core/Def/Implementation/ColorSchemes/ColorSchemeApplier.RegistryItem.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
namespace Microsoft.VisualStudio.LanguageServices.ColorSchemes
{
internal partial class ColorSchemeApplier
{
private class RegistryItem
{
public string SectionName { get; }
public string ValueName => "Data";
public byte[] ValueData { get; }
public RegistryItem(string sectionName, byte[] valueData)
{
SectionName = sectionName;
ValueData = valueData;
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
namespace Microsoft.VisualStudio.LanguageServices.ColorSchemes
{
internal partial class ColorSchemeApplier
{
private class RegistryItem
{
public string SectionName { get; }
public string ValueName => "Data";
public byte[] ValueData { get; }
public RegistryItem(string sectionName, byte[] valueData)
{
SectionName = sectionName;
ValueData = valueData;
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Test/Core/Platform/Desktop/AppDomainUtils.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
#if NET472
using System;
using System.IO;
using System.Reflection;
namespace Roslyn.Test.Utilities.Desktop
{
public static class AppDomainUtils
{
private static readonly object s_lock = new object();
private static bool s_hookedResolve;
public static AppDomain Create(string name = null, string basePath = null)
{
name = name ?? "Custom AppDomain";
basePath = basePath ?? Path.GetDirectoryName(typeof(AppDomainUtils).Assembly.Location);
lock (s_lock)
{
if (!s_hookedResolve)
{
AppDomain.CurrentDomain.AssemblyResolve += OnResolve;
s_hookedResolve = true;
}
}
return AppDomain.CreateDomain(name, null, new AppDomainSetup()
{
ConfigurationFile = AppDomain.CurrentDomain.SetupInformation.ConfigurationFile,
ApplicationBase = basePath
});
}
/// <summary>
/// When run under xunit without AppDomains all DLLs get loaded via the AssemblyResolve
/// event. In some cases the xunit, AppDomain marshalling, xunit doesn't fully hook
/// the event and we need to do it for our assemblies.
/// </summary>
private static Assembly OnResolve(object sender, ResolveEventArgs e)
{
var assemblyName = new AssemblyName(e.Name);
var fullPath = Path.Combine(
Path.GetDirectoryName(typeof(AppDomainUtils).Assembly.Location),
assemblyName.Name + ".dll");
if (File.Exists(fullPath))
{
return Assembly.LoadFrom(fullPath);
}
return null;
}
}
}
#endif
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
#if NET472
using System;
using System.IO;
using System.Reflection;
namespace Roslyn.Test.Utilities.Desktop
{
public static class AppDomainUtils
{
private static readonly object s_lock = new object();
private static bool s_hookedResolve;
public static AppDomain Create(string name = null, string basePath = null)
{
name = name ?? "Custom AppDomain";
basePath = basePath ?? Path.GetDirectoryName(typeof(AppDomainUtils).Assembly.Location);
lock (s_lock)
{
if (!s_hookedResolve)
{
AppDomain.CurrentDomain.AssemblyResolve += OnResolve;
s_hookedResolve = true;
}
}
return AppDomain.CreateDomain(name, null, new AppDomainSetup()
{
ConfigurationFile = AppDomain.CurrentDomain.SetupInformation.ConfigurationFile,
ApplicationBase = basePath
});
}
/// <summary>
/// When run under xunit without AppDomains all DLLs get loaded via the AssemblyResolve
/// event. In some cases the xunit, AppDomain marshalling, xunit doesn't fully hook
/// the event and we need to do it for our assemblies.
/// </summary>
private static Assembly OnResolve(object sender, ResolveEventArgs e)
{
var assemblyName = new AssemblyName(e.Name);
var fullPath = Path.Combine(
Path.GetDirectoryName(typeof(AppDomainUtils).Assembly.Location),
assemblyName.Name + ".dll");
if (File.Exists(fullPath))
{
return Assembly.LoadFrom(fullPath);
}
return null;
}
}
}
#endif
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/CSharp/Impl/Options/AutomationObject/AutomationObject.Naming.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Xml.Linq;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics.Analyzers.NamingStyles;
using Microsoft.CodeAnalysis.Simplification;
namespace Microsoft.VisualStudio.LanguageServices.CSharp.Options
{
public partial class AutomationObject
{
public string Style_NamingPreferences
{
get { return GetOption(NamingStyleOptions.NamingPreferences).CreateXElement().ToString(); }
set
{
try
{
SetOption(NamingStyleOptions.NamingPreferences, NamingStylePreferences.FromXElement(XElement.Parse(value)));
}
catch (Exception)
{
}
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Xml.Linq;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics.Analyzers.NamingStyles;
using Microsoft.CodeAnalysis.Simplification;
namespace Microsoft.VisualStudio.LanguageServices.CSharp.Options
{
public partial class AutomationObject
{
public string Style_NamingPreferences
{
get { return GetOption(NamingStyleOptions.NamingPreferences).CreateXElement().ToString(); }
set
{
try
{
SetOption(NamingStyleOptions.NamingPreferences, NamingStylePreferences.FromXElement(XElement.Parse(value)));
}
catch (Exception)
{
}
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/CSharpTest2/Recommendations/NewKeywordRecommenderTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Recommendations
{
public class NewKeywordRecommenderTests : KeywordRecommenderTests
{
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAtRoot()
{
await VerifyKeywordAsync(
@"$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterClass()
{
await VerifyKeywordAsync(
@"class C { }
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterGlobalStatement()
{
await VerifyKeywordAsync(
@"System.Console.WriteLine();
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterGlobalVariableDeclaration()
{
await VerifyKeywordAsync(
@"int i = 0;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInUsingAlias()
{
await VerifyAbsenceAsync(
@"using Goo = $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInGlobalUsingAlias()
{
await VerifyAbsenceAsync(
@"global using Goo = $$");
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestEmptyStatement(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"$$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNewTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C<T> where T : $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterTypeParameterConstraint2()
{
await VerifyKeywordAsync(
@"class C<T>
where T : $$
where U : U");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterMethodTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C {
void Goo<T>()
where T : $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterMethodTypeParameterConstraint2()
{
await VerifyKeywordAsync(
@"class C {
void Goo<T>()
where T : $$
where U : T");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterClassTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C<T> where T : class, $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterStructTypeParameterConstraint()
{
await VerifyAbsenceAsync(
@"class C<T> where T : struct, $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterSimpleTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C<T> where T : IGoo, $$");
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestStartOfExpression(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
[WorkItem(34324, "https://github.com/dotnet/roslyn/issues/34324")]
public async Task TestAfterNullCoalescingAssignment(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q ??= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInParenthesizedExpression(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestPlusEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q += $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestMinusEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q -= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestTimesEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q *= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestDivideEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q /= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestModEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q %= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestXorEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q ^= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAndEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q &= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q |= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestLeftShiftEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q <<= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestRightShiftEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q >>= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterMinus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"- $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterPlus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"+ $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterNot(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"! $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterTilde(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"~ $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryTimes(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a * $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryDivide(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a / $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryMod(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a % $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryPlus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a + $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryMinus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a - $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryLeftShift(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a << $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryRightShift(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a >> $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryLessThan(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a < $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryGreaterThan(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a > $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterEqualsEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a == $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterNotEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a != $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterLessThanEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a <= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterGreaterThanEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a >= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterNullable(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a ?? $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterArrayRankSpecifier1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new int[ $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterArrayRankSpecifier2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new int[expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterConditional1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a ? $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[InlineData(false)]
[InlineData(true, Skip = "https://github.com/dotnet/roslyn/issues/44443")]
public async Task TestAfterConditional2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a ? expr | $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo( $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo(expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument3(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new Goo( $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument4(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new Goo(expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterRef(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo(ref $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterOut(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo(out $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestLambda(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Action<int> a = i => $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInCollectionInitializer1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new System.Collections.Generic.List<int>() { $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInCollectionInitializer2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new System.Collections.Generic.List<int>() { expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInForeachIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"foreach (var v in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInAwaitForeachIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"await foreach (var v in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInFromIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInJoinIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
join a in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInJoinOn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
join a in b on $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInJoinEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
join a in b on equals $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestWhere(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
where $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrderby1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
orderby $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrderby2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
orderby a, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrderby3(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
orderby a ascending, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterSelect(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
select $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterGroup(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
group $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterGroupBy(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
group expr by $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterReturn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"return $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterYieldReturn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"yield return $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAttributeReturn()
{
await VerifyAbsenceAsync(
@"[return $$");
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterThrow(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"throw $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInWhile(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"while ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInUsing(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"using ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInAwaitUsing(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"await using ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInLock(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"lock ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInIf(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"if ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInSwitch(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"switch ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterExtern()
{
await VerifyKeywordAsync(@"extern alias Goo;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterUsing()
{
await VerifyKeywordAsync(@"using Goo;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterGlobalUsing()
{
await VerifyKeywordAsync(
@"global using Goo;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNamespace()
{
await VerifyKeywordAsync(@"namespace N {}
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterFileScopedNamespace()
{
await VerifyKeywordAsync(
@"namespace N;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterDelegateDeclaration()
{
await VerifyKeywordAsync(@"delegate void Goo();
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterMethodInClass()
{
await VerifyKeywordAsync(
@"class C {
void Goo() {}
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterFieldInClass()
{
await VerifyKeywordAsync(
@"class C {
int i;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterPropertyInClass()
{
await VerifyKeywordAsync(
@"class C {
int i { get; }
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeUsing()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular,
@"$$
using Goo;");
}
[WpfFact(Skip = "https://github.com/dotnet/roslyn/issues/9880"), Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeUsing_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"$$
using Goo;");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeGlobalUsing()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular,
@"$$
global using Goo;");
}
[WpfFact(Skip = "https://github.com/dotnet/roslyn/issues/9880"), Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeGlobalUsing_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"$$
global using Goo;");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterAssemblyAttribute()
{
await VerifyKeywordAsync(@"[assembly: goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterRootAttribute()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular, @"[goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRootAttribute_Interactive()
{
// The global function could be hiding a member inherited from System.Object.
await VerifyKeywordAsync(SourceCodeKind.Script, @"[goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedAttribute()
{
await VerifyKeywordAsync(
@"class C {
[goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideStruct()
{
await VerifyKeywordAsync(
@"struct S {
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideInterface()
{
await VerifyKeywordAsync(
@"interface I {
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideClass()
{
await VerifyKeywordAsync(
@"class C {
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterPartial()
=> await VerifyAbsenceAsync(@"partial $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAbstract()
=> await VerifyAbsenceAsync(@"abstract $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterInternal()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterInternal_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterPublic()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"public $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterPublic_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"public $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterStaticInternal()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"static internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterStaticInternal_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"static internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterInternalStatic()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"internal static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterInternalStatic_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"internal static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterInvalidInternal()
=> await VerifyAbsenceAsync(@"virtual internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterClass()
=> await VerifyAbsenceAsync(@"class $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterPrivate()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular,
@"private $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterPrivate_Script()
{
await VerifyKeywordAsync(SourceCodeKind.Script,
@"private $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterSealed()
=> await VerifyAbsenceAsync(@"sealed $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterStatic()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterStatic_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedStatic()
{
await VerifyKeywordAsync(
@"class C {
static $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedInternal()
{
await VerifyKeywordAsync(
@"class C {
internal $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedPrivate()
{
await VerifyKeywordAsync(
@"class C {
private $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterDelegate()
=> await VerifyAbsenceAsync(@"delegate $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedAbstract()
{
await VerifyKeywordAsync(
@"class C {
abstract $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedVirtual()
{
await VerifyKeywordAsync(
@"class C {
virtual $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterNestedNew()
{
await VerifyAbsenceAsync(@"class C {
new $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterNestedOverride()
{
await VerifyAbsenceAsync(@"class C {
override $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedSealed()
{
await VerifyKeywordAsync(
@"class C {
sealed $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInProperty()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInPropertyAfterAccessor()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { get; $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInPropertyAfterAccessibility()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { get; protected $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInPropertyAfterInternal()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { get; internal $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterCastType1()
{
await VerifyKeywordAsync(AddInsideMethod(
@"return (LeafSegment)$$"));
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterCastType2()
{
await VerifyKeywordAsync(AddInsideMethod(
@"return (LeafSegment)(object)$$"));
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterParenthesizedExpression()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"return (a + b)$$"));
}
[WorkItem(538264, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538264")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInConstMemberInitializer1()
{
// User could say "new int()" here.
await VerifyKeywordAsync(
@"class E {
const int a = $$
}");
}
[WorkItem(538264, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538264")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInConstLocalInitializer1()
{
// User could say "new int()" here.
await VerifyKeywordAsync(
@"class E {
void Goo() {
const int a = $$
}
}");
}
[WorkItem(538264, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538264")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInMemberInitializer1()
{
await VerifyKeywordAsync(
@"class E {
int a = $$
}");
}
[WorkItem(538804, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538804")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInTypeOf()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"typeof($$"));
}
[WorkItem(538804, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538804")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInDefault()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"default($$"));
}
[WorkItem(538804, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538804")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInSizeOf()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"sizeof($$"));
}
[WorkItem(544219, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544219")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInObjectInitializerMemberContext()
{
await VerifyAbsenceAsync(@"
class C
{
public int x, y;
void M()
{
var c = new C { x = 2, y = 3, $$");
}
[WorkItem(544486, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544486")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideInitOfConstFieldDecl()
{
// user could say "new int()" here.
await VerifyKeywordAsync(
@"class C
{
const int value = $$");
}
[WorkItem(544998, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544998")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideStructParameterInitializer()
{
await VerifyKeywordAsync(
@"struct C
{
void M(C c = $$
}");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRefExpression()
{
await VerifyKeywordAsync(AddInsideMethod(
@"ref int x = ref $$"));
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Recommendations
{
public class NewKeywordRecommenderTests : KeywordRecommenderTests
{
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAtRoot()
{
await VerifyKeywordAsync(
@"$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterClass()
{
await VerifyKeywordAsync(
@"class C { }
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterGlobalStatement()
{
await VerifyKeywordAsync(
@"System.Console.WriteLine();
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterGlobalVariableDeclaration()
{
await VerifyKeywordAsync(
@"int i = 0;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInUsingAlias()
{
await VerifyAbsenceAsync(
@"using Goo = $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInGlobalUsingAlias()
{
await VerifyAbsenceAsync(
@"global using Goo = $$");
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestEmptyStatement(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"$$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNewTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C<T> where T : $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterTypeParameterConstraint2()
{
await VerifyKeywordAsync(
@"class C<T>
where T : $$
where U : U");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterMethodTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C {
void Goo<T>()
where T : $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterMethodTypeParameterConstraint2()
{
await VerifyKeywordAsync(
@"class C {
void Goo<T>()
where T : $$
where U : T");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterClassTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C<T> where T : class, $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterStructTypeParameterConstraint()
{
await VerifyAbsenceAsync(
@"class C<T> where T : struct, $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterSimpleTypeParameterConstraint()
{
await VerifyKeywordAsync(
@"class C<T> where T : IGoo, $$");
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestStartOfExpression(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
[WorkItem(34324, "https://github.com/dotnet/roslyn/issues/34324")]
public async Task TestAfterNullCoalescingAssignment(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q ??= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInParenthesizedExpression(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestPlusEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q += $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestMinusEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q -= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestTimesEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q *= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestDivideEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q /= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestModEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q %= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestXorEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q ^= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAndEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q &= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q |= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestLeftShiftEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q <<= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestRightShiftEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"q >>= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterMinus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"- $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterPlus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"+ $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterNot(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"! $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterTilde(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"~ $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryTimes(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a * $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryDivide(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a / $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryMod(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a % $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryPlus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a + $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryMinus(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a - $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryLeftShift(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a << $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryRightShift(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a >> $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryLessThan(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a < $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterBinaryGreaterThan(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a > $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterEqualsEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a == $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterNotEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a != $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterLessThanEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a <= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterGreaterThanEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a >= $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterNullable(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a ?? $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterArrayRankSpecifier1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new int[ $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterArrayRankSpecifier2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new int[expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterConditional1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a ? $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[InlineData(false)]
[InlineData(true, Skip = "https://github.com/dotnet/roslyn/issues/44443")]
public async Task TestAfterConditional2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"a ? expr | $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo( $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo(expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument3(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new Goo( $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInArgument4(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new Goo(expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterRef(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo(ref $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterOut(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Goo(out $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestLambda(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"Action<int> a = i => $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInCollectionInitializer1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new System.Collections.Generic.List<int>() { $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInCollectionInitializer2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"new System.Collections.Generic.List<int>() { expr, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInForeachIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"foreach (var v in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInAwaitForeachIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"await foreach (var v in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInFromIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInJoinIn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
join a in $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInJoinOn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
join a in b on $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInJoinEquals(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
join a in b on equals $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestWhere(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
where $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrderby1(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
orderby $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrderby2(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
orderby a, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestOrderby3(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
orderby a ascending, $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterSelect(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
select $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterGroup(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
group $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterGroupBy(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"var q = from x in y
group expr by $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterReturn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"return $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterYieldReturn(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"yield return $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAttributeReturn()
{
await VerifyAbsenceAsync(
@"[return $$");
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestAfterThrow(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"throw $$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInWhile(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"while ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInUsing(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"using ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInAwaitUsing(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"await using ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInLock(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"lock ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInIf(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"if ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Theory, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
[CombinatorialData]
public async Task TestInSwitch(bool topLevelStatement)
{
await VerifyKeywordAsync(AddInsideMethod(
@"switch ($$", topLevelStatement: topLevelStatement), options: CSharp9ParseOptions);
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterExtern()
{
await VerifyKeywordAsync(@"extern alias Goo;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterUsing()
{
await VerifyKeywordAsync(@"using Goo;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterGlobalUsing()
{
await VerifyKeywordAsync(
@"global using Goo;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNamespace()
{
await VerifyKeywordAsync(@"namespace N {}
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterFileScopedNamespace()
{
await VerifyKeywordAsync(
@"namespace N;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterDelegateDeclaration()
{
await VerifyKeywordAsync(@"delegate void Goo();
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterMethodInClass()
{
await VerifyKeywordAsync(
@"class C {
void Goo() {}
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterFieldInClass()
{
await VerifyKeywordAsync(
@"class C {
int i;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterPropertyInClass()
{
await VerifyKeywordAsync(
@"class C {
int i { get; }
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeUsing()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular,
@"$$
using Goo;");
}
[WpfFact(Skip = "https://github.com/dotnet/roslyn/issues/9880"), Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeUsing_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"$$
using Goo;");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeGlobalUsing()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular,
@"$$
global using Goo;");
}
[WpfFact(Skip = "https://github.com/dotnet/roslyn/issues/9880"), Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotBeforeGlobalUsing_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"$$
global using Goo;");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterAssemblyAttribute()
{
await VerifyKeywordAsync(@"[assembly: goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterRootAttribute()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular, @"[goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRootAttribute_Interactive()
{
// The global function could be hiding a member inherited from System.Object.
await VerifyKeywordAsync(SourceCodeKind.Script, @"[goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedAttribute()
{
await VerifyKeywordAsync(
@"class C {
[goo]
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideStruct()
{
await VerifyKeywordAsync(
@"struct S {
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideInterface()
{
await VerifyKeywordAsync(
@"interface I {
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideClass()
{
await VerifyKeywordAsync(
@"class C {
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterPartial()
=> await VerifyAbsenceAsync(@"partial $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAbstract()
=> await VerifyAbsenceAsync(@"abstract $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterInternal()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterInternal_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterPublic()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"public $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterPublic_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"public $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterStaticInternal()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"static internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterStaticInternal_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"static internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterInternalStatic()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"internal static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterInternalStatic_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"internal static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterInvalidInternal()
=> await VerifyAbsenceAsync(@"virtual internal $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterClass()
=> await VerifyAbsenceAsync(@"class $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterPrivate()
{
await VerifyAbsenceAsync(SourceCodeKind.Regular,
@"private $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterPrivate_Script()
{
await VerifyKeywordAsync(SourceCodeKind.Script,
@"private $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterSealed()
=> await VerifyAbsenceAsync(@"sealed $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterStatic()
=> await VerifyAbsenceAsync(SourceCodeKind.Regular, @"static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterStatic_Interactive()
=> await VerifyKeywordAsync(SourceCodeKind.Script, @"static $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedStatic()
{
await VerifyKeywordAsync(
@"class C {
static $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedInternal()
{
await VerifyKeywordAsync(
@"class C {
internal $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedPrivate()
{
await VerifyKeywordAsync(
@"class C {
private $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterDelegate()
=> await VerifyAbsenceAsync(@"delegate $$");
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedAbstract()
{
await VerifyKeywordAsync(
@"class C {
abstract $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedVirtual()
{
await VerifyKeywordAsync(
@"class C {
virtual $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterNestedNew()
{
await VerifyAbsenceAsync(@"class C {
new $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterNestedOverride()
{
await VerifyAbsenceAsync(@"class C {
override $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterNestedSealed()
{
await VerifyKeywordAsync(
@"class C {
sealed $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInProperty()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInPropertyAfterAccessor()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { get; $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInPropertyAfterAccessibility()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { get; protected $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInPropertyAfterInternal()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { get; internal $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterCastType1()
{
await VerifyKeywordAsync(AddInsideMethod(
@"return (LeafSegment)$$"));
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterCastType2()
{
await VerifyKeywordAsync(AddInsideMethod(
@"return (LeafSegment)(object)$$"));
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterParenthesizedExpression()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"return (a + b)$$"));
}
[WorkItem(538264, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538264")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInConstMemberInitializer1()
{
// User could say "new int()" here.
await VerifyKeywordAsync(
@"class E {
const int a = $$
}");
}
[WorkItem(538264, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538264")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInConstLocalInitializer1()
{
// User could say "new int()" here.
await VerifyKeywordAsync(
@"class E {
void Goo() {
const int a = $$
}
}");
}
[WorkItem(538264, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538264")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInMemberInitializer1()
{
await VerifyKeywordAsync(
@"class E {
int a = $$
}");
}
[WorkItem(538804, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538804")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInTypeOf()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"typeof($$"));
}
[WorkItem(538804, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538804")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInDefault()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"default($$"));
}
[WorkItem(538804, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/538804")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInSizeOf()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"sizeof($$"));
}
[WorkItem(544219, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544219")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInObjectInitializerMemberContext()
{
await VerifyAbsenceAsync(@"
class C
{
public int x, y;
void M()
{
var c = new C { x = 2, y = 3, $$");
}
[WorkItem(544486, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544486")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideInitOfConstFieldDecl()
{
// user could say "new int()" here.
await VerifyKeywordAsync(
@"class C
{
const int value = $$");
}
[WorkItem(544998, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544998")]
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestInsideStructParameterInitializer()
{
await VerifyKeywordAsync(
@"struct C
{
void M(C c = $$
}");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRefExpression()
{
await VerifyKeywordAsync(AddInsideMethod(
@"ref int x = ref $$"));
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/Test2/Rename/RenameCommandHandlerTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Editor.Implementation.InlineRename
Imports Microsoft.CodeAnalysis.Editor.Shared.Extensions
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Extensions
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces
Imports Microsoft.CodeAnalysis.Text.Shared.Extensions
Imports Microsoft.VisualStudio.Commanding
Imports Microsoft.VisualStudio.Text
Imports Microsoft.VisualStudio.Text.Editor
Imports Microsoft.VisualStudio.Text.Editor.Commanding.Commands
Imports Microsoft.VisualStudio.Text.Operations
Namespace Microsoft.CodeAnalysis.Editor.UnitTests.Rename
<[UseExportProvider]>
Public Class RenameCommandHandlerTests
Private Shared Function CreateCommandHandler(workspace As TestWorkspace) As RenameCommandHandler
Return workspace.ExportProvider.GetCommandHandler(Of RenameCommandHandler)(PredefinedCommandHandlerNames.Rename)
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RenameCommandInvokesInlineRename(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
CreateCommandHandler(workspace).ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Throw New Exception("The operation should have been handled."), Utilities.TestCommandExecutionContext.Create())
Dim expectedTriggerToken = workspace.CurrentSolution.Projects.Single().Documents.Single().GetSyntaxRootAsync().Result.FindToken(view.Caret.Position.BufferPosition)
Assert.Equal(expectedTriggerToken.Span.ToSnapshotSpan(view.TextSnapshot), view.Selection.SelectedSpans.Single())
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
<Trait(Traits.Feature, Traits.Features.Interactive)>
Public Sub RenameCommandDisabledInSubmission(host As RenameTestHost)
Using workspace = TestWorkspace.Create(
<Workspace>
<Submission Language="C#" CommonReferences="true">
object $$goo;
</Submission>
</Workspace>,
workspaceKind:=WorkspaceKind.Interactive,
composition:=EditorTestCompositions.EditorFeaturesWpf)
' Force initialization.
workspace.GetOpenDocumentIds().Select(Function(id) workspace.GetTestDocument(id).GetTextView()).ToList()
Dim textView = workspace.Documents.Single().GetTextView()
Dim handler = CreateCommandHandler(workspace)
Dim delegatedToNext = False
Dim nextHandler =
Function()
delegatedToNext = True
Return CommandState.Unavailable
End Function
Dim state = handler.GetCommandState(New RenameCommandArgs(textView, textView.TextBuffer), nextHandler)
Assert.True(delegatedToNext)
Assert.False(state.IsAvailable)
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RenameCommandWithSelectionDoesNotSelect(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|F|]oo
{
}
</Document>
</Project>
</Workspace>, host)
Dim document = workspace.Documents.Single()
Dim view = document.GetTextView()
Dim selectedSpan = workspace.Documents.Single(Function(d) d.SelectedSpans.Any()).SelectedSpans.Single().ToSnapshotSpan(document.GetTextBuffer().CurrentSnapshot)
view.Caret.MoveTo(selectedSpan.End)
view.Selection.Select(selectedSpan, isReversed:=False)
CreateCommandHandler(workspace).ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Throw New Exception("The operation should have been handled."), Utilities.TestCommandExecutionContext.Create())
Assert.Equal(selectedSpan, view.Selection.SelectedSpans.Single())
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function RenameCommandWithReversedSelectionDoesNotSelectOrCrash(host As RenameTestHost) As System.Threading.Tasks.Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|F|]oo
{
}
</Document>
</Project>
</Workspace>, host)
Dim document = workspace.Documents.Single()
Dim view = document.GetTextView()
Dim selectedSpan = workspace.Documents.Single(Function(d) d.SelectedSpans.Any()).SelectedSpans.Single().ToSnapshotSpan(document.GetTextBuffer().CurrentSnapshot)
view.Caret.MoveTo(selectedSpan.End)
view.Selection.Select(selectedSpan, isReversed:=True)
CreateCommandHandler(workspace).ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Throw New Exception("The operation should have been handled."), Utilities.TestCommandExecutionContext.Create())
Await WaitForRename(workspace)
Assert.Equal(selectedSpan.Span, view.Selection.SelectedSpans.Single().Span)
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingOutsideRenameSpanCommitsAndPreservesVirtualSelection(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim session = StartSession(workspace)
editorOperations.MoveLineDown(extendSelection:=False)
Assert.Equal(4, view.Caret.Position.VirtualSpaces)
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "p"c), Sub() editorOperations.InsertText("p"), Utilities.TestCommandExecutionContext.Create())
Assert.Equal(" p", view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RenameCommandNotActiveWhenNotTouchingIdentifier(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int |$$|x = 0;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim commandState = commandHandler.GetCommandState(New RenameCommandArgs(view, view.TextBuffer), Function() New CommandState())
Assert.True(commandState.IsAvailable)
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingSpaceDuringRename(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, " "c),
Sub() AssertEx.Fail("Space should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
session.Cancel()
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingTabDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo
{
Goo f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
' TODO: should we make tab wait instead?
Await WaitForRename(workspace)
' Unfocus the dashboard
Dim dashboard = DirectCast(view.GetAdornmentLayer("RoslynRenameDashboard").Elements(0).Adornment, Dashboard)
dashboard.ShouldReceiveKeyboardNavigation = False
commandHandler.ExecuteCommand(New TabKeyCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Tab should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(3, view.Caret.Position.BufferPosition.GetContainingLine().LineNumber)
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function SelectAllDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo // comment
{
Goo f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim startPosition = view.Caret.Position.BufferPosition.Position
Dim identifierSpan = New Span(startPosition, 3)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Assert.True(view.Selection.IsEmpty())
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
Assert.Equal(identifierSpan, view.Selection.SelectedSpans.Single().Span)
Assert.Equal(identifierSpan.End, view.Caret.Position.BufferPosition.Position)
view.Selection.Clear()
Assert.True(view.Selection.IsEmpty())
Assert.True(commandHandler.ExecuteCommand(New SelectAllCommandArgs(view, view.TextBuffer),
Utilities.TestCommandExecutionContext.Create()))
Assert.Equal(identifierSpan, view.Selection.SelectedSpans.Single().Span)
Assert.Equal(identifierSpan.End, view.Caret.Position.BufferPosition.Position)
commandHandler.ExecuteCommand(New SelectAllCommandArgs(view, view.TextBuffer),
Sub() editorOperations.SelectAll(),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(view.TextBuffer.CurrentSnapshot.GetFullSpan(), view.Selection.SelectedSpans.Single().Span)
End Using
End Function
<WpfTheory>
<WorkItem(851629, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/851629")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function WordDeleteDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|] // comment
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim startPosition = view.Caret.Position.BufferPosition.Position
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextSnapshot, startPosition))
' with the caret at the start, this should delete the whole identifier
commandHandler.ExecuteCommand(New WordDeleteToEndCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Command should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "")
editorOperations.InsertText("this")
Await WaitForRename(workspace)
Assert.Equal("@this", view.TextSnapshot.GetText(startPosition, 5))
' with a selection, we should delete the from the beginning of the rename span to the end of the selection
' Note that the default editor handling would try to delete the '@' character, we override this behavior since
' that '@' character is in a read only region during rename.
view.Selection.Select(New SnapshotSpan(view.TextSnapshot, Span.FromBounds(startPosition + 2, startPosition + 4)), isReversed:=True)
commandHandler.ExecuteCommand(New WordDeleteToStartCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Command should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "s")
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function NavigationDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo // comment
{
Goo f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim startPosition = view.Caret.Position.BufferPosition.Position
Dim identifierSpan = New Span(startPosition, 3)
view.Selection.Select(New SnapshotSpan(view.TextBuffer.CurrentSnapshot, identifierSpan), isReversed:=False)
Dim lineStart = view.Caret.Position.BufferPosition.GetContainingLine().Start.Position
Dim lineEnd = view.Caret.Position.BufferPosition.GetContainingLine().End.Position
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
#Region "LineStart"
' we start with the identifier selected
Assert.Equal(identifierSpan, view.Selection.SelectedSpans.Single().Span)
' LineStart should move to the beginning of identifierSpan
commandHandler.ExecuteCommand(New LineStartCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Home should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(0, view.Selection.SelectedSpans.Single().Span.Length)
Assert.Equal(startPosition, view.Caret.Position.BufferPosition.Position)
' LineStart again should move to the beginning of the line
commandHandler.ExecuteCommand(New LineStartCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToStartOfLine(extendSelection:=False),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(lineStart, view.Caret.Position.BufferPosition.Position)
#End Region
#Region "LineStartExtend"
' Reset the position to the middle of the identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, startPosition + 1))
' LineStartExtend should move to the beginning of identifierSpan and extend the selection
commandHandler.ExecuteCommand(New LineStartExtendCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Shift+Home should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(New Span(startPosition, 1), view.Selection.SelectedSpans.Single().Span)
' LineStartExtend again should move to the beginning of the line and extend the selection
commandHandler.ExecuteCommand(New LineStartExtendCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToStartOfLine(extendSelection:=True),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(Span.FromBounds(lineStart, startPosition + 1), view.Selection.SelectedSpans.Single().Span)
#End Region
#Region "LineEnd"
' Reset the position to the middle of the identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, startPosition + 1))
' LineEnd should move to the end of identifierSpan
commandHandler.ExecuteCommand(New LineEndCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("End should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(0, view.Selection.SelectedSpans.Single().Span.Length)
Assert.Equal(identifierSpan.End, view.Caret.Position.BufferPosition.Position)
' LineEnd again should move to the end of the line
commandHandler.ExecuteCommand(New LineEndCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToEndOfLine(extendSelection:=False),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(lineEnd, view.Caret.Position.BufferPosition.Position)
#End Region
#Region "LineEndExtend"
' Reset the position to the middle of the identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, startPosition + 1))
' LineEndExtend should move to the end of identifierSpan and extend the selection
commandHandler.ExecuteCommand(New LineEndExtendCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Shift+End should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(Span.FromBounds(startPosition + 1, identifierSpan.End), view.Selection.SelectedSpans.Single().Span)
' LineEndExtend again should move to the end of the line and extend the selection
commandHandler.ExecuteCommand(New LineEndExtendCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToEndOfLine(extendSelection:=True),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(Span.FromBounds(startPosition + 1, lineEnd), view.Selection.SelectedSpans.Single().Span)
#End Region
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingTypeCharacterDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim session = StartSession(workspace)
editorOperations.MoveToNextCharacter(extendSelection:=False)
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "$"c),
Sub() editorOperations.InsertText("$"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Goo")
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingInOtherPartsOfFileTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move selection and cursor to a readonly region
Dim span = view.TextBuffer.CurrentSnapshot.GetSpanFromBounds(0, 0)
view.Selection.Select(span, isReversed:=False)
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, span.End))
' Now let's type and that should commit Rename
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' Verify that the key pressed went to the start of the file
Assert.Equal("Z"c, view.TextBuffer.CurrentSnapshot(0))
End Using
End Function
<WpfTheory()>
<WorkItem(820248, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/820248")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function DeletingInEditSpanPropagatesEdit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Delete the first identifier char
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New DeleteKeyCommandArgs(view, view.TextBuffer),
Sub() editorOperations.Delete(),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "oo")
Assert.NotNull(workspace.GetService(Of IInlineRenameService).ActiveSession)
session.Cancel()
End Using
End Function
<WpfTheory>
<WorkItem(820248, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/820248")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function BackspacingInEditSpanPropagatesEdit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|Go$$o|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Delete the first identifier char
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New BackspaceKeyCommandArgs(view, view.TextBuffer),
Sub() editorOperations.Backspace(),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Go")
Assert.NotNull(workspace.GetService(Of IInlineRenameService).ActiveSession)
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function DeletingInOtherPartsOfFileTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move selection and cursor to a readonly region
Dim span = view.TextBuffer.CurrentSnapshot.GetSpanFromBounds(0, 0)
view.Selection.Select(span, isReversed:=False)
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, span.End))
' Now let's type and that should commit Rename
commandHandler.ExecuteCommand(New DeleteKeyCommandArgs(view, view.TextBuffer),
Sub() editorOperations.Delete(),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
End Using
End Function
<WorkItem(577178, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/577178")>
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingInOtherFileTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
<Document>
class Bar
{
Bar b;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.ElementAt(0).GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move the cursor to the next file
Dim newview = workspace.Documents.ElementAt(1).GetTextView()
editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(newview)
newview.Caret.MoveTo(New SnapshotPoint(newview.TextBuffer.CurrentSnapshot, 0))
' Type the char at the beginning of the file
commandHandler.ExecuteCommand(New TypeCharCommandArgs(newview, newview.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' Verify that the key pressed went to the start of the file
Assert.Equal("Z"c, newview.TextBuffer.CurrentSnapshot(0))
End Using
End Function
<WorkItem(577178, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/577178")>
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingInOtherFileWithConflictTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
public partial class A
{
public class [|$$B|]
{
}
}
</Document>
<Document>
public partial class A
{
public BB bb;
}
public class BB
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.ElementAt(0).GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move the cursor to the next file
Dim newview = workspace.Documents.ElementAt(1).GetTextView()
editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(newview)
newview.Caret.MoveTo(New SnapshotPoint(newview.TextBuffer.CurrentSnapshot, 0))
' Type the char at the beginning of the file
commandHandler.ExecuteCommand(New TypeCharCommandArgs(newview, newview.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BB")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' Verify that the key pressed went to the start of the file
Assert.Equal("Z"c, newview.TextBuffer.CurrentSnapshot(0))
End Using
End Function
<WpfTheory, CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function RenameMemberFromCref(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" AssemblyName="CSharpAssembly" CommonReferences="true">
<Document FilePath="Test.cs">
<![CDATA[
class Program
{
/// <see cref="Program.[|$$Main|]"/> to start the program.
static void [|Main|](string[] args)
{
}
}
]]>
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "Z"c), Sub() editorOperations.InsertText("Z"), Utilities.TestCommandExecutionContext.Create())
commandHandler.ExecuteCommand(New ReturnKeyCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Z")
End Using
End Function
<WpfTheory, WorkItem(878173, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/878173"), CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function RenameInDocumentsWithoutOpenTextViews(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" AssemblyName="CSharpAssembly" CommonReferences="true">
<Document FilePath="Test.cs">
<![CDATA[
partial class [|$$Program|]
{
static void Main(string[] args)
{
}
}
]]>
</Document>
<Document FilePath="Test2.cs">
<![CDATA[
partial class [|Program|]
{
}
]]>
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.First(Function(d) d.Name = "Test.cs").GetTextView()
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Dim closedDocument = workspace.Documents.First(Function(d) d.Name = "Test2.cs")
closedDocument.CloseTextView()
Assert.True(workspace.IsDocumentOpen(closedDocument.Id))
commandHandler.ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Z")
End Using
End Function
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlEnterDuringRenameCSharp(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int ba$$r;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineAboveCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineAbove(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlEnterOutsideSpansDuringRenameCSharp(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int ba$$r;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Move caret out of rename session span
editorOperations.MoveLineDown(extendSelection:=False)
commandHandler.ExecuteCommand(New OpenLineAboveCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineAbove(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlShiftEnterDuringRenameCSharp(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int ba$$r;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineBelowCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineBelow(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlEnterDuringRenameBasic(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineAboveCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineAbove(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlShiftEnterDuringRenameBasic(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineBelowCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineBelow(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(1142095, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1142095")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function SaveDuringRenameCommits(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"), Utilities.TestCommandExecutionContext.Create())
' Now save the document, which should commit Rename
commandHandler.ExecuteCommand(New SaveCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
End Using
End Function
<WpfTheory>
<WorkItem(1142701, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1142701")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub MoveSelectedLinesUpDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New MoveSelectedLinesUpCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(1142701, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1142701")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub MoveSelectedLinesDownDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New MoveSelectedLinesDownCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub ReorderParametersDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New ReorderParametersCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RemoveParametersDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New RemoveParametersCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub ExtractInterfaceDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New ExtractInterfaceCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub EncapsulateFieldDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New EncapsulateFieldCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function CutDuringRename_InsideIdentifier(host As RenameTestHost) As Task
Await VerifySessionActiveAfterCutPasteInsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New CutCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function PasteDuringRename_InsideIdentifier(host As RenameTestHost) As Task
Await VerifySessionActiveAfterCutPasteInsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New PasteCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub CutDuringRename_OutsideIdentifier(host As RenameTestHost)
VerifySessionCommittedAfterCutPasteOutsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New CutCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub PasteDuringRename_OutsideIdentifier(host As RenameTestHost)
VerifySessionCommittedAfterCutPasteOutsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New PasteCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
Private Shared Sub VerifyCommandCommitsRenameSessionAndExecutesCommand(host As RenameTestHost, executeCommand As Action(Of RenameCommandHandler, IWpfTextView, Action))
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
// Comment
class [|C$$|]
{
[|C|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "D"c),
Sub() editorOperations.InsertText("D"),
Utilities.TestCommandExecutionContext.Create())
' Then execute the command
Dim commandInvokedString = "/*Command Invoked*/"
executeCommand(commandHandler, view, Sub() editorOperations.InsertText(commandInvokedString))
' Verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
Assert.Contains("D f", view.TextBuffer.CurrentSnapshot.GetText())
' Verify the command was routed to the editor.
Assert.Contains(commandInvokedString, view.TextBuffer.CurrentSnapshot.GetText())
End Using
End Sub
Private Shared Async Function VerifySessionActiveAfterCutPasteInsideIdentifier(host As RenameTestHost, executeCommand As Action(Of RenameCommandHandler, IWpfTextView, Action)) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
// Comment
class [|C$$|]
{
[|C|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Then execute the command
Dim commandInvokedString = "commandInvoked"
executeCommand(commandHandler, view, Sub() editorOperations.InsertText(commandInvokedString))
' Verify rename session is still active
Assert.NotNull(workspace.GetService(Of IInlineRenameService).ActiveSession)
Await VerifyTagsAreCorrect(workspace, commandInvokedString)
End Using
End Function
Private Shared Sub VerifySessionCommittedAfterCutPasteOutsideIdentifier(host As RenameTestHost, executeCommand As Action(Of RenameCommandHandler, IWpfTextView, Action))
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
// Comment
class [|C$$|]
{
[|C|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "D"c),
Sub() editorOperations.InsertText("D"),
Utilities.TestCommandExecutionContext.Create())
' Then execute the command
Dim commandInvokedString = "commandInvoked"
Dim selectionStart = workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value - 6
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, selectionStart))
view.SetSelection(New SnapshotSpan(view.TextBuffer.CurrentSnapshot, New Span(selectionStart, 2)))
executeCommand(commandHandler, view, Sub() editorOperations.InsertText(commandInvokedString))
' Verify rename session was committed
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
Assert.Contains("D f", view.TextBuffer.CurrentSnapshot.GetText())
Assert.Contains(commandInvokedString, view.TextBuffer.CurrentSnapshot.GetText())
End Using
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Editor.Implementation.InlineRename
Imports Microsoft.CodeAnalysis.Editor.Shared.Extensions
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Extensions
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces
Imports Microsoft.CodeAnalysis.Text.Shared.Extensions
Imports Microsoft.VisualStudio.Commanding
Imports Microsoft.VisualStudio.Text
Imports Microsoft.VisualStudio.Text.Editor
Imports Microsoft.VisualStudio.Text.Editor.Commanding.Commands
Imports Microsoft.VisualStudio.Text.Operations
Namespace Microsoft.CodeAnalysis.Editor.UnitTests.Rename
<[UseExportProvider]>
Public Class RenameCommandHandlerTests
Private Shared Function CreateCommandHandler(workspace As TestWorkspace) As RenameCommandHandler
Return workspace.ExportProvider.GetCommandHandler(Of RenameCommandHandler)(PredefinedCommandHandlerNames.Rename)
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RenameCommandInvokesInlineRename(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
CreateCommandHandler(workspace).ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Throw New Exception("The operation should have been handled."), Utilities.TestCommandExecutionContext.Create())
Dim expectedTriggerToken = workspace.CurrentSolution.Projects.Single().Documents.Single().GetSyntaxRootAsync().Result.FindToken(view.Caret.Position.BufferPosition)
Assert.Equal(expectedTriggerToken.Span.ToSnapshotSpan(view.TextSnapshot), view.Selection.SelectedSpans.Single())
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
<Trait(Traits.Feature, Traits.Features.Interactive)>
Public Sub RenameCommandDisabledInSubmission(host As RenameTestHost)
Using workspace = TestWorkspace.Create(
<Workspace>
<Submission Language="C#" CommonReferences="true">
object $$goo;
</Submission>
</Workspace>,
workspaceKind:=WorkspaceKind.Interactive,
composition:=EditorTestCompositions.EditorFeaturesWpf)
' Force initialization.
workspace.GetOpenDocumentIds().Select(Function(id) workspace.GetTestDocument(id).GetTextView()).ToList()
Dim textView = workspace.Documents.Single().GetTextView()
Dim handler = CreateCommandHandler(workspace)
Dim delegatedToNext = False
Dim nextHandler =
Function()
delegatedToNext = True
Return CommandState.Unavailable
End Function
Dim state = handler.GetCommandState(New RenameCommandArgs(textView, textView.TextBuffer), nextHandler)
Assert.True(delegatedToNext)
Assert.False(state.IsAvailable)
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RenameCommandWithSelectionDoesNotSelect(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|F|]oo
{
}
</Document>
</Project>
</Workspace>, host)
Dim document = workspace.Documents.Single()
Dim view = document.GetTextView()
Dim selectedSpan = workspace.Documents.Single(Function(d) d.SelectedSpans.Any()).SelectedSpans.Single().ToSnapshotSpan(document.GetTextBuffer().CurrentSnapshot)
view.Caret.MoveTo(selectedSpan.End)
view.Selection.Select(selectedSpan, isReversed:=False)
CreateCommandHandler(workspace).ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Throw New Exception("The operation should have been handled."), Utilities.TestCommandExecutionContext.Create())
Assert.Equal(selectedSpan, view.Selection.SelectedSpans.Single())
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function RenameCommandWithReversedSelectionDoesNotSelectOrCrash(host As RenameTestHost) As System.Threading.Tasks.Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|F|]oo
{
}
</Document>
</Project>
</Workspace>, host)
Dim document = workspace.Documents.Single()
Dim view = document.GetTextView()
Dim selectedSpan = workspace.Documents.Single(Function(d) d.SelectedSpans.Any()).SelectedSpans.Single().ToSnapshotSpan(document.GetTextBuffer().CurrentSnapshot)
view.Caret.MoveTo(selectedSpan.End)
view.Selection.Select(selectedSpan, isReversed:=True)
CreateCommandHandler(workspace).ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Throw New Exception("The operation should have been handled."), Utilities.TestCommandExecutionContext.Create())
Await WaitForRename(workspace)
Assert.Equal(selectedSpan.Span, view.Selection.SelectedSpans.Single().Span)
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingOutsideRenameSpanCommitsAndPreservesVirtualSelection(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim session = StartSession(workspace)
editorOperations.MoveLineDown(extendSelection:=False)
Assert.Equal(4, view.Caret.Position.VirtualSpaces)
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "p"c), Sub() editorOperations.InsertText("p"), Utilities.TestCommandExecutionContext.Create())
Assert.Equal(" p", view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RenameCommandNotActiveWhenNotTouchingIdentifier(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int |$$|x = 0;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim commandState = commandHandler.GetCommandState(New RenameCommandArgs(view, view.TextBuffer), Function() New CommandState())
Assert.True(commandState.IsAvailable)
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingSpaceDuringRename(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, " "c),
Sub() AssertEx.Fail("Space should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
session.Cancel()
End Using
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingTabDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo
{
Goo f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
' TODO: should we make tab wait instead?
Await WaitForRename(workspace)
' Unfocus the dashboard
Dim dashboard = DirectCast(view.GetAdornmentLayer("RoslynRenameDashboard").Elements(0).Adornment, Dashboard)
dashboard.ShouldReceiveKeyboardNavigation = False
commandHandler.ExecuteCommand(New TabKeyCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Tab should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(3, view.Caret.Position.BufferPosition.GetContainingLine().LineNumber)
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function SelectAllDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo // comment
{
Goo f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim startPosition = view.Caret.Position.BufferPosition.Position
Dim identifierSpan = New Span(startPosition, 3)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Assert.True(view.Selection.IsEmpty())
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
Assert.Equal(identifierSpan, view.Selection.SelectedSpans.Single().Span)
Assert.Equal(identifierSpan.End, view.Caret.Position.BufferPosition.Position)
view.Selection.Clear()
Assert.True(view.Selection.IsEmpty())
Assert.True(commandHandler.ExecuteCommand(New SelectAllCommandArgs(view, view.TextBuffer),
Utilities.TestCommandExecutionContext.Create()))
Assert.Equal(identifierSpan, view.Selection.SelectedSpans.Single().Span)
Assert.Equal(identifierSpan.End, view.Caret.Position.BufferPosition.Position)
commandHandler.ExecuteCommand(New SelectAllCommandArgs(view, view.TextBuffer),
Sub() editorOperations.SelectAll(),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(view.TextBuffer.CurrentSnapshot.GetFullSpan(), view.Selection.SelectedSpans.Single().Span)
End Using
End Function
<WpfTheory>
<WorkItem(851629, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/851629")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function WordDeleteDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|] // comment
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim startPosition = view.Caret.Position.BufferPosition.Position
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextSnapshot, startPosition))
' with the caret at the start, this should delete the whole identifier
commandHandler.ExecuteCommand(New WordDeleteToEndCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Command should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "")
editorOperations.InsertText("this")
Await WaitForRename(workspace)
Assert.Equal("@this", view.TextSnapshot.GetText(startPosition, 5))
' with a selection, we should delete the from the beginning of the rename span to the end of the selection
' Note that the default editor handling would try to delete the '@' character, we override this behavior since
' that '@' character is in a read only region during rename.
view.Selection.Select(New SnapshotSpan(view.TextSnapshot, Span.FromBounds(startPosition + 2, startPosition + 4)), isReversed:=True)
commandHandler.ExecuteCommand(New WordDeleteToStartCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Command should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "s")
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function NavigationDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class $$Goo // comment
{
Goo f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim startPosition = view.Caret.Position.BufferPosition.Position
Dim identifierSpan = New Span(startPosition, 3)
view.Selection.Select(New SnapshotSpan(view.TextBuffer.CurrentSnapshot, identifierSpan), isReversed:=False)
Dim lineStart = view.Caret.Position.BufferPosition.GetContainingLine().Start.Position
Dim lineEnd = view.Caret.Position.BufferPosition.GetContainingLine().End.Position
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
#Region "LineStart"
' we start with the identifier selected
Assert.Equal(identifierSpan, view.Selection.SelectedSpans.Single().Span)
' LineStart should move to the beginning of identifierSpan
commandHandler.ExecuteCommand(New LineStartCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Home should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(0, view.Selection.SelectedSpans.Single().Span.Length)
Assert.Equal(startPosition, view.Caret.Position.BufferPosition.Position)
' LineStart again should move to the beginning of the line
commandHandler.ExecuteCommand(New LineStartCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToStartOfLine(extendSelection:=False),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(lineStart, view.Caret.Position.BufferPosition.Position)
#End Region
#Region "LineStartExtend"
' Reset the position to the middle of the identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, startPosition + 1))
' LineStartExtend should move to the beginning of identifierSpan and extend the selection
commandHandler.ExecuteCommand(New LineStartExtendCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Shift+Home should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(New Span(startPosition, 1), view.Selection.SelectedSpans.Single().Span)
' LineStartExtend again should move to the beginning of the line and extend the selection
commandHandler.ExecuteCommand(New LineStartExtendCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToStartOfLine(extendSelection:=True),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(Span.FromBounds(lineStart, startPosition + 1), view.Selection.SelectedSpans.Single().Span)
#End Region
#Region "LineEnd"
' Reset the position to the middle of the identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, startPosition + 1))
' LineEnd should move to the end of identifierSpan
commandHandler.ExecuteCommand(New LineEndCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("End should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(0, view.Selection.SelectedSpans.Single().Span.Length)
Assert.Equal(identifierSpan.End, view.Caret.Position.BufferPosition.Position)
' LineEnd again should move to the end of the line
commandHandler.ExecuteCommand(New LineEndCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToEndOfLine(extendSelection:=False),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(lineEnd, view.Caret.Position.BufferPosition.Position)
#End Region
#Region "LineEndExtend"
' Reset the position to the middle of the identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, startPosition + 1))
' LineEndExtend should move to the end of identifierSpan and extend the selection
commandHandler.ExecuteCommand(New LineEndExtendCommandArgs(view, view.TextBuffer),
Sub() AssertEx.Fail("Shift+End should not have been passed to the editor."),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(Span.FromBounds(startPosition + 1, identifierSpan.End), view.Selection.SelectedSpans.Single().Span)
' LineEndExtend again should move to the end of the line and extend the selection
commandHandler.ExecuteCommand(New LineEndExtendCommandArgs(view, view.TextBuffer),
Sub() editorOperations.MoveToEndOfLine(extendSelection:=True),
Utilities.TestCommandExecutionContext.Create())
Assert.Equal(Span.FromBounds(startPosition + 1, lineEnd), view.Selection.SelectedSpans.Single().Span)
#End Region
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingTypeCharacterDuringRename(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
Dim session = StartSession(workspace)
editorOperations.MoveToNextCharacter(extendSelection:=False)
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "$"c),
Sub() editorOperations.InsertText("$"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Goo")
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingInOtherPartsOfFileTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move selection and cursor to a readonly region
Dim span = view.TextBuffer.CurrentSnapshot.GetSpanFromBounds(0, 0)
view.Selection.Select(span, isReversed:=False)
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, span.End))
' Now let's type and that should commit Rename
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' Verify that the key pressed went to the start of the file
Assert.Equal("Z"c, view.TextBuffer.CurrentSnapshot(0))
End Using
End Function
<WpfTheory()>
<WorkItem(820248, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/820248")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function DeletingInEditSpanPropagatesEdit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Delete the first identifier char
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New DeleteKeyCommandArgs(view, view.TextBuffer),
Sub() editorOperations.Delete(),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "oo")
Assert.NotNull(workspace.GetService(Of IInlineRenameService).ActiveSession)
session.Cancel()
End Using
End Function
<WpfTheory>
<WorkItem(820248, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/820248")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function BackspacingInEditSpanPropagatesEdit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|Go$$o|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Delete the first identifier char
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New BackspaceKeyCommandArgs(view, view.TextBuffer),
Sub() editorOperations.Backspace(),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Go")
Assert.NotNull(workspace.GetService(Of IInlineRenameService).ActiveSession)
session.Cancel()
End Using
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function DeletingInOtherPartsOfFileTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move selection and cursor to a readonly region
Dim span = view.TextBuffer.CurrentSnapshot.GetSpanFromBounds(0, 0)
view.Selection.Select(span, isReversed:=False)
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, span.End))
' Now let's type and that should commit Rename
commandHandler.ExecuteCommand(New DeleteKeyCommandArgs(view, view.TextBuffer),
Sub() editorOperations.Delete(),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
End Using
End Function
<WorkItem(577178, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/577178")>
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingInOtherFileTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
<Document>
class Bar
{
Bar b;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.ElementAt(0).GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move the cursor to the next file
Dim newview = workspace.Documents.ElementAt(1).GetTextView()
editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(newview)
newview.Caret.MoveTo(New SnapshotPoint(newview.TextBuffer.CurrentSnapshot, 0))
' Type the char at the beginning of the file
commandHandler.ExecuteCommand(New TypeCharCommandArgs(newview, newview.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' Verify that the key pressed went to the start of the file
Assert.Equal("Z"c, newview.TextBuffer.CurrentSnapshot(0))
End Using
End Function
<WorkItem(577178, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/577178")>
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function TypingInOtherFileWithConflictTriggersCommit(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
public partial class A
{
public class [|$$B|]
{
}
}
</Document>
<Document>
public partial class A
{
public BB bb;
}
public class BB
{
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.ElementAt(0).GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
view.Selection.Clear()
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"),
Utilities.TestCommandExecutionContext.Create())
' Move the cursor to the next file
Dim newview = workspace.Documents.ElementAt(1).GetTextView()
editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(newview)
newview.Caret.MoveTo(New SnapshotPoint(newview.TextBuffer.CurrentSnapshot, 0))
' Type the char at the beginning of the file
commandHandler.ExecuteCommand(New TypeCharCommandArgs(newview, newview.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BB")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' Verify that the key pressed went to the start of the file
Assert.Equal("Z"c, newview.TextBuffer.CurrentSnapshot(0))
End Using
End Function
<WpfTheory, CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function RenameMemberFromCref(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" AssemblyName="CSharpAssembly" CommonReferences="true">
<Document FilePath="Test.cs">
<![CDATA[
class Program
{
/// <see cref="Program.[|$$Main|]"/> to start the program.
static void [|Main|](string[] args)
{
}
}
]]>
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "Z"c), Sub() editorOperations.InsertText("Z"), Utilities.TestCommandExecutionContext.Create())
commandHandler.ExecuteCommand(New ReturnKeyCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Z")
End Using
End Function
<WpfTheory, WorkItem(878173, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/878173"), CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function RenameInDocumentsWithoutOpenTextViews(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" AssemblyName="CSharpAssembly" CommonReferences="true">
<Document FilePath="Test.cs">
<![CDATA[
partial class [|$$Program|]
{
static void Main(string[] args)
{
}
}
]]>
</Document>
<Document FilePath="Test2.cs">
<![CDATA[
partial class [|Program|]
{
}
]]>
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.First(Function(d) d.Name = "Test.cs").GetTextView()
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
Dim commandHandler = CreateCommandHandler(workspace)
Dim closedDocument = workspace.Documents.First(Function(d) d.Name = "Test2.cs")
closedDocument.CloseTextView()
Assert.True(workspace.IsDocumentOpen(closedDocument.Id))
commandHandler.ExecuteCommand(New RenameCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "Z"c),
Sub() editorOperations.InsertText("Z"),
Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "Z")
End Using
End Function
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlEnterDuringRenameCSharp(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int ba$$r;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineAboveCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineAbove(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlEnterOutsideSpansDuringRenameCSharp(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int ba$$r;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Move caret out of rename session span
editorOperations.MoveLineDown(extendSelection:=False)
commandHandler.ExecuteCommand(New OpenLineAboveCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineAbove(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlShiftEnterDuringRenameCSharp(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class Goo
{
int ba$$r;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineBelowCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineBelow(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlEnterDuringRenameBasic(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineAboveCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineAbove(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(942811, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/942811")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub TypingCtrlShiftEnterDuringRenameBasic(host As RenameTestHost)
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="Visual Basic" CommonReferences="true">
<Document>
Class [|Go$$o|]
End Class
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
commandHandler.ExecuteCommand(New OpenLineBelowCommandArgs(view, view.TextBuffer),
Sub() editorOperations.OpenLineBelow(),
Utilities.TestCommandExecutionContext.Create())
' verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
' verify the command was routed to the editor and an empty line was inserted.
Assert.Equal(String.Empty, view.Caret.Position.BufferPosition.GetContainingLine.GetText())
End Using
End Sub
<WpfTheory>
<WorkItem(1142095, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1142095")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function SaveDuringRenameCommits(host As RenameTestHost) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
class [|$$Goo|]
{
[|Goo|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Await WaitForRename(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService).GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "B"c),
Sub() editorOperations.InsertText("B"), Utilities.TestCommandExecutionContext.Create())
' Now save the document, which should commit Rename
commandHandler.ExecuteCommand(New SaveCommandArgs(view, view.TextBuffer), Sub() Exit Sub, Utilities.TestCommandExecutionContext.Create())
Await VerifyTagsAreCorrect(workspace, "BGoo")
' Rename session was indeed committed and is no longer active
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
End Using
End Function
<WpfTheory>
<WorkItem(1142701, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1142701")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub MoveSelectedLinesUpDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New MoveSelectedLinesUpCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(1142701, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1142701")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub MoveSelectedLinesDownDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New MoveSelectedLinesDownCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub ReorderParametersDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New ReorderParametersCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub RemoveParametersDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New RemoveParametersCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub ExtractInterfaceDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New ExtractInterfaceCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<WorkItem(991517, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/991517")>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub EncapsulateFieldDuringRename(host As RenameTestHost)
VerifyCommandCommitsRenameSessionAndExecutesCommand(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New EncapsulateFieldCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function CutDuringRename_InsideIdentifier(host As RenameTestHost) As Task
Await VerifySessionActiveAfterCutPasteInsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New CutCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Async Function PasteDuringRename_InsideIdentifier(host As RenameTestHost) As Task
Await VerifySessionActiveAfterCutPasteInsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New PasteCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Function
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub CutDuringRename_OutsideIdentifier(host As RenameTestHost)
VerifySessionCommittedAfterCutPasteOutsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New CutCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
<WpfTheory>
<CombinatorialData, Trait(Traits.Feature, Traits.Features.Rename)>
Public Sub PasteDuringRename_OutsideIdentifier(host As RenameTestHost)
VerifySessionCommittedAfterCutPasteOutsideIdentifier(
host,
Sub(commandHandler As RenameCommandHandler, view As IWpfTextView, nextHandler As Action)
commandHandler.ExecuteCommand(New PasteCommandArgs(view, view.TextBuffer), nextHandler, Utilities.TestCommandExecutionContext.Create())
End Sub)
End Sub
Private Shared Sub VerifyCommandCommitsRenameSessionAndExecutesCommand(host As RenameTestHost, executeCommand As Action(Of RenameCommandHandler, IWpfTextView, Action))
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
// Comment
class [|C$$|]
{
[|C|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "D"c),
Sub() editorOperations.InsertText("D"),
Utilities.TestCommandExecutionContext.Create())
' Then execute the command
Dim commandInvokedString = "/*Command Invoked*/"
executeCommand(commandHandler, view, Sub() editorOperations.InsertText(commandInvokedString))
' Verify rename session was committed.
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
Assert.Contains("D f", view.TextBuffer.CurrentSnapshot.GetText())
' Verify the command was routed to the editor.
Assert.Contains(commandInvokedString, view.TextBuffer.CurrentSnapshot.GetText())
End Using
End Sub
Private Shared Async Function VerifySessionActiveAfterCutPasteInsideIdentifier(host As RenameTestHost, executeCommand As Action(Of RenameCommandHandler, IWpfTextView, Action)) As Task
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
// Comment
class [|C$$|]
{
[|C|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Then execute the command
Dim commandInvokedString = "commandInvoked"
executeCommand(commandHandler, view, Sub() editorOperations.InsertText(commandInvokedString))
' Verify rename session is still active
Assert.NotNull(workspace.GetService(Of IInlineRenameService).ActiveSession)
Await VerifyTagsAreCorrect(workspace, commandInvokedString)
End Using
End Function
Private Shared Sub VerifySessionCommittedAfterCutPasteOutsideIdentifier(host As RenameTestHost, executeCommand As Action(Of RenameCommandHandler, IWpfTextView, Action))
Using workspace = CreateWorkspaceWithWaiter(
<Workspace>
<Project Language="C#" CommonReferences="true">
<Document>
// Comment
class [|C$$|]
{
[|C|] f;
}
</Document>
</Project>
</Workspace>, host)
Dim view = workspace.Documents.Single().GetTextView()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
Dim commandHandler = CreateCommandHandler(workspace)
Dim session = StartSession(workspace)
Dim editorOperations = workspace.GetService(Of IEditorOperationsFactoryService)().GetEditorOperations(view)
' Type first in the main identifier
view.Selection.Clear()
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value))
commandHandler.ExecuteCommand(New TypeCharCommandArgs(view, view.TextBuffer, "D"c),
Sub() editorOperations.InsertText("D"),
Utilities.TestCommandExecutionContext.Create())
' Then execute the command
Dim commandInvokedString = "commandInvoked"
Dim selectionStart = workspace.Documents.Single(Function(d) d.CursorPosition.HasValue).CursorPosition.Value - 6
view.Caret.MoveTo(New SnapshotPoint(view.TextBuffer.CurrentSnapshot, selectionStart))
view.SetSelection(New SnapshotSpan(view.TextBuffer.CurrentSnapshot, New Span(selectionStart, 2)))
executeCommand(commandHandler, view, Sub() editorOperations.InsertText(commandInvokedString))
' Verify rename session was committed
Assert.Null(workspace.GetService(Of IInlineRenameService).ActiveSession)
Assert.Contains("D f", view.TextBuffer.CurrentSnapshot.GetText())
Assert.Contains(commandInvokedString, view.TextBuffer.CurrentSnapshot.GetText())
End Using
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/SharedUtilitiesAndExtensions/Compiler/CSharp/Formatting/Rules/TokenBasedFormattingRule.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Utilities;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Editing;
using Microsoft.CodeAnalysis.Formatting.Rules;
using Microsoft.CodeAnalysis.Options;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Formatting
{
internal sealed class TokenBasedFormattingRule : BaseFormattingRule
{
internal const string Name = "CSharp Token Based Formatting Rule";
private readonly CachedOptions _options;
public TokenBasedFormattingRule()
: this(new CachedOptions(null))
{
}
private TokenBasedFormattingRule(CachedOptions options)
{
_options = options;
}
public override AbstractFormattingRule WithOptions(AnalyzerConfigOptions options)
{
var cachedOptions = new CachedOptions(options);
if (cachedOptions == _options)
{
return this;
}
return new TokenBasedFormattingRule(cachedOptions);
}
public override AdjustNewLinesOperation? GetAdjustNewLinesOperation(in SyntaxToken previousToken, in SyntaxToken currentToken, in NextGetAdjustNewLinesOperation nextOperation)
{
////////////////////////////////////////////////////
// brace related operations
// * { or * }
switch (currentToken.Kind())
{
case SyntaxKind.OpenBraceToken:
if (currentToken.IsInterpolation())
{
return null;
}
if (!previousToken.IsParenInParenthesizedExpression())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
break;
case SyntaxKind.CloseBraceToken:
if (currentToken.IsInterpolation())
{
return null;
}
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// do { } while case
if (previousToken.Kind() == SyntaxKind.CloseBraceToken && currentToken.Kind() == SyntaxKind.WhileKeyword)
{
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
// { * or } *
switch (previousToken.Kind())
{
case SyntaxKind.CloseBraceToken:
if (previousToken.IsInterpolation())
{
return null;
}
if (!previousToken.IsCloseBraceOfExpression())
{
if (!currentToken.IsKind(SyntaxKind.SemicolonToken) &&
!currentToken.IsParenInParenthesizedExpression() &&
!currentToken.IsCommaInInitializerExpression() &&
!currentToken.IsCommaInAnyArgumentsList() &&
!currentToken.IsCommaInTupleExpression() &&
!currentToken.IsParenInArgumentList() &&
!currentToken.IsDotInMemberAccess() &&
!currentToken.IsCloseParenInStatement() &&
!currentToken.IsEqualsTokenInAutoPropertyInitializers() &&
!currentToken.IsColonInCasePatternSwitchLabel() && // no newline required before colon in pattern-switch-label (ex: `case {<pattern>}:`)
!currentToken.IsColonInSwitchExpressionArm()) // no newline required before colon in switch-expression-arm (ex: `{<pattern>}: expression`)
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
}
break;
case SyntaxKind.OpenBraceToken:
if (previousToken.IsInterpolation())
{
return null;
}
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
///////////////////////////////////////////////////
// statement related operations
// object and anonymous initializer "," case
if (previousToken.IsCommaInInitializerExpression())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// , * in switch expression arm
// ```
// e switch
// {
// pattern1: expression1, // newline with minimum of 1 line (each arm must be on its own line)
// pattern2: expression2 ...
// ```
if (previousToken.IsCommaInSwitchExpression())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// , * in property sub-pattern
// ```
// e is
// {
// property1: pattern1, // newline so the next line should be indented same as this one
// property2: pattern2, property3: pattern3, ... // but with minimum 0 lines so each property isn't forced to its own line
// ```
if (previousToken.IsCommaInPropertyPatternClause())
{
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
// else * except else if case
if (previousToken.Kind() == SyntaxKind.ElseKeyword && currentToken.Kind() != SyntaxKind.IfKeyword)
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// , * in enum declarations
if (previousToken.IsCommaInEnumDeclaration())
{
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
// : cases
if (previousToken.IsColonInSwitchLabel() ||
previousToken.IsColonInLabeledStatement())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// embedded statement
if (previousToken.Kind() == SyntaxKind.CloseParenToken && previousToken.Parent.IsEmbeddedStatementOwnerWithCloseParen())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
if (previousToken.Kind() == SyntaxKind.DoKeyword && previousToken.Parent.IsKind(SyntaxKind.DoStatement))
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// for (int i = 10; i < 10; i++) case
if (previousToken.IsSemicolonInForStatement())
{
return nextOperation.Invoke(in previousToken, in currentToken);
}
// ; case in the switch case statement and else condition
if (previousToken.Kind() == SyntaxKind.SemicolonToken &&
(currentToken.Kind() == SyntaxKind.CaseKeyword || currentToken.Kind() == SyntaxKind.DefaultKeyword || currentToken.Kind() == SyntaxKind.ElseKeyword))
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// ; * or ; * for using directive
if (previousToken.Kind() == SyntaxKind.SemicolonToken)
{
return AdjustNewLinesAfterSemicolonToken(previousToken, currentToken);
}
// attribute case ] *
// force to next line for top level attributes
if (previousToken.Kind() == SyntaxKind.CloseBracketToken && previousToken.Parent is AttributeListSyntax)
{
var attributeOwner = previousToken.Parent?.Parent;
if (attributeOwner is CompilationUnitSyntax ||
attributeOwner is MemberDeclarationSyntax ||
attributeOwner is AccessorDeclarationSyntax)
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
return nextOperation.Invoke(in previousToken, in currentToken);
}
private AdjustNewLinesOperation AdjustNewLinesAfterSemicolonToken(
SyntaxToken previousToken, SyntaxToken currentToken)
{
// between anything that isn't a using directive, we don't touch newlines after a semicolon
if (!(previousToken.Parent is UsingDirectiveSyntax previousUsing))
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
// if the user is separating using-groups, and we're between two usings, and these
// usings *should* be separated, then do so (if the usings were already properly
// sorted).
if (_options.SeparateImportDirectiveGroups &&
currentToken.Parent is UsingDirectiveSyntax currentUsing &&
UsingsAndExternAliasesOrganizer.NeedsGrouping(previousUsing, currentUsing))
{
RoslynDebug.AssertNotNull(currentUsing.Parent);
var usings = GetUsings(currentUsing.Parent);
if (usings.IsSorted(UsingsAndExternAliasesDirectiveComparer.SystemFirstInstance) ||
usings.IsSorted(UsingsAndExternAliasesDirectiveComparer.NormalInstance))
{
// Force at least one blank line here.
return CreateAdjustNewLinesOperation(2, AdjustNewLinesOption.PreserveLines);
}
}
// For all other cases where we have a using-directive, just make sure it's followed by
// a new-line.
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
private static SyntaxList<UsingDirectiveSyntax> GetUsings(SyntaxNode node)
=> node switch
{
CompilationUnitSyntax compilationUnit => compilationUnit.Usings,
BaseNamespaceDeclarationSyntax namespaceDecl => namespaceDecl.Usings,
_ => throw ExceptionUtilities.UnexpectedValue(node.Kind()),
};
public override AdjustSpacesOperation? GetAdjustSpacesOperation(in SyntaxToken previousToken, in SyntaxToken currentToken, in NextGetAdjustSpacesOperation nextOperation)
{
//////////////////////////////////////////////////////
// ";" related operations
if (currentToken.Kind() == SyntaxKind.SemicolonToken)
{
// ; ;
if (previousToken.Kind() == SyntaxKind.SemicolonToken)
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ) ; with embedded statement case
if (previousToken.Kind() == SyntaxKind.CloseParenToken && previousToken.Parent.IsEmbeddedStatementOwnerWithCloseParen())
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * ;
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// omitted tokens case
if (previousToken.Kind() == SyntaxKind.OmittedArraySizeExpressionToken ||
previousToken.Kind() == SyntaxKind.OmittedTypeArgumentToken ||
currentToken.Kind() == SyntaxKind.OmittedArraySizeExpressionToken ||
currentToken.Kind() == SyntaxKind.OmittedTypeArgumentToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
if (previousToken.IsKind(SyntaxKind.CloseBracketToken) &&
previousToken.Parent.IsKind(SyntaxKind.AttributeList) &&
previousToken.Parent.IsParentKind(SyntaxKind.Parameter))
{
if (currentToken.IsKind(SyntaxKind.OpenBracketToken))
{
// multiple attribute on parameter stick together
// void M([...][...]
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
else
{
// attribute is spaced from parameter type
// void M([...] int
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// extension method on tuple type
// M(this (
if (currentToken.Kind() == SyntaxKind.OpenParenToken &&
previousToken.Kind() == SyntaxKind.ThisKeyword)
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// new (int, int)[]
if (currentToken.Kind() == SyntaxKind.OpenParenToken &&
previousToken.Kind() == SyntaxKind.NewKeyword &&
previousToken.Parent.IsKind(SyntaxKind.ObjectCreationExpression, SyntaxKind.ArrayCreationExpression))
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// some * "(" cases
if (currentToken.Kind() == SyntaxKind.OpenParenToken)
{
if (previousToken.Kind() == SyntaxKind.IdentifierToken ||
previousToken.Kind() == SyntaxKind.DefaultKeyword ||
previousToken.Kind() == SyntaxKind.BaseKeyword ||
previousToken.Kind() == SyntaxKind.ThisKeyword ||
previousToken.Kind() == SyntaxKind.NewKeyword ||
previousToken.IsGenericGreaterThanToken() ||
currentToken.IsParenInArgumentList())
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// empty () or []
if (previousToken.ParenOrBracketContainsNothing(currentToken))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// attribute case
// , [
if (previousToken.Kind() == SyntaxKind.CommaToken && currentToken.Kind() == SyntaxKind.OpenBracketToken && currentToken.Parent is AttributeListSyntax)
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ] *
if (previousToken.Kind() == SyntaxKind.CloseBracketToken && previousToken.Parent is AttributeListSyntax)
{
// preserving dev10 behavior, in dev10 we didn't touch space after attribute
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.PreserveSpaces);
}
// * )
// * ]
// * ,
// * .
// * ->
switch (currentToken.Kind())
{
case SyntaxKind.CloseParenToken:
case SyntaxKind.CloseBracketToken:
case SyntaxKind.CommaToken:
case SyntaxKind.DotToken:
case SyntaxKind.MinusGreaterThanToken:
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * [
if (currentToken.IsKind(SyntaxKind.OpenBracketToken) &&
!previousToken.IsOpenBraceOrCommaOfObjectInitializer())
{
if (previousToken.IsOpenBraceOfAccessorList() ||
previousToken.IsLastTokenOfNode<AccessorDeclarationSyntax>())
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
else
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// case * :
// default:
// <label> :
// { Property1.Property2: ... }
if (currentToken.IsKind(SyntaxKind.ColonToken))
{
if (currentToken.Parent.IsKind(SyntaxKind.CaseSwitchLabel,
SyntaxKind.CasePatternSwitchLabel,
SyntaxKind.DefaultSwitchLabel,
SyntaxKind.LabeledStatement,
SyntaxKind.AttributeTargetSpecifier,
SyntaxKind.NameColon,
SyntaxKind.ExpressionColon,
SyntaxKind.SwitchExpressionArm))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// [cast expression] * case
if (previousToken.Parent is CastExpressionSyntax &&
previousToken.Kind() == SyntaxKind.CloseParenToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// generic name
if (previousToken.Parent.IsKind(SyntaxKind.TypeArgumentList, SyntaxKind.TypeParameterList, SyntaxKind.FunctionPointerType))
{
// generic name < *
if (previousToken.Kind() == SyntaxKind.LessThanToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// generic name > *
if (previousToken.Kind() == SyntaxKind.GreaterThanToken && currentToken.Kind() == SyntaxKind.GreaterThanToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// generic name * < or * >
if ((currentToken.Kind() == SyntaxKind.LessThanToken || currentToken.Kind() == SyntaxKind.GreaterThanToken) &&
currentToken.Parent.IsKind(SyntaxKind.TypeArgumentList, SyntaxKind.TypeParameterList))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ++ * or -- *
if ((previousToken.Kind() == SyntaxKind.PlusPlusToken || previousToken.Kind() == SyntaxKind.MinusMinusToken) &&
previousToken.Parent is PrefixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * ++ or * --
if ((currentToken.Kind() == SyntaxKind.PlusPlusToken || currentToken.Kind() == SyntaxKind.MinusMinusToken) &&
currentToken.Parent is PostfixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// For spacing between the identifier and the conditional operator
if (currentToken.IsKind(SyntaxKind.QuestionToken) && currentToken.Parent.IsKind(SyntaxKind.ConditionalAccessExpression))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// nullable
if (currentToken.Kind() == SyntaxKind.QuestionToken &&
currentToken.Parent.IsKind(SyntaxKind.NullableType, SyntaxKind.ClassConstraint))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// No space between an array type and ?
if (currentToken.IsKind(SyntaxKind.QuestionToken) &&
previousToken.Parent?.IsParentKind(SyntaxKind.ArrayType) == true)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpaces);
}
// suppress warning operator: null! or x! or x++! or x[i]! or (x)! or ...
if (currentToken.Kind() == SyntaxKind.ExclamationToken &&
currentToken.Parent.IsKind(SyntaxKind.SuppressNullableWarningExpression))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// pointer case for regular pointers
if (currentToken.Kind() == SyntaxKind.AsteriskToken && currentToken.Parent is PointerTypeSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// unary asterisk operator (PointerIndirectionExpression)
if (previousToken.Kind() == SyntaxKind.AsteriskToken && previousToken.Parent is PrefixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ( * or ) * or [ * or ] * or . * or -> *
switch (previousToken.Kind())
{
case SyntaxKind.OpenParenToken:
case SyntaxKind.OpenBracketToken:
case SyntaxKind.DotToken:
case SyntaxKind.MinusGreaterThanToken:
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
case SyntaxKind.CloseParenToken:
case SyntaxKind.CloseBracketToken:
var space = (previousToken.Kind() == currentToken.Kind()) ? 0 : 1;
return CreateAdjustSpacesOperation(space, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// +1 or -1
if (previousToken.IsPlusOrMinusExpression() && !currentToken.IsPlusOrMinusExpression())
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// +- or -+
if (previousToken.IsPlusOrMinusExpression() && currentToken.IsPlusOrMinusExpression() &&
previousToken.Kind() != currentToken.Kind())
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ! *, except where ! is the suppress nullable warning operator
if (previousToken.Kind() == SyntaxKind.ExclamationToken
&& !previousToken.Parent.IsKind(SyntaxKind.SuppressNullableWarningExpression))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ~ * case
if (previousToken.Kind() == SyntaxKind.TildeToken && (previousToken.Parent is PrefixUnaryExpressionSyntax || previousToken.Parent is DestructorDeclarationSyntax))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// & * case
if (previousToken.Kind() == SyntaxKind.AmpersandToken &&
previousToken.Parent is PrefixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * :: or :: * case
if (previousToken.Kind() == SyntaxKind.ColonColonToken || currentToken.Kind() == SyntaxKind.ColonColonToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
return nextOperation.Invoke(in previousToken, in currentToken);
}
private readonly struct CachedOptions : IEquatable<CachedOptions>
{
public readonly bool SeparateImportDirectiveGroups;
public CachedOptions(AnalyzerConfigOptions? options)
{
SeparateImportDirectiveGroups = GetOptionOrDefault(options, GenerationOptions.SeparateImportDirectiveGroups);
}
public static bool operator ==(CachedOptions left, CachedOptions right)
=> left.Equals(right);
public static bool operator !=(CachedOptions left, CachedOptions right)
=> !(left == right);
private static T GetOptionOrDefault<T>(AnalyzerConfigOptions? options, PerLanguageOption2<T> option)
{
if (options is null)
return option.DefaultValue;
return options.GetOption(option);
}
public override bool Equals(object? obj)
=> obj is CachedOptions options && Equals(options);
public bool Equals(CachedOptions other)
{
return SeparateImportDirectiveGroups == other.SeparateImportDirectiveGroups;
}
public override int GetHashCode()
{
var hashCode = 0;
hashCode = (hashCode << 1) + (SeparateImportDirectiveGroups ? 1 : 0);
return hashCode;
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Utilities;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Editing;
using Microsoft.CodeAnalysis.Formatting.Rules;
using Microsoft.CodeAnalysis.Options;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Formatting
{
internal sealed class TokenBasedFormattingRule : BaseFormattingRule
{
internal const string Name = "CSharp Token Based Formatting Rule";
private readonly CachedOptions _options;
public TokenBasedFormattingRule()
: this(new CachedOptions(null))
{
}
private TokenBasedFormattingRule(CachedOptions options)
{
_options = options;
}
public override AbstractFormattingRule WithOptions(AnalyzerConfigOptions options)
{
var cachedOptions = new CachedOptions(options);
if (cachedOptions == _options)
{
return this;
}
return new TokenBasedFormattingRule(cachedOptions);
}
public override AdjustNewLinesOperation? GetAdjustNewLinesOperation(in SyntaxToken previousToken, in SyntaxToken currentToken, in NextGetAdjustNewLinesOperation nextOperation)
{
////////////////////////////////////////////////////
// brace related operations
// * { or * }
switch (currentToken.Kind())
{
case SyntaxKind.OpenBraceToken:
if (currentToken.IsInterpolation())
{
return null;
}
if (!previousToken.IsParenInParenthesizedExpression())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
break;
case SyntaxKind.CloseBraceToken:
if (currentToken.IsInterpolation())
{
return null;
}
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// do { } while case
if (previousToken.Kind() == SyntaxKind.CloseBraceToken && currentToken.Kind() == SyntaxKind.WhileKeyword)
{
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
// { * or } *
switch (previousToken.Kind())
{
case SyntaxKind.CloseBraceToken:
if (previousToken.IsInterpolation())
{
return null;
}
if (!previousToken.IsCloseBraceOfExpression())
{
if (!currentToken.IsKind(SyntaxKind.SemicolonToken) &&
!currentToken.IsParenInParenthesizedExpression() &&
!currentToken.IsCommaInInitializerExpression() &&
!currentToken.IsCommaInAnyArgumentsList() &&
!currentToken.IsCommaInTupleExpression() &&
!currentToken.IsParenInArgumentList() &&
!currentToken.IsDotInMemberAccess() &&
!currentToken.IsCloseParenInStatement() &&
!currentToken.IsEqualsTokenInAutoPropertyInitializers() &&
!currentToken.IsColonInCasePatternSwitchLabel() && // no newline required before colon in pattern-switch-label (ex: `case {<pattern>}:`)
!currentToken.IsColonInSwitchExpressionArm()) // no newline required before colon in switch-expression-arm (ex: `{<pattern>}: expression`)
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
}
break;
case SyntaxKind.OpenBraceToken:
if (previousToken.IsInterpolation())
{
return null;
}
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
///////////////////////////////////////////////////
// statement related operations
// object and anonymous initializer "," case
if (previousToken.IsCommaInInitializerExpression())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// , * in switch expression arm
// ```
// e switch
// {
// pattern1: expression1, // newline with minimum of 1 line (each arm must be on its own line)
// pattern2: expression2 ...
// ```
if (previousToken.IsCommaInSwitchExpression())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// , * in property sub-pattern
// ```
// e is
// {
// property1: pattern1, // newline so the next line should be indented same as this one
// property2: pattern2, property3: pattern3, ... // but with minimum 0 lines so each property isn't forced to its own line
// ```
if (previousToken.IsCommaInPropertyPatternClause())
{
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
// else * except else if case
if (previousToken.Kind() == SyntaxKind.ElseKeyword && currentToken.Kind() != SyntaxKind.IfKeyword)
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// , * in enum declarations
if (previousToken.IsCommaInEnumDeclaration())
{
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
// : cases
if (previousToken.IsColonInSwitchLabel() ||
previousToken.IsColonInLabeledStatement())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// embedded statement
if (previousToken.Kind() == SyntaxKind.CloseParenToken && previousToken.Parent.IsEmbeddedStatementOwnerWithCloseParen())
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
if (previousToken.Kind() == SyntaxKind.DoKeyword && previousToken.Parent.IsKind(SyntaxKind.DoStatement))
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// for (int i = 10; i < 10; i++) case
if (previousToken.IsSemicolonInForStatement())
{
return nextOperation.Invoke(in previousToken, in currentToken);
}
// ; case in the switch case statement and else condition
if (previousToken.Kind() == SyntaxKind.SemicolonToken &&
(currentToken.Kind() == SyntaxKind.CaseKeyword || currentToken.Kind() == SyntaxKind.DefaultKeyword || currentToken.Kind() == SyntaxKind.ElseKeyword))
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
// ; * or ; * for using directive
if (previousToken.Kind() == SyntaxKind.SemicolonToken)
{
return AdjustNewLinesAfterSemicolonToken(previousToken, currentToken);
}
// attribute case ] *
// force to next line for top level attributes
if (previousToken.Kind() == SyntaxKind.CloseBracketToken && previousToken.Parent is AttributeListSyntax)
{
var attributeOwner = previousToken.Parent?.Parent;
if (attributeOwner is CompilationUnitSyntax ||
attributeOwner is MemberDeclarationSyntax ||
attributeOwner is AccessorDeclarationSyntax)
{
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
}
return nextOperation.Invoke(in previousToken, in currentToken);
}
private AdjustNewLinesOperation AdjustNewLinesAfterSemicolonToken(
SyntaxToken previousToken, SyntaxToken currentToken)
{
// between anything that isn't a using directive, we don't touch newlines after a semicolon
if (!(previousToken.Parent is UsingDirectiveSyntax previousUsing))
return CreateAdjustNewLinesOperation(0, AdjustNewLinesOption.PreserveLines);
// if the user is separating using-groups, and we're between two usings, and these
// usings *should* be separated, then do so (if the usings were already properly
// sorted).
if (_options.SeparateImportDirectiveGroups &&
currentToken.Parent is UsingDirectiveSyntax currentUsing &&
UsingsAndExternAliasesOrganizer.NeedsGrouping(previousUsing, currentUsing))
{
RoslynDebug.AssertNotNull(currentUsing.Parent);
var usings = GetUsings(currentUsing.Parent);
if (usings.IsSorted(UsingsAndExternAliasesDirectiveComparer.SystemFirstInstance) ||
usings.IsSorted(UsingsAndExternAliasesDirectiveComparer.NormalInstance))
{
// Force at least one blank line here.
return CreateAdjustNewLinesOperation(2, AdjustNewLinesOption.PreserveLines);
}
}
// For all other cases where we have a using-directive, just make sure it's followed by
// a new-line.
return CreateAdjustNewLinesOperation(1, AdjustNewLinesOption.PreserveLines);
}
private static SyntaxList<UsingDirectiveSyntax> GetUsings(SyntaxNode node)
=> node switch
{
CompilationUnitSyntax compilationUnit => compilationUnit.Usings,
BaseNamespaceDeclarationSyntax namespaceDecl => namespaceDecl.Usings,
_ => throw ExceptionUtilities.UnexpectedValue(node.Kind()),
};
public override AdjustSpacesOperation? GetAdjustSpacesOperation(in SyntaxToken previousToken, in SyntaxToken currentToken, in NextGetAdjustSpacesOperation nextOperation)
{
//////////////////////////////////////////////////////
// ";" related operations
if (currentToken.Kind() == SyntaxKind.SemicolonToken)
{
// ; ;
if (previousToken.Kind() == SyntaxKind.SemicolonToken)
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ) ; with embedded statement case
if (previousToken.Kind() == SyntaxKind.CloseParenToken && previousToken.Parent.IsEmbeddedStatementOwnerWithCloseParen())
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * ;
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// omitted tokens case
if (previousToken.Kind() == SyntaxKind.OmittedArraySizeExpressionToken ||
previousToken.Kind() == SyntaxKind.OmittedTypeArgumentToken ||
currentToken.Kind() == SyntaxKind.OmittedArraySizeExpressionToken ||
currentToken.Kind() == SyntaxKind.OmittedTypeArgumentToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
if (previousToken.IsKind(SyntaxKind.CloseBracketToken) &&
previousToken.Parent.IsKind(SyntaxKind.AttributeList) &&
previousToken.Parent.IsParentKind(SyntaxKind.Parameter))
{
if (currentToken.IsKind(SyntaxKind.OpenBracketToken))
{
// multiple attribute on parameter stick together
// void M([...][...]
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
else
{
// attribute is spaced from parameter type
// void M([...] int
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// extension method on tuple type
// M(this (
if (currentToken.Kind() == SyntaxKind.OpenParenToken &&
previousToken.Kind() == SyntaxKind.ThisKeyword)
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// new (int, int)[]
if (currentToken.Kind() == SyntaxKind.OpenParenToken &&
previousToken.Kind() == SyntaxKind.NewKeyword &&
previousToken.Parent.IsKind(SyntaxKind.ObjectCreationExpression, SyntaxKind.ArrayCreationExpression))
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// some * "(" cases
if (currentToken.Kind() == SyntaxKind.OpenParenToken)
{
if (previousToken.Kind() == SyntaxKind.IdentifierToken ||
previousToken.Kind() == SyntaxKind.DefaultKeyword ||
previousToken.Kind() == SyntaxKind.BaseKeyword ||
previousToken.Kind() == SyntaxKind.ThisKeyword ||
previousToken.Kind() == SyntaxKind.NewKeyword ||
previousToken.IsGenericGreaterThanToken() ||
currentToken.IsParenInArgumentList())
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// empty () or []
if (previousToken.ParenOrBracketContainsNothing(currentToken))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// attribute case
// , [
if (previousToken.Kind() == SyntaxKind.CommaToken && currentToken.Kind() == SyntaxKind.OpenBracketToken && currentToken.Parent is AttributeListSyntax)
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ] *
if (previousToken.Kind() == SyntaxKind.CloseBracketToken && previousToken.Parent is AttributeListSyntax)
{
// preserving dev10 behavior, in dev10 we didn't touch space after attribute
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.PreserveSpaces);
}
// * )
// * ]
// * ,
// * .
// * ->
switch (currentToken.Kind())
{
case SyntaxKind.CloseParenToken:
case SyntaxKind.CloseBracketToken:
case SyntaxKind.CommaToken:
case SyntaxKind.DotToken:
case SyntaxKind.MinusGreaterThanToken:
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * [
if (currentToken.IsKind(SyntaxKind.OpenBracketToken) &&
!previousToken.IsOpenBraceOrCommaOfObjectInitializer())
{
if (previousToken.IsOpenBraceOfAccessorList() ||
previousToken.IsLastTokenOfNode<AccessorDeclarationSyntax>())
{
return CreateAdjustSpacesOperation(1, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
else
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// case * :
// default:
// <label> :
// { Property1.Property2: ... }
if (currentToken.IsKind(SyntaxKind.ColonToken))
{
if (currentToken.Parent.IsKind(SyntaxKind.CaseSwitchLabel,
SyntaxKind.CasePatternSwitchLabel,
SyntaxKind.DefaultSwitchLabel,
SyntaxKind.LabeledStatement,
SyntaxKind.AttributeTargetSpecifier,
SyntaxKind.NameColon,
SyntaxKind.ExpressionColon,
SyntaxKind.SwitchExpressionArm))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// [cast expression] * case
if (previousToken.Parent is CastExpressionSyntax &&
previousToken.Kind() == SyntaxKind.CloseParenToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// generic name
if (previousToken.Parent.IsKind(SyntaxKind.TypeArgumentList, SyntaxKind.TypeParameterList, SyntaxKind.FunctionPointerType))
{
// generic name < *
if (previousToken.Kind() == SyntaxKind.LessThanToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// generic name > *
if (previousToken.Kind() == SyntaxKind.GreaterThanToken && currentToken.Kind() == SyntaxKind.GreaterThanToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
}
// generic name * < or * >
if ((currentToken.Kind() == SyntaxKind.LessThanToken || currentToken.Kind() == SyntaxKind.GreaterThanToken) &&
currentToken.Parent.IsKind(SyntaxKind.TypeArgumentList, SyntaxKind.TypeParameterList))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ++ * or -- *
if ((previousToken.Kind() == SyntaxKind.PlusPlusToken || previousToken.Kind() == SyntaxKind.MinusMinusToken) &&
previousToken.Parent is PrefixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * ++ or * --
if ((currentToken.Kind() == SyntaxKind.PlusPlusToken || currentToken.Kind() == SyntaxKind.MinusMinusToken) &&
currentToken.Parent is PostfixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// For spacing between the identifier and the conditional operator
if (currentToken.IsKind(SyntaxKind.QuestionToken) && currentToken.Parent.IsKind(SyntaxKind.ConditionalAccessExpression))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// nullable
if (currentToken.Kind() == SyntaxKind.QuestionToken &&
currentToken.Parent.IsKind(SyntaxKind.NullableType, SyntaxKind.ClassConstraint))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// No space between an array type and ?
if (currentToken.IsKind(SyntaxKind.QuestionToken) &&
previousToken.Parent?.IsParentKind(SyntaxKind.ArrayType) == true)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpaces);
}
// suppress warning operator: null! or x! or x++! or x[i]! or (x)! or ...
if (currentToken.Kind() == SyntaxKind.ExclamationToken &&
currentToken.Parent.IsKind(SyntaxKind.SuppressNullableWarningExpression))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// pointer case for regular pointers
if (currentToken.Kind() == SyntaxKind.AsteriskToken && currentToken.Parent is PointerTypeSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// unary asterisk operator (PointerIndirectionExpression)
if (previousToken.Kind() == SyntaxKind.AsteriskToken && previousToken.Parent is PrefixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ( * or ) * or [ * or ] * or . * or -> *
switch (previousToken.Kind())
{
case SyntaxKind.OpenParenToken:
case SyntaxKind.OpenBracketToken:
case SyntaxKind.DotToken:
case SyntaxKind.MinusGreaterThanToken:
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
case SyntaxKind.CloseParenToken:
case SyntaxKind.CloseBracketToken:
var space = (previousToken.Kind() == currentToken.Kind()) ? 0 : 1;
return CreateAdjustSpacesOperation(space, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// +1 or -1
if (previousToken.IsPlusOrMinusExpression() && !currentToken.IsPlusOrMinusExpression())
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// +- or -+
if (previousToken.IsPlusOrMinusExpression() && currentToken.IsPlusOrMinusExpression() &&
previousToken.Kind() != currentToken.Kind())
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ! *, except where ! is the suppress nullable warning operator
if (previousToken.Kind() == SyntaxKind.ExclamationToken
&& !previousToken.Parent.IsKind(SyntaxKind.SuppressNullableWarningExpression))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// ~ * case
if (previousToken.Kind() == SyntaxKind.TildeToken && (previousToken.Parent is PrefixUnaryExpressionSyntax || previousToken.Parent is DestructorDeclarationSyntax))
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// & * case
if (previousToken.Kind() == SyntaxKind.AmpersandToken &&
previousToken.Parent is PrefixUnaryExpressionSyntax)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
// * :: or :: * case
if (previousToken.Kind() == SyntaxKind.ColonColonToken || currentToken.Kind() == SyntaxKind.ColonColonToken)
{
return CreateAdjustSpacesOperation(0, AdjustSpacesOption.ForceSpacesIfOnSingleLine);
}
return nextOperation.Invoke(in previousToken, in currentToken);
}
private readonly struct CachedOptions : IEquatable<CachedOptions>
{
public readonly bool SeparateImportDirectiveGroups;
public CachedOptions(AnalyzerConfigOptions? options)
{
SeparateImportDirectiveGroups = GetOptionOrDefault(options, GenerationOptions.SeparateImportDirectiveGroups);
}
public static bool operator ==(CachedOptions left, CachedOptions right)
=> left.Equals(right);
public static bool operator !=(CachedOptions left, CachedOptions right)
=> !(left == right);
private static T GetOptionOrDefault<T>(AnalyzerConfigOptions? options, PerLanguageOption2<T> option)
{
if (options is null)
return option.DefaultValue;
return options.GetOption(option);
}
public override bool Equals(object? obj)
=> obj is CachedOptions options && Equals(options);
public bool Equals(CachedOptions other)
{
return SeparateImportDirectiveGroups == other.SeparateImportDirectiveGroups;
}
public override int GetHashCode()
{
var hashCode = 0;
hashCode = (hashCode << 1) + (SeparateImportDirectiveGroups ? 1 : 0);
return hashCode;
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/CSharp/Portable/CodeFixes/GenerateMethod/GenerateMethodCodeFixProvider.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Composition;
using System.Diagnostics.CodeAnalysis;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeActions;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysis.CodeFixes.GenerateMember;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.GenerateMember.GenerateParameterizedMember;
using Microsoft.CodeAnalysis.Shared.Extensions;
namespace Microsoft.CodeAnalysis.CSharp.CodeFixes.GenerateMethod
{
internal static class GenerateMethodDiagnosticIds
{
private const string CS0103 = nameof(CS0103); // error CS0103: Error The name 'Goo' does not exist in the current context
private const string CS0117 = nameof(CS0117); // error CS0117: 'Class' does not contain a definition for 'Goo'
private const string CS0118 = nameof(CS0118); // error CS0118: 'X' is a namespace but is used like a variable
private const string CS0122 = nameof(CS0122); // error CS0122: 'Class' is inaccessible due to its protection level.
private const string CS0305 = nameof(CS0305); // error CS0305: Using the generic method 'CA.M<V>()' requires 1 type arguments
private const string CS0308 = nameof(CS0308); // error CS0308: The non-generic method 'Program.Goo()' cannot be used with type arguments
private const string CS0539 = nameof(CS0539); // error CS0539: 'A.Goo<T>()' in explicit interface declaration is not a member of interface
private const string CS1061 = nameof(CS1061); // error CS1061: Error 'Class' does not contain a definition for 'Goo' and no extension method 'Goo'
private const string CS1501 = nameof(CS1501); // error CS1501: No overload for method 'M' takes 1 arguments
private const string CS1503 = nameof(CS1503); // error CS1503: Argument 1: cannot convert from 'double' to 'int'
private const string CS1660 = nameof(CS1660); // error CS1660: Cannot convert lambda expression to type 'string[]' because it is not a delegate type
private const string CS1739 = nameof(CS1739); // error CS1739: The best overload for 'M' does not have a parameter named 'x'
private const string CS7036 = nameof(CS7036); // error CS7036: There is no argument given that corresponds to the required formal parameter 'x' of 'C.M(int)'
private const string CS1955 = nameof(CS1955); // error CS1955: Non-invocable member 'Goo' cannot be used like a method.
public static readonly ImmutableArray<string> FixableDiagnosticIds =
ImmutableArray.Create(
CS0103,
CS0117,
CS0118,
CS0122,
CS0305,
CS0308,
CS0539,
CS1061,
CS1501,
CS1503,
CS1660,
CS1739,
CS7036,
CS1955);
}
[ExportCodeFixProvider(LanguageNames.CSharp, Name = PredefinedCodeFixProviderNames.GenerateMethod), Shared]
[ExtensionOrder(After = PredefinedCodeFixProviderNames.GenerateEnumMember, Before = PredefinedCodeFixProviderNames.PopulateSwitch)]
internal class GenerateMethodCodeFixProvider : AbstractGenerateMemberCodeFixProvider
{
[ImportingConstructor]
[SuppressMessage("RoslynDiagnosticsReliability", "RS0033:Importing constructor should be [Obsolete]", Justification = "Used in test code: https://github.com/dotnet/roslyn/issues/42814")]
public GenerateMethodCodeFixProvider()
{
}
public override ImmutableArray<string> FixableDiagnosticIds { get; } =
GenerateMethodDiagnosticIds.FixableDiagnosticIds;
protected override bool IsCandidate(SyntaxNode node, SyntaxToken token, Diagnostic diagnostic)
{
return node.IsKind(SyntaxKind.IdentifierName) ||
node.IsKind(SyntaxKind.MethodDeclaration) ||
node.IsKind(SyntaxKind.InvocationExpression) ||
node.IsKind(SyntaxKind.CastExpression) ||
node is LiteralExpressionSyntax ||
node is SimpleNameSyntax ||
node is ExpressionSyntax;
}
protected override SyntaxNode? GetTargetNode(SyntaxNode node)
{
switch (node)
{
case InvocationExpressionSyntax invocation:
return invocation.Expression.GetRightmostName();
case MemberBindingExpressionSyntax memberBindingExpression:
return memberBindingExpression.Name;
}
return node;
}
protected override Task<ImmutableArray<CodeAction>> GetCodeActionsAsync(
Document document, SyntaxNode node, CancellationToken cancellationToken)
{
var service = document.GetRequiredLanguageService<IGenerateParameterizedMemberService>();
return service.GenerateMethodAsync(document, node, cancellationToken);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Composition;
using System.Diagnostics.CodeAnalysis;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeActions;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysis.CodeFixes.GenerateMember;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.GenerateMember.GenerateParameterizedMember;
using Microsoft.CodeAnalysis.Shared.Extensions;
namespace Microsoft.CodeAnalysis.CSharp.CodeFixes.GenerateMethod
{
internal static class GenerateMethodDiagnosticIds
{
private const string CS0103 = nameof(CS0103); // error CS0103: Error The name 'Goo' does not exist in the current context
private const string CS0117 = nameof(CS0117); // error CS0117: 'Class' does not contain a definition for 'Goo'
private const string CS0118 = nameof(CS0118); // error CS0118: 'X' is a namespace but is used like a variable
private const string CS0122 = nameof(CS0122); // error CS0122: 'Class' is inaccessible due to its protection level.
private const string CS0305 = nameof(CS0305); // error CS0305: Using the generic method 'CA.M<V>()' requires 1 type arguments
private const string CS0308 = nameof(CS0308); // error CS0308: The non-generic method 'Program.Goo()' cannot be used with type arguments
private const string CS0539 = nameof(CS0539); // error CS0539: 'A.Goo<T>()' in explicit interface declaration is not a member of interface
private const string CS1061 = nameof(CS1061); // error CS1061: Error 'Class' does not contain a definition for 'Goo' and no extension method 'Goo'
private const string CS1501 = nameof(CS1501); // error CS1501: No overload for method 'M' takes 1 arguments
private const string CS1503 = nameof(CS1503); // error CS1503: Argument 1: cannot convert from 'double' to 'int'
private const string CS1660 = nameof(CS1660); // error CS1660: Cannot convert lambda expression to type 'string[]' because it is not a delegate type
private const string CS1739 = nameof(CS1739); // error CS1739: The best overload for 'M' does not have a parameter named 'x'
private const string CS7036 = nameof(CS7036); // error CS7036: There is no argument given that corresponds to the required formal parameter 'x' of 'C.M(int)'
private const string CS1955 = nameof(CS1955); // error CS1955: Non-invocable member 'Goo' cannot be used like a method.
public static readonly ImmutableArray<string> FixableDiagnosticIds =
ImmutableArray.Create(
CS0103,
CS0117,
CS0118,
CS0122,
CS0305,
CS0308,
CS0539,
CS1061,
CS1501,
CS1503,
CS1660,
CS1739,
CS7036,
CS1955);
}
[ExportCodeFixProvider(LanguageNames.CSharp, Name = PredefinedCodeFixProviderNames.GenerateMethod), Shared]
[ExtensionOrder(After = PredefinedCodeFixProviderNames.GenerateEnumMember, Before = PredefinedCodeFixProviderNames.PopulateSwitch)]
internal class GenerateMethodCodeFixProvider : AbstractGenerateMemberCodeFixProvider
{
[ImportingConstructor]
[SuppressMessage("RoslynDiagnosticsReliability", "RS0033:Importing constructor should be [Obsolete]", Justification = "Used in test code: https://github.com/dotnet/roslyn/issues/42814")]
public GenerateMethodCodeFixProvider()
{
}
public override ImmutableArray<string> FixableDiagnosticIds { get; } =
GenerateMethodDiagnosticIds.FixableDiagnosticIds;
protected override bool IsCandidate(SyntaxNode node, SyntaxToken token, Diagnostic diagnostic)
{
return node.IsKind(SyntaxKind.IdentifierName) ||
node.IsKind(SyntaxKind.MethodDeclaration) ||
node.IsKind(SyntaxKind.InvocationExpression) ||
node.IsKind(SyntaxKind.CastExpression) ||
node is LiteralExpressionSyntax ||
node is SimpleNameSyntax ||
node is ExpressionSyntax;
}
protected override SyntaxNode? GetTargetNode(SyntaxNode node)
{
switch (node)
{
case InvocationExpressionSyntax invocation:
return invocation.Expression.GetRightmostName();
case MemberBindingExpressionSyntax memberBindingExpression:
return memberBindingExpression.Name;
}
return node;
}
protected override Task<ImmutableArray<CodeAction>> GetCodeActionsAsync(
Document document, SyntaxNode node, CancellationToken cancellationToken)
{
var service = document.GetRequiredLanguageService<IGenerateParameterizedMemberService>();
return service.GenerateMethodAsync(document, node, cancellationToken);
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/IntegrationTest/IntegrationTests/VisualBasic/BasicLineCommit.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities.Input;
using Roslyn.Test.Utilities;
using Xunit;
using ProjName = Microsoft.VisualStudio.IntegrationTest.Utilities.Common.ProjectUtils.Project;
namespace Roslyn.VisualStudio.IntegrationTests.VisualBasic
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class BasicLineCommit : AbstractEditorTest
{
protected override string LanguageName => LanguageNames.VisualBasic;
public BasicLineCommit(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory, nameof(BasicLineCommit))
{
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CaseCorrection()
{
VisualStudio.Editor.SetText(@"Module Goo
Sub M()
Dim x = Sub()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("Sub()", charsOffset: 1);
VisualStudio.Editor.SendKeys(VirtualKey.Enter);
VisualStudio.Editor.Verify.CaretPosition(48);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void UndoWithEndConstruct()
{
VisualStudio.Editor.SetText(@"Module Module1
Sub Main()
End Sub
REM
End Module");
VisualStudio.Editor.PlaceCaret(" REM");
VisualStudio.Editor.SendKeys("sub", VirtualKey.Escape, " goo()", VirtualKey.Enter);
VisualStudio.Editor.Verify.TextContains(@"Sub goo()
End Sub");
VisualStudio.ExecuteCommand(WellKnownCommandNames.Edit_Undo);
VisualStudio.Editor.Verify.CaretPosition(54);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void UndoWithoutEndConstruct()
{
VisualStudio.Editor.SetText(@"Module Module1
''' <summary></summary>
Sub Main()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("Module1");
VisualStudio.Editor.SendKeys(VirtualKey.Down, VirtualKey.Enter);
VisualStudio.Editor.Verify.TextContains(@"Module Module1
''' <summary></summary>
Sub Main()
End Sub
End Module");
VisualStudio.Editor.Verify.CaretPosition(18);
VisualStudio.ExecuteCommand(WellKnownCommandNames.Edit_Undo);
VisualStudio.Editor.Verify.CaretPosition(16);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CommitOnSave()
{
VisualStudio.Editor.SetText(@"Module Module1
Sub Main()
End Sub
End Module
");
VisualStudio.Editor.PlaceCaret("(", charsOffset: 1);
VisualStudio.Editor.SendKeys("x As integer", VirtualKey.Tab);
VisualStudio.Editor.Verify.IsNotSaved();
VisualStudio.Editor.SendKeys(new KeyPress(VirtualKey.S, ShiftState.Ctrl));
var savedFileName = VisualStudio.Editor.Verify.IsSaved();
try
{
VisualStudio.Editor.Verify.TextContains(@"Sub Main(x As Integer)");
}
catch (Exception e)
{
throw new InvalidOperationException($"Unexpected failure after saving document '{savedFileName}'", e);
}
VisualStudio.ExecuteCommand(WellKnownCommandNames.Edit_Undo);
VisualStudio.Editor.Verify.TextContains(@"Sub Main(x As Integer)");
VisualStudio.Editor.Verify.CaretPosition(45);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CommitOnFocusLost()
{
VisualStudio.Editor.SetText(@"Module M
Sub M()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("End Sub", charsOffset: -1);
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.AddFile(new ProjName(ProjectName), "TestZ.vb", open: true); // Cause focus lost
VisualStudio.SolutionExplorer.OpenFile(new ProjName(ProjectName), "TestZ.vb"); // Work around https://github.com/dotnet/roslyn/issues/18488
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.CloseCodeFile(new ProjName(ProjectName), "TestZ.vb", saveFile: false);
VisualStudio.Editor.Verify.TextContains(@"
Sub M()
End Sub
");
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CommitOnFocusLostDoesNotFormatWithPrettyListingOff()
{
try
{
VisualStudio.Workspace.SetPerLanguageOption("PrettyListing", "FeatureOnOffOptions", LanguageNames.VisualBasic, false);
VisualStudio.Editor.SetText(@"Module M
Sub M()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("End Sub", charsOffset: -1);
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.AddFile(new ProjName(ProjectName), "TestZ.vb", open: true); // Cause focus lost
VisualStudio.SolutionExplorer.OpenFile(new ProjName(ProjectName), "TestZ.vb"); // Work around https://github.com/dotnet/roslyn/issues/18488
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.CloseCodeFile(new ProjName(ProjectName), "TestZ.vb", saveFile: false);
VisualStudio.Editor.Verify.TextContains(@"
Sub M()
End Sub
");
}
finally
{
VisualStudio.Workspace.SetPerLanguageOption("PrettyListing", "FeatureOnOffOptions", LanguageNames.VisualBasic, true);
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities.Input;
using Roslyn.Test.Utilities;
using Xunit;
using ProjName = Microsoft.VisualStudio.IntegrationTest.Utilities.Common.ProjectUtils.Project;
namespace Roslyn.VisualStudio.IntegrationTests.VisualBasic
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class BasicLineCommit : AbstractEditorTest
{
protected override string LanguageName => LanguageNames.VisualBasic;
public BasicLineCommit(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory, nameof(BasicLineCommit))
{
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CaseCorrection()
{
VisualStudio.Editor.SetText(@"Module Goo
Sub M()
Dim x = Sub()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("Sub()", charsOffset: 1);
VisualStudio.Editor.SendKeys(VirtualKey.Enter);
VisualStudio.Editor.Verify.CaretPosition(48);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void UndoWithEndConstruct()
{
VisualStudio.Editor.SetText(@"Module Module1
Sub Main()
End Sub
REM
End Module");
VisualStudio.Editor.PlaceCaret(" REM");
VisualStudio.Editor.SendKeys("sub", VirtualKey.Escape, " goo()", VirtualKey.Enter);
VisualStudio.Editor.Verify.TextContains(@"Sub goo()
End Sub");
VisualStudio.ExecuteCommand(WellKnownCommandNames.Edit_Undo);
VisualStudio.Editor.Verify.CaretPosition(54);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void UndoWithoutEndConstruct()
{
VisualStudio.Editor.SetText(@"Module Module1
''' <summary></summary>
Sub Main()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("Module1");
VisualStudio.Editor.SendKeys(VirtualKey.Down, VirtualKey.Enter);
VisualStudio.Editor.Verify.TextContains(@"Module Module1
''' <summary></summary>
Sub Main()
End Sub
End Module");
VisualStudio.Editor.Verify.CaretPosition(18);
VisualStudio.ExecuteCommand(WellKnownCommandNames.Edit_Undo);
VisualStudio.Editor.Verify.CaretPosition(16);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CommitOnSave()
{
VisualStudio.Editor.SetText(@"Module Module1
Sub Main()
End Sub
End Module
");
VisualStudio.Editor.PlaceCaret("(", charsOffset: 1);
VisualStudio.Editor.SendKeys("x As integer", VirtualKey.Tab);
VisualStudio.Editor.Verify.IsNotSaved();
VisualStudio.Editor.SendKeys(new KeyPress(VirtualKey.S, ShiftState.Ctrl));
var savedFileName = VisualStudio.Editor.Verify.IsSaved();
try
{
VisualStudio.Editor.Verify.TextContains(@"Sub Main(x As Integer)");
}
catch (Exception e)
{
throw new InvalidOperationException($"Unexpected failure after saving document '{savedFileName}'", e);
}
VisualStudio.ExecuteCommand(WellKnownCommandNames.Edit_Undo);
VisualStudio.Editor.Verify.TextContains(@"Sub Main(x As Integer)");
VisualStudio.Editor.Verify.CaretPosition(45);
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CommitOnFocusLost()
{
VisualStudio.Editor.SetText(@"Module M
Sub M()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("End Sub", charsOffset: -1);
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.AddFile(new ProjName(ProjectName), "TestZ.vb", open: true); // Cause focus lost
VisualStudio.SolutionExplorer.OpenFile(new ProjName(ProjectName), "TestZ.vb"); // Work around https://github.com/dotnet/roslyn/issues/18488
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.CloseCodeFile(new ProjName(ProjectName), "TestZ.vb", saveFile: false);
VisualStudio.Editor.Verify.TextContains(@"
Sub M()
End Sub
");
}
[WpfFact, Trait(Traits.Feature, Traits.Features.LineCommit)]
private void CommitOnFocusLostDoesNotFormatWithPrettyListingOff()
{
try
{
VisualStudio.Workspace.SetPerLanguageOption("PrettyListing", "FeatureOnOffOptions", LanguageNames.VisualBasic, false);
VisualStudio.Editor.SetText(@"Module M
Sub M()
End Sub
End Module");
VisualStudio.Editor.PlaceCaret("End Sub", charsOffset: -1);
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.AddFile(new ProjName(ProjectName), "TestZ.vb", open: true); // Cause focus lost
VisualStudio.SolutionExplorer.OpenFile(new ProjName(ProjectName), "TestZ.vb"); // Work around https://github.com/dotnet/roslyn/issues/18488
VisualStudio.Editor.SendKeys(" ");
VisualStudio.SolutionExplorer.CloseCodeFile(new ProjName(ProjectName), "TestZ.vb", saveFile: false);
VisualStudio.Editor.Verify.TextContains(@"
Sub M()
End Sub
");
}
finally
{
VisualStudio.Workspace.SetPerLanguageOption("PrettyListing", "FeatureOnOffOptions", LanguageNames.VisualBasic, true);
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/CSharp/Portable/Binder/LocalInProgressBinder.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Text;
namespace Microsoft.CodeAnalysis.CSharp
{
/// <summary>
/// This binder keeps track of the local variable (if any) that is currently being evaluated
/// so that it can be passed into the next call to LocalSymbol.GetConstantValue (and
/// its callers).
/// </summary>
internal sealed class LocalInProgressBinder : Binder
{
private readonly LocalSymbol _inProgress;
internal LocalInProgressBinder(LocalSymbol inProgress, Binder next)
: base(next)
{
_inProgress = inProgress;
}
internal override LocalSymbol LocalInProgress
{
get
{
return _inProgress;
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.Text;
namespace Microsoft.CodeAnalysis.CSharp
{
/// <summary>
/// This binder keeps track of the local variable (if any) that is currently being evaluated
/// so that it can be passed into the next call to LocalSymbol.GetConstantValue (and
/// its callers).
/// </summary>
internal sealed class LocalInProgressBinder : Binder
{
private readonly LocalSymbol _inProgress;
internal LocalInProgressBinder(LocalSymbol inProgress, Binder next)
: base(next)
{
_inProgress = inProgress;
}
internal override LocalSymbol LocalInProgress
{
get
{
return _inProgress;
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/CSharp/Portable/Simplification/Reducers/CSharpEscapingReducer.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Utilities;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Shared.Extensions;
namespace Microsoft.CodeAnalysis.CSharp.Simplification
{
internal partial class CSharpEscapingReducer : AbstractCSharpReducer
{
private static readonly ObjectPool<IReductionRewriter> s_pool = new(
() => new Rewriter(s_pool));
public CSharpEscapingReducer() : base(s_pool)
{
}
private static readonly Func<SyntaxToken, SemanticModel, OptionSet, CancellationToken, SyntaxToken> s_simplifyIdentifierToken = SimplifyIdentifierToken;
private static SyntaxToken SimplifyIdentifierToken(
SyntaxToken token,
SemanticModel semanticModel,
OptionSet optionSet,
CancellationToken cancellationToken)
{
var unescapedIdentifier = token.ValueText;
var enclosingXmlNameAttr = token.GetAncestors(n => n is XmlNameAttributeSyntax).FirstOrDefault();
// always escape keywords
if (SyntaxFacts.GetKeywordKind(unescapedIdentifier) != SyntaxKind.None && enclosingXmlNameAttr == null)
{
return CreateNewIdentifierTokenFromToken(token, escape: true);
}
// Escape the Await Identifier if within the Single Line Lambda & Multi Line Context
// and async method
var parent = token.Parent;
if (SyntaxFacts.GetContextualKeywordKind(unescapedIdentifier) == SyntaxKind.AwaitKeyword)
{
var enclosingLambdaExpression = parent.GetAncestorsOrThis(n => (n is SimpleLambdaExpressionSyntax || n is ParenthesizedLambdaExpressionSyntax)).FirstOrDefault();
if (enclosingLambdaExpression != null)
{
if (enclosingLambdaExpression is SimpleLambdaExpressionSyntax simpleLambda)
{
if (simpleLambda.AsyncKeyword.Kind() == SyntaxKind.AsyncKeyword)
{
return token;
}
}
if (enclosingLambdaExpression is ParenthesizedLambdaExpressionSyntax parenLamdba)
{
if (parenLamdba.AsyncKeyword.Kind() == SyntaxKind.AsyncKeyword)
{
return token;
}
}
}
var enclosingMethodBlock = parent.GetAncestorsOrThis(n => n is MethodDeclarationSyntax).FirstOrDefault();
if (enclosingMethodBlock != null && ((MethodDeclarationSyntax)enclosingMethodBlock).Modifiers.Any(n => n.Kind() == SyntaxKind.AsyncKeyword))
{
return token;
}
}
// within a query all contextual query keywords need to be escaped, even if they appear in a non query context.
if (token.GetAncestors(n => n is QueryExpressionSyntax).Any())
{
switch (SyntaxFacts.GetContextualKeywordKind(unescapedIdentifier))
{
case SyntaxKind.FromKeyword:
case SyntaxKind.WhereKeyword:
case SyntaxKind.SelectKeyword:
case SyntaxKind.GroupKeyword:
case SyntaxKind.IntoKeyword:
case SyntaxKind.OrderByKeyword:
case SyntaxKind.JoinKeyword:
case SyntaxKind.LetKeyword:
case SyntaxKind.InKeyword:
case SyntaxKind.OnKeyword:
case SyntaxKind.EqualsKeyword:
case SyntaxKind.ByKeyword:
case SyntaxKind.AscendingKeyword:
case SyntaxKind.DescendingKeyword:
return CreateNewIdentifierTokenFromToken(token, escape: true);
}
}
var result = token.Kind() == SyntaxKind.IdentifierToken ? CreateNewIdentifierTokenFromToken(token, escape: false) : token;
// we can't remove the escaping if this would change the semantic. This can happen in cases
// where there are two attribute declarations: one with and one without the attribute
// suffix.
if (SyntaxFacts.IsAttributeName(parent))
{
var expression = (SimpleNameSyntax)parent;
var newExpression = expression.WithIdentifier(result);
var speculationAnalyzer = new SpeculationAnalyzer(expression, newExpression, semanticModel, cancellationToken);
if (speculationAnalyzer.ReplacementChangesSemantics())
{
return CreateNewIdentifierTokenFromToken(token, escape: true);
}
}
// TODO: handle crefs and param names of xml doc comments.
// crefs have the same escaping rules than csharp, param names do not allow escaping in Dev11, but
// we may want to change that for Roslyn (Bug 17984, " Could treat '@' specially in <param>, <typeparam>, etc")
return result;
}
private static SyntaxToken CreateNewIdentifierTokenFromToken(SyntaxToken originalToken, bool escape)
{
var isVerbatimIdentifier = originalToken.IsVerbatimIdentifier();
if (isVerbatimIdentifier == escape)
{
return originalToken;
}
var unescapedText = isVerbatimIdentifier ? originalToken.ToString().Substring(1) : originalToken.ToString();
return escape
? originalToken.CopyAnnotationsTo(SyntaxFactory.VerbatimIdentifier(originalToken.LeadingTrivia, unescapedText, originalToken.ValueText, originalToken.TrailingTrivia))
: originalToken.CopyAnnotationsTo(SyntaxFactory.Identifier(originalToken.LeadingTrivia, SyntaxKind.IdentifierToken, unescapedText, originalToken.ValueText, originalToken.TrailingTrivia));
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Extensions;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Utilities;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Shared.Extensions;
namespace Microsoft.CodeAnalysis.CSharp.Simplification
{
internal partial class CSharpEscapingReducer : AbstractCSharpReducer
{
private static readonly ObjectPool<IReductionRewriter> s_pool = new(
() => new Rewriter(s_pool));
public CSharpEscapingReducer() : base(s_pool)
{
}
private static readonly Func<SyntaxToken, SemanticModel, OptionSet, CancellationToken, SyntaxToken> s_simplifyIdentifierToken = SimplifyIdentifierToken;
private static SyntaxToken SimplifyIdentifierToken(
SyntaxToken token,
SemanticModel semanticModel,
OptionSet optionSet,
CancellationToken cancellationToken)
{
var unescapedIdentifier = token.ValueText;
var enclosingXmlNameAttr = token.GetAncestors(n => n is XmlNameAttributeSyntax).FirstOrDefault();
// always escape keywords
if (SyntaxFacts.GetKeywordKind(unescapedIdentifier) != SyntaxKind.None && enclosingXmlNameAttr == null)
{
return CreateNewIdentifierTokenFromToken(token, escape: true);
}
// Escape the Await Identifier if within the Single Line Lambda & Multi Line Context
// and async method
var parent = token.Parent;
if (SyntaxFacts.GetContextualKeywordKind(unescapedIdentifier) == SyntaxKind.AwaitKeyword)
{
var enclosingLambdaExpression = parent.GetAncestorsOrThis(n => (n is SimpleLambdaExpressionSyntax || n is ParenthesizedLambdaExpressionSyntax)).FirstOrDefault();
if (enclosingLambdaExpression != null)
{
if (enclosingLambdaExpression is SimpleLambdaExpressionSyntax simpleLambda)
{
if (simpleLambda.AsyncKeyword.Kind() == SyntaxKind.AsyncKeyword)
{
return token;
}
}
if (enclosingLambdaExpression is ParenthesizedLambdaExpressionSyntax parenLamdba)
{
if (parenLamdba.AsyncKeyword.Kind() == SyntaxKind.AsyncKeyword)
{
return token;
}
}
}
var enclosingMethodBlock = parent.GetAncestorsOrThis(n => n is MethodDeclarationSyntax).FirstOrDefault();
if (enclosingMethodBlock != null && ((MethodDeclarationSyntax)enclosingMethodBlock).Modifiers.Any(n => n.Kind() == SyntaxKind.AsyncKeyword))
{
return token;
}
}
// within a query all contextual query keywords need to be escaped, even if they appear in a non query context.
if (token.GetAncestors(n => n is QueryExpressionSyntax).Any())
{
switch (SyntaxFacts.GetContextualKeywordKind(unescapedIdentifier))
{
case SyntaxKind.FromKeyword:
case SyntaxKind.WhereKeyword:
case SyntaxKind.SelectKeyword:
case SyntaxKind.GroupKeyword:
case SyntaxKind.IntoKeyword:
case SyntaxKind.OrderByKeyword:
case SyntaxKind.JoinKeyword:
case SyntaxKind.LetKeyword:
case SyntaxKind.InKeyword:
case SyntaxKind.OnKeyword:
case SyntaxKind.EqualsKeyword:
case SyntaxKind.ByKeyword:
case SyntaxKind.AscendingKeyword:
case SyntaxKind.DescendingKeyword:
return CreateNewIdentifierTokenFromToken(token, escape: true);
}
}
var result = token.Kind() == SyntaxKind.IdentifierToken ? CreateNewIdentifierTokenFromToken(token, escape: false) : token;
// we can't remove the escaping if this would change the semantic. This can happen in cases
// where there are two attribute declarations: one with and one without the attribute
// suffix.
if (SyntaxFacts.IsAttributeName(parent))
{
var expression = (SimpleNameSyntax)parent;
var newExpression = expression.WithIdentifier(result);
var speculationAnalyzer = new SpeculationAnalyzer(expression, newExpression, semanticModel, cancellationToken);
if (speculationAnalyzer.ReplacementChangesSemantics())
{
return CreateNewIdentifierTokenFromToken(token, escape: true);
}
}
// TODO: handle crefs and param names of xml doc comments.
// crefs have the same escaping rules than csharp, param names do not allow escaping in Dev11, but
// we may want to change that for Roslyn (Bug 17984, " Could treat '@' specially in <param>, <typeparam>, etc")
return result;
}
private static SyntaxToken CreateNewIdentifierTokenFromToken(SyntaxToken originalToken, bool escape)
{
var isVerbatimIdentifier = originalToken.IsVerbatimIdentifier();
if (isVerbatimIdentifier == escape)
{
return originalToken;
}
var unescapedText = isVerbatimIdentifier ? originalToken.ToString().Substring(1) : originalToken.ToString();
return escape
? originalToken.CopyAnnotationsTo(SyntaxFactory.VerbatimIdentifier(originalToken.LeadingTrivia, unescapedText, originalToken.ValueText, originalToken.TrailingTrivia))
: originalToken.CopyAnnotationsTo(SyntaxFactory.Identifier(originalToken.LeadingTrivia, SyntaxKind.IdentifierToken, unescapedText, originalToken.ValueText, originalToken.TrailingTrivia));
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/CSharp/EmbeddedLanguages/CSharpEmbeddedLanguageEditorFeaturesProvider.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Composition;
using Microsoft.CodeAnalysis.CSharp.EmbeddedLanguages.LanguageServices;
using Microsoft.CodeAnalysis.CSharp.Features.EmbeddedLanguages;
using Microsoft.CodeAnalysis.Editor.EmbeddedLanguages;
using Microsoft.CodeAnalysis.EmbeddedLanguages.LanguageServices;
using Microsoft.CodeAnalysis.Host.Mef;
namespace Microsoft.CodeAnalysis.CSharp.Editor.EmbeddedLanguages
{
[ExportLanguageService(typeof(IEmbeddedLanguagesProvider), LanguageNames.CSharp, ServiceLayer.Editor), Shared]
internal class CSharpEmbeddedLanguageEditorFeaturesProvider : AbstractEmbeddedLanguageEditorFeaturesProvider
{
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public CSharpEmbeddedLanguageEditorFeaturesProvider()
: base(CSharpEmbeddedLanguagesProvider.Info)
{
}
internal override string EscapeText(string text, SyntaxToken token)
=> EmbeddedLanguageUtilities.EscapeText(text, token);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Composition;
using Microsoft.CodeAnalysis.CSharp.EmbeddedLanguages.LanguageServices;
using Microsoft.CodeAnalysis.CSharp.Features.EmbeddedLanguages;
using Microsoft.CodeAnalysis.Editor.EmbeddedLanguages;
using Microsoft.CodeAnalysis.EmbeddedLanguages.LanguageServices;
using Microsoft.CodeAnalysis.Host.Mef;
namespace Microsoft.CodeAnalysis.CSharp.Editor.EmbeddedLanguages
{
[ExportLanguageService(typeof(IEmbeddedLanguagesProvider), LanguageNames.CSharp, ServiceLayer.Editor), Shared]
internal class CSharpEmbeddedLanguageEditorFeaturesProvider : AbstractEmbeddedLanguageEditorFeaturesProvider
{
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public CSharpEmbeddedLanguageEditorFeaturesProvider()
: base(CSharpEmbeddedLanguagesProvider.Info)
{
}
internal override string EscapeText(string text, SyntaxToken token)
=> EmbeddedLanguageUtilities.EscapeText(text, token);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/Remote/ServiceHub/Host/Storage/RemoteCloudCacheStorageServiceFactory.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Composition;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Host.Mef;
using Microsoft.CodeAnalysis.Remote.Host;
using Microsoft.CodeAnalysis.Storage;
using Microsoft.CodeAnalysis.Storage.CloudCache;
using Microsoft.VisualStudio;
using Microsoft.VisualStudio.LanguageServices.Storage;
using Microsoft.VisualStudio.RpcContracts.Caching;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Remote.Storage
{
[ExportWorkspaceService(typeof(ICloudCacheStorageServiceFactory), WorkspaceKind.RemoteWorkspace), Shared]
internal class RemoteCloudCacheStorageServiceFactory : ICloudCacheStorageServiceFactory
{
private readonly IGlobalServiceBroker _globalServiceBroker;
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public RemoteCloudCacheStorageServiceFactory(IGlobalServiceBroker globalServiceBroker)
{
_globalServiceBroker = globalServiceBroker;
}
public AbstractPersistentStorageService Create(IPersistentStorageConfiguration configuration)
=> new RemoteCloudCachePersistentStorageService(_globalServiceBroker, configuration);
private class RemoteCloudCachePersistentStorageService : AbstractCloudCachePersistentStorageService
{
private readonly IGlobalServiceBroker _globalServiceBroker;
public RemoteCloudCachePersistentStorageService(IGlobalServiceBroker globalServiceBroker, IPersistentStorageConfiguration configuration)
: base(configuration)
{
_globalServiceBroker = globalServiceBroker;
}
protected override void DisposeCacheService(ICacheService cacheService)
{
if (cacheService is IAsyncDisposable asyncDisposable)
{
asyncDisposable.DisposeAsync().AsTask().Wait();
}
else if (cacheService is IDisposable disposable)
{
disposable.Dispose();
}
}
protected override async ValueTask<ICacheService> CreateCacheServiceAsync(CancellationToken cancellationToken)
{
var serviceBroker = _globalServiceBroker.Instance;
#pragma warning disable ISB001 // Dispose of proxies
// cache service will be disposed inside RemoteCloudCacheService.Dispose
var cacheService = await serviceBroker.GetProxyAsync<ICacheService>(VisualStudioServices.VS2019_10.CacheService, cancellationToken: cancellationToken).ConfigureAwait(false);
#pragma warning restore ISB001 // Dispose of proxies
Contract.ThrowIfNull(cacheService);
return cacheService;
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Composition;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Host.Mef;
using Microsoft.CodeAnalysis.Remote.Host;
using Microsoft.CodeAnalysis.Storage;
using Microsoft.CodeAnalysis.Storage.CloudCache;
using Microsoft.VisualStudio;
using Microsoft.VisualStudio.LanguageServices.Storage;
using Microsoft.VisualStudio.RpcContracts.Caching;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Remote.Storage
{
[ExportWorkspaceService(typeof(ICloudCacheStorageServiceFactory), WorkspaceKind.RemoteWorkspace), Shared]
internal class RemoteCloudCacheStorageServiceFactory : ICloudCacheStorageServiceFactory
{
private readonly IGlobalServiceBroker _globalServiceBroker;
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public RemoteCloudCacheStorageServiceFactory(IGlobalServiceBroker globalServiceBroker)
{
_globalServiceBroker = globalServiceBroker;
}
public AbstractPersistentStorageService Create(IPersistentStorageConfiguration configuration)
=> new RemoteCloudCachePersistentStorageService(_globalServiceBroker, configuration);
private class RemoteCloudCachePersistentStorageService : AbstractCloudCachePersistentStorageService
{
private readonly IGlobalServiceBroker _globalServiceBroker;
public RemoteCloudCachePersistentStorageService(IGlobalServiceBroker globalServiceBroker, IPersistentStorageConfiguration configuration)
: base(configuration)
{
_globalServiceBroker = globalServiceBroker;
}
protected override void DisposeCacheService(ICacheService cacheService)
{
if (cacheService is IAsyncDisposable asyncDisposable)
{
asyncDisposable.DisposeAsync().AsTask().Wait();
}
else if (cacheService is IDisposable disposable)
{
disposable.Dispose();
}
}
protected override async ValueTask<ICacheService> CreateCacheServiceAsync(CancellationToken cancellationToken)
{
var serviceBroker = _globalServiceBroker.Instance;
#pragma warning disable ISB001 // Dispose of proxies
// cache service will be disposed inside RemoteCloudCacheService.Dispose
var cacheService = await serviceBroker.GetProxyAsync<ICacheService>(VisualStudioServices.VS2019_10.CacheService, cancellationToken: cancellationToken).ConfigureAwait(false);
#pragma warning restore ISB001 // Dispose of proxies
Contract.ThrowIfNull(cacheService);
return cacheService;
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/Core/Portable/FindSymbols/SymbolFinder_Hierarchy.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.ComponentModel;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Shared.Utilities;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.FindSymbols
{
public static partial class SymbolFinder
{
/// <summary>
/// Find symbols for members that override the specified member symbol.
/// </summary>
public static async Task<IEnumerable<ISymbol>> FindOverridesAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
return await FindOverridesArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindOverridesAsync"/>
/// <remarks>
/// Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.
/// </remarks>
internal static async Task<ImmutableArray<ISymbol>> FindOverridesArrayAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var results = ArrayBuilder<ISymbol>.GetInstance();
symbol = symbol?.OriginalDefinition;
if (symbol.IsOverridable())
{
// To find the overrides, we need to walk down the type hierarchy and check all
// derived types.
var containingType = symbol.ContainingType;
var derivedTypes = await FindDerivedClassesAsync(
containingType, solution, projects, cancellationToken).ConfigureAwait(false);
foreach (var type in derivedTypes)
{
foreach (var m in type.GetMembers(symbol.Name))
{
var sourceMember = await FindSourceDefinitionAsync(m, solution, cancellationToken).ConfigureAwait(false);
var bestMember = sourceMember ?? m;
if (await IsOverrideAsync(solution, bestMember, symbol, cancellationToken).ConfigureAwait(false))
{
results.Add(bestMember);
}
}
}
}
return results.ToImmutableAndFree();
}
internal static async Task<bool> IsOverrideAsync(Solution solution, ISymbol member, ISymbol symbol, CancellationToken cancellationToken)
{
for (var current = member; current != null; current = current.GetOverriddenMember())
{
if (await OriginalSymbolsMatchAsync(solution, current.GetOverriddenMember(), symbol.OriginalDefinition, cancellationToken).ConfigureAwait(false))
return true;
}
return false;
}
/// <summary>
/// Find symbols for declarations that implement members of the specified interface symbol
/// </summary>
public static async Task<IEnumerable<ISymbol>> FindImplementedInterfaceMembersAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
return await FindImplementedInterfaceMembersArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
}
internal static Task<ImmutableArray<ISymbol>> FindImplementedInterfaceMembersArrayAsync(
ISymbol symbol, Solution solution, CancellationToken cancellationToken)
{
return FindImplementedInterfaceMembersArrayAsync(symbol, solution, projects: null, cancellationToken);
}
/// <inheritdoc cref="FindImplementedInterfaceMembersAsync"/>
/// <remarks>
/// Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.
/// </remarks>
internal static async Task<ImmutableArray<ISymbol>> FindImplementedInterfaceMembersArrayAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects, CancellationToken cancellationToken)
{
// Member can only implement interface members if it is an explicit member, or if it is
// public
if (symbol != null)
{
var explicitImplementations = symbol.ExplicitInterfaceImplementations();
if (explicitImplementations.Length > 0)
{
return explicitImplementations;
}
else if (
symbol.DeclaredAccessibility == Accessibility.Public &&
(symbol.ContainingType.TypeKind == TypeKind.Class || symbol.ContainingType.TypeKind == TypeKind.Struct))
{
// Interface implementation is a tricky thing. A method may implement an interface
// method, even if its containing type doesn't state that it implements the
// interface. For example:
//
// interface IGoo { void Goo(); }
//
// class Base { public void Goo(); }
//
// class Derived : Base, IGoo { }
//
// In this case, Base.Goo *does* implement IGoo.Goo in the context of the type
// Derived.
var containingType = symbol.ContainingType.OriginalDefinition;
var derivedClasses = await SymbolFinder.FindDerivedClassesAsync(
containingType, solution, projects, cancellationToken).ConfigureAwait(false);
var allTypes = derivedClasses.Concat(containingType);
using var _ = ArrayBuilder<ISymbol>.GetInstance(out var builder);
foreach (var type in allTypes)
{
foreach (var interfaceType in type.AllInterfaces)
{
// We don't want to look inside this type if we can avoid it. So first
// make sure that the interface even contains a symbol with the same
// name as the symbol we're looking for.
var nameToLookFor = symbol.IsPropertyAccessor()
? ((IMethodSymbol)symbol).AssociatedSymbol.Name
: symbol.Name;
if (interfaceType.MemberNames.Contains(nameToLookFor))
{
foreach (var m in interfaceType.GetMembers(symbol.Name))
{
var sourceMethod = await FindSourceDefinitionAsync(m, solution, cancellationToken).ConfigureAwait(false);
var bestMethod = sourceMethod ?? m;
var implementations = await type.FindImplementationsForInterfaceMemberAsync(bestMethod, solution, cancellationToken).ConfigureAwait(false);
foreach (var implementation in implementations)
{
if (implementation != null &&
SymbolEquivalenceComparer.Instance.Equals(implementation.OriginalDefinition, symbol.OriginalDefinition))
{
builder.Add(bestMethod);
}
}
}
}
}
}
return builder.Distinct(SymbolEquivalenceComparer.Instance).ToImmutableArray();
}
}
return ImmutableArray<ISymbol>.Empty;
}
#region derived classes
/// <summary>
/// Finds all the derived classes of the given type. Implementations of an interface are not considered
/// "derived", but can be found with <see cref="FindImplementationsAsync(ISymbol, Solution,
/// IImmutableSet{Project}, CancellationToken)"/>.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
/// <param name="cancellationToken"></param>
/// <returns>The derived types of the symbol. The symbol passed in is not included in this list.</returns>
[EditorBrowsable(EditorBrowsableState.Never)]
public static Task<IEnumerable<INamedTypeSymbol>> FindDerivedClassesAsync(
INamedTypeSymbol type, Solution solution, IImmutableSet<Project> projects, CancellationToken cancellationToken)
{
return FindDerivedClassesAsync(type, solution, transitive: true, projects, cancellationToken);
}
/// <summary>
/// Finds the derived classes of the given type. Implementations of an interface are not considered
/// "derived", but can be found with <see cref="FindImplementationsAsync(ISymbol, Solution,
/// IImmutableSet{Project}, CancellationToken)"/>.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="transitive">If the search should stop at immediately derived classes, or should continue past that.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
/// <param name="cancellationToken"></param>
/// <returns>The derived types of the symbol. The symbol passed in is not included in this list.</returns>
#pragma warning disable RS0026 // Do not add multiple public overloads with optional parameters
public static async Task<IEnumerable<INamedTypeSymbol>> FindDerivedClassesAsync(
INamedTypeSymbol type, Solution solution, bool transitive = true, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
#pragma warning restore RS0026 // Do not add multiple public overloads with optional parameters
{
if (type == null)
throw new ArgumentNullException(nameof(type));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
return await FindDerivedClassesArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindDerivedClassesArrayAsync(INamedTypeSymbol, Solution, bool, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks> Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.</remarks>
internal static async Task<ImmutableArray<INamedTypeSymbol>> FindDerivedClassesArrayAsync(
INamedTypeSymbol type, Solution solution, bool transitive, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var types = await DependentTypeFinder.FindTypesAsync(
type, solution, projects, transitive, DependentTypesKind.DerivedClasses, cancellationToken).ConfigureAwait(false);
return types.WhereAsArray(t => IsAccessible(t));
}
#endregion
#region derived interfaces
/// <summary>
/// Finds the derived interfaces of the given interfaces.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="transitive">If the search should stop at immediately derived interfaces, or should continue past that.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
/// <returns>The derived interfaces of the symbol. The symbol passed in is not included in this list.</returns>
#pragma warning disable RS0026 // Do not add multiple public overloads with optional parameters
public static async Task<IEnumerable<INamedTypeSymbol>> FindDerivedInterfacesAsync(
INamedTypeSymbol type, Solution solution, bool transitive = true, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
#pragma warning restore RS0026 // Do not add multiple public overloads with optional parameters
{
if (type == null)
throw new ArgumentNullException(nameof(type));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
return await FindDerivedInterfacesArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindDerivedInterfacesAsync(INamedTypeSymbol, Solution, bool, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks> Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.</remarks>
internal static async Task<ImmutableArray<INamedTypeSymbol>> FindDerivedInterfacesArrayAsync(
INamedTypeSymbol type, Solution solution, bool transitive, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var types = await DependentTypeFinder.FindTypesAsync(
type, solution, projects, transitive, DependentTypesKind.DerivedInterfaces, cancellationToken).ConfigureAwait(false);
return types.WhereAsArray(t => IsAccessible(t));
}
#endregion
#region interface implementations
/// <summary>
/// Finds the accessible <see langword="class"/> or <see langword="struct"/> types that implement the given
/// interface.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="transitive">If the search should stop at immediately derived interfaces, or should continue past that.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
#pragma warning disable RS0026 // Do not add multiple public overloads with optional parameters
public static async Task<IEnumerable<INamedTypeSymbol>> FindImplementationsAsync(
INamedTypeSymbol type, Solution solution, bool transitive = true, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
#pragma warning restore RS0026 // Do not add multiple public overloads with optional parameters
{
if (type == null)
throw new ArgumentNullException(nameof(type));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
return await FindImplementationsArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindImplementationsAsync(INamedTypeSymbol, Solution, bool, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks> Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.</remarks>
internal static async Task<ImmutableArray<INamedTypeSymbol>> FindImplementationsArrayAsync(
INamedTypeSymbol type, Solution solution, bool transitive, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var types = await DependentTypeFinder.FindTypesAsync(
type, solution, projects, transitive, DependentTypesKind.ImplementingTypes, cancellationToken).ConfigureAwait(false);
return types.WhereAsArray(t => IsAccessible(t));
}
#endregion
/// <summary>
/// Finds all the accessible symbols that implement an interface or interface member. For an <see
/// cref="INamedTypeSymbol"/> this will be both immediate and transitive implementations.
/// </summary>
public static async Task<IEnumerable<ISymbol>> FindImplementationsAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
if (symbol == null)
throw new ArgumentNullException(nameof(symbol));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
// A symbol can only have implementations if it's an interface or a
// method/property/event from an interface.
if (symbol is INamedTypeSymbol namedTypeSymbol)
{
return await FindImplementationsAsync(
namedTypeSymbol, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
}
return await FindMemberImplementationsArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindImplementationsAsync(ISymbol, Solution, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks>
/// Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.
/// </remarks>
internal static async Task<ImmutableArray<ISymbol>> FindMemberImplementationsArrayAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
if (!symbol.IsImplementableMember())
return ImmutableArray<ISymbol>.Empty;
var containingType = symbol.ContainingType.OriginalDefinition;
// implementations could be found in any class/struct implementations of the containing interface. And, in
// the case of DIM, they could be found in any derived interface.
var classAndStructImplementations = await FindImplementationsAsync(containingType, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
var transitiveDerivedInterfaces = await FindDerivedInterfacesAsync(containingType, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
var allTypes = classAndStructImplementations.Concat(transitiveDerivedInterfaces);
using var _ = ArrayBuilder<ISymbol>.GetInstance(out var results);
foreach (var t in allTypes)
{
var implementations = await t.FindImplementationsForInterfaceMemberAsync(symbol, solution, cancellationToken).ConfigureAwait(false);
foreach (var implementation in implementations)
{
var sourceDef = await FindSourceDefinitionAsync(implementation, solution, cancellationToken).ConfigureAwait(false);
var bestDef = sourceDef ?? implementation;
if (IsAccessible(bestDef))
results.Add(bestDef.OriginalDefinition);
}
}
return results.Distinct(SymbolEquivalenceComparer.Instance).ToImmutableArray();
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.ComponentModel;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Shared.Utilities;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.FindSymbols
{
public static partial class SymbolFinder
{
/// <summary>
/// Find symbols for members that override the specified member symbol.
/// </summary>
public static async Task<IEnumerable<ISymbol>> FindOverridesAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
return await FindOverridesArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindOverridesAsync"/>
/// <remarks>
/// Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.
/// </remarks>
internal static async Task<ImmutableArray<ISymbol>> FindOverridesArrayAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var results = ArrayBuilder<ISymbol>.GetInstance();
symbol = symbol?.OriginalDefinition;
if (symbol.IsOverridable())
{
// To find the overrides, we need to walk down the type hierarchy and check all
// derived types.
var containingType = symbol.ContainingType;
var derivedTypes = await FindDerivedClassesAsync(
containingType, solution, projects, cancellationToken).ConfigureAwait(false);
foreach (var type in derivedTypes)
{
foreach (var m in type.GetMembers(symbol.Name))
{
var sourceMember = await FindSourceDefinitionAsync(m, solution, cancellationToken).ConfigureAwait(false);
var bestMember = sourceMember ?? m;
if (await IsOverrideAsync(solution, bestMember, symbol, cancellationToken).ConfigureAwait(false))
{
results.Add(bestMember);
}
}
}
}
return results.ToImmutableAndFree();
}
internal static async Task<bool> IsOverrideAsync(Solution solution, ISymbol member, ISymbol symbol, CancellationToken cancellationToken)
{
for (var current = member; current != null; current = current.GetOverriddenMember())
{
if (await OriginalSymbolsMatchAsync(solution, current.GetOverriddenMember(), symbol.OriginalDefinition, cancellationToken).ConfigureAwait(false))
return true;
}
return false;
}
/// <summary>
/// Find symbols for declarations that implement members of the specified interface symbol
/// </summary>
public static async Task<IEnumerable<ISymbol>> FindImplementedInterfaceMembersAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
return await FindImplementedInterfaceMembersArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
}
internal static Task<ImmutableArray<ISymbol>> FindImplementedInterfaceMembersArrayAsync(
ISymbol symbol, Solution solution, CancellationToken cancellationToken)
{
return FindImplementedInterfaceMembersArrayAsync(symbol, solution, projects: null, cancellationToken);
}
/// <inheritdoc cref="FindImplementedInterfaceMembersAsync"/>
/// <remarks>
/// Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.
/// </remarks>
internal static async Task<ImmutableArray<ISymbol>> FindImplementedInterfaceMembersArrayAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects, CancellationToken cancellationToken)
{
// Member can only implement interface members if it is an explicit member, or if it is
// public
if (symbol != null)
{
var explicitImplementations = symbol.ExplicitInterfaceImplementations();
if (explicitImplementations.Length > 0)
{
return explicitImplementations;
}
else if (
symbol.DeclaredAccessibility == Accessibility.Public &&
(symbol.ContainingType.TypeKind == TypeKind.Class || symbol.ContainingType.TypeKind == TypeKind.Struct))
{
// Interface implementation is a tricky thing. A method may implement an interface
// method, even if its containing type doesn't state that it implements the
// interface. For example:
//
// interface IGoo { void Goo(); }
//
// class Base { public void Goo(); }
//
// class Derived : Base, IGoo { }
//
// In this case, Base.Goo *does* implement IGoo.Goo in the context of the type
// Derived.
var containingType = symbol.ContainingType.OriginalDefinition;
var derivedClasses = await SymbolFinder.FindDerivedClassesAsync(
containingType, solution, projects, cancellationToken).ConfigureAwait(false);
var allTypes = derivedClasses.Concat(containingType);
using var _ = ArrayBuilder<ISymbol>.GetInstance(out var builder);
foreach (var type in allTypes)
{
foreach (var interfaceType in type.AllInterfaces)
{
// We don't want to look inside this type if we can avoid it. So first
// make sure that the interface even contains a symbol with the same
// name as the symbol we're looking for.
var nameToLookFor = symbol.IsPropertyAccessor()
? ((IMethodSymbol)symbol).AssociatedSymbol.Name
: symbol.Name;
if (interfaceType.MemberNames.Contains(nameToLookFor))
{
foreach (var m in interfaceType.GetMembers(symbol.Name))
{
var sourceMethod = await FindSourceDefinitionAsync(m, solution, cancellationToken).ConfigureAwait(false);
var bestMethod = sourceMethod ?? m;
var implementations = await type.FindImplementationsForInterfaceMemberAsync(bestMethod, solution, cancellationToken).ConfigureAwait(false);
foreach (var implementation in implementations)
{
if (implementation != null &&
SymbolEquivalenceComparer.Instance.Equals(implementation.OriginalDefinition, symbol.OriginalDefinition))
{
builder.Add(bestMethod);
}
}
}
}
}
}
return builder.Distinct(SymbolEquivalenceComparer.Instance).ToImmutableArray();
}
}
return ImmutableArray<ISymbol>.Empty;
}
#region derived classes
/// <summary>
/// Finds all the derived classes of the given type. Implementations of an interface are not considered
/// "derived", but can be found with <see cref="FindImplementationsAsync(ISymbol, Solution,
/// IImmutableSet{Project}, CancellationToken)"/>.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
/// <param name="cancellationToken"></param>
/// <returns>The derived types of the symbol. The symbol passed in is not included in this list.</returns>
[EditorBrowsable(EditorBrowsableState.Never)]
public static Task<IEnumerable<INamedTypeSymbol>> FindDerivedClassesAsync(
INamedTypeSymbol type, Solution solution, IImmutableSet<Project> projects, CancellationToken cancellationToken)
{
return FindDerivedClassesAsync(type, solution, transitive: true, projects, cancellationToken);
}
/// <summary>
/// Finds the derived classes of the given type. Implementations of an interface are not considered
/// "derived", but can be found with <see cref="FindImplementationsAsync(ISymbol, Solution,
/// IImmutableSet{Project}, CancellationToken)"/>.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="transitive">If the search should stop at immediately derived classes, or should continue past that.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
/// <param name="cancellationToken"></param>
/// <returns>The derived types of the symbol. The symbol passed in is not included in this list.</returns>
#pragma warning disable RS0026 // Do not add multiple public overloads with optional parameters
public static async Task<IEnumerable<INamedTypeSymbol>> FindDerivedClassesAsync(
INamedTypeSymbol type, Solution solution, bool transitive = true, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
#pragma warning restore RS0026 // Do not add multiple public overloads with optional parameters
{
if (type == null)
throw new ArgumentNullException(nameof(type));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
return await FindDerivedClassesArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindDerivedClassesArrayAsync(INamedTypeSymbol, Solution, bool, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks> Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.</remarks>
internal static async Task<ImmutableArray<INamedTypeSymbol>> FindDerivedClassesArrayAsync(
INamedTypeSymbol type, Solution solution, bool transitive, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var types = await DependentTypeFinder.FindTypesAsync(
type, solution, projects, transitive, DependentTypesKind.DerivedClasses, cancellationToken).ConfigureAwait(false);
return types.WhereAsArray(t => IsAccessible(t));
}
#endregion
#region derived interfaces
/// <summary>
/// Finds the derived interfaces of the given interfaces.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="transitive">If the search should stop at immediately derived interfaces, or should continue past that.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
/// <returns>The derived interfaces of the symbol. The symbol passed in is not included in this list.</returns>
#pragma warning disable RS0026 // Do not add multiple public overloads with optional parameters
public static async Task<IEnumerable<INamedTypeSymbol>> FindDerivedInterfacesAsync(
INamedTypeSymbol type, Solution solution, bool transitive = true, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
#pragma warning restore RS0026 // Do not add multiple public overloads with optional parameters
{
if (type == null)
throw new ArgumentNullException(nameof(type));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
return await FindDerivedInterfacesArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindDerivedInterfacesAsync(INamedTypeSymbol, Solution, bool, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks> Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.</remarks>
internal static async Task<ImmutableArray<INamedTypeSymbol>> FindDerivedInterfacesArrayAsync(
INamedTypeSymbol type, Solution solution, bool transitive, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var types = await DependentTypeFinder.FindTypesAsync(
type, solution, projects, transitive, DependentTypesKind.DerivedInterfaces, cancellationToken).ConfigureAwait(false);
return types.WhereAsArray(t => IsAccessible(t));
}
#endregion
#region interface implementations
/// <summary>
/// Finds the accessible <see langword="class"/> or <see langword="struct"/> types that implement the given
/// interface.
/// </summary>
/// <param name="type">The symbol to find derived types of.</param>
/// <param name="solution">The solution to search in.</param>
/// <param name="transitive">If the search should stop at immediately derived interfaces, or should continue past that.</param>
/// <param name="projects">The projects to search. Can be null to search the entire solution.</param>
#pragma warning disable RS0026 // Do not add multiple public overloads with optional parameters
public static async Task<IEnumerable<INamedTypeSymbol>> FindImplementationsAsync(
INamedTypeSymbol type, Solution solution, bool transitive = true, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
#pragma warning restore RS0026 // Do not add multiple public overloads with optional parameters
{
if (type == null)
throw new ArgumentNullException(nameof(type));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
return await FindImplementationsArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindImplementationsAsync(INamedTypeSymbol, Solution, bool, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks> Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.</remarks>
internal static async Task<ImmutableArray<INamedTypeSymbol>> FindImplementationsArrayAsync(
INamedTypeSymbol type, Solution solution, bool transitive, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
var types = await DependentTypeFinder.FindTypesAsync(
type, solution, projects, transitive, DependentTypesKind.ImplementingTypes, cancellationToken).ConfigureAwait(false);
return types.WhereAsArray(t => IsAccessible(t));
}
#endregion
/// <summary>
/// Finds all the accessible symbols that implement an interface or interface member. For an <see
/// cref="INamedTypeSymbol"/> this will be both immediate and transitive implementations.
/// </summary>
public static async Task<IEnumerable<ISymbol>> FindImplementationsAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
if (symbol == null)
throw new ArgumentNullException(nameof(symbol));
if (solution == null)
throw new ArgumentNullException(nameof(solution));
// A symbol can only have implementations if it's an interface or a
// method/property/event from an interface.
if (symbol is INamedTypeSymbol namedTypeSymbol)
{
return await FindImplementationsAsync(
namedTypeSymbol, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
}
return await FindMemberImplementationsArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
}
/// <inheritdoc cref="FindImplementationsAsync(ISymbol, Solution, IImmutableSet{Project}, CancellationToken)"/>
/// <remarks>
/// Use this overload to avoid boxing the result into an <see cref="IEnumerable{T}"/>.
/// </remarks>
internal static async Task<ImmutableArray<ISymbol>> FindMemberImplementationsArrayAsync(
ISymbol symbol, Solution solution, IImmutableSet<Project> projects = null, CancellationToken cancellationToken = default)
{
if (!symbol.IsImplementableMember())
return ImmutableArray<ISymbol>.Empty;
var containingType = symbol.ContainingType.OriginalDefinition;
// implementations could be found in any class/struct implementations of the containing interface. And, in
// the case of DIM, they could be found in any derived interface.
var classAndStructImplementations = await FindImplementationsAsync(containingType, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
var transitiveDerivedInterfaces = await FindDerivedInterfacesAsync(containingType, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
var allTypes = classAndStructImplementations.Concat(transitiveDerivedInterfaces);
using var _ = ArrayBuilder<ISymbol>.GetInstance(out var results);
foreach (var t in allTypes)
{
var implementations = await t.FindImplementationsForInterfaceMemberAsync(symbol, solution, cancellationToken).ConfigureAwait(false);
foreach (var implementation in implementations)
{
var sourceDef = await FindSourceDefinitionAsync(implementation, solution, cancellationToken).ConfigureAwait(false);
var bestDef = sourceDef ?? implementation;
if (IsAccessible(bestDef))
results.Add(bestDef.OriginalDefinition);
}
}
return results.Distinct(SymbolEquivalenceComparer.Instance).ToImmutableArray();
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/Remote/ServiceHub/Services/InheritanceMargin/RemoteInheritanceMarginService.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.InheritanceMargin;
namespace Microsoft.CodeAnalysis.Remote
{
internal sealed class RemoteInheritanceMarginService : BrokeredServiceBase, IRemoteInheritanceMarginService
{
internal sealed class Factory : FactoryBase<IRemoteInheritanceMarginService>
{
protected override IRemoteInheritanceMarginService CreateService(in ServiceConstructionArguments arguments)
{
return new RemoteInheritanceMarginService(arguments);
}
}
public RemoteInheritanceMarginService(in ServiceConstructionArguments arguments) : base(in arguments)
{
}
public ValueTask<ImmutableArray<SerializableInheritanceMarginItem>> GetInheritanceMarginItemsAsync(
PinnedSolutionInfo pinnedSolutionInfo,
ProjectId projectId,
ImmutableArray<(SymbolKey symbolKey, int lineNumber)> symbolKeyAndLineNumbers,
CancellationToken cancellationToken)
=> RunServiceAsync(async cancellationToken =>
{
var solution = await GetSolutionAsync(pinnedSolutionInfo, cancellationToken).ConfigureAwait(false);
return await InheritanceMarginServiceHelper
.GetInheritanceMemberItemAsync(solution, projectId, symbolKeyAndLineNumbers, cancellationToken)
.ConfigureAwait(false);
}, cancellationToken);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.InheritanceMargin;
namespace Microsoft.CodeAnalysis.Remote
{
internal sealed class RemoteInheritanceMarginService : BrokeredServiceBase, IRemoteInheritanceMarginService
{
internal sealed class Factory : FactoryBase<IRemoteInheritanceMarginService>
{
protected override IRemoteInheritanceMarginService CreateService(in ServiceConstructionArguments arguments)
{
return new RemoteInheritanceMarginService(arguments);
}
}
public RemoteInheritanceMarginService(in ServiceConstructionArguments arguments) : base(in arguments)
{
}
public ValueTask<ImmutableArray<SerializableInheritanceMarginItem>> GetInheritanceMarginItemsAsync(
PinnedSolutionInfo pinnedSolutionInfo,
ProjectId projectId,
ImmutableArray<(SymbolKey symbolKey, int lineNumber)> symbolKeyAndLineNumbers,
CancellationToken cancellationToken)
=> RunServiceAsync(async cancellationToken =>
{
var solution = await GetSolutionAsync(pinnedSolutionInfo, cancellationToken).ConfigureAwait(false);
return await InheritanceMarginServiceHelper
.GetInheritanceMemberItemAsync(solution, projectId, symbolKeyAndLineNumbers, cancellationToken)
.ConfigureAwait(false);
}, cancellationToken);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Analyzers/CSharp/Tests/RemoveUnnecessaryParentheses/RemoveUnnecessaryPatternParenthesesTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysis.CSharp.RemoveUnnecessaryParentheses;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Diagnostics;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.RemoveUnnecessaryParentheses
{
public partial class RemoveUnnecessaryPatternParenthesesTests : AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest
{
public RemoveUnnecessaryPatternParenthesesTests(ITestOutputHelper logger)
: base(logger)
{
}
internal override (DiagnosticAnalyzer, CodeFixProvider) CreateDiagnosticProviderAndFixer(Workspace workspace)
=> (new CSharpRemoveUnnecessaryPatternParenthesesDiagnosticAnalyzer(), new CSharpRemoveUnnecessaryParenthesesCodeFixProvider());
private async Task TestAsync(string initial, string expected, bool offeredWhenRequireForClarityIsEnabled, int index = 0)
{
await TestInRegularAndScriptAsync(initial, expected, options: RemoveAllUnnecessaryParentheses, index: index);
if (offeredWhenRequireForClarityIsEnabled)
{
await TestInRegularAndScriptAsync(initial, expected, options: RequireAllParenthesesForClarity, index: index);
}
else
{
await TestMissingAsync(initial, parameters: new TestParameters(options: RequireAllParenthesesForClarity));
}
}
internal override bool ShouldSkipMessageDescriptionVerification(DiagnosticDescriptor descriptor)
=> descriptor.ImmutableCustomTags().Contains(WellKnownDiagnosticTags.Unnecessary) && descriptor.DefaultSeverity == DiagnosticSeverity.Hidden;
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestArithmeticRequiredForClarity2()
{
await TestInRegularAndScript1Async(
@"class C
{
void M(object o)
{
bool x = o is a or $$(b and c);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b and c;
}
}", parameters: new TestParameters(options: RequireArithmeticBinaryParenthesesForClarity));
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestLogicalRequiredForClarity1()
{
await TestMissingAsync(
@"class C
{
void M(object o)
{
bool x = o is a or $$(b and c);
}
}", new TestParameters(options: RequireOtherBinaryParenthesesForClarity));
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestLogicalNotRequiredForClarityWhenPrecedenceStaysTheSame1()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is a or $$(b or c);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b or c;
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestLogicalNotRequiredForClarityWhenPrecedenceStaysTheSame2()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is $$(a or b) or c;
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b or c;
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForIsPattern()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is $$(a or b);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b;
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForCasePattern()
{
await TestAsync(
@"class C
{
void M(object o)
{
switch (o)
{
case $$(a or b):
return;
}
}
}",
@"class C
{
void M(object o)
{
switch (o)
{
case a or b:
return;
}
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForSwitchArmPattern()
{
await TestAsync(
@"class C
{
int M(object o)
{
return o switch
{
$$(a or b) => 0,
};
}
}",
@"class C
{
int M(object o)
{
return o switch
{
a or b => 0,
};
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForSubPattern()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is { X: $$(a or b) };
}
}",
@"class C
{
void M(object o)
{
bool x = o is { X: a or b };
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestNotAlwaysUnnecessaryForUnaryPattern1()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is a or $$(not b);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or not b;
}
}", offeredWhenRequireForClarityIsEnabled: false);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestNotAlwaysUnnecessaryForUnaryPattern2()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is $$(not a) or b;
}
}",
@"class C
{
void M(object o)
{
bool x = o is not a or b;
}
}", offeredWhenRequireForClarityIsEnabled: false);
}
[WorkItem(52589, "https://github.com/dotnet/roslyn/issues/52589")]
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysNecessaryForDiscard()
{
await TestDiagnosticMissingAsync(
@"
class C
{
void M(object o)
{
if (o is $$(_))
{
}
}
}");
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestUnnecessaryForDiscardInSubpattern()
{
await TestAsync(
@"
class C
{
void M(object o)
{
if (o is string { Length: $$(_) })
{
}
}
}",
@"
class C
{
void M(object o)
{
if (o is string { Length: _ })
{
}
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysis.CSharp.RemoveUnnecessaryParentheses;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Diagnostics;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.RemoveUnnecessaryParentheses
{
public partial class RemoveUnnecessaryPatternParenthesesTests : AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest
{
public RemoveUnnecessaryPatternParenthesesTests(ITestOutputHelper logger)
: base(logger)
{
}
internal override (DiagnosticAnalyzer, CodeFixProvider) CreateDiagnosticProviderAndFixer(Workspace workspace)
=> (new CSharpRemoveUnnecessaryPatternParenthesesDiagnosticAnalyzer(), new CSharpRemoveUnnecessaryParenthesesCodeFixProvider());
private async Task TestAsync(string initial, string expected, bool offeredWhenRequireForClarityIsEnabled, int index = 0)
{
await TestInRegularAndScriptAsync(initial, expected, options: RemoveAllUnnecessaryParentheses, index: index);
if (offeredWhenRequireForClarityIsEnabled)
{
await TestInRegularAndScriptAsync(initial, expected, options: RequireAllParenthesesForClarity, index: index);
}
else
{
await TestMissingAsync(initial, parameters: new TestParameters(options: RequireAllParenthesesForClarity));
}
}
internal override bool ShouldSkipMessageDescriptionVerification(DiagnosticDescriptor descriptor)
=> descriptor.ImmutableCustomTags().Contains(WellKnownDiagnosticTags.Unnecessary) && descriptor.DefaultSeverity == DiagnosticSeverity.Hidden;
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestArithmeticRequiredForClarity2()
{
await TestInRegularAndScript1Async(
@"class C
{
void M(object o)
{
bool x = o is a or $$(b and c);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b and c;
}
}", parameters: new TestParameters(options: RequireArithmeticBinaryParenthesesForClarity));
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestLogicalRequiredForClarity1()
{
await TestMissingAsync(
@"class C
{
void M(object o)
{
bool x = o is a or $$(b and c);
}
}", new TestParameters(options: RequireOtherBinaryParenthesesForClarity));
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestLogicalNotRequiredForClarityWhenPrecedenceStaysTheSame1()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is a or $$(b or c);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b or c;
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestLogicalNotRequiredForClarityWhenPrecedenceStaysTheSame2()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is $$(a or b) or c;
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b or c;
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForIsPattern()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is $$(a or b);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or b;
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForCasePattern()
{
await TestAsync(
@"class C
{
void M(object o)
{
switch (o)
{
case $$(a or b):
return;
}
}
}",
@"class C
{
void M(object o)
{
switch (o)
{
case a or b:
return;
}
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForSwitchArmPattern()
{
await TestAsync(
@"class C
{
int M(object o)
{
return o switch
{
$$(a or b) => 0,
};
}
}",
@"class C
{
int M(object o)
{
return o switch
{
a or b => 0,
};
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysUnnecessaryForSubPattern()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is { X: $$(a or b) };
}
}",
@"class C
{
void M(object o)
{
bool x = o is { X: a or b };
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestNotAlwaysUnnecessaryForUnaryPattern1()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is a or $$(not b);
}
}",
@"class C
{
void M(object o)
{
bool x = o is a or not b;
}
}", offeredWhenRequireForClarityIsEnabled: false);
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestNotAlwaysUnnecessaryForUnaryPattern2()
{
await TestAsync(
@"class C
{
void M(object o)
{
bool x = o is $$(not a) or b;
}
}",
@"class C
{
void M(object o)
{
bool x = o is not a or b;
}
}", offeredWhenRequireForClarityIsEnabled: false);
}
[WorkItem(52589, "https://github.com/dotnet/roslyn/issues/52589")]
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestAlwaysNecessaryForDiscard()
{
await TestDiagnosticMissingAsync(
@"
class C
{
void M(object o)
{
if (o is $$(_))
{
}
}
}");
}
[Fact, Trait(Traits.Feature, Traits.Features.CodeActionsRemoveUnnecessaryParentheses)]
public async Task TestUnnecessaryForDiscardInSubpattern()
{
await TestAsync(
@"
class C
{
void M(object o)
{
if (o is string { Length: $$(_) })
{
}
}
}",
@"
class C
{
void M(object o)
{
if (o is string { Length: _ })
{
}
}
}", offeredWhenRequireForClarityIsEnabled: true);
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/CSharp/Portable/Symbols/Synthesized/Records/SynthesizedRecordEqualityOperatorBase.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
/// <summary>
/// The record type includes synthesized '==' and '!=' operators equivalent to operators declared as follows:
///
/// For record class:
/// public static bool operator==(R? left, R? right)
/// => (object) left == right || ((object)left != null && left.Equals(right));
/// public static bool operator !=(R? left, R? right)
/// => !(left == right);
///
/// For record struct:
/// public static bool operator==(R left, R right)
/// => left.Equals(right);
/// public static bool operator !=(R left, R right)
/// => !(left == right);
///
///The 'Equals' method called by the '==' operator is the 'Equals(R? other)' (<see cref="SynthesizedRecordEquals"/>).
///The '!=' operator delegates to the '==' operator. It is an error if the operators are declared explicitly.
/// </summary>
internal abstract class SynthesizedRecordEqualityOperatorBase : SourceUserDefinedOperatorSymbolBase
{
private readonly int _memberOffset;
protected SynthesizedRecordEqualityOperatorBase(SourceMemberContainerTypeSymbol containingType, string name, int memberOffset, BindingDiagnosticBag diagnostics)
: base(MethodKind.UserDefinedOperator, explicitInterfaceType: null, name, containingType, containingType.Locations[0], (CSharpSyntaxNode)containingType.SyntaxReferences[0].GetSyntax(),
DeclarationModifiers.Public | DeclarationModifiers.Static, hasBody: true, isExpressionBodied: false, isIterator: false, isNullableAnalysisEnabled: false, diagnostics)
{
Debug.Assert(name == WellKnownMemberNames.EqualityOperatorName || name == WellKnownMemberNames.InequalityOperatorName);
_memberOffset = memberOffset;
}
public sealed override bool IsImplicitlyDeclared => true;
protected sealed override Location ReturnTypeLocation => Locations[0];
internal sealed override LexicalSortKey GetLexicalSortKey() => LexicalSortKey.GetSynthesizedMemberKey(_memberOffset);
protected sealed override SourceMemberMethodSymbol? BoundAttributesSource => null;
internal sealed override OneOrMany<SyntaxList<AttributeListSyntax>> GetAttributeDeclarations() => OneOrMany.Create(default(SyntaxList<AttributeListSyntax>));
public sealed override string? GetDocumentationCommentXml(CultureInfo? preferredCulture = null, bool expandIncludes = false, CancellationToken cancellationToken = default) => null;
internal sealed override bool GenerateDebugInfo => false;
internal sealed override bool SynthesizesLoweredBoundBody => true;
protected sealed override (TypeWithAnnotations ReturnType, ImmutableArray<ParameterSymbol> Parameters) MakeParametersAndBindReturnType(BindingDiagnosticBag diagnostics)
{
var compilation = DeclaringCompilation;
var location = ReturnTypeLocation;
var annotation = ContainingType.IsRecordStruct ? NullableAnnotation.Oblivious : NullableAnnotation.Annotated;
return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)),
Parameters: ImmutableArray.Create<ParameterSymbol>(
new SourceSimpleParameterSymbol(owner: this,
TypeWithAnnotations.Create(ContainingType, annotation),
ordinal: 0, RefKind.None, "left", Locations),
new SourceSimpleParameterSymbol(owner: this,
TypeWithAnnotations.Create(ContainingType, annotation),
ordinal: 1, RefKind.None, "right", Locations)));
}
protected override int GetParameterCountFromSyntax() => 2;
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
/// <summary>
/// The record type includes synthesized '==' and '!=' operators equivalent to operators declared as follows:
///
/// For record class:
/// public static bool operator==(R? left, R? right)
/// => (object) left == right || ((object)left != null && left.Equals(right));
/// public static bool operator !=(R? left, R? right)
/// => !(left == right);
///
/// For record struct:
/// public static bool operator==(R left, R right)
/// => left.Equals(right);
/// public static bool operator !=(R left, R right)
/// => !(left == right);
///
///The 'Equals' method called by the '==' operator is the 'Equals(R? other)' (<see cref="SynthesizedRecordEquals"/>).
///The '!=' operator delegates to the '==' operator. It is an error if the operators are declared explicitly.
/// </summary>
internal abstract class SynthesizedRecordEqualityOperatorBase : SourceUserDefinedOperatorSymbolBase
{
private readonly int _memberOffset;
protected SynthesizedRecordEqualityOperatorBase(SourceMemberContainerTypeSymbol containingType, string name, int memberOffset, BindingDiagnosticBag diagnostics)
: base(MethodKind.UserDefinedOperator, explicitInterfaceType: null, name, containingType, containingType.Locations[0], (CSharpSyntaxNode)containingType.SyntaxReferences[0].GetSyntax(),
DeclarationModifiers.Public | DeclarationModifiers.Static, hasBody: true, isExpressionBodied: false, isIterator: false, isNullableAnalysisEnabled: false, diagnostics)
{
Debug.Assert(name == WellKnownMemberNames.EqualityOperatorName || name == WellKnownMemberNames.InequalityOperatorName);
_memberOffset = memberOffset;
}
public sealed override bool IsImplicitlyDeclared => true;
protected sealed override Location ReturnTypeLocation => Locations[0];
internal sealed override LexicalSortKey GetLexicalSortKey() => LexicalSortKey.GetSynthesizedMemberKey(_memberOffset);
protected sealed override SourceMemberMethodSymbol? BoundAttributesSource => null;
internal sealed override OneOrMany<SyntaxList<AttributeListSyntax>> GetAttributeDeclarations() => OneOrMany.Create(default(SyntaxList<AttributeListSyntax>));
public sealed override string? GetDocumentationCommentXml(CultureInfo? preferredCulture = null, bool expandIncludes = false, CancellationToken cancellationToken = default) => null;
internal sealed override bool GenerateDebugInfo => false;
internal sealed override bool SynthesizesLoweredBoundBody => true;
protected sealed override (TypeWithAnnotations ReturnType, ImmutableArray<ParameterSymbol> Parameters) MakeParametersAndBindReturnType(BindingDiagnosticBag diagnostics)
{
var compilation = DeclaringCompilation;
var location = ReturnTypeLocation;
var annotation = ContainingType.IsRecordStruct ? NullableAnnotation.Oblivious : NullableAnnotation.Annotated;
return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)),
Parameters: ImmutableArray.Create<ParameterSymbol>(
new SourceSimpleParameterSymbol(owner: this,
TypeWithAnnotations.Create(ContainingType, annotation),
ordinal: 0, RefKind.None, "left", Locations),
new SourceSimpleParameterSymbol(owner: this,
TypeWithAnnotations.Create(ContainingType, annotation),
ordinal: 1, RefKind.None, "right", Locations)));
}
protected override int GetParameterCountFromSyntax() => 2;
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Portable/BoundTree/BoundUserDefinedConversion.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic
Partial Friend Class BoundUserDefinedConversion
Public ReadOnly Property Operand As BoundExpression
Get
If (InOutConversionFlags And 1) <> 0 Then
Return DirectCast([Call].Arguments(0), BoundConversion).Operand
Else
Return [Call].Arguments(0)
End If
End Get
End Property
Public ReadOnly Property InConversionOpt As BoundConversion
Get
If (InOutConversionFlags And 1) <> 0 Then
Return DirectCast([Call].Arguments(0), BoundConversion)
End If
Return Nothing
End Get
End Property
Public ReadOnly Property OutConversionOpt As BoundConversion
Get
If (InOutConversionFlags And 2) <> 0 Then
Return DirectCast(UnderlyingExpression, BoundConversion)
End If
Return Nothing
End Get
End Property
Public ReadOnly Property [Call] As BoundCall
Get
If (InOutConversionFlags And 2) <> 0 Then
Return DirectCast(DirectCast(UnderlyingExpression, BoundConversion).Operand, BoundCall)
End If
Return DirectCast(UnderlyingExpression, BoundCall)
End Get
End Property
#If DEBUG Then
Private Sub Validate()
Dim outConversion As BoundConversion = OutConversionOpt
If outConversion IsNot Nothing Then
Debug.Assert(Conversions.ConversionExists(outConversion.ConversionKind) AndAlso (outConversion.ConversionKind And ConversionKind.UserDefined) = 0)
End If
Dim underlyingCall = [Call]
Debug.Assert(underlyingCall.Method.MethodKind = MethodKind.Conversion AndAlso underlyingCall.Method.ParameterCount = 1)
Dim operand As BoundExpression
Dim inConversion As BoundConversion = InConversionOpt
If inConversion IsNot Nothing Then
Debug.Assert(Conversions.ConversionExists(inConversion.ConversionKind) AndAlso (inConversion.ConversionKind And ConversionKind.UserDefined) = 0)
operand = inConversion.Operand
Else
operand = underlyingCall.Arguments(0)
End If
Debug.Assert(operand.Type.IsSameTypeIgnoringAll(Type))
End Sub
#End If
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic
Partial Friend Class BoundUserDefinedConversion
Public ReadOnly Property Operand As BoundExpression
Get
If (InOutConversionFlags And 1) <> 0 Then
Return DirectCast([Call].Arguments(0), BoundConversion).Operand
Else
Return [Call].Arguments(0)
End If
End Get
End Property
Public ReadOnly Property InConversionOpt As BoundConversion
Get
If (InOutConversionFlags And 1) <> 0 Then
Return DirectCast([Call].Arguments(0), BoundConversion)
End If
Return Nothing
End Get
End Property
Public ReadOnly Property OutConversionOpt As BoundConversion
Get
If (InOutConversionFlags And 2) <> 0 Then
Return DirectCast(UnderlyingExpression, BoundConversion)
End If
Return Nothing
End Get
End Property
Public ReadOnly Property [Call] As BoundCall
Get
If (InOutConversionFlags And 2) <> 0 Then
Return DirectCast(DirectCast(UnderlyingExpression, BoundConversion).Operand, BoundCall)
End If
Return DirectCast(UnderlyingExpression, BoundCall)
End Get
End Property
#If DEBUG Then
Private Sub Validate()
Dim outConversion As BoundConversion = OutConversionOpt
If outConversion IsNot Nothing Then
Debug.Assert(Conversions.ConversionExists(outConversion.ConversionKind) AndAlso (outConversion.ConversionKind And ConversionKind.UserDefined) = 0)
End If
Dim underlyingCall = [Call]
Debug.Assert(underlyingCall.Method.MethodKind = MethodKind.Conversion AndAlso underlyingCall.Method.ParameterCount = 1)
Dim operand As BoundExpression
Dim inConversion As BoundConversion = InConversionOpt
If inConversion IsNot Nothing Then
Debug.Assert(Conversions.ConversionExists(inConversion.ConversionKind) AndAlso (inConversion.ConversionKind And ConversionKind.UserDefined) = 0)
operand = inConversion.Operand
Else
operand = underlyingCall.Arguments(0)
End If
Debug.Assert(operand.Type.IsSameTypeIgnoringAll(Type))
End Sub
#End If
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Scripting/Core/Hosting/AssemblyLoader/CoreAssemblyLoaderImpl.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.Loader;
namespace Microsoft.CodeAnalysis.Scripting.Hosting
{
internal sealed class CoreAssemblyLoaderImpl : AssemblyLoaderImpl
{
private readonly LoadContext _inMemoryAssemblyContext;
internal CoreAssemblyLoaderImpl(InteractiveAssemblyLoader loader)
: base(loader)
{
_inMemoryAssemblyContext = new LoadContext(Loader, null);
}
public override Assembly LoadFromStream(Stream peStream, Stream pdbStream)
{
return _inMemoryAssemblyContext.LoadFromStream(peStream, pdbStream);
}
public override AssemblyAndLocation LoadFromPath(string path)
{
// Create a new context that knows the directory where the assembly was loaded from
// and uses it to resolve dependencies of the assembly. We could create one context per directory,
// but there is no need to reuse contexts.
var assembly = new LoadContext(Loader, Path.GetDirectoryName(path)).LoadFromAssemblyPath(path);
return new AssemblyAndLocation(assembly, path, fromGac: false);
}
public override void Dispose()
{
// nop
}
private sealed class LoadContext : AssemblyLoadContext
{
private readonly string _loadDirectoryOpt;
private readonly InteractiveAssemblyLoader _loader;
internal LoadContext(InteractiveAssemblyLoader loader, string loadDirectoryOpt)
{
Debug.Assert(loader != null);
_loader = loader;
_loadDirectoryOpt = loadDirectoryOpt;
// CoreCLR resolves assemblies in steps:
//
// 1) Call AssemblyLoadContext.Load -- our context returns null
// 2) TPA list
// 3) Default.Resolving event
// 4) AssemblyLoadContext.Resolving event -- hooked below
//
// What we want is to let the default context load assemblies it knows about (this includes already loaded assemblies,
// assemblies in AppPath, platform assemblies, assemblies explciitly resolved by the App by hooking Default.Resolving, etc.).
// Only if the assembly can't be resolved that way, the interactive resolver steps in.
//
// This order is necessary to avoid loading assemblies twice (by the host App and by interactive loader).
Resolving += (_, assemblyName) =>
_loader.ResolveAssembly(AssemblyIdentity.FromAssemblyReference(assemblyName), _loadDirectoryOpt);
}
protected override Assembly Load(AssemblyName assemblyName) => null;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.Loader;
namespace Microsoft.CodeAnalysis.Scripting.Hosting
{
internal sealed class CoreAssemblyLoaderImpl : AssemblyLoaderImpl
{
private readonly LoadContext _inMemoryAssemblyContext;
internal CoreAssemblyLoaderImpl(InteractiveAssemblyLoader loader)
: base(loader)
{
_inMemoryAssemblyContext = new LoadContext(Loader, null);
}
public override Assembly LoadFromStream(Stream peStream, Stream pdbStream)
{
return _inMemoryAssemblyContext.LoadFromStream(peStream, pdbStream);
}
public override AssemblyAndLocation LoadFromPath(string path)
{
// Create a new context that knows the directory where the assembly was loaded from
// and uses it to resolve dependencies of the assembly. We could create one context per directory,
// but there is no need to reuse contexts.
var assembly = new LoadContext(Loader, Path.GetDirectoryName(path)).LoadFromAssemblyPath(path);
return new AssemblyAndLocation(assembly, path, fromGac: false);
}
public override void Dispose()
{
// nop
}
private sealed class LoadContext : AssemblyLoadContext
{
private readonly string _loadDirectoryOpt;
private readonly InteractiveAssemblyLoader _loader;
internal LoadContext(InteractiveAssemblyLoader loader, string loadDirectoryOpt)
{
Debug.Assert(loader != null);
_loader = loader;
_loadDirectoryOpt = loadDirectoryOpt;
// CoreCLR resolves assemblies in steps:
//
// 1) Call AssemblyLoadContext.Load -- our context returns null
// 2) TPA list
// 3) Default.Resolving event
// 4) AssemblyLoadContext.Resolving event -- hooked below
//
// What we want is to let the default context load assemblies it knows about (this includes already loaded assemblies,
// assemblies in AppPath, platform assemblies, assemblies explciitly resolved by the App by hooking Default.Resolving, etc.).
// Only if the assembly can't be resolved that way, the interactive resolver steps in.
//
// This order is necessary to avoid loading assemblies twice (by the host App and by interactive loader).
Resolving += (_, assemblyName) =>
_loader.ResolveAssembly(AssemblyIdentity.FromAssemblyReference(assemblyName), _loadDirectoryOpt);
}
protected override Assembly Load(AssemblyName assemblyName) => null;
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Portable/Symbols/InstanceTypeSymbol.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Generic
Imports System.Collections.Immutable
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic.Symbols
''' <summary>
''' An InstanceTypeSymbol is a NamedTypeSymbol that is a pure instance type, where the class
''' (and any containing classes) have no type substitutions applied.
''' This class provide shared implementation for types whose definition is (possibly lazily)
''' constructed from source or metadata. It provides the shared implementation between these two, primarily
''' the implementation of Construct and InternalSubstituteTypeParameters.
''' </summary>
Friend MustInherit Class InstanceTypeSymbol
Inherits NamedTypeSymbol
Friend NotOverridable Overrides ReadOnly Property TypeArgumentsNoUseSiteDiagnostics As ImmutableArray(Of TypeSymbol)
Get
' This is always the instance type, so the type arguments are the same as the type parameters.
If Arity > 0 Then
Return StaticCast(Of TypeSymbol).From(Me.TypeParameters)
Else
Return ImmutableArray(Of TypeSymbol).Empty
End If
End Get
End Property
Public NotOverridable Overrides Function GetTypeArgumentCustomModifiers(ordinal As Integer) As ImmutableArray(Of CustomModifier)
' This is always the instance type, so the type arguments do not have any modifiers.
Return GetEmptyTypeArgumentCustomModifiers(ordinal)
End Function
Friend NotOverridable Overrides ReadOnly Property HasTypeArgumentsCustomModifiers As Boolean
Get
' This is always the instance type, so the type arguments do not have any modifiers.
Return False
End Get
End Property
' Instance types are always constructible if they have arity >= 1
Friend Overrides ReadOnly Property CanConstruct As Boolean
Get
Return Arity > 0
End Get
End Property
Public NotOverridable Overrides Function Construct(typeArguments As ImmutableArray(Of TypeSymbol)) As NamedTypeSymbol
CheckCanConstructAndTypeArguments(typeArguments)
Dim substitution = VisualBasic.Symbols.TypeSubstitution.Create(Me, Me.TypeParameters, typeArguments, allowAlphaRenamedTypeParametersAsArguments:=True)
If substitution Is Nothing Then
Return Me
Else
Debug.Assert(substitution.TargetGenericDefinition Is Me)
Return New SubstitutedNamedType.ConstructedInstanceType(substitution)
End If
End Function
''' <summary>
''' Substitute the given type substitution within this type, returning a new type. If the
''' substitution had no effect, return Me.
''' !!! Only code implementing construction of generic types is allowed to call this method !!!
''' !!! All other code should use Construct methods. !!!
''' </summary>
Friend Overrides Function InternalSubstituteTypeParameters(substitution As TypeSubstitution) As TypeWithModifiers
Return New TypeWithModifiers(SubstituteTypeParametersInNamedType(substitution))
End Function
Private Function SubstituteTypeParametersInNamedType(substitution As TypeSubstitution) As NamedTypeSymbol
If substitution IsNot Nothing Then
' The substitution might target one of this type's children.
substitution = substitution.GetSubstitutionForGenericDefinitionOrContainers(Me)
End If
If substitution Is Nothing Then
Return Me
End If
' Substitution targets either this type or one of its containers
Dim newContainer As NamedTypeSymbol
If substitution.TargetGenericDefinition Is Me Then
If substitution.Parent Is Nothing Then
Debug.Assert(Me.Arity > 0)
Return New SubstitutedNamedType.ConstructedInstanceType(substitution)
End If
newContainer = DirectCast(Me.ContainingType.InternalSubstituteTypeParameters(substitution.Parent).AsTypeSymbolOnly(), NamedTypeSymbol)
Else
newContainer = DirectCast(Me.ContainingType.InternalSubstituteTypeParameters(substitution).AsTypeSymbolOnly(), NamedTypeSymbol)
End If
Debug.Assert(Me.ContainingType IsNot Nothing)
If Me.Arity = 0 Then
Debug.Assert(Not newContainer.IsDefinition)
Return SubstitutedNamedType.SpecializedNonGenericType.Create(DirectCast(newContainer, NamedTypeSymbol), Me, substitution)
End If
' First we need to create SpecializedGenericType to construct this guy from.
Dim constructFrom = SubstitutedNamedType.SpecializedGenericType.Create(DirectCast(newContainer, NamedTypeSymbol), Me)
If substitution.TargetGenericDefinition Is Me Then
Debug.Assert(newContainer.TypeSubstitution Is substitution.Parent) ' How can it be otherwise? The contained type didn't have any substitution before.
Return New SubstitutedNamedType.ConstructedSpecializedGenericType(constructFrom, substitution)
End If
Return constructFrom
End Function
Friend Overrides ReadOnly Property TypeSubstitution As TypeSubstitution
Get
Return Nothing
End Get
End Property
Public Overrides ReadOnly Property ConstructedFrom As NamedTypeSymbol
Get
Return Me
End Get
End Property
Public Overrides Function GetHashCode() As Integer
Return System.Runtime.CompilerServices.RuntimeHelpers.GetHashCode(Me)
End Function
Public Overrides Function Equals(other As TypeSymbol, comparison As TypeCompareKind) As Boolean
If other Is Me Then
Return True
End If
If other Is Nothing OrElse (comparison And TypeCompareKind.AllIgnoreOptionsForVB) = 0 Then
Return False
End If
Dim otherTuple = TryCast(other, TupleTypeSymbol)
If otherTuple IsNot Nothing Then
Return otherTuple.Equals(Me, comparison)
End If
If other.OriginalDefinition IsNot Me Then
Return False
End If
' Delegate comparison to the other type to ensure symmetry
Debug.Assert(TypeOf other Is SubstitutedNamedType)
Return other.Equals(Me, comparison)
End Function
#Region "Use-Site Diagnostics"
Protected Function CalculateUseSiteInfo() As UseSiteInfo(Of AssemblySymbol)
' Check base type.
Dim useSiteInfo = New UseSiteInfo(Of AssemblySymbol)(PrimaryDependency).AdjustDiagnosticInfo(DeriveUseSiteErrorInfoFromBase())
If useSiteInfo.DiagnosticInfo IsNot Nothing Then
Return useSiteInfo
End If
' If we reach a type (Me) that is in an assembly with unified references,
' we check if that type definition depends on a type from a unified reference.
If Me.ContainingModule.HasUnifiedReferences Then
Dim errorInfo As DiagnosticInfo = GetUnificationUseSiteDiagnosticRecursive(Me, checkedTypes:=Nothing)
If errorInfo IsNot Nothing Then
Debug.Assert(errorInfo.Severity = DiagnosticSeverity.Error)
useSiteInfo = New UseSiteInfo(Of AssemblySymbol)(errorInfo)
End If
End If
Return useSiteInfo
End Function
Private Function DeriveUseSiteErrorInfoFromBase() As DiagnosticInfo
Dim base As NamedTypeSymbol = Me.BaseTypeNoUseSiteDiagnostics
While base IsNot Nothing
If base.IsErrorType() AndAlso TypeOf base Is NoPiaIllegalGenericInstantiationSymbol Then
Return base.GetUseSiteInfo().DiagnosticInfo
End If
base = base.BaseTypeNoUseSiteDiagnostics
End While
Return Nothing
End Function
Friend NotOverridable Overrides Function GetUnificationUseSiteDiagnosticRecursive(owner As Symbol, ByRef checkedTypes As HashSet(Of TypeSymbol)) As DiagnosticInfo
Debug.Assert(owner.ContainingModule.HasUnifiedReferences)
If Not MarkCheckedIfNecessary(checkedTypes) Then
Return Nothing
End If
Dim info = owner.ContainingModule.GetUnificationUseSiteErrorInfo(Me)
If info IsNot Nothing Then
Return info
End If
' TODO (tomat): use-site errors should be reported on each part of a qualified name,
' we shouldn't need to walk containing types here (see bug 15793)
' containing type
Dim containing = Me.ContainingType
If containing IsNot Nothing Then
info = containing.GetUnificationUseSiteDiagnosticRecursive(owner, checkedTypes)
If info IsNot Nothing Then
Return info
End If
End If
' base type
Dim base = Me.BaseTypeNoUseSiteDiagnostics
If base IsNot Nothing Then
info = base.GetUnificationUseSiteDiagnosticRecursive(owner, checkedTypes)
If info IsNot Nothing Then
Return info
End If
End If
' implemented interfaces, type parameter constraints, type arguments
Return If(GetUnificationUseSiteDiagnosticRecursive(Me.InterfacesNoUseSiteDiagnostics, owner, checkedTypes),
GetUnificationUseSiteDiagnosticRecursive(Me.TypeParameters, owner, checkedTypes))
End Function
#End Region
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Generic
Imports System.Collections.Immutable
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic.Symbols
''' <summary>
''' An InstanceTypeSymbol is a NamedTypeSymbol that is a pure instance type, where the class
''' (and any containing classes) have no type substitutions applied.
''' This class provide shared implementation for types whose definition is (possibly lazily)
''' constructed from source or metadata. It provides the shared implementation between these two, primarily
''' the implementation of Construct and InternalSubstituteTypeParameters.
''' </summary>
Friend MustInherit Class InstanceTypeSymbol
Inherits NamedTypeSymbol
Friend NotOverridable Overrides ReadOnly Property TypeArgumentsNoUseSiteDiagnostics As ImmutableArray(Of TypeSymbol)
Get
' This is always the instance type, so the type arguments are the same as the type parameters.
If Arity > 0 Then
Return StaticCast(Of TypeSymbol).From(Me.TypeParameters)
Else
Return ImmutableArray(Of TypeSymbol).Empty
End If
End Get
End Property
Public NotOverridable Overrides Function GetTypeArgumentCustomModifiers(ordinal As Integer) As ImmutableArray(Of CustomModifier)
' This is always the instance type, so the type arguments do not have any modifiers.
Return GetEmptyTypeArgumentCustomModifiers(ordinal)
End Function
Friend NotOverridable Overrides ReadOnly Property HasTypeArgumentsCustomModifiers As Boolean
Get
' This is always the instance type, so the type arguments do not have any modifiers.
Return False
End Get
End Property
' Instance types are always constructible if they have arity >= 1
Friend Overrides ReadOnly Property CanConstruct As Boolean
Get
Return Arity > 0
End Get
End Property
Public NotOverridable Overrides Function Construct(typeArguments As ImmutableArray(Of TypeSymbol)) As NamedTypeSymbol
CheckCanConstructAndTypeArguments(typeArguments)
Dim substitution = VisualBasic.Symbols.TypeSubstitution.Create(Me, Me.TypeParameters, typeArguments, allowAlphaRenamedTypeParametersAsArguments:=True)
If substitution Is Nothing Then
Return Me
Else
Debug.Assert(substitution.TargetGenericDefinition Is Me)
Return New SubstitutedNamedType.ConstructedInstanceType(substitution)
End If
End Function
''' <summary>
''' Substitute the given type substitution within this type, returning a new type. If the
''' substitution had no effect, return Me.
''' !!! Only code implementing construction of generic types is allowed to call this method !!!
''' !!! All other code should use Construct methods. !!!
''' </summary>
Friend Overrides Function InternalSubstituteTypeParameters(substitution As TypeSubstitution) As TypeWithModifiers
Return New TypeWithModifiers(SubstituteTypeParametersInNamedType(substitution))
End Function
Private Function SubstituteTypeParametersInNamedType(substitution As TypeSubstitution) As NamedTypeSymbol
If substitution IsNot Nothing Then
' The substitution might target one of this type's children.
substitution = substitution.GetSubstitutionForGenericDefinitionOrContainers(Me)
End If
If substitution Is Nothing Then
Return Me
End If
' Substitution targets either this type or one of its containers
Dim newContainer As NamedTypeSymbol
If substitution.TargetGenericDefinition Is Me Then
If substitution.Parent Is Nothing Then
Debug.Assert(Me.Arity > 0)
Return New SubstitutedNamedType.ConstructedInstanceType(substitution)
End If
newContainer = DirectCast(Me.ContainingType.InternalSubstituteTypeParameters(substitution.Parent).AsTypeSymbolOnly(), NamedTypeSymbol)
Else
newContainer = DirectCast(Me.ContainingType.InternalSubstituteTypeParameters(substitution).AsTypeSymbolOnly(), NamedTypeSymbol)
End If
Debug.Assert(Me.ContainingType IsNot Nothing)
If Me.Arity = 0 Then
Debug.Assert(Not newContainer.IsDefinition)
Return SubstitutedNamedType.SpecializedNonGenericType.Create(DirectCast(newContainer, NamedTypeSymbol), Me, substitution)
End If
' First we need to create SpecializedGenericType to construct this guy from.
Dim constructFrom = SubstitutedNamedType.SpecializedGenericType.Create(DirectCast(newContainer, NamedTypeSymbol), Me)
If substitution.TargetGenericDefinition Is Me Then
Debug.Assert(newContainer.TypeSubstitution Is substitution.Parent) ' How can it be otherwise? The contained type didn't have any substitution before.
Return New SubstitutedNamedType.ConstructedSpecializedGenericType(constructFrom, substitution)
End If
Return constructFrom
End Function
Friend Overrides ReadOnly Property TypeSubstitution As TypeSubstitution
Get
Return Nothing
End Get
End Property
Public Overrides ReadOnly Property ConstructedFrom As NamedTypeSymbol
Get
Return Me
End Get
End Property
Public Overrides Function GetHashCode() As Integer
Return System.Runtime.CompilerServices.RuntimeHelpers.GetHashCode(Me)
End Function
Public Overrides Function Equals(other As TypeSymbol, comparison As TypeCompareKind) As Boolean
If other Is Me Then
Return True
End If
If other Is Nothing OrElse (comparison And TypeCompareKind.AllIgnoreOptionsForVB) = 0 Then
Return False
End If
Dim otherTuple = TryCast(other, TupleTypeSymbol)
If otherTuple IsNot Nothing Then
Return otherTuple.Equals(Me, comparison)
End If
If other.OriginalDefinition IsNot Me Then
Return False
End If
' Delegate comparison to the other type to ensure symmetry
Debug.Assert(TypeOf other Is SubstitutedNamedType)
Return other.Equals(Me, comparison)
End Function
#Region "Use-Site Diagnostics"
Protected Function CalculateUseSiteInfo() As UseSiteInfo(Of AssemblySymbol)
' Check base type.
Dim useSiteInfo = New UseSiteInfo(Of AssemblySymbol)(PrimaryDependency).AdjustDiagnosticInfo(DeriveUseSiteErrorInfoFromBase())
If useSiteInfo.DiagnosticInfo IsNot Nothing Then
Return useSiteInfo
End If
' If we reach a type (Me) that is in an assembly with unified references,
' we check if that type definition depends on a type from a unified reference.
If Me.ContainingModule.HasUnifiedReferences Then
Dim errorInfo As DiagnosticInfo = GetUnificationUseSiteDiagnosticRecursive(Me, checkedTypes:=Nothing)
If errorInfo IsNot Nothing Then
Debug.Assert(errorInfo.Severity = DiagnosticSeverity.Error)
useSiteInfo = New UseSiteInfo(Of AssemblySymbol)(errorInfo)
End If
End If
Return useSiteInfo
End Function
Private Function DeriveUseSiteErrorInfoFromBase() As DiagnosticInfo
Dim base As NamedTypeSymbol = Me.BaseTypeNoUseSiteDiagnostics
While base IsNot Nothing
If base.IsErrorType() AndAlso TypeOf base Is NoPiaIllegalGenericInstantiationSymbol Then
Return base.GetUseSiteInfo().DiagnosticInfo
End If
base = base.BaseTypeNoUseSiteDiagnostics
End While
Return Nothing
End Function
Friend NotOverridable Overrides Function GetUnificationUseSiteDiagnosticRecursive(owner As Symbol, ByRef checkedTypes As HashSet(Of TypeSymbol)) As DiagnosticInfo
Debug.Assert(owner.ContainingModule.HasUnifiedReferences)
If Not MarkCheckedIfNecessary(checkedTypes) Then
Return Nothing
End If
Dim info = owner.ContainingModule.GetUnificationUseSiteErrorInfo(Me)
If info IsNot Nothing Then
Return info
End If
' TODO (tomat): use-site errors should be reported on each part of a qualified name,
' we shouldn't need to walk containing types here (see bug 15793)
' containing type
Dim containing = Me.ContainingType
If containing IsNot Nothing Then
info = containing.GetUnificationUseSiteDiagnosticRecursive(owner, checkedTypes)
If info IsNot Nothing Then
Return info
End If
End If
' base type
Dim base = Me.BaseTypeNoUseSiteDiagnostics
If base IsNot Nothing Then
info = base.GetUnificationUseSiteDiagnosticRecursive(owner, checkedTypes)
If info IsNot Nothing Then
Return info
End If
End If
' implemented interfaces, type parameter constraints, type arguments
Return If(GetUnificationUseSiteDiagnosticRecursive(Me.InterfacesNoUseSiteDiagnostics, owner, checkedTypes),
GetUnificationUseSiteDiagnosticRecursive(Me.TypeParameters, owner, checkedTypes))
End Function
#End Region
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/Core/Portable/Diagnostics/AnalyzerHelper.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Diagnostics.Telemetry;
using Microsoft.CodeAnalysis.ErrorReporting;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Diagnostics
{
internal static partial class AnalyzerHelper
{
// These are the error codes of the compiler warnings.
// Keep the ids the same so that de-duplication against compiler errors
// works in the error list (after a build).
internal const string WRN_AnalyzerCannotBeCreatedIdCS = "CS8032";
internal const string WRN_AnalyzerCannotBeCreatedIdVB = "BC42376";
internal const string WRN_NoAnalyzerInAssemblyIdCS = "CS8033";
internal const string WRN_NoAnalyzerInAssemblyIdVB = "BC42377";
internal const string WRN_UnableToLoadAnalyzerIdCS = "CS8034";
internal const string WRN_UnableToLoadAnalyzerIdVB = "BC42378";
internal const string WRN_AnalyzerReferencesNetFrameworkIdCS = "CS8850";
internal const string WRN_AnalyzerReferencesNetFrameworkIdVB = "BC42503";
// Shared with Compiler
internal const string AnalyzerExceptionDiagnosticId = "AD0001";
internal const string AnalyzerDriverExceptionDiagnosticId = "AD0002";
// IDE only errors
internal const string WRN_AnalyzerCannotBeCreatedId = "AD1000";
internal const string WRN_NoAnalyzerInAssemblyId = "AD1001";
internal const string WRN_UnableToLoadAnalyzerId = "AD1002";
internal const string WRN_AnalyzerReferencesNetFrameworkId = "AD1003";
private const string AnalyzerExceptionDiagnosticCategory = "Intellisense";
public static bool IsWorkspaceDiagnosticAnalyzer(this DiagnosticAnalyzer analyzer)
=> analyzer is DocumentDiagnosticAnalyzer || analyzer is ProjectDiagnosticAnalyzer || analyzer == FileContentLoadAnalyzer.Instance;
public static bool IsBuiltInAnalyzer(this DiagnosticAnalyzer analyzer)
=> analyzer is IBuiltInAnalyzer || analyzer.IsWorkspaceDiagnosticAnalyzer() || analyzer.IsCompilerAnalyzer();
public static bool IsOpenFileOnly(this DiagnosticAnalyzer analyzer, OptionSet options)
=> analyzer is IBuiltInAnalyzer builtInAnalyzer && builtInAnalyzer.OpenFileOnly(options);
public static ReportDiagnostic GetEffectiveSeverity(this DiagnosticDescriptor descriptor, CompilationOptions options)
{
return options == null
? descriptor.DefaultSeverity.ToReportDiagnostic()
: descriptor.GetEffectiveSeverity(options);
}
public static (string analyzerId, VersionStamp version) GetAnalyzerIdAndVersion(this DiagnosticAnalyzer analyzer)
{
// Get the unique ID for given diagnostic analyzer.
// note that we also put version stamp so that we can detect changed analyzer.
var typeInfo = analyzer.GetType().GetTypeInfo();
return (analyzer.GetAnalyzerId(), GetAnalyzerVersion(typeInfo.Assembly.Location));
}
public static string GetAnalyzerAssemblyName(this DiagnosticAnalyzer analyzer)
=> analyzer.GetType().Assembly.GetName().Name ?? throw ExceptionUtilities.Unreachable;
public static OptionSet GetAnalyzerOptionSet(this AnalyzerOptions analyzerOptions, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var optionSetAsync = GetAnalyzerOptionSetAsync(analyzerOptions, syntaxTree, cancellationToken);
if (optionSetAsync.IsCompleted)
return optionSetAsync.Result;
return optionSetAsync.AsTask().GetAwaiter().GetResult();
}
public static async ValueTask<OptionSet> GetAnalyzerOptionSetAsync(this AnalyzerOptions analyzerOptions, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var configOptions = analyzerOptions.AnalyzerConfigOptionsProvider.GetOptions(syntaxTree);
#pragma warning disable CS0612 // Type or member is obsolete
var optionSet = await GetDocumentOptionSetAsync(analyzerOptions, syntaxTree, cancellationToken).ConfigureAwait(false);
#pragma warning restore CS0612 // Type or member is obsolete
return new AnalyzerConfigOptionSet(configOptions, optionSet);
}
public static T GetOption<T>(this AnalyzerOptions analyzerOptions, ILanguageSpecificOption<T> option, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var optionAsync = GetOptionAsync<T>(analyzerOptions, option, language: null, syntaxTree, cancellationToken);
if (optionAsync.IsCompleted)
return optionAsync.Result;
return optionAsync.AsTask().GetAwaiter().GetResult();
}
public static T GetOption<T>(this AnalyzerOptions analyzerOptions, IPerLanguageOption<T> option, string? language, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var optionAsync = GetOptionAsync<T>(analyzerOptions, option, language, syntaxTree, cancellationToken);
if (optionAsync.IsCompleted)
return optionAsync.Result;
return optionAsync.AsTask().GetAwaiter().GetResult();
}
public static async ValueTask<T> GetOptionAsync<T>(this AnalyzerOptions analyzerOptions, IOption option, string? language, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
if (analyzerOptions.TryGetEditorConfigOption<T>(option, syntaxTree, out var value))
{
return value;
}
#pragma warning disable CS0612 // Type or member is obsolete
var optionSet = await analyzerOptions.GetDocumentOptionSetAsync(syntaxTree, cancellationToken).ConfigureAwait(false);
#pragma warning restore CS0612 // Type or member is obsolete
if (optionSet != null)
{
value = optionSet.GetOption<T>(new OptionKey(option, language));
}
return value ?? (T)option.DefaultValue!;
}
[PerformanceSensitive("https://github.com/dotnet/roslyn/issues/23582", OftenCompletesSynchronously = true)]
public static ValueTask<OptionSet?> GetDocumentOptionSetAsync(this AnalyzerOptions analyzerOptions, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
if (analyzerOptions is not WorkspaceAnalyzerOptions workspaceAnalyzerOptions)
{
return ValueTaskFactory.FromResult((OptionSet?)null);
}
return workspaceAnalyzerOptions.GetDocumentOptionSetAsync(syntaxTree, cancellationToken);
}
/// <summary>
/// Create a diagnostic for exception thrown by the given analyzer.
/// </summary>
/// <remarks>
/// Keep this method in sync with "AnalyzerExecutor.CreateAnalyzerExceptionDiagnostic".
/// </remarks>
internal static Diagnostic CreateAnalyzerExceptionDiagnostic(DiagnosticAnalyzer analyzer, Exception e)
{
var analyzerName = analyzer.ToString();
// TODO: It is not ideal to create a new descriptor per analyzer exception diagnostic instance.
// However, until we add a LongMessage field to the Diagnostic, we are forced to park the instance specific description onto the Descriptor's Description field.
// This requires us to create a new DiagnosticDescriptor instance per diagnostic instance.
var descriptor = new DiagnosticDescriptor(AnalyzerExceptionDiagnosticId,
title: FeaturesResources.User_Diagnostic_Analyzer_Failure,
messageFormat: FeaturesResources.Analyzer_0_threw_an_exception_of_type_1_with_message_2,
description: string.Format(FeaturesResources.Analyzer_0_threw_the_following_exception_colon_1, analyzerName, e.CreateDiagnosticDescription()),
category: AnalyzerExceptionDiagnosticCategory,
defaultSeverity: DiagnosticSeverity.Warning,
isEnabledByDefault: true,
customTags: WellKnownDiagnosticTags.AnalyzerException);
return Diagnostic.Create(descriptor, Location.None, analyzerName, e.GetType(), e.Message);
}
private static VersionStamp GetAnalyzerVersion(string path)
{
if (path == null || !File.Exists(path))
{
return VersionStamp.Default;
}
return VersionStamp.Create(File.GetLastWriteTimeUtc(path));
}
public static DiagnosticData CreateAnalyzerLoadFailureDiagnostic(AnalyzerLoadFailureEventArgs e, string fullPath, ProjectId? projectId, string? language)
{
static string GetLanguageSpecificId(string? language, string noLanguageId, string csharpId, string vbId)
=> language == null ? noLanguageId : (language == LanguageNames.CSharp) ? csharpId : vbId;
string id, messageFormat, message;
switch (e.ErrorCode)
{
case AnalyzerLoadFailureEventArgs.FailureErrorCode.UnableToLoadAnalyzer:
id = GetLanguageSpecificId(language, WRN_UnableToLoadAnalyzerId, WRN_UnableToLoadAnalyzerIdCS, WRN_UnableToLoadAnalyzerIdVB);
messageFormat = FeaturesResources.Unable_to_load_Analyzer_assembly_0_colon_1;
message = string.Format(FeaturesResources.Unable_to_load_Analyzer_assembly_0_colon_1, fullPath, e.Message);
break;
case AnalyzerLoadFailureEventArgs.FailureErrorCode.UnableToCreateAnalyzer:
id = GetLanguageSpecificId(language, WRN_AnalyzerCannotBeCreatedId, WRN_AnalyzerCannotBeCreatedIdCS, WRN_AnalyzerCannotBeCreatedIdVB);
messageFormat = FeaturesResources.An_instance_of_analyzer_0_cannot_be_created_from_1_colon_2;
message = string.Format(FeaturesResources.An_instance_of_analyzer_0_cannot_be_created_from_1_colon_2, e.TypeName, fullPath, e.Message);
break;
case AnalyzerLoadFailureEventArgs.FailureErrorCode.NoAnalyzers:
id = GetLanguageSpecificId(language, WRN_NoAnalyzerInAssemblyId, WRN_NoAnalyzerInAssemblyIdCS, WRN_NoAnalyzerInAssemblyIdVB);
messageFormat = FeaturesResources.The_assembly_0_does_not_contain_any_analyzers;
message = string.Format(FeaturesResources.The_assembly_0_does_not_contain_any_analyzers, fullPath);
break;
case AnalyzerLoadFailureEventArgs.FailureErrorCode.ReferencesFramework:
id = GetLanguageSpecificId(language, WRN_AnalyzerReferencesNetFrameworkId, WRN_AnalyzerReferencesNetFrameworkIdCS, WRN_AnalyzerReferencesNetFrameworkIdVB);
messageFormat = FeaturesResources.The_assembly_0_containing_type_1_references_NET_Framework;
message = string.Format(FeaturesResources.The_assembly_0_containing_type_1_references_NET_Framework, fullPath, e.TypeName);
break;
default:
throw ExceptionUtilities.UnexpectedValue(e.ErrorCode);
}
var description = e.Exception.CreateDiagnosticDescription();
return new DiagnosticData(
id,
FeaturesResources.Roslyn_HostError,
message,
messageFormat,
severity: DiagnosticSeverity.Warning,
defaultSeverity: DiagnosticSeverity.Warning,
isEnabledByDefault: true,
description: description,
warningLevel: 0,
projectId: projectId,
customTags: ImmutableArray<string>.Empty,
properties: ImmutableDictionary<string, string?>.Empty,
language: language);
}
public static void AppendAnalyzerMap(this Dictionary<string, DiagnosticAnalyzer> analyzerMap, IEnumerable<DiagnosticAnalyzer> analyzers)
{
foreach (var analyzer in analyzers)
{
// user might have included exact same analyzer twice as project analyzers explicitly. we consider them as one
analyzerMap[analyzer.GetAnalyzerId()] = analyzer;
}
}
public static IEnumerable<AnalyzerPerformanceInfo> ToAnalyzerPerformanceInfo(this IDictionary<DiagnosticAnalyzer, AnalyzerTelemetryInfo> analysisResult, DiagnosticAnalyzerInfoCache analyzerInfo)
=> analysisResult.Select(kv => new AnalyzerPerformanceInfo(kv.Key.GetAnalyzerId(), analyzerInfo.IsTelemetryCollectionAllowed(kv.Key), kv.Value.ExecutionTime));
public static async Task<CompilationWithAnalyzers?> CreateCompilationWithAnalyzersAsync(
Project project,
IEnumerable<DiagnosticAnalyzer> analyzers,
bool includeSuppressedDiagnostics,
CancellationToken cancellationToken)
{
var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
if (compilation == null)
{
// project doesn't support compilation
return null;
}
// Create driver that holds onto compilation and associated analyzers
var filteredAnalyzers = analyzers.Where(a => !a.IsWorkspaceDiagnosticAnalyzer()).ToImmutableArrayOrEmpty();
// PERF: there is no analyzers for this compilation.
// compilationWithAnalyzer will throw if it is created with no analyzers which is perf optimization.
if (filteredAnalyzers.IsEmpty)
{
return null;
}
Contract.ThrowIfFalse(project.SupportsCompilation);
AssertCompilation(project, compilation);
// in IDE, we always set concurrentAnalysis == false otherwise, we can get into thread starvation due to
// async being used with synchronous blocking concurrency.
var analyzerOptions = new CompilationWithAnalyzersOptions(
options: new WorkspaceAnalyzerOptions(project.AnalyzerOptions, project.Solution),
onAnalyzerException: null,
analyzerExceptionFilter: GetAnalyzerExceptionFilter(),
concurrentAnalysis: false,
logAnalyzerExecutionTime: true,
reportSuppressedDiagnostics: includeSuppressedDiagnostics);
// Create driver that holds onto compilation and associated analyzers
return compilation.WithAnalyzers(filteredAnalyzers, analyzerOptions);
Func<Exception, bool> GetAnalyzerExceptionFilter()
{
return ex =>
{
if (ex is not OperationCanceledException && project.Solution.Workspace.Options.GetOption(InternalDiagnosticsOptions.CrashOnAnalyzerException))
{
// report telemetry
FatalError.ReportAndPropagate(ex);
// force fail fast (the host might not crash when reporting telemetry):
FailFast.OnFatalException(ex);
}
return true;
};
}
}
[Conditional("DEBUG")]
private static void AssertCompilation(Project project, Compilation compilation1)
{
// given compilation must be from given project.
Contract.ThrowIfFalse(project.TryGetCompilation(out var compilation2));
Contract.ThrowIfFalse(compilation1 == compilation2);
}
public static async Task<ImmutableArray<Diagnostic>> ComputeDocumentDiagnosticAnalyzerDiagnosticsAsync(
DocumentDiagnosticAnalyzer analyzer,
Document document,
AnalysisKind kind,
Compilation? compilation,
CancellationToken cancellationToken)
{
cancellationToken.ThrowIfCancellationRequested();
ImmutableArray<Diagnostic> diagnostics;
try
{
var analyzeAsync = kind switch
{
AnalysisKind.Syntax => analyzer.AnalyzeSyntaxAsync(document, cancellationToken),
AnalysisKind.Semantic => analyzer.AnalyzeSemanticsAsync(document, cancellationToken),
_ => throw ExceptionUtilities.UnexpectedValue(kind),
};
diagnostics = (await analyzeAsync.ConfigureAwait(false)).NullToEmpty();
#if DEBUG
// since all DocumentDiagnosticAnalyzers are from internal users, we only do debug check. also this can be expensive at runtime
// since it requires await. if we find any offender through NFW, we should be able to fix those since all those should
// from intern teams.
await VerifyDiagnosticLocationsAsync(diagnostics, document.Project, cancellationToken).ConfigureAwait(false);
#endif
}
catch (Exception e) when (!IsCanceled(e, cancellationToken))
{
diagnostics = ImmutableArray.Create(CreateAnalyzerExceptionDiagnostic(analyzer, e));
}
if (compilation != null)
{
diagnostics = CompilationWithAnalyzers.GetEffectiveDiagnostics(diagnostics, compilation).ToImmutableArrayOrEmpty();
}
return diagnostics;
}
public static async Task<ImmutableArray<Diagnostic>> ComputeProjectDiagnosticAnalyzerDiagnosticsAsync(
ProjectDiagnosticAnalyzer analyzer,
Project project,
Compilation? compilation,
CancellationToken cancellationToken)
{
cancellationToken.ThrowIfCancellationRequested();
ImmutableArray<Diagnostic> diagnostics;
try
{
diagnostics = (await analyzer.AnalyzeProjectAsync(project, cancellationToken).ConfigureAwait(false)).NullToEmpty();
#if DEBUG
// since all ProjectDiagnosticAnalyzers are from internal users, we only do debug check. also this can be expensive at runtime
// since it requires await. if we find any offender through NFW, we should be able to fix those since all those should
// from intern teams.
await VerifyDiagnosticLocationsAsync(diagnostics, project, cancellationToken).ConfigureAwait(false);
#endif
}
catch (Exception e) when (!IsCanceled(e, cancellationToken))
{
diagnostics = ImmutableArray.Create(CreateAnalyzerExceptionDiagnostic(analyzer, e));
}
// Apply filtering from compilation options (source suppressions, ruleset, etc.)
if (compilation != null)
{
diagnostics = CompilationWithAnalyzers.GetEffectiveDiagnostics(diagnostics, compilation).ToImmutableArrayOrEmpty();
}
return diagnostics;
}
private static bool IsCanceled(Exception ex, CancellationToken cancellationToken)
=> (ex as OperationCanceledException)?.CancellationToken == cancellationToken;
#if DEBUG
private static async Task VerifyDiagnosticLocationsAsync(ImmutableArray<Diagnostic> diagnostics, Project project, CancellationToken cancellationToken)
{
foreach (var diagnostic in diagnostics)
{
await VerifyDiagnosticLocationAsync(diagnostic.Id, diagnostic.Location).ConfigureAwait(false);
if (diagnostic.AdditionalLocations != null)
{
foreach (var location in diagnostic.AdditionalLocations)
{
await VerifyDiagnosticLocationAsync(diagnostic.Id, location).ConfigureAwait(false);
}
}
}
async Task VerifyDiagnosticLocationAsync(string id, Location location)
{
switch (location.Kind)
{
case LocationKind.None:
case LocationKind.MetadataFile:
case LocationKind.XmlFile:
// ignore these kinds
break;
case LocationKind.SourceFile:
{
RoslynDebug.Assert(location.SourceTree != null);
if (project.GetDocument(location.SourceTree) == null)
{
// Disallow diagnostics with source locations outside this project.
throw new ArgumentException(string.Format(FeaturesResources.Reported_diagnostic_0_has_a_source_location_in_file_1_which_is_not_part_of_the_compilation_being_analyzed, id, location.SourceTree.FilePath), "diagnostic");
}
if (location.SourceSpan.End > location.SourceTree.Length)
{
// Disallow diagnostics with source locations outside this project.
throw new ArgumentException(string.Format(FeaturesResources.Reported_diagnostic_0_has_a_source_location_1_in_file_2_which_is_outside_of_the_given_file, id, location.SourceSpan, location.SourceTree.FilePath), "diagnostic");
}
}
break;
case LocationKind.ExternalFile:
{
var filePath = location.GetLineSpan().Path;
var document = TryGetDocumentWithFilePath(filePath);
if (document == null)
{
// this is not a roslyn file. we don't care about this file.
return;
}
// this can be potentially expensive since it will load text if it is not already loaded.
// but, this text is most likely already loaded since producer of this diagnostic (Document/ProjectDiagnosticAnalyzers)
// should have loaded it to produce the diagnostic at the first place. once loaded, it should stay in memory until
// project cache goes away. when text is already there, await should return right away.
var text = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
if (location.SourceSpan.End > text.Length)
{
// Disallow diagnostics with locations outside this project.
throw new ArgumentException(string.Format(FeaturesResources.Reported_diagnostic_0_has_a_source_location_1_in_file_2_which_is_outside_of_the_given_file, id, location.SourceSpan, filePath), "diagnostic");
}
}
break;
default:
throw ExceptionUtilities.Unreachable;
}
}
Document? TryGetDocumentWithFilePath(string path)
{
foreach (var documentId in project.Solution.GetDocumentIdsWithFilePath(path))
{
if (documentId.ProjectId == project.Id)
{
return project.GetDocument(documentId);
}
}
return null;
}
}
#endif
public static IEnumerable<DiagnosticData> ConvertToLocalDiagnostics(this IEnumerable<Diagnostic> diagnostics, TextDocument targetTextDocument, TextSpan? span = null)
{
foreach (var diagnostic in diagnostics)
{
if (!IsReportedInDocument(diagnostic, targetTextDocument))
{
continue;
}
if (span.HasValue && !span.Value.IntersectsWith(diagnostic.Location.SourceSpan))
{
continue;
}
yield return DiagnosticData.Create(diagnostic, targetTextDocument);
}
static bool IsReportedInDocument(Diagnostic diagnostic, TextDocument targetTextDocument)
{
if (diagnostic.Location.SourceTree != null)
{
return targetTextDocument.Project.GetDocument(diagnostic.Location.SourceTree) == targetTextDocument;
}
else if (diagnostic.Location.Kind == LocationKind.ExternalFile)
{
var lineSpan = diagnostic.Location.GetLineSpan();
var documentIds = targetTextDocument.Project.Solution.GetDocumentIdsWithFilePath(lineSpan.Path);
return documentIds.Any(id => id == targetTextDocument.Id);
}
return false;
}
}
#if DEBUG
internal static bool AreEquivalent(Diagnostic[] diagnosticsA, Diagnostic[] diagnosticsB)
{
var set = new HashSet<Diagnostic>(diagnosticsA, DiagnosticComparer.Instance);
return set.SetEquals(diagnosticsB);
}
private sealed class DiagnosticComparer : IEqualityComparer<Diagnostic?>
{
internal static readonly DiagnosticComparer Instance = new();
public bool Equals(Diagnostic? x, Diagnostic? y)
{
if (x is null)
return y is null;
else if (y is null)
return false;
return x.Id == y.Id && x.Location == y.Location;
}
public int GetHashCode(Diagnostic? obj)
{
if (obj is null)
return 0;
return Hash.Combine(obj.Id.GetHashCode(), obj.Location.GetHashCode());
}
}
#endif
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Diagnostics.Telemetry;
using Microsoft.CodeAnalysis.ErrorReporting;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Diagnostics
{
internal static partial class AnalyzerHelper
{
// These are the error codes of the compiler warnings.
// Keep the ids the same so that de-duplication against compiler errors
// works in the error list (after a build).
internal const string WRN_AnalyzerCannotBeCreatedIdCS = "CS8032";
internal const string WRN_AnalyzerCannotBeCreatedIdVB = "BC42376";
internal const string WRN_NoAnalyzerInAssemblyIdCS = "CS8033";
internal const string WRN_NoAnalyzerInAssemblyIdVB = "BC42377";
internal const string WRN_UnableToLoadAnalyzerIdCS = "CS8034";
internal const string WRN_UnableToLoadAnalyzerIdVB = "BC42378";
internal const string WRN_AnalyzerReferencesNetFrameworkIdCS = "CS8850";
internal const string WRN_AnalyzerReferencesNetFrameworkIdVB = "BC42503";
// Shared with Compiler
internal const string AnalyzerExceptionDiagnosticId = "AD0001";
internal const string AnalyzerDriverExceptionDiagnosticId = "AD0002";
// IDE only errors
internal const string WRN_AnalyzerCannotBeCreatedId = "AD1000";
internal const string WRN_NoAnalyzerInAssemblyId = "AD1001";
internal const string WRN_UnableToLoadAnalyzerId = "AD1002";
internal const string WRN_AnalyzerReferencesNetFrameworkId = "AD1003";
private const string AnalyzerExceptionDiagnosticCategory = "Intellisense";
public static bool IsWorkspaceDiagnosticAnalyzer(this DiagnosticAnalyzer analyzer)
=> analyzer is DocumentDiagnosticAnalyzer || analyzer is ProjectDiagnosticAnalyzer || analyzer == FileContentLoadAnalyzer.Instance;
public static bool IsBuiltInAnalyzer(this DiagnosticAnalyzer analyzer)
=> analyzer is IBuiltInAnalyzer || analyzer.IsWorkspaceDiagnosticAnalyzer() || analyzer.IsCompilerAnalyzer();
public static bool IsOpenFileOnly(this DiagnosticAnalyzer analyzer, OptionSet options)
=> analyzer is IBuiltInAnalyzer builtInAnalyzer && builtInAnalyzer.OpenFileOnly(options);
public static ReportDiagnostic GetEffectiveSeverity(this DiagnosticDescriptor descriptor, CompilationOptions options)
{
return options == null
? descriptor.DefaultSeverity.ToReportDiagnostic()
: descriptor.GetEffectiveSeverity(options);
}
public static (string analyzerId, VersionStamp version) GetAnalyzerIdAndVersion(this DiagnosticAnalyzer analyzer)
{
// Get the unique ID for given diagnostic analyzer.
// note that we also put version stamp so that we can detect changed analyzer.
var typeInfo = analyzer.GetType().GetTypeInfo();
return (analyzer.GetAnalyzerId(), GetAnalyzerVersion(typeInfo.Assembly.Location));
}
public static string GetAnalyzerAssemblyName(this DiagnosticAnalyzer analyzer)
=> analyzer.GetType().Assembly.GetName().Name ?? throw ExceptionUtilities.Unreachable;
public static OptionSet GetAnalyzerOptionSet(this AnalyzerOptions analyzerOptions, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var optionSetAsync = GetAnalyzerOptionSetAsync(analyzerOptions, syntaxTree, cancellationToken);
if (optionSetAsync.IsCompleted)
return optionSetAsync.Result;
return optionSetAsync.AsTask().GetAwaiter().GetResult();
}
public static async ValueTask<OptionSet> GetAnalyzerOptionSetAsync(this AnalyzerOptions analyzerOptions, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var configOptions = analyzerOptions.AnalyzerConfigOptionsProvider.GetOptions(syntaxTree);
#pragma warning disable CS0612 // Type or member is obsolete
var optionSet = await GetDocumentOptionSetAsync(analyzerOptions, syntaxTree, cancellationToken).ConfigureAwait(false);
#pragma warning restore CS0612 // Type or member is obsolete
return new AnalyzerConfigOptionSet(configOptions, optionSet);
}
public static T GetOption<T>(this AnalyzerOptions analyzerOptions, ILanguageSpecificOption<T> option, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var optionAsync = GetOptionAsync<T>(analyzerOptions, option, language: null, syntaxTree, cancellationToken);
if (optionAsync.IsCompleted)
return optionAsync.Result;
return optionAsync.AsTask().GetAwaiter().GetResult();
}
public static T GetOption<T>(this AnalyzerOptions analyzerOptions, IPerLanguageOption<T> option, string? language, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
var optionAsync = GetOptionAsync<T>(analyzerOptions, option, language, syntaxTree, cancellationToken);
if (optionAsync.IsCompleted)
return optionAsync.Result;
return optionAsync.AsTask().GetAwaiter().GetResult();
}
public static async ValueTask<T> GetOptionAsync<T>(this AnalyzerOptions analyzerOptions, IOption option, string? language, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
if (analyzerOptions.TryGetEditorConfigOption<T>(option, syntaxTree, out var value))
{
return value;
}
#pragma warning disable CS0612 // Type or member is obsolete
var optionSet = await analyzerOptions.GetDocumentOptionSetAsync(syntaxTree, cancellationToken).ConfigureAwait(false);
#pragma warning restore CS0612 // Type or member is obsolete
if (optionSet != null)
{
value = optionSet.GetOption<T>(new OptionKey(option, language));
}
return value ?? (T)option.DefaultValue!;
}
[PerformanceSensitive("https://github.com/dotnet/roslyn/issues/23582", OftenCompletesSynchronously = true)]
public static ValueTask<OptionSet?> GetDocumentOptionSetAsync(this AnalyzerOptions analyzerOptions, SyntaxTree syntaxTree, CancellationToken cancellationToken)
{
if (analyzerOptions is not WorkspaceAnalyzerOptions workspaceAnalyzerOptions)
{
return ValueTaskFactory.FromResult((OptionSet?)null);
}
return workspaceAnalyzerOptions.GetDocumentOptionSetAsync(syntaxTree, cancellationToken);
}
/// <summary>
/// Create a diagnostic for exception thrown by the given analyzer.
/// </summary>
/// <remarks>
/// Keep this method in sync with "AnalyzerExecutor.CreateAnalyzerExceptionDiagnostic".
/// </remarks>
internal static Diagnostic CreateAnalyzerExceptionDiagnostic(DiagnosticAnalyzer analyzer, Exception e)
{
var analyzerName = analyzer.ToString();
// TODO: It is not ideal to create a new descriptor per analyzer exception diagnostic instance.
// However, until we add a LongMessage field to the Diagnostic, we are forced to park the instance specific description onto the Descriptor's Description field.
// This requires us to create a new DiagnosticDescriptor instance per diagnostic instance.
var descriptor = new DiagnosticDescriptor(AnalyzerExceptionDiagnosticId,
title: FeaturesResources.User_Diagnostic_Analyzer_Failure,
messageFormat: FeaturesResources.Analyzer_0_threw_an_exception_of_type_1_with_message_2,
description: string.Format(FeaturesResources.Analyzer_0_threw_the_following_exception_colon_1, analyzerName, e.CreateDiagnosticDescription()),
category: AnalyzerExceptionDiagnosticCategory,
defaultSeverity: DiagnosticSeverity.Warning,
isEnabledByDefault: true,
customTags: WellKnownDiagnosticTags.AnalyzerException);
return Diagnostic.Create(descriptor, Location.None, analyzerName, e.GetType(), e.Message);
}
private static VersionStamp GetAnalyzerVersion(string path)
{
if (path == null || !File.Exists(path))
{
return VersionStamp.Default;
}
return VersionStamp.Create(File.GetLastWriteTimeUtc(path));
}
public static DiagnosticData CreateAnalyzerLoadFailureDiagnostic(AnalyzerLoadFailureEventArgs e, string fullPath, ProjectId? projectId, string? language)
{
static string GetLanguageSpecificId(string? language, string noLanguageId, string csharpId, string vbId)
=> language == null ? noLanguageId : (language == LanguageNames.CSharp) ? csharpId : vbId;
string id, messageFormat, message;
switch (e.ErrorCode)
{
case AnalyzerLoadFailureEventArgs.FailureErrorCode.UnableToLoadAnalyzer:
id = GetLanguageSpecificId(language, WRN_UnableToLoadAnalyzerId, WRN_UnableToLoadAnalyzerIdCS, WRN_UnableToLoadAnalyzerIdVB);
messageFormat = FeaturesResources.Unable_to_load_Analyzer_assembly_0_colon_1;
message = string.Format(FeaturesResources.Unable_to_load_Analyzer_assembly_0_colon_1, fullPath, e.Message);
break;
case AnalyzerLoadFailureEventArgs.FailureErrorCode.UnableToCreateAnalyzer:
id = GetLanguageSpecificId(language, WRN_AnalyzerCannotBeCreatedId, WRN_AnalyzerCannotBeCreatedIdCS, WRN_AnalyzerCannotBeCreatedIdVB);
messageFormat = FeaturesResources.An_instance_of_analyzer_0_cannot_be_created_from_1_colon_2;
message = string.Format(FeaturesResources.An_instance_of_analyzer_0_cannot_be_created_from_1_colon_2, e.TypeName, fullPath, e.Message);
break;
case AnalyzerLoadFailureEventArgs.FailureErrorCode.NoAnalyzers:
id = GetLanguageSpecificId(language, WRN_NoAnalyzerInAssemblyId, WRN_NoAnalyzerInAssemblyIdCS, WRN_NoAnalyzerInAssemblyIdVB);
messageFormat = FeaturesResources.The_assembly_0_does_not_contain_any_analyzers;
message = string.Format(FeaturesResources.The_assembly_0_does_not_contain_any_analyzers, fullPath);
break;
case AnalyzerLoadFailureEventArgs.FailureErrorCode.ReferencesFramework:
id = GetLanguageSpecificId(language, WRN_AnalyzerReferencesNetFrameworkId, WRN_AnalyzerReferencesNetFrameworkIdCS, WRN_AnalyzerReferencesNetFrameworkIdVB);
messageFormat = FeaturesResources.The_assembly_0_containing_type_1_references_NET_Framework;
message = string.Format(FeaturesResources.The_assembly_0_containing_type_1_references_NET_Framework, fullPath, e.TypeName);
break;
default:
throw ExceptionUtilities.UnexpectedValue(e.ErrorCode);
}
var description = e.Exception.CreateDiagnosticDescription();
return new DiagnosticData(
id,
FeaturesResources.Roslyn_HostError,
message,
messageFormat,
severity: DiagnosticSeverity.Warning,
defaultSeverity: DiagnosticSeverity.Warning,
isEnabledByDefault: true,
description: description,
warningLevel: 0,
projectId: projectId,
customTags: ImmutableArray<string>.Empty,
properties: ImmutableDictionary<string, string?>.Empty,
language: language);
}
public static void AppendAnalyzerMap(this Dictionary<string, DiagnosticAnalyzer> analyzerMap, IEnumerable<DiagnosticAnalyzer> analyzers)
{
foreach (var analyzer in analyzers)
{
// user might have included exact same analyzer twice as project analyzers explicitly. we consider them as one
analyzerMap[analyzer.GetAnalyzerId()] = analyzer;
}
}
public static IEnumerable<AnalyzerPerformanceInfo> ToAnalyzerPerformanceInfo(this IDictionary<DiagnosticAnalyzer, AnalyzerTelemetryInfo> analysisResult, DiagnosticAnalyzerInfoCache analyzerInfo)
=> analysisResult.Select(kv => new AnalyzerPerformanceInfo(kv.Key.GetAnalyzerId(), analyzerInfo.IsTelemetryCollectionAllowed(kv.Key), kv.Value.ExecutionTime));
public static async Task<CompilationWithAnalyzers?> CreateCompilationWithAnalyzersAsync(
Project project,
IEnumerable<DiagnosticAnalyzer> analyzers,
bool includeSuppressedDiagnostics,
CancellationToken cancellationToken)
{
var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
if (compilation == null)
{
// project doesn't support compilation
return null;
}
// Create driver that holds onto compilation and associated analyzers
var filteredAnalyzers = analyzers.Where(a => !a.IsWorkspaceDiagnosticAnalyzer()).ToImmutableArrayOrEmpty();
// PERF: there is no analyzers for this compilation.
// compilationWithAnalyzer will throw if it is created with no analyzers which is perf optimization.
if (filteredAnalyzers.IsEmpty)
{
return null;
}
Contract.ThrowIfFalse(project.SupportsCompilation);
AssertCompilation(project, compilation);
// in IDE, we always set concurrentAnalysis == false otherwise, we can get into thread starvation due to
// async being used with synchronous blocking concurrency.
var analyzerOptions = new CompilationWithAnalyzersOptions(
options: new WorkspaceAnalyzerOptions(project.AnalyzerOptions, project.Solution),
onAnalyzerException: null,
analyzerExceptionFilter: GetAnalyzerExceptionFilter(),
concurrentAnalysis: false,
logAnalyzerExecutionTime: true,
reportSuppressedDiagnostics: includeSuppressedDiagnostics);
// Create driver that holds onto compilation and associated analyzers
return compilation.WithAnalyzers(filteredAnalyzers, analyzerOptions);
Func<Exception, bool> GetAnalyzerExceptionFilter()
{
return ex =>
{
if (ex is not OperationCanceledException && project.Solution.Workspace.Options.GetOption(InternalDiagnosticsOptions.CrashOnAnalyzerException))
{
// report telemetry
FatalError.ReportAndPropagate(ex);
// force fail fast (the host might not crash when reporting telemetry):
FailFast.OnFatalException(ex);
}
return true;
};
}
}
[Conditional("DEBUG")]
private static void AssertCompilation(Project project, Compilation compilation1)
{
// given compilation must be from given project.
Contract.ThrowIfFalse(project.TryGetCompilation(out var compilation2));
Contract.ThrowIfFalse(compilation1 == compilation2);
}
public static async Task<ImmutableArray<Diagnostic>> ComputeDocumentDiagnosticAnalyzerDiagnosticsAsync(
DocumentDiagnosticAnalyzer analyzer,
Document document,
AnalysisKind kind,
Compilation? compilation,
CancellationToken cancellationToken)
{
cancellationToken.ThrowIfCancellationRequested();
ImmutableArray<Diagnostic> diagnostics;
try
{
var analyzeAsync = kind switch
{
AnalysisKind.Syntax => analyzer.AnalyzeSyntaxAsync(document, cancellationToken),
AnalysisKind.Semantic => analyzer.AnalyzeSemanticsAsync(document, cancellationToken),
_ => throw ExceptionUtilities.UnexpectedValue(kind),
};
diagnostics = (await analyzeAsync.ConfigureAwait(false)).NullToEmpty();
#if DEBUG
// since all DocumentDiagnosticAnalyzers are from internal users, we only do debug check. also this can be expensive at runtime
// since it requires await. if we find any offender through NFW, we should be able to fix those since all those should
// from intern teams.
await VerifyDiagnosticLocationsAsync(diagnostics, document.Project, cancellationToken).ConfigureAwait(false);
#endif
}
catch (Exception e) when (!IsCanceled(e, cancellationToken))
{
diagnostics = ImmutableArray.Create(CreateAnalyzerExceptionDiagnostic(analyzer, e));
}
if (compilation != null)
{
diagnostics = CompilationWithAnalyzers.GetEffectiveDiagnostics(diagnostics, compilation).ToImmutableArrayOrEmpty();
}
return diagnostics;
}
public static async Task<ImmutableArray<Diagnostic>> ComputeProjectDiagnosticAnalyzerDiagnosticsAsync(
ProjectDiagnosticAnalyzer analyzer,
Project project,
Compilation? compilation,
CancellationToken cancellationToken)
{
cancellationToken.ThrowIfCancellationRequested();
ImmutableArray<Diagnostic> diagnostics;
try
{
diagnostics = (await analyzer.AnalyzeProjectAsync(project, cancellationToken).ConfigureAwait(false)).NullToEmpty();
#if DEBUG
// since all ProjectDiagnosticAnalyzers are from internal users, we only do debug check. also this can be expensive at runtime
// since it requires await. if we find any offender through NFW, we should be able to fix those since all those should
// from intern teams.
await VerifyDiagnosticLocationsAsync(diagnostics, project, cancellationToken).ConfigureAwait(false);
#endif
}
catch (Exception e) when (!IsCanceled(e, cancellationToken))
{
diagnostics = ImmutableArray.Create(CreateAnalyzerExceptionDiagnostic(analyzer, e));
}
// Apply filtering from compilation options (source suppressions, ruleset, etc.)
if (compilation != null)
{
diagnostics = CompilationWithAnalyzers.GetEffectiveDiagnostics(diagnostics, compilation).ToImmutableArrayOrEmpty();
}
return diagnostics;
}
private static bool IsCanceled(Exception ex, CancellationToken cancellationToken)
=> (ex as OperationCanceledException)?.CancellationToken == cancellationToken;
#if DEBUG
private static async Task VerifyDiagnosticLocationsAsync(ImmutableArray<Diagnostic> diagnostics, Project project, CancellationToken cancellationToken)
{
foreach (var diagnostic in diagnostics)
{
await VerifyDiagnosticLocationAsync(diagnostic.Id, diagnostic.Location).ConfigureAwait(false);
if (diagnostic.AdditionalLocations != null)
{
foreach (var location in diagnostic.AdditionalLocations)
{
await VerifyDiagnosticLocationAsync(diagnostic.Id, location).ConfigureAwait(false);
}
}
}
async Task VerifyDiagnosticLocationAsync(string id, Location location)
{
switch (location.Kind)
{
case LocationKind.None:
case LocationKind.MetadataFile:
case LocationKind.XmlFile:
// ignore these kinds
break;
case LocationKind.SourceFile:
{
RoslynDebug.Assert(location.SourceTree != null);
if (project.GetDocument(location.SourceTree) == null)
{
// Disallow diagnostics with source locations outside this project.
throw new ArgumentException(string.Format(FeaturesResources.Reported_diagnostic_0_has_a_source_location_in_file_1_which_is_not_part_of_the_compilation_being_analyzed, id, location.SourceTree.FilePath), "diagnostic");
}
if (location.SourceSpan.End > location.SourceTree.Length)
{
// Disallow diagnostics with source locations outside this project.
throw new ArgumentException(string.Format(FeaturesResources.Reported_diagnostic_0_has_a_source_location_1_in_file_2_which_is_outside_of_the_given_file, id, location.SourceSpan, location.SourceTree.FilePath), "diagnostic");
}
}
break;
case LocationKind.ExternalFile:
{
var filePath = location.GetLineSpan().Path;
var document = TryGetDocumentWithFilePath(filePath);
if (document == null)
{
// this is not a roslyn file. we don't care about this file.
return;
}
// this can be potentially expensive since it will load text if it is not already loaded.
// but, this text is most likely already loaded since producer of this diagnostic (Document/ProjectDiagnosticAnalyzers)
// should have loaded it to produce the diagnostic at the first place. once loaded, it should stay in memory until
// project cache goes away. when text is already there, await should return right away.
var text = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
if (location.SourceSpan.End > text.Length)
{
// Disallow diagnostics with locations outside this project.
throw new ArgumentException(string.Format(FeaturesResources.Reported_diagnostic_0_has_a_source_location_1_in_file_2_which_is_outside_of_the_given_file, id, location.SourceSpan, filePath), "diagnostic");
}
}
break;
default:
throw ExceptionUtilities.Unreachable;
}
}
Document? TryGetDocumentWithFilePath(string path)
{
foreach (var documentId in project.Solution.GetDocumentIdsWithFilePath(path))
{
if (documentId.ProjectId == project.Id)
{
return project.GetDocument(documentId);
}
}
return null;
}
}
#endif
public static IEnumerable<DiagnosticData> ConvertToLocalDiagnostics(this IEnumerable<Diagnostic> diagnostics, TextDocument targetTextDocument, TextSpan? span = null)
{
foreach (var diagnostic in diagnostics)
{
if (!IsReportedInDocument(diagnostic, targetTextDocument))
{
continue;
}
if (span.HasValue && !span.Value.IntersectsWith(diagnostic.Location.SourceSpan))
{
continue;
}
yield return DiagnosticData.Create(diagnostic, targetTextDocument);
}
static bool IsReportedInDocument(Diagnostic diagnostic, TextDocument targetTextDocument)
{
if (diagnostic.Location.SourceTree != null)
{
return targetTextDocument.Project.GetDocument(diagnostic.Location.SourceTree) == targetTextDocument;
}
else if (diagnostic.Location.Kind == LocationKind.ExternalFile)
{
var lineSpan = diagnostic.Location.GetLineSpan();
var documentIds = targetTextDocument.Project.Solution.GetDocumentIdsWithFilePath(lineSpan.Path);
return documentIds.Any(id => id == targetTextDocument.Id);
}
return false;
}
}
#if DEBUG
internal static bool AreEquivalent(Diagnostic[] diagnosticsA, Diagnostic[] diagnosticsB)
{
var set = new HashSet<Diagnostic>(diagnosticsA, DiagnosticComparer.Instance);
return set.SetEquals(diagnosticsB);
}
private sealed class DiagnosticComparer : IEqualityComparer<Diagnostic?>
{
internal static readonly DiagnosticComparer Instance = new();
public bool Equals(Diagnostic? x, Diagnostic? y)
{
if (x is null)
return y is null;
else if (y is null)
return false;
return x.Id == y.Id && x.Location == y.Location;
}
public int GetHashCode(Diagnostic? obj)
{
if (obj is null)
return 0;
return Hash.Combine(obj.Id.GetHashCode(), obj.Location.GetHashCode());
}
}
#endif
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/Core/Portable/Shared/Utilities/IStreamingProgressTrackerExtensions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Threading;
using System.Threading.Tasks;
namespace Microsoft.CodeAnalysis.Shared.Utilities
{
internal static class IStreamingProgressTrackerExtensions
{
/// <summary>
/// Returns an <see cref="IAsyncDisposable"/> that will call <see
/// cref="IStreamingProgressTracker.ItemCompletedAsync"/> on <paramref
/// name="progressTracker"/> when it is disposed.
/// </summary>
public static async Task<IAsyncDisposable> AddSingleItemAsync(this IStreamingProgressTracker progressTracker, CancellationToken cancellationToken)
{
await progressTracker.AddItemsAsync(1, cancellationToken).ConfigureAwait(false);
return new StreamingProgressDisposer(progressTracker, cancellationToken);
}
private class StreamingProgressDisposer : IAsyncDisposable
{
private readonly IStreamingProgressTracker _progressTracker;
private readonly CancellationToken _cancellationToken;
public StreamingProgressDisposer(IStreamingProgressTracker progressTracker, CancellationToken cancellationToken)
{
_progressTracker = progressTracker;
_cancellationToken = cancellationToken;
}
public async ValueTask DisposeAsync()
=> await _progressTracker.ItemCompletedAsync(_cancellationToken).ConfigureAwait(false);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Threading;
using System.Threading.Tasks;
namespace Microsoft.CodeAnalysis.Shared.Utilities
{
internal static class IStreamingProgressTrackerExtensions
{
/// <summary>
/// Returns an <see cref="IAsyncDisposable"/> that will call <see
/// cref="IStreamingProgressTracker.ItemCompletedAsync"/> on <paramref
/// name="progressTracker"/> when it is disposed.
/// </summary>
public static async Task<IAsyncDisposable> AddSingleItemAsync(this IStreamingProgressTracker progressTracker, CancellationToken cancellationToken)
{
await progressTracker.AddItemsAsync(1, cancellationToken).ConfigureAwait(false);
return new StreamingProgressDisposer(progressTracker, cancellationToken);
}
private class StreamingProgressDisposer : IAsyncDisposable
{
private readonly IStreamingProgressTracker _progressTracker;
private readonly CancellationToken _cancellationToken;
public StreamingProgressDisposer(IStreamingProgressTracker progressTracker, CancellationToken cancellationToken)
{
_progressTracker = progressTracker;
_cancellationToken = cancellationToken;
}
public async ValueTask DisposeAsync()
=> await _progressTracker.ItemCompletedAsync(_cancellationToken).ConfigureAwait(false);
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/VisualBasicTest/KeywordHighlighting/AbstractVisualBasicKeywordHighlighterTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Extensions
Imports Microsoft.CodeAnalysis.Editor.UnitTests.KeywordHighlighting
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.KeywordHighlighting
Public MustInherit Class AbstractVisualBasicKeywordHighlighterTests
Inherits AbstractKeywordHighlighterTests
Protected Overrides Function GetOptions() As IEnumerable(Of ParseOptions)
Return SpecializedCollections.SingletonEnumerable(TestOptions.Regular)
End Function
Protected Overloads Function TestAsync(element As XElement) As Task
Return TestAsync(element.NormalizedValue)
End Function
Protected Overrides Function CreateWorkspaceFromFile(code As String, options As ParseOptions) As TestWorkspace
Return TestWorkspace.CreateVisualBasic(code, options, composition:=Composition)
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Extensions
Imports Microsoft.CodeAnalysis.Editor.UnitTests.KeywordHighlighting
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.KeywordHighlighting
Public MustInherit Class AbstractVisualBasicKeywordHighlighterTests
Inherits AbstractKeywordHighlighterTests
Protected Overrides Function GetOptions() As IEnumerable(Of ParseOptions)
Return SpecializedCollections.SingletonEnumerable(TestOptions.Regular)
End Function
Protected Overloads Function TestAsync(element As XElement) As Task
Return TestAsync(element.NormalizedValue)
End Function
Protected Overrides Function CreateWorkspaceFromFile(code As String, options As ParseOptions) As TestWorkspace
Return TestWorkspace.CreateVisualBasic(code, options, composition:=Composition)
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/IntegrationTest/IntegrationTests/AbstractInteractiveWindowTest.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Threading.Tasks;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Xunit.Abstractions;
namespace Roslyn.VisualStudio.IntegrationTests
{
public abstract class AbstractInteractiveWindowTest : AbstractIntegrationTest
{
protected AbstractInteractiveWindowTest(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory)
{
}
public override async Task InitializeAsync()
{
await base.InitializeAsync().ConfigureAwait(true);
ClearInteractiveWindow();
}
protected void ClearInteractiveWindow()
{
VisualStudio.InteractiveWindow.Initialize();
VisualStudio.InteractiveWindow.ClearScreen();
VisualStudio.InteractiveWindow.ShowWindow();
VisualStudio.InteractiveWindow.Reset();
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Threading.Tasks;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Xunit.Abstractions;
namespace Roslyn.VisualStudio.IntegrationTests
{
public abstract class AbstractInteractiveWindowTest : AbstractIntegrationTest
{
protected AbstractInteractiveWindowTest(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory)
{
}
public override async Task InitializeAsync()
{
await base.InitializeAsync().ConfigureAwait(true);
ClearInteractiveWindow();
}
protected void ClearInteractiveWindow()
{
VisualStudio.InteractiveWindow.Initialize();
VisualStudio.InteractiveWindow.ClearScreen();
VisualStudio.InteractiveWindow.ShowWindow();
VisualStudio.InteractiveWindow.Reset();
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/CSharpTest2/Recommendations/AddKeywordRecommenderTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Recommendations
{
public class AddKeywordRecommenderTests : KeywordRecommenderTests
{
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAtRoot_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterClass_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"class C { }
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterGlobalStatement_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"System.Console.WriteLine();
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterGlobalVariableDeclaration_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"int i = 0;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInUsingAlias()
{
await VerifyAbsenceAsync(
@"using Goo = $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInGlobalUsingAlias()
{
await VerifyAbsenceAsync(
@"global using Goo = $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInEmptyStatement()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"$$"));
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterEvent()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterAttribute()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { [Bar] $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRemove()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { remove { } $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRemoveAndAttribute()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { remove { } [Bar] $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRemoveBlock()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { set { } $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAddKeyword()
{
await VerifyAbsenceAsync(
@"class C {
event Goo Bar { add $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAddAccessor()
{
await VerifyAbsenceAsync(
@"class C {
event Goo Bar { add { } $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInProperty()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { $$");
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Recommendations
{
public class AddKeywordRecommenderTests : KeywordRecommenderTests
{
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAtRoot_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterClass_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"class C { }
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterGlobalStatement_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"System.Console.WriteLine();
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterGlobalVariableDeclaration_Interactive()
{
await VerifyAbsenceAsync(SourceCodeKind.Script,
@"int i = 0;
$$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInUsingAlias()
{
await VerifyAbsenceAsync(
@"using Goo = $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInGlobalUsingAlias()
{
await VerifyAbsenceAsync(
@"global using Goo = $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInEmptyStatement()
{
await VerifyAbsenceAsync(AddInsideMethod(
@"$$"));
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterEvent()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterAttribute()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { [Bar] $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRemove()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { remove { } $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRemoveAndAttribute()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { remove { } [Bar] $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestAfterRemoveBlock()
{
await VerifyKeywordAsync(
@"class C {
event Goo Bar { set { } $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAddKeyword()
{
await VerifyAbsenceAsync(
@"class C {
event Goo Bar { add $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotAfterAddAccessor()
{
await VerifyAbsenceAsync(
@"class C {
event Goo Bar { add { } $$");
}
[Fact, Trait(Traits.Feature, Traits.Features.KeywordRecommending)]
public async Task TestNotInProperty()
{
await VerifyAbsenceAsync(
@"class C {
int Goo { $$");
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Test/Core/Metadata/MetadataValidation.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Reflection.Metadata;
using System.Reflection.Metadata.Ecma335;
using System.Reflection.PortableExecutable;
using Microsoft.CodeAnalysis;
using Microsoft.Metadata.Tools;
using Roslyn.Utilities;
using Xunit;
namespace Roslyn.Test.Utilities
{
public static class MetadataValidation
{
/// <summary>
/// Returns the name of the attribute class
/// </summary>
internal static string GetAttributeName(MetadataReader metadataReader, CustomAttributeHandle customAttribute)
{
var ctorHandle = metadataReader.GetCustomAttribute(customAttribute).Constructor;
if (ctorHandle.Kind == HandleKind.MemberReference) // MemberRef
{
var container = metadataReader.GetMemberReference((MemberReferenceHandle)ctorHandle).Parent;
var name = metadataReader.GetTypeReference((TypeReferenceHandle)container).Name;
return metadataReader.GetString(name);
}
else
{
Assert.True(false, "not impl");
return null;
}
}
internal static CustomAttributeHandle FindCustomAttribute(MetadataReader metadataReader, string attributeClassName)
{
foreach (var caHandle in metadataReader.CustomAttributes)
{
if (string.Equals(GetAttributeName(metadataReader, caHandle), attributeClassName, StringComparison.Ordinal))
{
return caHandle;
}
}
return default(CustomAttributeHandle);
}
/// <summary>
/// Used to validate metadata blobs emitted for MarshalAs.
/// </summary>
internal static void MarshalAsMetadataValidator(PEAssembly assembly, Func<string, PEAssembly, byte[]> getExpectedBlob, bool isField = true)
{
var metadataReader = assembly.GetMetadataReader();
// no custom attributes should be emitted on parameters, fields or methods:
foreach (var ca in metadataReader.CustomAttributes)
{
Assert.NotEqual("MarshalAsAttribute", GetAttributeName(metadataReader, ca));
}
int expectedMarshalCount = 0;
if (isField)
{
// fields
foreach (var fieldDef in metadataReader.FieldDefinitions)
{
var field = metadataReader.GetFieldDefinition(fieldDef);
string fieldName = metadataReader.GetString(field.Name);
byte[] expectedBlob = getExpectedBlob(fieldName, assembly);
if (expectedBlob != null)
{
BlobHandle descriptor = metadataReader.GetFieldDefinition(fieldDef).GetMarshallingDescriptor();
Assert.False(descriptor.IsNil, "Expecting record in FieldMarshal table");
Assert.NotEqual(0, (int)(field.Attributes & FieldAttributes.HasFieldMarshal));
expectedMarshalCount++;
byte[] actualBlob = metadataReader.GetBlobBytes(descriptor);
AssertEx.Equal(expectedBlob, actualBlob);
}
else
{
Assert.Equal(0, (int)(field.Attributes & FieldAttributes.HasFieldMarshal));
}
}
}
else
{
// parameters
foreach (var methodHandle in metadataReader.MethodDefinitions)
{
var methodDef = metadataReader.GetMethodDefinition(methodHandle);
string memberName = metadataReader.GetString(methodDef.Name);
foreach (var paramHandle in methodDef.GetParameters())
{
var paramRow = metadataReader.GetParameter(paramHandle);
string paramName = metadataReader.GetString(paramRow.Name);
byte[] expectedBlob = getExpectedBlob(memberName + ":" + paramName, assembly);
if (expectedBlob != null)
{
Assert.NotEqual(0, (int)(paramRow.Attributes & ParameterAttributes.HasFieldMarshal));
expectedMarshalCount++;
BlobHandle descriptor = metadataReader.GetParameter(paramHandle).GetMarshallingDescriptor();
Assert.False(descriptor.IsNil, "Expecting record in FieldMarshal table");
byte[] actualBlob = metadataReader.GetBlobBytes(descriptor);
AssertEx.Equal(expectedBlob, actualBlob);
}
else
{
Assert.Equal(0, (int)(paramRow.Attributes & ParameterAttributes.HasFieldMarshal));
}
}
}
}
Assert.Equal(expectedMarshalCount, metadataReader.GetTableRowCount(TableIndex.FieldMarshal));
}
internal static IEnumerable<string> GetFullTypeNames(MetadataReader metadataReader)
{
foreach (var typeDefHandle in metadataReader.TypeDefinitions)
{
var typeDef = metadataReader.GetTypeDefinition(typeDefHandle);
var ns = metadataReader.GetString(typeDef.Namespace);
var name = metadataReader.GetString(typeDef.Name);
yield return (ns.Length == 0) ? name : (ns + "." + name);
}
}
internal static IEnumerable<string> GetExportedTypesFullNames(MetadataReader metadataReader)
{
foreach (var typeDefHandle in metadataReader.ExportedTypes)
{
var typeDef = metadataReader.GetExportedType(typeDefHandle);
var ns = metadataReader.GetString(typeDef.Namespace);
var name = metadataReader.GetString(typeDef.Name);
yield return (ns.Length == 0) ? name : (ns + "." + name);
}
}
public static void VerifyMetadataEqualModuloMvid(Stream peStream1, Stream peStream2)
{
peStream1.Position = 0;
peStream2.Position = 0;
var peReader1 = new PEReader(peStream1);
var peReader2 = new PEReader(peStream2);
var md1 = peReader1.GetMetadata().GetContent();
var md2 = peReader2.GetMetadata().GetContent();
var mdReader1 = peReader1.GetMetadataReader();
var mdReader2 = peReader2.GetMetadataReader();
var mvidIndex1 = mdReader1.GetModuleDefinition().Mvid;
var mvidIndex2 = mdReader2.GetModuleDefinition().Mvid;
var mvidOffset1 = mdReader1.GetHeapMetadataOffset(HeapIndex.Guid) + 16 * (MetadataTokens.GetHeapOffset(mvidIndex1) - 1);
var mvidOffset2 = mdReader2.GetHeapMetadataOffset(HeapIndex.Guid) + 16 * (MetadataTokens.GetHeapOffset(mvidIndex2) - 1);
if (!md1.RemoveRange(mvidOffset1, 16).SequenceEqual(md1.RemoveRange(mvidOffset2, 16)))
{
var mdw1 = new StringWriter();
var mdw2 = new StringWriter();
new MetadataVisualizer(mdReader1, mdw1).Visualize();
new MetadataVisualizer(mdReader2, mdw2).Visualize();
mdw1.Flush();
mdw2.Flush();
AssertEx.AssertResultsEqual(mdw1.ToString(), mdw2.ToString());
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Reflection.Metadata;
using System.Reflection.Metadata.Ecma335;
using System.Reflection.PortableExecutable;
using Microsoft.CodeAnalysis;
using Microsoft.Metadata.Tools;
using Roslyn.Utilities;
using Xunit;
namespace Roslyn.Test.Utilities
{
public static class MetadataValidation
{
/// <summary>
/// Returns the name of the attribute class
/// </summary>
internal static string GetAttributeName(MetadataReader metadataReader, CustomAttributeHandle customAttribute)
{
var ctorHandle = metadataReader.GetCustomAttribute(customAttribute).Constructor;
if (ctorHandle.Kind == HandleKind.MemberReference) // MemberRef
{
var container = metadataReader.GetMemberReference((MemberReferenceHandle)ctorHandle).Parent;
var name = metadataReader.GetTypeReference((TypeReferenceHandle)container).Name;
return metadataReader.GetString(name);
}
else
{
Assert.True(false, "not impl");
return null;
}
}
internal static CustomAttributeHandle FindCustomAttribute(MetadataReader metadataReader, string attributeClassName)
{
foreach (var caHandle in metadataReader.CustomAttributes)
{
if (string.Equals(GetAttributeName(metadataReader, caHandle), attributeClassName, StringComparison.Ordinal))
{
return caHandle;
}
}
return default(CustomAttributeHandle);
}
/// <summary>
/// Used to validate metadata blobs emitted for MarshalAs.
/// </summary>
internal static void MarshalAsMetadataValidator(PEAssembly assembly, Func<string, PEAssembly, byte[]> getExpectedBlob, bool isField = true)
{
var metadataReader = assembly.GetMetadataReader();
// no custom attributes should be emitted on parameters, fields or methods:
foreach (var ca in metadataReader.CustomAttributes)
{
Assert.NotEqual("MarshalAsAttribute", GetAttributeName(metadataReader, ca));
}
int expectedMarshalCount = 0;
if (isField)
{
// fields
foreach (var fieldDef in metadataReader.FieldDefinitions)
{
var field = metadataReader.GetFieldDefinition(fieldDef);
string fieldName = metadataReader.GetString(field.Name);
byte[] expectedBlob = getExpectedBlob(fieldName, assembly);
if (expectedBlob != null)
{
BlobHandle descriptor = metadataReader.GetFieldDefinition(fieldDef).GetMarshallingDescriptor();
Assert.False(descriptor.IsNil, "Expecting record in FieldMarshal table");
Assert.NotEqual(0, (int)(field.Attributes & FieldAttributes.HasFieldMarshal));
expectedMarshalCount++;
byte[] actualBlob = metadataReader.GetBlobBytes(descriptor);
AssertEx.Equal(expectedBlob, actualBlob);
}
else
{
Assert.Equal(0, (int)(field.Attributes & FieldAttributes.HasFieldMarshal));
}
}
}
else
{
// parameters
foreach (var methodHandle in metadataReader.MethodDefinitions)
{
var methodDef = metadataReader.GetMethodDefinition(methodHandle);
string memberName = metadataReader.GetString(methodDef.Name);
foreach (var paramHandle in methodDef.GetParameters())
{
var paramRow = metadataReader.GetParameter(paramHandle);
string paramName = metadataReader.GetString(paramRow.Name);
byte[] expectedBlob = getExpectedBlob(memberName + ":" + paramName, assembly);
if (expectedBlob != null)
{
Assert.NotEqual(0, (int)(paramRow.Attributes & ParameterAttributes.HasFieldMarshal));
expectedMarshalCount++;
BlobHandle descriptor = metadataReader.GetParameter(paramHandle).GetMarshallingDescriptor();
Assert.False(descriptor.IsNil, "Expecting record in FieldMarshal table");
byte[] actualBlob = metadataReader.GetBlobBytes(descriptor);
AssertEx.Equal(expectedBlob, actualBlob);
}
else
{
Assert.Equal(0, (int)(paramRow.Attributes & ParameterAttributes.HasFieldMarshal));
}
}
}
}
Assert.Equal(expectedMarshalCount, metadataReader.GetTableRowCount(TableIndex.FieldMarshal));
}
internal static IEnumerable<string> GetFullTypeNames(MetadataReader metadataReader)
{
foreach (var typeDefHandle in metadataReader.TypeDefinitions)
{
var typeDef = metadataReader.GetTypeDefinition(typeDefHandle);
var ns = metadataReader.GetString(typeDef.Namespace);
var name = metadataReader.GetString(typeDef.Name);
yield return (ns.Length == 0) ? name : (ns + "." + name);
}
}
internal static IEnumerable<string> GetExportedTypesFullNames(MetadataReader metadataReader)
{
foreach (var typeDefHandle in metadataReader.ExportedTypes)
{
var typeDef = metadataReader.GetExportedType(typeDefHandle);
var ns = metadataReader.GetString(typeDef.Namespace);
var name = metadataReader.GetString(typeDef.Name);
yield return (ns.Length == 0) ? name : (ns + "." + name);
}
}
public static void VerifyMetadataEqualModuloMvid(Stream peStream1, Stream peStream2)
{
peStream1.Position = 0;
peStream2.Position = 0;
var peReader1 = new PEReader(peStream1);
var peReader2 = new PEReader(peStream2);
var md1 = peReader1.GetMetadata().GetContent();
var md2 = peReader2.GetMetadata().GetContent();
var mdReader1 = peReader1.GetMetadataReader();
var mdReader2 = peReader2.GetMetadataReader();
var mvidIndex1 = mdReader1.GetModuleDefinition().Mvid;
var mvidIndex2 = mdReader2.GetModuleDefinition().Mvid;
var mvidOffset1 = mdReader1.GetHeapMetadataOffset(HeapIndex.Guid) + 16 * (MetadataTokens.GetHeapOffset(mvidIndex1) - 1);
var mvidOffset2 = mdReader2.GetHeapMetadataOffset(HeapIndex.Guid) + 16 * (MetadataTokens.GetHeapOffset(mvidIndex2) - 1);
if (!md1.RemoveRange(mvidOffset1, 16).SequenceEqual(md1.RemoveRange(mvidOffset2, 16)))
{
var mdw1 = new StringWriter();
var mdw2 = new StringWriter();
new MetadataVisualizer(mdReader1, mdw1).Visualize();
new MetadataVisualizer(mdReader2, mdw2).Visualize();
mdw1.Flush();
mdw2.Flush();
AssertEx.AssertResultsEqual(mdw1.ToString(), mdw2.ToString());
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/CSharp/Portable/Symbols/Synthesized/SynthesizedSubmissionConstructor.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Diagnostics;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
internal sealed class SynthesizedSubmissionConstructor : SynthesizedInstanceConstructor
{
private readonly ImmutableArray<ParameterSymbol> _parameters;
internal SynthesizedSubmissionConstructor(NamedTypeSymbol containingType, BindingDiagnosticBag diagnostics)
: base(containingType)
{
Debug.Assert(containingType.TypeKind == TypeKind.Submission);
Debug.Assert(diagnostics != null);
var compilation = containingType.DeclaringCompilation;
var submissionArrayType = compilation.CreateArrayTypeSymbol(compilation.GetSpecialType(SpecialType.System_Object));
var useSiteInfo = submissionArrayType.GetUseSiteInfo();
diagnostics.Add(useSiteInfo, NoLocation.Singleton);
_parameters = ImmutableArray.Create<ParameterSymbol>(
SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(submissionArrayType), 0, RefKind.None, "submissionArray"));
}
public override ImmutableArray<ParameterSymbol> Parameters
{
get { return _parameters; }
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Diagnostics;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
internal sealed class SynthesizedSubmissionConstructor : SynthesizedInstanceConstructor
{
private readonly ImmutableArray<ParameterSymbol> _parameters;
internal SynthesizedSubmissionConstructor(NamedTypeSymbol containingType, BindingDiagnosticBag diagnostics)
: base(containingType)
{
Debug.Assert(containingType.TypeKind == TypeKind.Submission);
Debug.Assert(diagnostics != null);
var compilation = containingType.DeclaringCompilation;
var submissionArrayType = compilation.CreateArrayTypeSymbol(compilation.GetSpecialType(SpecialType.System_Object));
var useSiteInfo = submissionArrayType.GetUseSiteInfo();
diagnostics.Add(useSiteInfo, NoLocation.Singleton);
_parameters = ImmutableArray.Create<ParameterSymbol>(
SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(submissionArrayType), 0, RefKind.None, "submissionArray"));
}
public override ImmutableArray<ParameterSymbol> Parameters
{
get { return _parameters; }
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Core/Test/CodeModel/AbstractCodeClassTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading.Tasks
Imports Microsoft.VisualStudio.LanguageServices.Implementation.CodeModel.Interop
Namespace Microsoft.VisualStudio.LanguageServices.UnitTests.CodeModel
Public MustInherit Class AbstractCodeClassTests
Inherits AbstractCodeElementTests(Of EnvDTE80.CodeClass2)
Protected Overrides Function GetStartPointFunc(codeElement As EnvDTE80.CodeClass2) As Func(Of EnvDTE.vsCMPart, EnvDTE.TextPoint)
Return Function(part) codeElement.GetStartPoint(part)
End Function
Protected Overrides Function GetEndPointFunc(codeElement As EnvDTE80.CodeClass2) As Func(Of EnvDTE.vsCMPart, EnvDTE.TextPoint)
Return Function(part) codeElement.GetEndPoint(part)
End Function
Protected Overrides Function GetAccess(codeElement As EnvDTE80.CodeClass2) As EnvDTE.vsCMAccess
Return codeElement.Access
End Function
Protected Overrides Function GetAccessSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE.vsCMAccess)
Return Sub(access) codeElement.Access = access
End Function
Protected Overrides Function GetAttributes(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.Attributes
End Function
Protected Overrides Function GetBases(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.Bases
End Function
Protected Overrides Function GetClassKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE80.vsCMClassKind
Return codeElement.ClassKind
End Function
Protected Overrides Function GetClassKindSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE80.vsCMClassKind)
Return Sub(value) codeElement.ClassKind = value
End Function
Protected Overrides Function GetComment(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.Comment
End Function
Protected Overrides Function GetCommentSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of String)
Return Sub(value) codeElement.Comment = value
End Function
Protected Overrides Function GetDataTypeKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE80.vsCMDataTypeKind
Return codeElement.DataTypeKind
End Function
Protected Overrides Function GetDataTypeKindSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE80.vsCMDataTypeKind)
Return Sub(value) codeElement.DataTypeKind = value
End Function
Protected Overrides Function GetDocComment(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.DocComment
End Function
Protected Overrides Function GetDocCommentSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of String)
Return Sub(value) codeElement.DocComment = value
End Function
Protected Overrides Function GetImplementedInterfaces(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.ImplementedInterfaces
End Function
Protected Overrides Function GetInheritanceKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE80.vsCMInheritanceKind
Return codeElement.InheritanceKind
End Function
Protected Overrides Function GetInheritanceKindSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE80.vsCMInheritanceKind)
Return Sub(value) codeElement.InheritanceKind = value
End Function
Protected Overrides Function GetIsAbstract(codeElement As EnvDTE80.CodeClass2) As Boolean
Return codeElement.IsAbstract
End Function
Protected Overrides Function GetIsAbstractSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of Boolean)
Return Sub(value) codeElement.IsAbstract = value
End Function
Protected Overrides Function GetIsGeneric(codeElement As EnvDTE80.CodeClass2) As Boolean
Return codeElement.IsGeneric
End Function
Protected Overrides Function GetIsShared(codeElement As EnvDTE80.CodeClass2) As Boolean
Return codeElement.IsShared
End Function
Protected Overrides Function GetIsSharedSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of Boolean)
Return Sub(value) codeElement.IsShared = value
End Function
Protected Overrides Function GetFullName(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.FullName
End Function
Protected Overrides Function GetKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE.vsCMElement
Return codeElement.Kind
End Function
Protected Overrides Function GetName(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.Name
End Function
Protected Overrides Function GetNameSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of String)
Return Sub(name) codeElement.Name = name
End Function
Protected Overrides Function GetNamespace(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeNamespace
Return codeElement.Namespace
End Function
Protected Overrides Function GetParent(codeElement As EnvDTE80.CodeClass2) As Object
Return codeElement.Parent
End Function
Protected Overrides Function GetParts(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.Parts
End Function
Protected Overrides Function IsDerivedFrom(codeElement As EnvDTE80.CodeClass2, fullName As String) As Boolean
Return codeElement.IsDerivedFrom(fullName)
End Function
Protected Overrides Function AddAttribute(codeElement As EnvDTE80.CodeClass2, data As AttributeData) As EnvDTE.CodeAttribute
Return codeElement.AddAttribute(data.Name, data.Value, data.Position)
End Function
Protected Overrides Function AddEvent(codeElement As EnvDTE80.CodeClass2, data As EventData) As EnvDTE80.CodeEvent
Return codeElement.AddEvent(data.Name, data.FullDelegateName, data.CreatePropertyStyleEvent, data.Position, data.Access)
End Function
Protected Overrides Function AddFunction(codeElement As EnvDTE80.CodeClass2, data As FunctionData) As EnvDTE.CodeFunction
Return codeElement.AddFunction(data.Name, data.Kind, data.Type, data.Position, data.Access, data.Location)
End Function
Protected Overrides Function AddProperty(codeElement As EnvDTE80.CodeClass2, data As PropertyData) As EnvDTE.CodeProperty
Return codeElement.AddProperty(data.GetterName, data.PutterName, data.Type, data.Position, data.Access, data.Location)
End Function
Protected Overrides Function AddVariable(codeElement As EnvDTE80.CodeClass2, data As VariableData) As EnvDTE.CodeVariable
Return codeElement.AddVariable(data.Name, data.Type, data.Position, data.Access, data.Location)
End Function
Protected Overrides Sub RemoveChild(codeElement As EnvDTE80.CodeClass2, child As Object)
codeElement.RemoveMember(child)
End Sub
Protected Overrides Function AddBase(codeElement As EnvDTE80.CodeClass2, base As Object, position As Object) As EnvDTE.CodeElement
Return codeElement.AddBase(base, position)
End Function
Protected Overrides Sub RemoveBase(codeElement As EnvDTE80.CodeClass2, element As Object)
codeElement.RemoveBase(element)
End Sub
Protected Overrides Function AddImplementedInterface(codeElement As EnvDTE80.CodeClass2, base As Object, position As Object) As EnvDTE.CodeInterface
Return codeElement.AddImplementedInterface(base, position)
End Function
Protected Overrides Sub RemoveImplementedInterface(codeElement As EnvDTE80.CodeClass2, element As Object)
codeElement.RemoveInterface(element)
End Sub
Protected Sub TestGetBaseName(code As XElement, expectedBaseName As String)
TestElement(code,
Sub(codeClass)
Dim codeClassBase = TryCast(codeClass, ICodeClassBase)
Assert.NotNull(codeClassBase)
Dim baseName As String = Nothing
Dim hRetVal = codeClassBase.GetBaseName(baseName)
Assert.Equal(VSConstants.S_OK, hRetVal)
Assert.Equal(expectedBaseName, baseName)
End Sub)
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading.Tasks
Imports Microsoft.VisualStudio.LanguageServices.Implementation.CodeModel.Interop
Namespace Microsoft.VisualStudio.LanguageServices.UnitTests.CodeModel
Public MustInherit Class AbstractCodeClassTests
Inherits AbstractCodeElementTests(Of EnvDTE80.CodeClass2)
Protected Overrides Function GetStartPointFunc(codeElement As EnvDTE80.CodeClass2) As Func(Of EnvDTE.vsCMPart, EnvDTE.TextPoint)
Return Function(part) codeElement.GetStartPoint(part)
End Function
Protected Overrides Function GetEndPointFunc(codeElement As EnvDTE80.CodeClass2) As Func(Of EnvDTE.vsCMPart, EnvDTE.TextPoint)
Return Function(part) codeElement.GetEndPoint(part)
End Function
Protected Overrides Function GetAccess(codeElement As EnvDTE80.CodeClass2) As EnvDTE.vsCMAccess
Return codeElement.Access
End Function
Protected Overrides Function GetAccessSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE.vsCMAccess)
Return Sub(access) codeElement.Access = access
End Function
Protected Overrides Function GetAttributes(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.Attributes
End Function
Protected Overrides Function GetBases(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.Bases
End Function
Protected Overrides Function GetClassKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE80.vsCMClassKind
Return codeElement.ClassKind
End Function
Protected Overrides Function GetClassKindSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE80.vsCMClassKind)
Return Sub(value) codeElement.ClassKind = value
End Function
Protected Overrides Function GetComment(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.Comment
End Function
Protected Overrides Function GetCommentSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of String)
Return Sub(value) codeElement.Comment = value
End Function
Protected Overrides Function GetDataTypeKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE80.vsCMDataTypeKind
Return codeElement.DataTypeKind
End Function
Protected Overrides Function GetDataTypeKindSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE80.vsCMDataTypeKind)
Return Sub(value) codeElement.DataTypeKind = value
End Function
Protected Overrides Function GetDocComment(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.DocComment
End Function
Protected Overrides Function GetDocCommentSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of String)
Return Sub(value) codeElement.DocComment = value
End Function
Protected Overrides Function GetImplementedInterfaces(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.ImplementedInterfaces
End Function
Protected Overrides Function GetInheritanceKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE80.vsCMInheritanceKind
Return codeElement.InheritanceKind
End Function
Protected Overrides Function GetInheritanceKindSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of EnvDTE80.vsCMInheritanceKind)
Return Sub(value) codeElement.InheritanceKind = value
End Function
Protected Overrides Function GetIsAbstract(codeElement As EnvDTE80.CodeClass2) As Boolean
Return codeElement.IsAbstract
End Function
Protected Overrides Function GetIsAbstractSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of Boolean)
Return Sub(value) codeElement.IsAbstract = value
End Function
Protected Overrides Function GetIsGeneric(codeElement As EnvDTE80.CodeClass2) As Boolean
Return codeElement.IsGeneric
End Function
Protected Overrides Function GetIsShared(codeElement As EnvDTE80.CodeClass2) As Boolean
Return codeElement.IsShared
End Function
Protected Overrides Function GetIsSharedSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of Boolean)
Return Sub(value) codeElement.IsShared = value
End Function
Protected Overrides Function GetFullName(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.FullName
End Function
Protected Overrides Function GetKind(codeElement As EnvDTE80.CodeClass2) As EnvDTE.vsCMElement
Return codeElement.Kind
End Function
Protected Overrides Function GetName(codeElement As EnvDTE80.CodeClass2) As String
Return codeElement.Name
End Function
Protected Overrides Function GetNameSetter(codeElement As EnvDTE80.CodeClass2) As Action(Of String)
Return Sub(name) codeElement.Name = name
End Function
Protected Overrides Function GetNamespace(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeNamespace
Return codeElement.Namespace
End Function
Protected Overrides Function GetParent(codeElement As EnvDTE80.CodeClass2) As Object
Return codeElement.Parent
End Function
Protected Overrides Function GetParts(codeElement As EnvDTE80.CodeClass2) As EnvDTE.CodeElements
Return codeElement.Parts
End Function
Protected Overrides Function IsDerivedFrom(codeElement As EnvDTE80.CodeClass2, fullName As String) As Boolean
Return codeElement.IsDerivedFrom(fullName)
End Function
Protected Overrides Function AddAttribute(codeElement As EnvDTE80.CodeClass2, data As AttributeData) As EnvDTE.CodeAttribute
Return codeElement.AddAttribute(data.Name, data.Value, data.Position)
End Function
Protected Overrides Function AddEvent(codeElement As EnvDTE80.CodeClass2, data As EventData) As EnvDTE80.CodeEvent
Return codeElement.AddEvent(data.Name, data.FullDelegateName, data.CreatePropertyStyleEvent, data.Position, data.Access)
End Function
Protected Overrides Function AddFunction(codeElement As EnvDTE80.CodeClass2, data As FunctionData) As EnvDTE.CodeFunction
Return codeElement.AddFunction(data.Name, data.Kind, data.Type, data.Position, data.Access, data.Location)
End Function
Protected Overrides Function AddProperty(codeElement As EnvDTE80.CodeClass2, data As PropertyData) As EnvDTE.CodeProperty
Return codeElement.AddProperty(data.GetterName, data.PutterName, data.Type, data.Position, data.Access, data.Location)
End Function
Protected Overrides Function AddVariable(codeElement As EnvDTE80.CodeClass2, data As VariableData) As EnvDTE.CodeVariable
Return codeElement.AddVariable(data.Name, data.Type, data.Position, data.Access, data.Location)
End Function
Protected Overrides Sub RemoveChild(codeElement As EnvDTE80.CodeClass2, child As Object)
codeElement.RemoveMember(child)
End Sub
Protected Overrides Function AddBase(codeElement As EnvDTE80.CodeClass2, base As Object, position As Object) As EnvDTE.CodeElement
Return codeElement.AddBase(base, position)
End Function
Protected Overrides Sub RemoveBase(codeElement As EnvDTE80.CodeClass2, element As Object)
codeElement.RemoveBase(element)
End Sub
Protected Overrides Function AddImplementedInterface(codeElement As EnvDTE80.CodeClass2, base As Object, position As Object) As EnvDTE.CodeInterface
Return codeElement.AddImplementedInterface(base, position)
End Function
Protected Overrides Sub RemoveImplementedInterface(codeElement As EnvDTE80.CodeClass2, element As Object)
codeElement.RemoveInterface(element)
End Sub
Protected Sub TestGetBaseName(code As XElement, expectedBaseName As String)
TestElement(code,
Sub(codeClass)
Dim codeClassBase = TryCast(codeClass, ICodeClassBase)
Assert.NotNull(codeClassBase)
Dim baseName As String = Nothing
Dim hRetVal = codeClassBase.GetBaseName(baseName)
Assert.Equal(VSConstants.S_OK, hRetVal)
Assert.Equal(expectedBaseName, baseName)
End Sub)
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Portable/Lowering/LocalRewriter/LocalRewriter_ConditionalAccess.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Immutable
Imports System.Diagnostics
Imports System.Runtime.InteropServices
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports TypeKind = Microsoft.CodeAnalysis.TypeKind
Namespace Microsoft.CodeAnalysis.VisualBasic
Partial Friend NotInheritable Class LocalRewriter
Private Shared Function ShouldCaptureConditionalAccessReceiver(receiver As BoundExpression) As Boolean
Select Case receiver.Kind
Case BoundKind.MeReference
Return False
Case BoundKind.Parameter
Return DirectCast(receiver, BoundParameter).ParameterSymbol.IsByRef
Case BoundKind.Local
Return DirectCast(receiver, BoundLocal).LocalSymbol.IsByRef
Case Else
Return Not receiver.IsDefaultValue()
End Select
End Function
Public Overrides Function VisitConditionalAccess(node As BoundConditionalAccess) As BoundNode
Debug.Assert(node.Type IsNot Nothing)
Dim rewrittenReceiver As BoundExpression = VisitExpressionNode(node.Receiver)
Dim receiverType As TypeSymbol = rewrittenReceiver.Type
Dim receiverOrCondition As BoundExpression
Dim placeholderReplacement As BoundExpression
Dim newPlaceholderId As Integer = 0
Dim newPlaceHolder As BoundConditionalAccessReceiverPlaceholder
Dim captureReceiver As Boolean
Dim temp As LocalSymbol = Nothing
Dim assignment As BoundExpression = Nothing
Dim needWhenNotNullPart As Boolean = True
Dim needWhenNullPart As Boolean = True
Dim factory = New SyntheticBoundNodeFactory(_topMethod, _currentMethodOrLambda, node.Syntax, _compilationState, _diagnostics)
If receiverType.IsNullableType() Then
' if( receiver.HasValue, receiver.GetValueOrDefault(). ... -> to Nullable, Nothing)
If HasNoValue(rewrittenReceiver) Then
' Nothing
receiverOrCondition = Nothing
needWhenNotNullPart = False
placeholderReplacement = Nothing
ElseIf HasValue(rewrittenReceiver) Then
' receiver. ... -> to Nullable
receiverOrCondition = Nothing
needWhenNullPart = False
placeholderReplacement = NullableValueOrDefault(rewrittenReceiver)
Else
Dim first As BoundExpression
If ShouldCaptureConditionalAccessReceiver(rewrittenReceiver) Then
temp = New SynthesizedLocal(Me._currentMethodOrLambda, receiverType, SynthesizedLocalKind.LoweringTemp)
assignment = factory.AssignmentExpression(factory.Local(temp, isLValue:=True), rewrittenReceiver.MakeRValue())
first = factory.Local(temp, isLValue:=True)
placeholderReplacement = factory.Local(temp, isLValue:=True)
Else
first = rewrittenReceiver
placeholderReplacement = rewrittenReceiver
End If
receiverOrCondition = NullableHasValue(first)
placeholderReplacement = NullableValueOrDefault(placeholderReplacement)
End If
captureReceiver = False
newPlaceHolder = Nothing
Else
If rewrittenReceiver.IsConstant Then
receiverOrCondition = Nothing
captureReceiver = False
newPlaceHolder = Nothing
If rewrittenReceiver.ConstantValueOpt.IsNothing Then
' Nothing
placeholderReplacement = Nothing
needWhenNotNullPart = False
Else
' receiver. ... -> to Nullable
placeholderReplacement = rewrittenReceiver.MakeRValue()
needWhenNullPart = False
End If
Else
' if( receiver IsNot Nothing, receiver. ... -> to Nullable, Nothing)
receiverOrCondition = rewrittenReceiver
captureReceiver = ShouldCaptureConditionalAccessReceiver(rewrittenReceiver)
Me._conditionalAccessReceiverPlaceholderId += 1
newPlaceholderId = Me._conditionalAccessReceiverPlaceholderId
Debug.Assert(newPlaceholderId <> 0)
newPlaceHolder = New BoundConditionalAccessReceiverPlaceholder(node.Placeholder.Syntax, newPlaceholderId, node.Placeholder.Type)
placeholderReplacement = newPlaceHolder
End If
End If
Dim whenNotNull As BoundExpression
Dim accessResultType As TypeSymbol = node.AccessExpression.Type
If needWhenNotNullPart Then
AddPlaceholderReplacement(node.Placeholder, placeholderReplacement)
whenNotNull = VisitExpressionNode(node.AccessExpression)
RemovePlaceholderReplacement(node.Placeholder)
Else
whenNotNull = Nothing ' We should simply produce Nothing as the result, if we need the result.
End If
Dim whenNull As BoundExpression
If node.Type.IsVoidType() Then
whenNull = Nothing
Else
If needWhenNotNullPart AndAlso Not accessResultType.IsNullableType() AndAlso accessResultType.IsValueType Then
whenNotNull = WrapInNullable(whenNotNull, node.Type)
End If
If needWhenNullPart Then
whenNull = If(node.Type.IsNullableType(), NullableNull(node.Syntax, node.Type), factory.Null(node.Type))
Else
whenNull = Nothing
End If
End If
Dim result As BoundExpression
Debug.Assert(needWhenNotNullPart OrElse needWhenNullPart)
If needWhenNotNullPart Then
If needWhenNullPart Then
result = New BoundLoweredConditionalAccess(node.Syntax, receiverOrCondition, captureReceiver, newPlaceholderId, whenNotNull, whenNull, node.Type)
Else
Debug.Assert(receiverOrCondition Is Nothing)
Debug.Assert(newPlaceHolder Is Nothing)
result = whenNotNull
End If
ElseIf whenNull IsNot Nothing Then
Debug.Assert(receiverOrCondition Is Nothing)
result = whenNull
Else
Debug.Assert(receiverOrCondition Is Nothing)
Debug.Assert(node.Type.IsVoidType())
result = New BoundSequence(node.Syntax, ImmutableArray(Of LocalSymbol).Empty, ImmutableArray(Of BoundExpression).Empty, Nothing, node.Type)
End If
If temp IsNot Nothing Then
If result.Type.IsVoidType() Then
result = New BoundSequence(node.Syntax, ImmutableArray.Create(temp), ImmutableArray.Create(assignment, result), Nothing, result.Type)
Else
result = New BoundSequence(node.Syntax, ImmutableArray.Create(temp), ImmutableArray.Create(assignment), result, result.Type)
End If
End If
Return result
End Function
Private Shared Function IsConditionalAccess(operand As BoundExpression, <Out> ByRef whenNotNull As BoundExpression, <Out> ByRef whenNull As BoundExpression) As Boolean
If operand.Kind = BoundKind.Sequence Then
Dim sequence = DirectCast(operand, BoundSequence)
If sequence.ValueOpt Is Nothing Then
whenNotNull = Nothing
whenNull = Nothing
Return False
End If
operand = sequence.ValueOpt
End If
If operand.Kind = BoundKind.LoweredConditionalAccess Then
Dim conditional = DirectCast(operand, BoundLoweredConditionalAccess)
whenNotNull = conditional.WhenNotNull
whenNull = conditional.WhenNullOpt
Return True
End If
whenNotNull = Nothing
whenNull = Nothing
Return False
End Function
Private Shared Function UpdateConditionalAccess(operand As BoundExpression, whenNotNull As BoundExpression, whenNull As BoundExpression) As BoundExpression
Dim sequence As BoundSequence
If operand.Kind = BoundKind.Sequence Then
sequence = DirectCast(operand, BoundSequence)
operand = sequence.ValueOpt
Else
sequence = Nothing
End If
Dim conditional = DirectCast(operand, BoundLoweredConditionalAccess)
operand = conditional.Update(conditional.ReceiverOrCondition,
conditional.CaptureReceiver,
conditional.PlaceholderId,
whenNotNull,
whenNull,
whenNotNull.Type)
If sequence Is Nothing Then
Return operand
End If
Return sequence.Update(sequence.Locals, sequence.SideEffects, operand, operand.Type)
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Immutable
Imports System.Diagnostics
Imports System.Runtime.InteropServices
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports TypeKind = Microsoft.CodeAnalysis.TypeKind
Namespace Microsoft.CodeAnalysis.VisualBasic
Partial Friend NotInheritable Class LocalRewriter
Private Shared Function ShouldCaptureConditionalAccessReceiver(receiver As BoundExpression) As Boolean
Select Case receiver.Kind
Case BoundKind.MeReference
Return False
Case BoundKind.Parameter
Return DirectCast(receiver, BoundParameter).ParameterSymbol.IsByRef
Case BoundKind.Local
Return DirectCast(receiver, BoundLocal).LocalSymbol.IsByRef
Case Else
Return Not receiver.IsDefaultValue()
End Select
End Function
Public Overrides Function VisitConditionalAccess(node As BoundConditionalAccess) As BoundNode
Debug.Assert(node.Type IsNot Nothing)
Dim rewrittenReceiver As BoundExpression = VisitExpressionNode(node.Receiver)
Dim receiverType As TypeSymbol = rewrittenReceiver.Type
Dim receiverOrCondition As BoundExpression
Dim placeholderReplacement As BoundExpression
Dim newPlaceholderId As Integer = 0
Dim newPlaceHolder As BoundConditionalAccessReceiverPlaceholder
Dim captureReceiver As Boolean
Dim temp As LocalSymbol = Nothing
Dim assignment As BoundExpression = Nothing
Dim needWhenNotNullPart As Boolean = True
Dim needWhenNullPart As Boolean = True
Dim factory = New SyntheticBoundNodeFactory(_topMethod, _currentMethodOrLambda, node.Syntax, _compilationState, _diagnostics)
If receiverType.IsNullableType() Then
' if( receiver.HasValue, receiver.GetValueOrDefault(). ... -> to Nullable, Nothing)
If HasNoValue(rewrittenReceiver) Then
' Nothing
receiverOrCondition = Nothing
needWhenNotNullPart = False
placeholderReplacement = Nothing
ElseIf HasValue(rewrittenReceiver) Then
' receiver. ... -> to Nullable
receiverOrCondition = Nothing
needWhenNullPart = False
placeholderReplacement = NullableValueOrDefault(rewrittenReceiver)
Else
Dim first As BoundExpression
If ShouldCaptureConditionalAccessReceiver(rewrittenReceiver) Then
temp = New SynthesizedLocal(Me._currentMethodOrLambda, receiverType, SynthesizedLocalKind.LoweringTemp)
assignment = factory.AssignmentExpression(factory.Local(temp, isLValue:=True), rewrittenReceiver.MakeRValue())
first = factory.Local(temp, isLValue:=True)
placeholderReplacement = factory.Local(temp, isLValue:=True)
Else
first = rewrittenReceiver
placeholderReplacement = rewrittenReceiver
End If
receiverOrCondition = NullableHasValue(first)
placeholderReplacement = NullableValueOrDefault(placeholderReplacement)
End If
captureReceiver = False
newPlaceHolder = Nothing
Else
If rewrittenReceiver.IsConstant Then
receiverOrCondition = Nothing
captureReceiver = False
newPlaceHolder = Nothing
If rewrittenReceiver.ConstantValueOpt.IsNothing Then
' Nothing
placeholderReplacement = Nothing
needWhenNotNullPart = False
Else
' receiver. ... -> to Nullable
placeholderReplacement = rewrittenReceiver.MakeRValue()
needWhenNullPart = False
End If
Else
' if( receiver IsNot Nothing, receiver. ... -> to Nullable, Nothing)
receiverOrCondition = rewrittenReceiver
captureReceiver = ShouldCaptureConditionalAccessReceiver(rewrittenReceiver)
Me._conditionalAccessReceiverPlaceholderId += 1
newPlaceholderId = Me._conditionalAccessReceiverPlaceholderId
Debug.Assert(newPlaceholderId <> 0)
newPlaceHolder = New BoundConditionalAccessReceiverPlaceholder(node.Placeholder.Syntax, newPlaceholderId, node.Placeholder.Type)
placeholderReplacement = newPlaceHolder
End If
End If
Dim whenNotNull As BoundExpression
Dim accessResultType As TypeSymbol = node.AccessExpression.Type
If needWhenNotNullPart Then
AddPlaceholderReplacement(node.Placeholder, placeholderReplacement)
whenNotNull = VisitExpressionNode(node.AccessExpression)
RemovePlaceholderReplacement(node.Placeholder)
Else
whenNotNull = Nothing ' We should simply produce Nothing as the result, if we need the result.
End If
Dim whenNull As BoundExpression
If node.Type.IsVoidType() Then
whenNull = Nothing
Else
If needWhenNotNullPart AndAlso Not accessResultType.IsNullableType() AndAlso accessResultType.IsValueType Then
whenNotNull = WrapInNullable(whenNotNull, node.Type)
End If
If needWhenNullPart Then
whenNull = If(node.Type.IsNullableType(), NullableNull(node.Syntax, node.Type), factory.Null(node.Type))
Else
whenNull = Nothing
End If
End If
Dim result As BoundExpression
Debug.Assert(needWhenNotNullPart OrElse needWhenNullPart)
If needWhenNotNullPart Then
If needWhenNullPart Then
result = New BoundLoweredConditionalAccess(node.Syntax, receiverOrCondition, captureReceiver, newPlaceholderId, whenNotNull, whenNull, node.Type)
Else
Debug.Assert(receiverOrCondition Is Nothing)
Debug.Assert(newPlaceHolder Is Nothing)
result = whenNotNull
End If
ElseIf whenNull IsNot Nothing Then
Debug.Assert(receiverOrCondition Is Nothing)
result = whenNull
Else
Debug.Assert(receiverOrCondition Is Nothing)
Debug.Assert(node.Type.IsVoidType())
result = New BoundSequence(node.Syntax, ImmutableArray(Of LocalSymbol).Empty, ImmutableArray(Of BoundExpression).Empty, Nothing, node.Type)
End If
If temp IsNot Nothing Then
If result.Type.IsVoidType() Then
result = New BoundSequence(node.Syntax, ImmutableArray.Create(temp), ImmutableArray.Create(assignment, result), Nothing, result.Type)
Else
result = New BoundSequence(node.Syntax, ImmutableArray.Create(temp), ImmutableArray.Create(assignment), result, result.Type)
End If
End If
Return result
End Function
Private Shared Function IsConditionalAccess(operand As BoundExpression, <Out> ByRef whenNotNull As BoundExpression, <Out> ByRef whenNull As BoundExpression) As Boolean
If operand.Kind = BoundKind.Sequence Then
Dim sequence = DirectCast(operand, BoundSequence)
If sequence.ValueOpt Is Nothing Then
whenNotNull = Nothing
whenNull = Nothing
Return False
End If
operand = sequence.ValueOpt
End If
If operand.Kind = BoundKind.LoweredConditionalAccess Then
Dim conditional = DirectCast(operand, BoundLoweredConditionalAccess)
whenNotNull = conditional.WhenNotNull
whenNull = conditional.WhenNullOpt
Return True
End If
whenNotNull = Nothing
whenNull = Nothing
Return False
End Function
Private Shared Function UpdateConditionalAccess(operand As BoundExpression, whenNotNull As BoundExpression, whenNull As BoundExpression) As BoundExpression
Dim sequence As BoundSequence
If operand.Kind = BoundKind.Sequence Then
sequence = DirectCast(operand, BoundSequence)
operand = sequence.ValueOpt
Else
sequence = Nothing
End If
Dim conditional = DirectCast(operand, BoundLoweredConditionalAccess)
operand = conditional.Update(conditional.ReceiverOrCondition,
conditional.CaptureReceiver,
conditional.PlaceholderId,
whenNotNull,
whenNull,
whenNotNull.Type)
If sequence Is Nothing Then
Return operand
End If
Return sequence.Update(sequence.Locals, sequence.SideEffects, operand, operand.Type)
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/VisualBasicTest/InlineMethod/VisualBasicInlineMethodTests_CrossLanguage.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.CodeRefactorings
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces
Imports Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.CodeRefactorings
Imports Microsoft.CodeAnalysis.VisualBasic.CodeRefactorings.InlineTemporary
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.InlineMethod
Public Class VisualBasicInlineMethodTests_CrossLanguage
Inherits AbstractVisualBasicCodeActionTest
Protected Overrides Function CreateCodeRefactoringProvider(workspace As Workspace, parameters As TestParameters) As CodeRefactoringProvider
Dim testWorkspace = DirectCast(workspace, TestWorkspace)
Return testWorkspace.ExportProvider.GetExportedValue(Of VisualBasicInlineMethodRefactoringProvider)
End Function
Private Async Function TestNoActionIsProvided(initialMarkup As String) As Task
Dim workspace = CreateWorkspaceFromOptions(initialMarkup, Nothing)
Dim actions = Await GetCodeActionsAsync(workspace, Nothing).ConfigureAwait(False)
Assert.True(actions.Item1.IsEmpty())
End Function
' Because this issue: https://github.com/dotnet/roslyn-sdk/issues/464
' it is hard to test cross language scenario.
' After it is resolved then this test should be merged to the other test class
<Fact>
Public Async Function TestCrossLanguageInline() As Task
Dim input = "
<Workspace>
<Project Language=""C#"" AssemblyName=""CSAssembly"" CommonReferences=""true"">
<Document>
public class TestClass
{
private void Callee()
{
}
}
</Document>
</Project>
<Project Language=""Visual Basic"" AssemblyName=""VBAssembly"" CommonReferences=""true"">
<ProjectReference>CSAssembly</ProjectReference>
<Document>
Public Class VBClass
Private Sub Caller()
Dim x = new TestClass()
x.Cal[||]lee()
End Sub
End Class
</Document>
</Project>
</Workspace>"
Await TestNoActionIsProvided(input).ConfigureAwait(False)
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.CodeRefactorings
Imports Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces
Imports Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.CodeRefactorings
Imports Microsoft.CodeAnalysis.VisualBasic.CodeRefactorings.InlineTemporary
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.InlineMethod
Public Class VisualBasicInlineMethodTests_CrossLanguage
Inherits AbstractVisualBasicCodeActionTest
Protected Overrides Function CreateCodeRefactoringProvider(workspace As Workspace, parameters As TestParameters) As CodeRefactoringProvider
Dim testWorkspace = DirectCast(workspace, TestWorkspace)
Return testWorkspace.ExportProvider.GetExportedValue(Of VisualBasicInlineMethodRefactoringProvider)
End Function
Private Async Function TestNoActionIsProvided(initialMarkup As String) As Task
Dim workspace = CreateWorkspaceFromOptions(initialMarkup, Nothing)
Dim actions = Await GetCodeActionsAsync(workspace, Nothing).ConfigureAwait(False)
Assert.True(actions.Item1.IsEmpty())
End Function
' Because this issue: https://github.com/dotnet/roslyn-sdk/issues/464
' it is hard to test cross language scenario.
' After it is resolved then this test should be merged to the other test class
<Fact>
Public Async Function TestCrossLanguageInline() As Task
Dim input = "
<Workspace>
<Project Language=""C#"" AssemblyName=""CSAssembly"" CommonReferences=""true"">
<Document>
public class TestClass
{
private void Callee()
{
}
}
</Document>
</Project>
<Project Language=""Visual Basic"" AssemblyName=""VBAssembly"" CommonReferences=""true"">
<ProjectReference>CSAssembly</ProjectReference>
<Document>
Public Class VBClass
Private Sub Caller()
Dim x = new TestClass()
x.Cal[||]lee()
End Sub
End Class
</Document>
</Project>
</Workspace>"
Await TestNoActionIsProvided(input).ConfigureAwait(False)
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/CSharp/Portable/Symbols/Source/SourceEventSymbol.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
using System.Collections.Generic;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.CSharp.Emit;
using System.Linq;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
/// <summary>
/// This class represents an event declared in source. It may be either
/// field-like (see <see cref="SourceFieldLikeEventSymbol"/>) or property-like (see
/// <see cref="SourceCustomEventSymbol"/>).
/// </summary>
internal abstract class SourceEventSymbol : EventSymbol, IAttributeTargetSymbol
{
private readonly Location _location;
private readonly SyntaxReference _syntaxRef;
private readonly DeclarationModifiers _modifiers;
internal readonly SourceMemberContainerTypeSymbol containingType;
private SymbolCompletionState _state;
private CustomAttributesBag<CSharpAttributeData>? _lazyCustomAttributesBag;
private string? _lazyDocComment;
private string? _lazyExpandedDocComment;
private OverriddenOrHiddenMembersResult? _lazyOverriddenOrHiddenMembers;
private ThreeState _lazyIsWindowsRuntimeEvent = ThreeState.Unknown;
// TODO: CLSCompliantAttribute
internal SourceEventSymbol(
SourceMemberContainerTypeSymbol containingType,
CSharpSyntaxNode syntax,
SyntaxTokenList modifiers,
bool isFieldLike,
ExplicitInterfaceSpecifierSyntax? interfaceSpecifierSyntaxOpt,
SyntaxToken nameTokenSyntax,
BindingDiagnosticBag diagnostics)
{
_location = nameTokenSyntax.GetLocation();
this.containingType = containingType;
_syntaxRef = syntax.GetReference();
var isExplicitInterfaceImplementation = interfaceSpecifierSyntaxOpt != null;
bool modifierErrors;
_modifiers = MakeModifiers(modifiers, isExplicitInterfaceImplementation, isFieldLike, _location, diagnostics, out modifierErrors);
this.CheckAccessibility(_location, diagnostics, isExplicitInterfaceImplementation);
}
internal sealed override bool RequiresCompletion
{
get { return true; }
}
internal sealed override bool HasComplete(CompletionPart part)
{
return _state.HasComplete(part);
}
internal override void ForceComplete(SourceLocation? locationOpt, CancellationToken cancellationToken)
{
_state.DefaultForceComplete(this, cancellationToken);
}
public abstract override string Name { get; }
public abstract override MethodSymbol? AddMethod { get; }
public abstract override MethodSymbol? RemoveMethod { get; }
public abstract override ImmutableArray<EventSymbol> ExplicitInterfaceImplementations { get; }
public abstract override TypeWithAnnotations TypeWithAnnotations { get; }
public sealed override Symbol ContainingSymbol
{
get
{
return containingType;
}
}
public override NamedTypeSymbol ContainingType
{
get
{
return this.containingType;
}
}
internal override LexicalSortKey GetLexicalSortKey()
{
return new LexicalSortKey(_location, this.DeclaringCompilation);
}
public sealed override ImmutableArray<Location> Locations
{
get
{
return ImmutableArray.Create(_location);
}
}
public sealed override ImmutableArray<SyntaxReference> DeclaringSyntaxReferences
{
get
{
return ImmutableArray.Create<SyntaxReference>(_syntaxRef);
}
}
/// <summary>
/// Gets the syntax list of custom attributes applied on the event symbol.
/// </summary>
internal SyntaxList<AttributeListSyntax> AttributeDeclarationSyntaxList
{
get
{
if (this.containingType.AnyMemberHasAttributes)
{
var syntax = this.CSharpSyntaxNode;
if (syntax != null)
{
switch (syntax.Kind())
{
case SyntaxKind.EventDeclaration:
return ((EventDeclarationSyntax)syntax).AttributeLists;
case SyntaxKind.VariableDeclarator:
Debug.Assert(syntax.Parent!.Parent is object);
return ((EventFieldDeclarationSyntax)syntax.Parent.Parent).AttributeLists;
default:
throw ExceptionUtilities.UnexpectedValue(syntax.Kind());
}
}
}
return default;
}
}
IAttributeTargetSymbol IAttributeTargetSymbol.AttributesOwner
{
get { return this; }
}
AttributeLocation IAttributeTargetSymbol.DefaultAttributeLocation
{
get { return AttributeLocation.Event; }
}
AttributeLocation IAttributeTargetSymbol.AllowedAttributeLocations
{
get
{
return this.AllowedAttributeLocations;
}
}
protected abstract AttributeLocation AllowedAttributeLocations
{
get;
}
/// <summary>
/// Returns a bag of applied custom attributes and data decoded from well-known attributes. Returns null if there are no attributes applied on the symbol.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
private CustomAttributesBag<CSharpAttributeData> GetAttributesBag()
{
if ((_lazyCustomAttributesBag == null || !_lazyCustomAttributesBag.IsSealed) &&
LoadAndValidateAttributes(OneOrMany.Create(this.AttributeDeclarationSyntaxList), ref _lazyCustomAttributesBag))
{
DeclaringCompilation.SymbolDeclaredEvent(this);
var wasCompletedThisThread = _state.NotePartComplete(CompletionPart.Attributes);
Debug.Assert(wasCompletedThisThread);
}
RoslynDebug.AssertNotNull(_lazyCustomAttributesBag);
return _lazyCustomAttributesBag;
}
/// <summary>
/// Gets the attributes applied on this symbol.
/// Returns an empty array if there are no attributes.
/// </summary>
/// <remarks>
/// NOTE: This method should always be kept as a sealed override.
/// If you want to override attribute binding logic for a sub-class, then override <see cref="GetAttributesBag"/> method.
/// </remarks>
public sealed override ImmutableArray<CSharpAttributeData> GetAttributes()
{
return this.GetAttributesBag().Attributes;
}
/// <summary>
/// Returns data decoded from well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
protected CommonEventWellKnownAttributeData GetDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (CommonEventWellKnownAttributeData)attributesBag.DecodedWellKnownAttributeData;
}
/// <summary>
/// Returns data decoded from special early bound well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
internal CommonEventEarlyWellKnownAttributeData GetEarlyDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (CommonEventEarlyWellKnownAttributeData)attributesBag.EarlyDecodedWellKnownAttributeData;
}
internal override CSharpAttributeData? EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments)
{
CSharpAttributeData? boundAttribute;
ObsoleteAttributeData? obsoleteData;
if (EarlyDecodeDeprecatedOrExperimentalOrObsoleteAttribute(ref arguments, out boundAttribute, out obsoleteData))
{
if (obsoleteData != null)
{
arguments.GetOrCreateData<CommonEventEarlyWellKnownAttributeData>().ObsoleteAttributeData = obsoleteData;
}
return boundAttribute;
}
return base.EarlyDecodeWellKnownAttribute(ref arguments);
}
/// <summary>
/// Returns data decoded from Obsolete attribute or null if there is no Obsolete attribute.
/// This property returns ObsoleteAttributeData.Uninitialized if attribute arguments haven't been decoded yet.
/// </summary>
internal override ObsoleteAttributeData? ObsoleteAttributeData
{
get
{
if (!this.containingType.AnyMemberHasAttributes)
{
return null;
}
var lazyCustomAttributesBag = _lazyCustomAttributesBag;
if (lazyCustomAttributesBag != null && lazyCustomAttributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
var data = (CommonEventEarlyWellKnownAttributeData)lazyCustomAttributesBag.EarlyDecodedWellKnownAttributeData;
return data != null ? data.ObsoleteAttributeData : null;
}
return ObsoleteAttributeData.Uninitialized;
}
}
internal sealed override void DecodeWellKnownAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments)
{
var attribute = arguments.Attribute;
Debug.Assert(!attribute.HasErrors);
Debug.Assert(arguments.SymbolPart == AttributeLocation.None);
var diagnostics = (BindingDiagnosticBag)arguments.Diagnostics;
if (attribute.IsTargetAttribute(this, AttributeDescription.SpecialNameAttribute))
{
arguments.GetOrCreateData<CommonEventWellKnownAttributeData>().HasSpecialNameAttribute = true;
}
else if (ReportExplicitUseOfReservedAttributes(in arguments, ReservedAttributes.NullableAttribute | ReservedAttributes.NativeIntegerAttribute | ReservedAttributes.TupleElementNamesAttribute))
{
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.ExcludeFromCodeCoverageAttribute))
{
arguments.GetOrCreateData<CommonEventWellKnownAttributeData>().HasExcludeFromCodeCoverageAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.SkipLocalsInitAttribute))
{
CSharpAttributeData.DecodeSkipLocalsInitAttribute<CommonEventWellKnownAttributeData>(DeclaringCompilation, ref arguments);
}
}
internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<SynthesizedAttributeData>? attributes)
{
base.AddSynthesizedAttributes(moduleBuilder, ref attributes);
var compilation = this.DeclaringCompilation;
var type = this.TypeWithAnnotations;
if (type.Type.ContainsDynamic())
{
AddSynthesizedAttribute(ref attributes, compilation.SynthesizeDynamicAttribute(type.Type, type.CustomModifiers.Length));
}
if (type.Type.ContainsNativeInteger())
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNativeIntegerAttribute(this, type.Type));
}
if (type.Type.ContainsTupleNames())
{
AddSynthesizedAttribute(ref attributes,
DeclaringCompilation.SynthesizeTupleNamesAttribute(type.Type));
}
if (compilation.ShouldEmitNullableAttributes(this))
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNullableAttributeIfNecessary(this, containingType.GetNullableContextValue(), type));
}
}
internal sealed override bool IsDirectlyExcludedFromCodeCoverage =>
GetDecodedWellKnownAttributeData()?.HasExcludeFromCodeCoverageAttribute == true;
internal sealed override bool HasSpecialName
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasSpecialNameAttribute;
}
}
public bool HasSkipLocalsInitAttribute
=> GetDecodedWellKnownAttributeData()?.HasSkipLocalsInitAttribute == true;
public sealed override bool IsAbstract
{
get { return (_modifiers & DeclarationModifiers.Abstract) != 0; }
}
public sealed override bool IsExtern
{
get { return (_modifiers & DeclarationModifiers.Extern) != 0; }
}
public sealed override bool IsStatic
{
get { return (_modifiers & DeclarationModifiers.Static) != 0; }
}
public sealed override bool IsOverride
{
get { return (_modifiers & DeclarationModifiers.Override) != 0; }
}
public sealed override bool IsSealed
{
get { return (_modifiers & DeclarationModifiers.Sealed) != 0; }
}
public sealed override bool IsVirtual
{
get { return (_modifiers & DeclarationModifiers.Virtual) != 0; }
}
internal bool IsReadOnly
{
get { return (_modifiers & DeclarationModifiers.ReadOnly) != 0; }
}
public sealed override Accessibility DeclaredAccessibility
{
get { return ModifierUtils.EffectiveAccessibility(_modifiers); }
}
internal sealed override bool MustCallMethodsDirectly
{
get { return false; } // always false for source events
}
internal SyntaxReference SyntaxReference
{
get { return _syntaxRef; }
}
internal CSharpSyntaxNode CSharpSyntaxNode
{
get { return (CSharpSyntaxNode)_syntaxRef.GetSyntax(); }
}
internal SyntaxTree SyntaxTree
{
get { return _syntaxRef.SyntaxTree; }
}
internal bool IsNew
{
get { return (_modifiers & DeclarationModifiers.New) != 0; }
}
internal DeclarationModifiers Modifiers
{
get { return _modifiers; }
}
private void CheckAccessibility(Location location, BindingDiagnosticBag diagnostics, bool isExplicitInterfaceImplementation)
{
var info = ModifierUtils.CheckAccessibility(_modifiers, this, isExplicitInterfaceImplementation);
if (info != null)
{
diagnostics.Add(new CSDiagnostic(info, location));
}
}
private DeclarationModifiers MakeModifiers(SyntaxTokenList modifiers, bool explicitInterfaceImplementation,
bool isFieldLike, Location location,
BindingDiagnosticBag diagnostics, out bool modifierErrors)
{
bool isInterface = this.ContainingType.IsInterface;
var defaultAccess = isInterface && !explicitInterfaceImplementation ? DeclarationModifiers.Public : DeclarationModifiers.Private;
var defaultInterfaceImplementationModifiers = DeclarationModifiers.None;
// Check that the set of modifiers is allowed
var allowedModifiers = DeclarationModifiers.Unsafe;
if (!explicitInterfaceImplementation)
{
allowedModifiers |= DeclarationModifiers.New |
DeclarationModifiers.Sealed |
DeclarationModifiers.Abstract |
DeclarationModifiers.Static |
DeclarationModifiers.Virtual |
DeclarationModifiers.AccessibilityMask;
if (!isInterface)
{
allowedModifiers |= DeclarationModifiers.Override;
}
else
{
// This is needed to make sure we can detect 'public' modifier specified explicitly and
// check it against language version below.
defaultAccess = DeclarationModifiers.None;
allowedModifiers |= DeclarationModifiers.Extern;
defaultInterfaceImplementationModifiers |= DeclarationModifiers.Sealed |
DeclarationModifiers.Abstract |
DeclarationModifiers.Static |
DeclarationModifiers.Virtual |
DeclarationModifiers.Extern |
DeclarationModifiers.AccessibilityMask;
}
}
else
{
Debug.Assert(explicitInterfaceImplementation);
if (isInterface)
{
allowedModifiers |= DeclarationModifiers.Abstract;
}
else
{
allowedModifiers |= DeclarationModifiers.Static;
}
}
if (this.ContainingType.IsStructType())
{
allowedModifiers |= DeclarationModifiers.ReadOnly;
}
if (!isInterface)
{
allowedModifiers |= DeclarationModifiers.Extern;
}
var mods = ModifierUtils.MakeAndCheckNontypeMemberModifiers(modifiers, defaultAccess, allowedModifiers, location, diagnostics, out modifierErrors);
ModifierUtils.CheckFeatureAvailabilityForStaticAbstractMembersInInterfacesIfNeeded(mods, explicitInterfaceImplementation, location, diagnostics);
this.CheckUnsafeModifier(mods, diagnostics);
ModifierUtils.ReportDefaultInterfaceImplementationModifiers(!isFieldLike, mods,
defaultInterfaceImplementationModifiers,
location, diagnostics);
// Let's overwrite modifiers for interface events with what they are supposed to be.
// Proper errors must have been reported by now.
if (isInterface)
{
mods = ModifierUtils.AdjustModifiersForAnInterfaceMember(mods, !isFieldLike, explicitInterfaceImplementation);
}
return mods;
}
protected void CheckModifiersAndType(BindingDiagnosticBag diagnostics)
{
Debug.Assert(!IsStatic || (!IsVirtual && !IsOverride)); // Otherwise 'virtual' and 'override' should have been reported and cleared earlier.
Location location = this.Locations[0];
var useSiteInfo = new CompoundUseSiteInfo<AssemblySymbol>(diagnostics, ContainingAssembly);
bool isExplicitInterfaceImplementationInInterface = ContainingType.IsInterface && IsExplicitInterfaceImplementation;
if (this.DeclaredAccessibility == Accessibility.Private && (IsVirtual || (IsAbstract && !isExplicitInterfaceImplementationInInterface) || IsOverride))
{
diagnostics.Add(ErrorCode.ERR_VirtualPrivate, location, this);
}
else if (IsStatic && IsAbstract && !ContainingType.IsInterface)
{
// A static member '{0}' cannot be marked as 'abstract'
diagnostics.Add(ErrorCode.ERR_StaticNotVirtual, location, ModifierUtils.ConvertSingleModifierToSyntaxText(DeclarationModifiers.Abstract));
}
else if (IsReadOnly && IsStatic)
{
// Static member '{0}' cannot be marked 'readonly'.
diagnostics.Add(ErrorCode.ERR_StaticMemberCantBeReadOnly, location, this);
}
else if (IsReadOnly && HasAssociatedField)
{
// Field-like event '{0}' cannot be 'readonly'.
diagnostics.Add(ErrorCode.ERR_FieldLikeEventCantBeReadOnly, location, this);
}
else if (IsOverride && (IsNew || IsVirtual))
{
// A member '{0}' marked as override cannot be marked as new or virtual
diagnostics.Add(ErrorCode.ERR_OverrideNotNew, location, this);
}
else if (IsSealed && !IsOverride && !(isExplicitInterfaceImplementationInInterface && IsAbstract))
{
// '{0}' cannot be sealed because it is not an override
diagnostics.Add(ErrorCode.ERR_SealedNonOverride, location, this);
}
else if (IsAbstract && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.AbstractKeyword));
}
else if (IsVirtual && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.VirtualKeyword));
}
else if (IsAbstract && IsExtern)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndExtern, location, this);
}
else if (IsAbstract && IsSealed && !isExplicitInterfaceImplementationInInterface)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndSealed, location, this);
}
else if (IsAbstract && IsVirtual)
{
diagnostics.Add(ErrorCode.ERR_AbstractNotVirtual, location, this.Kind.Localize(), this);
}
else if (ContainingType.IsSealed && this.DeclaredAccessibility.HasProtected() && !this.IsOverride)
{
diagnostics.Add(AccessCheck.GetProtectedMemberInSealedTypeError(ContainingType), location, this);
}
else if (ContainingType.IsStatic && !IsStatic)
{
diagnostics.Add(ErrorCode.ERR_InstanceMemberInStaticClass, location, Name);
}
else if (this.Type.IsVoidType())
{
// Diagnostic reported by parser.
}
else if (!this.IsNoMoreVisibleThan(this.Type, ref useSiteInfo) && (CSharpSyntaxNode as EventDeclarationSyntax)?.ExplicitInterfaceSpecifier == null)
{
// Dev10 reports different errors for field-like events (ERR_BadVisFieldType) and custom events (ERR_BadVisPropertyType).
// Both seem odd, so add a new one.
diagnostics.Add(ErrorCode.ERR_BadVisEventType, location, this, this.Type);
}
else if (!this.Type.IsDelegateType() && !this.Type.IsErrorType())
{
// Suppressed for error types.
diagnostics.Add(ErrorCode.ERR_EventNotDelegate, location, this);
}
else if (IsAbstract && !ContainingType.IsAbstract && (ContainingType.TypeKind == TypeKind.Class || ContainingType.TypeKind == TypeKind.Submission))
{
// '{0}' is abstract but it is contained in non-abstract type '{1}'
diagnostics.Add(ErrorCode.ERR_AbstractInConcreteClass, location, this, ContainingType);
}
else if (IsVirtual && ContainingType.IsSealed)
{
// '{0}' is a new virtual member in sealed type '{1}'
diagnostics.Add(ErrorCode.ERR_NewVirtualInSealed, location, this, ContainingType);
}
diagnostics.Add(location, useSiteInfo);
}
public override string GetDocumentationCommentXml(CultureInfo? preferredCulture = null, bool expandIncludes = false, CancellationToken cancellationToken = default)
{
ref var lazyDocComment = ref expandIncludes ? ref _lazyExpandedDocComment : ref _lazyDocComment;
return SourceDocumentationCommentUtils.GetAndCacheDocumentationComment(this, expandIncludes, ref lazyDocComment);
}
protected static void CopyEventCustomModifiers(EventSymbol eventWithCustomModifiers, ref TypeWithAnnotations type, AssemblySymbol containingAssembly)
{
RoslynDebug.Assert((object)eventWithCustomModifiers != null);
TypeSymbol overriddenEventType = eventWithCustomModifiers.Type;
// We do an extra check before copying the type to handle the case where the overriding
// event (incorrectly) has a different type than the overridden event. In such cases,
// we want to retain the original (incorrect) type to avoid hiding the type given in source.
if (type.Type.Equals(overriddenEventType, TypeCompareKind.IgnoreCustomModifiersAndArraySizesAndLowerBounds | TypeCompareKind.IgnoreNullableModifiersForReferenceTypes | TypeCompareKind.IgnoreDynamic))
{
type = type.WithTypeAndModifiers(CustomModifierUtils.CopyTypeCustomModifiers(overriddenEventType, type.Type, containingAssembly),
eventWithCustomModifiers.TypeWithAnnotations.CustomModifiers);
}
}
internal override OverriddenOrHiddenMembersResult OverriddenOrHiddenMembers
{
get
{
if (_lazyOverriddenOrHiddenMembers == null)
{
Interlocked.CompareExchange(ref _lazyOverriddenOrHiddenMembers, this.MakeOverriddenOrHiddenMembers(), null);
}
return _lazyOverriddenOrHiddenMembers;
}
}
public sealed override bool IsWindowsRuntimeEvent
{
get
{
if (!_lazyIsWindowsRuntimeEvent.HasValue())
{
// This would be a CompareExchange if there was an overload for ThreeState.
_lazyIsWindowsRuntimeEvent = ComputeIsWindowsRuntimeEvent().ToThreeState();
}
Debug.Assert(_lazyIsWindowsRuntimeEvent.HasValue());
return _lazyIsWindowsRuntimeEvent.Value();
}
}
private bool ComputeIsWindowsRuntimeEvent()
{
// If you explicitly implement an event, then you're a WinRT event if and only if it's a WinRT event.
ImmutableArray<EventSymbol> explicitInterfaceImplementations = this.ExplicitInterfaceImplementations;
if (!explicitInterfaceImplementations.IsEmpty)
{
// If there could be more than one, we'd have to worry about conflicts, but that's impossible for source events.
Debug.Assert(explicitInterfaceImplementations.Length == 1);
// Don't have to worry about conflicting with the override rule, since explicit impls are never overrides (in source).
Debug.Assert((object?)this.OverriddenEvent == null);
return explicitInterfaceImplementations[0].IsWindowsRuntimeEvent;
}
// Interface events don't override or implicitly implement other events, so they only
// depend on the output kind at this point.
if (this.containingType.IsInterfaceType())
{
return this.IsCompilationOutputWinMdObj();
}
// If you override an event, then you're a WinRT event if and only if it's a WinRT event.
EventSymbol? overriddenEvent = this.OverriddenEvent;
if ((object?)overriddenEvent != null)
{
return overriddenEvent.IsWindowsRuntimeEvent;
}
// If you implicitly implement one or more interface events (for yourself, not for a derived type),
// then you're a WinRT event if and only if at least one is a WinRT event.
//
// NOTE: it's possible that we returned false above even though we would have returned true
// below. Whenever this occurs, we need to report a diagnostic (because an event can't be
// both WinRT and non-WinRT), but we'll do that when we're checking interface implementations
// (see SourceMemberContainerTypeSymbol.ComputeInterfaceImplementations).
bool sawImplicitImplementation = false;
foreach (NamedTypeSymbol @interface in this.containingType.InterfacesAndTheirBaseInterfacesNoUseSiteDiagnostics.Keys)
{
foreach (Symbol interfaceMember in @interface.GetMembers(this.Name))
{
if (interfaceMember.Kind == SymbolKind.Event && //quick check (necessary, not sufficient)
interfaceMember.IsImplementableInterfaceMember() &&
// We are passing ignoreImplementationInInterfacesIfResultIsNotReady: true to avoid a cycle. If false is passed, FindImplementationForInterfaceMemberInNonInterface
// will look how event accessors are implemented and we end up here again since we will need to know their signature for that.
this == this.containingType.FindImplementationForInterfaceMemberInNonInterface(interfaceMember, ignoreImplementationInInterfacesIfResultIsNotReady: true)) //slow check (necessary and sufficient)
{
sawImplicitImplementation = true;
if (((EventSymbol)interfaceMember).IsWindowsRuntimeEvent)
{
return true;
}
}
}
}
// If you implement one or more interface events and none of them are WinRT events, then you
// are not a WinRT event.
if (sawImplicitImplementation)
{
return false;
}
// If you're not constrained by your relationships with other members, then you're a WinRT event
// if and only if this compilation will produce a ".winmdobj" file.
return this.IsCompilationOutputWinMdObj();
}
internal static string GetAccessorName(string eventName, bool isAdder)
{
return (isAdder ? "add_" : "remove_") + eventName;
}
protected TypeWithAnnotations BindEventType(Binder binder, TypeSyntax typeSyntax, BindingDiagnosticBag diagnostics)
{
// NOTE: no point in reporting unsafe errors in the return type - anything unsafe will either
// fail to be a delegate or will be (invalidly) passed as a type argument.
// Prevent constraint checking.
binder = binder.WithAdditionalFlagsAndContainingMemberOrLambda(BinderFlags.SuppressConstraintChecks | BinderFlags.SuppressUnsafeDiagnostics, this);
return binder.BindType(typeSyntax, diagnostics);
}
internal override void AfterAddingTypeMembersChecks(ConversionsBase conversions, BindingDiagnosticBag diagnostics)
{
var compilation = DeclaringCompilation;
var location = this.Locations[0];
this.CheckModifiersAndType(diagnostics);
this.Type.CheckAllConstraints(compilation, conversions, location, diagnostics);
if (Type.ContainsNativeInteger())
{
compilation.EnsureNativeIntegerAttributeExists(diagnostics, location, modifyCompilation: true);
}
if (compilation.ShouldEmitNullableAttributes(this) &&
TypeWithAnnotations.NeedsNullableAttribute())
{
compilation.EnsureNullableAttributeExists(diagnostics, location, modifyCompilation: true);
}
EventSymbol? explicitlyImplementedEvent = ExplicitInterfaceImplementations.FirstOrDefault();
if (explicitlyImplementedEvent is object)
{
CheckExplicitImplementationAccessor(AddMethod, explicitlyImplementedEvent.AddMethod, explicitlyImplementedEvent, diagnostics);
CheckExplicitImplementationAccessor(RemoveMethod, explicitlyImplementedEvent.RemoveMethod, explicitlyImplementedEvent, diagnostics);
}
}
private void CheckExplicitImplementationAccessor(MethodSymbol? thisAccessor, MethodSymbol? otherAccessor, EventSymbol explicitlyImplementedEvent, BindingDiagnosticBag diagnostics)
{
if (!otherAccessor.IsImplementable() && thisAccessor is object)
{
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyAddingAccessor, thisAccessor.Locations[0], thisAccessor, explicitlyImplementedEvent);
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
using System.Collections.Generic;
using Microsoft.CodeAnalysis.Diagnostics;
using Microsoft.CodeAnalysis.CSharp.Emit;
using System.Linq;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
/// <summary>
/// This class represents an event declared in source. It may be either
/// field-like (see <see cref="SourceFieldLikeEventSymbol"/>) or property-like (see
/// <see cref="SourceCustomEventSymbol"/>).
/// </summary>
internal abstract class SourceEventSymbol : EventSymbol, IAttributeTargetSymbol
{
private readonly Location _location;
private readonly SyntaxReference _syntaxRef;
private readonly DeclarationModifiers _modifiers;
internal readonly SourceMemberContainerTypeSymbol containingType;
private SymbolCompletionState _state;
private CustomAttributesBag<CSharpAttributeData>? _lazyCustomAttributesBag;
private string? _lazyDocComment;
private string? _lazyExpandedDocComment;
private OverriddenOrHiddenMembersResult? _lazyOverriddenOrHiddenMembers;
private ThreeState _lazyIsWindowsRuntimeEvent = ThreeState.Unknown;
// TODO: CLSCompliantAttribute
internal SourceEventSymbol(
SourceMemberContainerTypeSymbol containingType,
CSharpSyntaxNode syntax,
SyntaxTokenList modifiers,
bool isFieldLike,
ExplicitInterfaceSpecifierSyntax? interfaceSpecifierSyntaxOpt,
SyntaxToken nameTokenSyntax,
BindingDiagnosticBag diagnostics)
{
_location = nameTokenSyntax.GetLocation();
this.containingType = containingType;
_syntaxRef = syntax.GetReference();
var isExplicitInterfaceImplementation = interfaceSpecifierSyntaxOpt != null;
bool modifierErrors;
_modifiers = MakeModifiers(modifiers, isExplicitInterfaceImplementation, isFieldLike, _location, diagnostics, out modifierErrors);
this.CheckAccessibility(_location, diagnostics, isExplicitInterfaceImplementation);
}
internal sealed override bool RequiresCompletion
{
get { return true; }
}
internal sealed override bool HasComplete(CompletionPart part)
{
return _state.HasComplete(part);
}
internal override void ForceComplete(SourceLocation? locationOpt, CancellationToken cancellationToken)
{
_state.DefaultForceComplete(this, cancellationToken);
}
public abstract override string Name { get; }
public abstract override MethodSymbol? AddMethod { get; }
public abstract override MethodSymbol? RemoveMethod { get; }
public abstract override ImmutableArray<EventSymbol> ExplicitInterfaceImplementations { get; }
public abstract override TypeWithAnnotations TypeWithAnnotations { get; }
public sealed override Symbol ContainingSymbol
{
get
{
return containingType;
}
}
public override NamedTypeSymbol ContainingType
{
get
{
return this.containingType;
}
}
internal override LexicalSortKey GetLexicalSortKey()
{
return new LexicalSortKey(_location, this.DeclaringCompilation);
}
public sealed override ImmutableArray<Location> Locations
{
get
{
return ImmutableArray.Create(_location);
}
}
public sealed override ImmutableArray<SyntaxReference> DeclaringSyntaxReferences
{
get
{
return ImmutableArray.Create<SyntaxReference>(_syntaxRef);
}
}
/// <summary>
/// Gets the syntax list of custom attributes applied on the event symbol.
/// </summary>
internal SyntaxList<AttributeListSyntax> AttributeDeclarationSyntaxList
{
get
{
if (this.containingType.AnyMemberHasAttributes)
{
var syntax = this.CSharpSyntaxNode;
if (syntax != null)
{
switch (syntax.Kind())
{
case SyntaxKind.EventDeclaration:
return ((EventDeclarationSyntax)syntax).AttributeLists;
case SyntaxKind.VariableDeclarator:
Debug.Assert(syntax.Parent!.Parent is object);
return ((EventFieldDeclarationSyntax)syntax.Parent.Parent).AttributeLists;
default:
throw ExceptionUtilities.UnexpectedValue(syntax.Kind());
}
}
}
return default;
}
}
IAttributeTargetSymbol IAttributeTargetSymbol.AttributesOwner
{
get { return this; }
}
AttributeLocation IAttributeTargetSymbol.DefaultAttributeLocation
{
get { return AttributeLocation.Event; }
}
AttributeLocation IAttributeTargetSymbol.AllowedAttributeLocations
{
get
{
return this.AllowedAttributeLocations;
}
}
protected abstract AttributeLocation AllowedAttributeLocations
{
get;
}
/// <summary>
/// Returns a bag of applied custom attributes and data decoded from well-known attributes. Returns null if there are no attributes applied on the symbol.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
private CustomAttributesBag<CSharpAttributeData> GetAttributesBag()
{
if ((_lazyCustomAttributesBag == null || !_lazyCustomAttributesBag.IsSealed) &&
LoadAndValidateAttributes(OneOrMany.Create(this.AttributeDeclarationSyntaxList), ref _lazyCustomAttributesBag))
{
DeclaringCompilation.SymbolDeclaredEvent(this);
var wasCompletedThisThread = _state.NotePartComplete(CompletionPart.Attributes);
Debug.Assert(wasCompletedThisThread);
}
RoslynDebug.AssertNotNull(_lazyCustomAttributesBag);
return _lazyCustomAttributesBag;
}
/// <summary>
/// Gets the attributes applied on this symbol.
/// Returns an empty array if there are no attributes.
/// </summary>
/// <remarks>
/// NOTE: This method should always be kept as a sealed override.
/// If you want to override attribute binding logic for a sub-class, then override <see cref="GetAttributesBag"/> method.
/// </remarks>
public sealed override ImmutableArray<CSharpAttributeData> GetAttributes()
{
return this.GetAttributesBag().Attributes;
}
/// <summary>
/// Returns data decoded from well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
protected CommonEventWellKnownAttributeData GetDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (CommonEventWellKnownAttributeData)attributesBag.DecodedWellKnownAttributeData;
}
/// <summary>
/// Returns data decoded from special early bound well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
internal CommonEventEarlyWellKnownAttributeData GetEarlyDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (CommonEventEarlyWellKnownAttributeData)attributesBag.EarlyDecodedWellKnownAttributeData;
}
internal override CSharpAttributeData? EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments)
{
CSharpAttributeData? boundAttribute;
ObsoleteAttributeData? obsoleteData;
if (EarlyDecodeDeprecatedOrExperimentalOrObsoleteAttribute(ref arguments, out boundAttribute, out obsoleteData))
{
if (obsoleteData != null)
{
arguments.GetOrCreateData<CommonEventEarlyWellKnownAttributeData>().ObsoleteAttributeData = obsoleteData;
}
return boundAttribute;
}
return base.EarlyDecodeWellKnownAttribute(ref arguments);
}
/// <summary>
/// Returns data decoded from Obsolete attribute or null if there is no Obsolete attribute.
/// This property returns ObsoleteAttributeData.Uninitialized if attribute arguments haven't been decoded yet.
/// </summary>
internal override ObsoleteAttributeData? ObsoleteAttributeData
{
get
{
if (!this.containingType.AnyMemberHasAttributes)
{
return null;
}
var lazyCustomAttributesBag = _lazyCustomAttributesBag;
if (lazyCustomAttributesBag != null && lazyCustomAttributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
var data = (CommonEventEarlyWellKnownAttributeData)lazyCustomAttributesBag.EarlyDecodedWellKnownAttributeData;
return data != null ? data.ObsoleteAttributeData : null;
}
return ObsoleteAttributeData.Uninitialized;
}
}
internal sealed override void DecodeWellKnownAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments)
{
var attribute = arguments.Attribute;
Debug.Assert(!attribute.HasErrors);
Debug.Assert(arguments.SymbolPart == AttributeLocation.None);
var diagnostics = (BindingDiagnosticBag)arguments.Diagnostics;
if (attribute.IsTargetAttribute(this, AttributeDescription.SpecialNameAttribute))
{
arguments.GetOrCreateData<CommonEventWellKnownAttributeData>().HasSpecialNameAttribute = true;
}
else if (ReportExplicitUseOfReservedAttributes(in arguments, ReservedAttributes.NullableAttribute | ReservedAttributes.NativeIntegerAttribute | ReservedAttributes.TupleElementNamesAttribute))
{
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.ExcludeFromCodeCoverageAttribute))
{
arguments.GetOrCreateData<CommonEventWellKnownAttributeData>().HasExcludeFromCodeCoverageAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.SkipLocalsInitAttribute))
{
CSharpAttributeData.DecodeSkipLocalsInitAttribute<CommonEventWellKnownAttributeData>(DeclaringCompilation, ref arguments);
}
}
internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<SynthesizedAttributeData>? attributes)
{
base.AddSynthesizedAttributes(moduleBuilder, ref attributes);
var compilation = this.DeclaringCompilation;
var type = this.TypeWithAnnotations;
if (type.Type.ContainsDynamic())
{
AddSynthesizedAttribute(ref attributes, compilation.SynthesizeDynamicAttribute(type.Type, type.CustomModifiers.Length));
}
if (type.Type.ContainsNativeInteger())
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNativeIntegerAttribute(this, type.Type));
}
if (type.Type.ContainsTupleNames())
{
AddSynthesizedAttribute(ref attributes,
DeclaringCompilation.SynthesizeTupleNamesAttribute(type.Type));
}
if (compilation.ShouldEmitNullableAttributes(this))
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNullableAttributeIfNecessary(this, containingType.GetNullableContextValue(), type));
}
}
internal sealed override bool IsDirectlyExcludedFromCodeCoverage =>
GetDecodedWellKnownAttributeData()?.HasExcludeFromCodeCoverageAttribute == true;
internal sealed override bool HasSpecialName
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasSpecialNameAttribute;
}
}
public bool HasSkipLocalsInitAttribute
=> GetDecodedWellKnownAttributeData()?.HasSkipLocalsInitAttribute == true;
public sealed override bool IsAbstract
{
get { return (_modifiers & DeclarationModifiers.Abstract) != 0; }
}
public sealed override bool IsExtern
{
get { return (_modifiers & DeclarationModifiers.Extern) != 0; }
}
public sealed override bool IsStatic
{
get { return (_modifiers & DeclarationModifiers.Static) != 0; }
}
public sealed override bool IsOverride
{
get { return (_modifiers & DeclarationModifiers.Override) != 0; }
}
public sealed override bool IsSealed
{
get { return (_modifiers & DeclarationModifiers.Sealed) != 0; }
}
public sealed override bool IsVirtual
{
get { return (_modifiers & DeclarationModifiers.Virtual) != 0; }
}
internal bool IsReadOnly
{
get { return (_modifiers & DeclarationModifiers.ReadOnly) != 0; }
}
public sealed override Accessibility DeclaredAccessibility
{
get { return ModifierUtils.EffectiveAccessibility(_modifiers); }
}
internal sealed override bool MustCallMethodsDirectly
{
get { return false; } // always false for source events
}
internal SyntaxReference SyntaxReference
{
get { return _syntaxRef; }
}
internal CSharpSyntaxNode CSharpSyntaxNode
{
get { return (CSharpSyntaxNode)_syntaxRef.GetSyntax(); }
}
internal SyntaxTree SyntaxTree
{
get { return _syntaxRef.SyntaxTree; }
}
internal bool IsNew
{
get { return (_modifiers & DeclarationModifiers.New) != 0; }
}
internal DeclarationModifiers Modifiers
{
get { return _modifiers; }
}
private void CheckAccessibility(Location location, BindingDiagnosticBag diagnostics, bool isExplicitInterfaceImplementation)
{
var info = ModifierUtils.CheckAccessibility(_modifiers, this, isExplicitInterfaceImplementation);
if (info != null)
{
diagnostics.Add(new CSDiagnostic(info, location));
}
}
private DeclarationModifiers MakeModifiers(SyntaxTokenList modifiers, bool explicitInterfaceImplementation,
bool isFieldLike, Location location,
BindingDiagnosticBag diagnostics, out bool modifierErrors)
{
bool isInterface = this.ContainingType.IsInterface;
var defaultAccess = isInterface && !explicitInterfaceImplementation ? DeclarationModifiers.Public : DeclarationModifiers.Private;
var defaultInterfaceImplementationModifiers = DeclarationModifiers.None;
// Check that the set of modifiers is allowed
var allowedModifiers = DeclarationModifiers.Unsafe;
if (!explicitInterfaceImplementation)
{
allowedModifiers |= DeclarationModifiers.New |
DeclarationModifiers.Sealed |
DeclarationModifiers.Abstract |
DeclarationModifiers.Static |
DeclarationModifiers.Virtual |
DeclarationModifiers.AccessibilityMask;
if (!isInterface)
{
allowedModifiers |= DeclarationModifiers.Override;
}
else
{
// This is needed to make sure we can detect 'public' modifier specified explicitly and
// check it against language version below.
defaultAccess = DeclarationModifiers.None;
allowedModifiers |= DeclarationModifiers.Extern;
defaultInterfaceImplementationModifiers |= DeclarationModifiers.Sealed |
DeclarationModifiers.Abstract |
DeclarationModifiers.Static |
DeclarationModifiers.Virtual |
DeclarationModifiers.Extern |
DeclarationModifiers.AccessibilityMask;
}
}
else
{
Debug.Assert(explicitInterfaceImplementation);
if (isInterface)
{
allowedModifiers |= DeclarationModifiers.Abstract;
}
else
{
allowedModifiers |= DeclarationModifiers.Static;
}
}
if (this.ContainingType.IsStructType())
{
allowedModifiers |= DeclarationModifiers.ReadOnly;
}
if (!isInterface)
{
allowedModifiers |= DeclarationModifiers.Extern;
}
var mods = ModifierUtils.MakeAndCheckNontypeMemberModifiers(modifiers, defaultAccess, allowedModifiers, location, diagnostics, out modifierErrors);
ModifierUtils.CheckFeatureAvailabilityForStaticAbstractMembersInInterfacesIfNeeded(mods, explicitInterfaceImplementation, location, diagnostics);
this.CheckUnsafeModifier(mods, diagnostics);
ModifierUtils.ReportDefaultInterfaceImplementationModifiers(!isFieldLike, mods,
defaultInterfaceImplementationModifiers,
location, diagnostics);
// Let's overwrite modifiers for interface events with what they are supposed to be.
// Proper errors must have been reported by now.
if (isInterface)
{
mods = ModifierUtils.AdjustModifiersForAnInterfaceMember(mods, !isFieldLike, explicitInterfaceImplementation);
}
return mods;
}
protected void CheckModifiersAndType(BindingDiagnosticBag diagnostics)
{
Debug.Assert(!IsStatic || (!IsVirtual && !IsOverride)); // Otherwise 'virtual' and 'override' should have been reported and cleared earlier.
Location location = this.Locations[0];
var useSiteInfo = new CompoundUseSiteInfo<AssemblySymbol>(diagnostics, ContainingAssembly);
bool isExplicitInterfaceImplementationInInterface = ContainingType.IsInterface && IsExplicitInterfaceImplementation;
if (this.DeclaredAccessibility == Accessibility.Private && (IsVirtual || (IsAbstract && !isExplicitInterfaceImplementationInInterface) || IsOverride))
{
diagnostics.Add(ErrorCode.ERR_VirtualPrivate, location, this);
}
else if (IsStatic && IsAbstract && !ContainingType.IsInterface)
{
// A static member '{0}' cannot be marked as 'abstract'
diagnostics.Add(ErrorCode.ERR_StaticNotVirtual, location, ModifierUtils.ConvertSingleModifierToSyntaxText(DeclarationModifiers.Abstract));
}
else if (IsReadOnly && IsStatic)
{
// Static member '{0}' cannot be marked 'readonly'.
diagnostics.Add(ErrorCode.ERR_StaticMemberCantBeReadOnly, location, this);
}
else if (IsReadOnly && HasAssociatedField)
{
// Field-like event '{0}' cannot be 'readonly'.
diagnostics.Add(ErrorCode.ERR_FieldLikeEventCantBeReadOnly, location, this);
}
else if (IsOverride && (IsNew || IsVirtual))
{
// A member '{0}' marked as override cannot be marked as new or virtual
diagnostics.Add(ErrorCode.ERR_OverrideNotNew, location, this);
}
else if (IsSealed && !IsOverride && !(isExplicitInterfaceImplementationInInterface && IsAbstract))
{
// '{0}' cannot be sealed because it is not an override
diagnostics.Add(ErrorCode.ERR_SealedNonOverride, location, this);
}
else if (IsAbstract && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.AbstractKeyword));
}
else if (IsVirtual && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.VirtualKeyword));
}
else if (IsAbstract && IsExtern)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndExtern, location, this);
}
else if (IsAbstract && IsSealed && !isExplicitInterfaceImplementationInInterface)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndSealed, location, this);
}
else if (IsAbstract && IsVirtual)
{
diagnostics.Add(ErrorCode.ERR_AbstractNotVirtual, location, this.Kind.Localize(), this);
}
else if (ContainingType.IsSealed && this.DeclaredAccessibility.HasProtected() && !this.IsOverride)
{
diagnostics.Add(AccessCheck.GetProtectedMemberInSealedTypeError(ContainingType), location, this);
}
else if (ContainingType.IsStatic && !IsStatic)
{
diagnostics.Add(ErrorCode.ERR_InstanceMemberInStaticClass, location, Name);
}
else if (this.Type.IsVoidType())
{
// Diagnostic reported by parser.
}
else if (!this.IsNoMoreVisibleThan(this.Type, ref useSiteInfo) && (CSharpSyntaxNode as EventDeclarationSyntax)?.ExplicitInterfaceSpecifier == null)
{
// Dev10 reports different errors for field-like events (ERR_BadVisFieldType) and custom events (ERR_BadVisPropertyType).
// Both seem odd, so add a new one.
diagnostics.Add(ErrorCode.ERR_BadVisEventType, location, this, this.Type);
}
else if (!this.Type.IsDelegateType() && !this.Type.IsErrorType())
{
// Suppressed for error types.
diagnostics.Add(ErrorCode.ERR_EventNotDelegate, location, this);
}
else if (IsAbstract && !ContainingType.IsAbstract && (ContainingType.TypeKind == TypeKind.Class || ContainingType.TypeKind == TypeKind.Submission))
{
// '{0}' is abstract but it is contained in non-abstract type '{1}'
diagnostics.Add(ErrorCode.ERR_AbstractInConcreteClass, location, this, ContainingType);
}
else if (IsVirtual && ContainingType.IsSealed)
{
// '{0}' is a new virtual member in sealed type '{1}'
diagnostics.Add(ErrorCode.ERR_NewVirtualInSealed, location, this, ContainingType);
}
diagnostics.Add(location, useSiteInfo);
}
public override string GetDocumentationCommentXml(CultureInfo? preferredCulture = null, bool expandIncludes = false, CancellationToken cancellationToken = default)
{
ref var lazyDocComment = ref expandIncludes ? ref _lazyExpandedDocComment : ref _lazyDocComment;
return SourceDocumentationCommentUtils.GetAndCacheDocumentationComment(this, expandIncludes, ref lazyDocComment);
}
protected static void CopyEventCustomModifiers(EventSymbol eventWithCustomModifiers, ref TypeWithAnnotations type, AssemblySymbol containingAssembly)
{
RoslynDebug.Assert((object)eventWithCustomModifiers != null);
TypeSymbol overriddenEventType = eventWithCustomModifiers.Type;
// We do an extra check before copying the type to handle the case where the overriding
// event (incorrectly) has a different type than the overridden event. In such cases,
// we want to retain the original (incorrect) type to avoid hiding the type given in source.
if (type.Type.Equals(overriddenEventType, TypeCompareKind.IgnoreCustomModifiersAndArraySizesAndLowerBounds | TypeCompareKind.IgnoreNullableModifiersForReferenceTypes | TypeCompareKind.IgnoreDynamic))
{
type = type.WithTypeAndModifiers(CustomModifierUtils.CopyTypeCustomModifiers(overriddenEventType, type.Type, containingAssembly),
eventWithCustomModifiers.TypeWithAnnotations.CustomModifiers);
}
}
internal override OverriddenOrHiddenMembersResult OverriddenOrHiddenMembers
{
get
{
if (_lazyOverriddenOrHiddenMembers == null)
{
Interlocked.CompareExchange(ref _lazyOverriddenOrHiddenMembers, this.MakeOverriddenOrHiddenMembers(), null);
}
return _lazyOverriddenOrHiddenMembers;
}
}
public sealed override bool IsWindowsRuntimeEvent
{
get
{
if (!_lazyIsWindowsRuntimeEvent.HasValue())
{
// This would be a CompareExchange if there was an overload for ThreeState.
_lazyIsWindowsRuntimeEvent = ComputeIsWindowsRuntimeEvent().ToThreeState();
}
Debug.Assert(_lazyIsWindowsRuntimeEvent.HasValue());
return _lazyIsWindowsRuntimeEvent.Value();
}
}
private bool ComputeIsWindowsRuntimeEvent()
{
// If you explicitly implement an event, then you're a WinRT event if and only if it's a WinRT event.
ImmutableArray<EventSymbol> explicitInterfaceImplementations = this.ExplicitInterfaceImplementations;
if (!explicitInterfaceImplementations.IsEmpty)
{
// If there could be more than one, we'd have to worry about conflicts, but that's impossible for source events.
Debug.Assert(explicitInterfaceImplementations.Length == 1);
// Don't have to worry about conflicting with the override rule, since explicit impls are never overrides (in source).
Debug.Assert((object?)this.OverriddenEvent == null);
return explicitInterfaceImplementations[0].IsWindowsRuntimeEvent;
}
// Interface events don't override or implicitly implement other events, so they only
// depend on the output kind at this point.
if (this.containingType.IsInterfaceType())
{
return this.IsCompilationOutputWinMdObj();
}
// If you override an event, then you're a WinRT event if and only if it's a WinRT event.
EventSymbol? overriddenEvent = this.OverriddenEvent;
if ((object?)overriddenEvent != null)
{
return overriddenEvent.IsWindowsRuntimeEvent;
}
// If you implicitly implement one or more interface events (for yourself, not for a derived type),
// then you're a WinRT event if and only if at least one is a WinRT event.
//
// NOTE: it's possible that we returned false above even though we would have returned true
// below. Whenever this occurs, we need to report a diagnostic (because an event can't be
// both WinRT and non-WinRT), but we'll do that when we're checking interface implementations
// (see SourceMemberContainerTypeSymbol.ComputeInterfaceImplementations).
bool sawImplicitImplementation = false;
foreach (NamedTypeSymbol @interface in this.containingType.InterfacesAndTheirBaseInterfacesNoUseSiteDiagnostics.Keys)
{
foreach (Symbol interfaceMember in @interface.GetMembers(this.Name))
{
if (interfaceMember.Kind == SymbolKind.Event && //quick check (necessary, not sufficient)
interfaceMember.IsImplementableInterfaceMember() &&
// We are passing ignoreImplementationInInterfacesIfResultIsNotReady: true to avoid a cycle. If false is passed, FindImplementationForInterfaceMemberInNonInterface
// will look how event accessors are implemented and we end up here again since we will need to know their signature for that.
this == this.containingType.FindImplementationForInterfaceMemberInNonInterface(interfaceMember, ignoreImplementationInInterfacesIfResultIsNotReady: true)) //slow check (necessary and sufficient)
{
sawImplicitImplementation = true;
if (((EventSymbol)interfaceMember).IsWindowsRuntimeEvent)
{
return true;
}
}
}
}
// If you implement one or more interface events and none of them are WinRT events, then you
// are not a WinRT event.
if (sawImplicitImplementation)
{
return false;
}
// If you're not constrained by your relationships with other members, then you're a WinRT event
// if and only if this compilation will produce a ".winmdobj" file.
return this.IsCompilationOutputWinMdObj();
}
internal static string GetAccessorName(string eventName, bool isAdder)
{
return (isAdder ? "add_" : "remove_") + eventName;
}
protected TypeWithAnnotations BindEventType(Binder binder, TypeSyntax typeSyntax, BindingDiagnosticBag diagnostics)
{
// NOTE: no point in reporting unsafe errors in the return type - anything unsafe will either
// fail to be a delegate or will be (invalidly) passed as a type argument.
// Prevent constraint checking.
binder = binder.WithAdditionalFlagsAndContainingMemberOrLambda(BinderFlags.SuppressConstraintChecks | BinderFlags.SuppressUnsafeDiagnostics, this);
return binder.BindType(typeSyntax, diagnostics);
}
internal override void AfterAddingTypeMembersChecks(ConversionsBase conversions, BindingDiagnosticBag diagnostics)
{
var compilation = DeclaringCompilation;
var location = this.Locations[0];
this.CheckModifiersAndType(diagnostics);
this.Type.CheckAllConstraints(compilation, conversions, location, diagnostics);
if (Type.ContainsNativeInteger())
{
compilation.EnsureNativeIntegerAttributeExists(diagnostics, location, modifyCompilation: true);
}
if (compilation.ShouldEmitNullableAttributes(this) &&
TypeWithAnnotations.NeedsNullableAttribute())
{
compilation.EnsureNullableAttributeExists(diagnostics, location, modifyCompilation: true);
}
EventSymbol? explicitlyImplementedEvent = ExplicitInterfaceImplementations.FirstOrDefault();
if (explicitlyImplementedEvent is object)
{
CheckExplicitImplementationAccessor(AddMethod, explicitlyImplementedEvent.AddMethod, explicitlyImplementedEvent, diagnostics);
CheckExplicitImplementationAccessor(RemoveMethod, explicitlyImplementedEvent.RemoveMethod, explicitlyImplementedEvent, diagnostics);
}
}
private void CheckExplicitImplementationAccessor(MethodSymbol? thisAccessor, MethodSymbol? otherAccessor, EventSymbol explicitlyImplementedEvent, BindingDiagnosticBag diagnostics)
{
if (!otherAccessor.IsImplementable() && thisAccessor is object)
{
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyAddingAccessor, thisAccessor.Locations[0], thisAccessor, explicitlyImplementedEvent);
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Tools/Source/CompilerGeneratorTools/Source/CSharpSyntaxGenerator/Grammar/GrammarGenerator.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
// We only support grammar generation in the command line version for now which is the netcoreapp target
#if NETCOREAPP
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
using System.Text.RegularExpressions;
using Microsoft.CodeAnalysis.CSharp;
namespace CSharpSyntaxGenerator.Grammar
{
internal static class GrammarGenerator
{
public static string Run(List<TreeType> types)
{
// Syntax.xml refers to a special pseudo-element 'Modifier'. Synthesize that for the grammar.
var modifiers = GetMembers<DeclarationModifiers>()
.Select(m => m + "Keyword").Where(n => GetSyntaxKind(n) != SyntaxKind.None)
.Select(n => new Kind { Name = n }).ToList();
types.Add(new Node { Name = "Modifier", Children = { new Field { Type = "SyntaxToken", Kinds = modifiers } } });
var rules = types.ToDictionary(n => n.Name, _ => new List<Production>());
foreach (var type in types)
{
if (type.Base != null && rules.TryGetValue(type.Base, out var productions))
productions.Add(RuleReference(type.Name));
if (type is Node && type.Children.Count > 0)
{
// Convert rules like `a: (x | y) ...` into:
// a: x ...
// | y ...;
if (type.Children[0] is Field field && field.Kinds.Count > 0)
{
foreach (var kind in field.Kinds)
{
field.Kinds = new List<Kind> { kind };
rules[type.Name].Add(HandleChildren(type.Children));
}
}
else
{
rules[type.Name].Add(HandleChildren(type.Children));
}
}
}
// The grammar will bottom out with certain lexical productions. Create rules for these.
var lexicalRules = rules.Values.SelectMany(ps => ps).SelectMany(p => p.ReferencedRules)
.Where(r => !rules.TryGetValue(r, out var productions) || productions.Count == 0).ToArray();
foreach (var name in lexicalRules)
rules[name] = new List<Production> { new Production("/* see lexical specification */") };
var seen = new HashSet<string>();
// Define a few major sections to help keep the grammar file naturally grouped.
var majorRules = ImmutableArray.Create(
"CompilationUnitSyntax", "MemberDeclarationSyntax", "TypeSyntax", "StatementSyntax", "ExpressionSyntax", "XmlNodeSyntax", "StructuredTriviaSyntax");
var result = "// <auto-generated />" + Environment.NewLine + "grammar csharp;" + Environment.NewLine;
// Handle each major section first and then walk any rules not hit transitively from them.
foreach (var rule in majorRules.Concat(rules.Keys.OrderBy(a => a)))
processRule(rule, ref result);
return result;
void processRule(string name, ref string result)
{
if (name != "CSharpSyntaxNode" && seen.Add(name))
{
// Order the productions to keep us independent from whatever changes happen in Syntax.xml.
var sorted = rules[name].OrderBy(v => v);
result += Environment.NewLine + RuleReference(name).Text + Environment.NewLine + " : " +
string.Join(Environment.NewLine + " | ", sorted) + Environment.NewLine + " ;" + Environment.NewLine;
// Now proceed in depth-first fashion through the referenced rules to keep related rules
// close by. Don't recurse into major-sections to help keep them separated in grammar file.
foreach (var production in sorted)
foreach (var referencedRule in production.ReferencedRules)
if (!majorRules.Concat(lexicalRules).Contains(referencedRule))
processRule(referencedRule, ref result);
}
}
}
private static Production Join(string delim, IEnumerable<Production> productions)
=> new Production(string.Join(delim, productions.Where(p => p.Text.Length > 0)), productions.SelectMany(p => p.ReferencedRules));
private static Production HandleChildren(IEnumerable<TreeTypeChild> children, string delim = " ")
=> Join(delim, children.Select(child =>
child is Choice c ? HandleChildren(c.Children, delim: " | ").Parenthesize().Suffix("?", when: c.Optional) :
child is Sequence s ? HandleChildren(s.Children).Parenthesize() :
child is Field f ? HandleField(f).Suffix("?", when: f.IsOptional) : throw new InvalidOperationException()));
private static Production HandleField(Field field)
// 'bool' fields are for a few properties we generate on DirectiveTrivia. They're not
// relevant to the grammar, so we just return an empty production to ignore them.
=> field.Type == "bool" ? new Production("") :
field.Type == "CSharpSyntaxNode" ? RuleReference(field.Kinds.Single().Name + "Syntax") :
field.Type.StartsWith("SeparatedSyntaxList") ? HandleSeparatedList(field, field.Type[("SeparatedSyntaxList".Length + 1)..^1]) :
field.Type.StartsWith("SyntaxList") ? HandleList(field, field.Type[("SyntaxList".Length + 1)..^1]) :
field.IsToken ? HandleTokenField(field) : RuleReference(field.Type);
private static Production HandleSeparatedList(Field field, string elementType)
=> RuleReference(elementType).Suffix(" (',' " + RuleReference(elementType) + ")")
.Suffix("*", when: field.MinCount < 2).Suffix("+", when: field.MinCount >= 2)
.Suffix(" ','?", when: field.AllowTrailingSeparator)
.Parenthesize(when: field.MinCount == 0).Suffix("?", when: field.MinCount == 0);
private static Production HandleList(Field field, string elementType)
=> (elementType != "SyntaxToken" ? RuleReference(elementType) :
field.Name == "Commas" ? new Production("','") :
field.Name == "Modifiers" ? RuleReference("Modifier") :
field.Name == "TextTokens" ? RuleReference(nameof(SyntaxKind.XmlTextLiteralToken)) : RuleReference(elementType))
.Suffix(field.MinCount == 0 ? "*" : "+");
private static Production HandleTokenField(Field field)
=> field.Kinds.Count == 0
? HandleTokenName(field.Name)
: Join(" | ", field.Kinds.Select(k => HandleTokenName(k.Name))).Parenthesize(when: field.Kinds.Count >= 2);
private static Production HandleTokenName(string tokenName)
=> GetSyntaxKind(tokenName) is var kind && kind == SyntaxKind.None ? RuleReference("SyntaxToken") :
SyntaxFacts.GetText(kind) is var text && text != "" ? new Production(text == "'" ? "'\\''" : $"'{text}'") :
tokenName.StartsWith("EndOf") ? new Production("") :
tokenName.StartsWith("Omitted") ? new Production("/* epsilon */") : RuleReference(tokenName);
private static SyntaxKind GetSyntaxKind(string name)
=> GetMembers<SyntaxKind>().Where(k => k.ToString() == name).SingleOrDefault();
private static IEnumerable<TEnum> GetMembers<TEnum>() where TEnum : struct, Enum
=> (IEnumerable<TEnum>)Enum.GetValues(typeof(TEnum));
private static Production RuleReference(string name)
=> new Production(
s_normalizationRegex.Replace(name.EndsWith("Syntax") ? name[..^"Syntax".Length] : name, "_").ToLower(),
ImmutableArray.Create(name));
// Converts a PascalCased name into snake_cased name.
private static readonly Regex s_normalizationRegex = new Regex(
"(?<=[A-Z])(?=[A-Z][a-z]) | (?<=[^A-Z])(?=[A-Z]) | (?<=[A-Za-z])(?=[^A-Za-z])",
RegexOptions.IgnorePatternWhitespace | RegexOptions.Compiled);
}
internal struct Production : IComparable<Production>
{
public readonly string Text;
public readonly ImmutableArray<string> ReferencedRules;
public Production(string text, IEnumerable<string> referencedRules = null)
{
Text = text;
ReferencedRules = referencedRules?.ToImmutableArray() ?? ImmutableArray<string>.Empty;
}
public override string ToString() => Text;
public int CompareTo(Production other) => StringComparer.Ordinal.Compare(this.Text, other.Text);
public Production Prefix(string prefix) => new Production(prefix + this, ReferencedRules);
public Production Suffix(string suffix, bool when = true) => when ? new Production(this + suffix, ReferencedRules) : this;
public Production Parenthesize(bool when = true) => when ? Prefix("(").Suffix(")") : this;
}
}
namespace Microsoft.CodeAnalysis
{
internal static class GreenNode
{
internal const int ListKind = 1; // See SyntaxKind.
}
}
#endif
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
// We only support grammar generation in the command line version for now which is the netcoreapp target
#if NETCOREAPP
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
using System.Text.RegularExpressions;
using Microsoft.CodeAnalysis.CSharp;
namespace CSharpSyntaxGenerator.Grammar
{
internal static class GrammarGenerator
{
public static string Run(List<TreeType> types)
{
// Syntax.xml refers to a special pseudo-element 'Modifier'. Synthesize that for the grammar.
var modifiers = GetMembers<DeclarationModifiers>()
.Select(m => m + "Keyword").Where(n => GetSyntaxKind(n) != SyntaxKind.None)
.Select(n => new Kind { Name = n }).ToList();
types.Add(new Node { Name = "Modifier", Children = { new Field { Type = "SyntaxToken", Kinds = modifiers } } });
var rules = types.ToDictionary(n => n.Name, _ => new List<Production>());
foreach (var type in types)
{
if (type.Base != null && rules.TryGetValue(type.Base, out var productions))
productions.Add(RuleReference(type.Name));
if (type is Node && type.Children.Count > 0)
{
// Convert rules like `a: (x | y) ...` into:
// a: x ...
// | y ...;
if (type.Children[0] is Field field && field.Kinds.Count > 0)
{
foreach (var kind in field.Kinds)
{
field.Kinds = new List<Kind> { kind };
rules[type.Name].Add(HandleChildren(type.Children));
}
}
else
{
rules[type.Name].Add(HandleChildren(type.Children));
}
}
}
// The grammar will bottom out with certain lexical productions. Create rules for these.
var lexicalRules = rules.Values.SelectMany(ps => ps).SelectMany(p => p.ReferencedRules)
.Where(r => !rules.TryGetValue(r, out var productions) || productions.Count == 0).ToArray();
foreach (var name in lexicalRules)
rules[name] = new List<Production> { new Production("/* see lexical specification */") };
var seen = new HashSet<string>();
// Define a few major sections to help keep the grammar file naturally grouped.
var majorRules = ImmutableArray.Create(
"CompilationUnitSyntax", "MemberDeclarationSyntax", "TypeSyntax", "StatementSyntax", "ExpressionSyntax", "XmlNodeSyntax", "StructuredTriviaSyntax");
var result = "// <auto-generated />" + Environment.NewLine + "grammar csharp;" + Environment.NewLine;
// Handle each major section first and then walk any rules not hit transitively from them.
foreach (var rule in majorRules.Concat(rules.Keys.OrderBy(a => a)))
processRule(rule, ref result);
return result;
void processRule(string name, ref string result)
{
if (name != "CSharpSyntaxNode" && seen.Add(name))
{
// Order the productions to keep us independent from whatever changes happen in Syntax.xml.
var sorted = rules[name].OrderBy(v => v);
result += Environment.NewLine + RuleReference(name).Text + Environment.NewLine + " : " +
string.Join(Environment.NewLine + " | ", sorted) + Environment.NewLine + " ;" + Environment.NewLine;
// Now proceed in depth-first fashion through the referenced rules to keep related rules
// close by. Don't recurse into major-sections to help keep them separated in grammar file.
foreach (var production in sorted)
foreach (var referencedRule in production.ReferencedRules)
if (!majorRules.Concat(lexicalRules).Contains(referencedRule))
processRule(referencedRule, ref result);
}
}
}
private static Production Join(string delim, IEnumerable<Production> productions)
=> new Production(string.Join(delim, productions.Where(p => p.Text.Length > 0)), productions.SelectMany(p => p.ReferencedRules));
private static Production HandleChildren(IEnumerable<TreeTypeChild> children, string delim = " ")
=> Join(delim, children.Select(child =>
child is Choice c ? HandleChildren(c.Children, delim: " | ").Parenthesize().Suffix("?", when: c.Optional) :
child is Sequence s ? HandleChildren(s.Children).Parenthesize() :
child is Field f ? HandleField(f).Suffix("?", when: f.IsOptional) : throw new InvalidOperationException()));
private static Production HandleField(Field field)
// 'bool' fields are for a few properties we generate on DirectiveTrivia. They're not
// relevant to the grammar, so we just return an empty production to ignore them.
=> field.Type == "bool" ? new Production("") :
field.Type == "CSharpSyntaxNode" ? RuleReference(field.Kinds.Single().Name + "Syntax") :
field.Type.StartsWith("SeparatedSyntaxList") ? HandleSeparatedList(field, field.Type[("SeparatedSyntaxList".Length + 1)..^1]) :
field.Type.StartsWith("SyntaxList") ? HandleList(field, field.Type[("SyntaxList".Length + 1)..^1]) :
field.IsToken ? HandleTokenField(field) : RuleReference(field.Type);
private static Production HandleSeparatedList(Field field, string elementType)
=> RuleReference(elementType).Suffix(" (',' " + RuleReference(elementType) + ")")
.Suffix("*", when: field.MinCount < 2).Suffix("+", when: field.MinCount >= 2)
.Suffix(" ','?", when: field.AllowTrailingSeparator)
.Parenthesize(when: field.MinCount == 0).Suffix("?", when: field.MinCount == 0);
private static Production HandleList(Field field, string elementType)
=> (elementType != "SyntaxToken" ? RuleReference(elementType) :
field.Name == "Commas" ? new Production("','") :
field.Name == "Modifiers" ? RuleReference("Modifier") :
field.Name == "TextTokens" ? RuleReference(nameof(SyntaxKind.XmlTextLiteralToken)) : RuleReference(elementType))
.Suffix(field.MinCount == 0 ? "*" : "+");
private static Production HandleTokenField(Field field)
=> field.Kinds.Count == 0
? HandleTokenName(field.Name)
: Join(" | ", field.Kinds.Select(k => HandleTokenName(k.Name))).Parenthesize(when: field.Kinds.Count >= 2);
private static Production HandleTokenName(string tokenName)
=> GetSyntaxKind(tokenName) is var kind && kind == SyntaxKind.None ? RuleReference("SyntaxToken") :
SyntaxFacts.GetText(kind) is var text && text != "" ? new Production(text == "'" ? "'\\''" : $"'{text}'") :
tokenName.StartsWith("EndOf") ? new Production("") :
tokenName.StartsWith("Omitted") ? new Production("/* epsilon */") : RuleReference(tokenName);
private static SyntaxKind GetSyntaxKind(string name)
=> GetMembers<SyntaxKind>().Where(k => k.ToString() == name).SingleOrDefault();
private static IEnumerable<TEnum> GetMembers<TEnum>() where TEnum : struct, Enum
=> (IEnumerable<TEnum>)Enum.GetValues(typeof(TEnum));
private static Production RuleReference(string name)
=> new Production(
s_normalizationRegex.Replace(name.EndsWith("Syntax") ? name[..^"Syntax".Length] : name, "_").ToLower(),
ImmutableArray.Create(name));
// Converts a PascalCased name into snake_cased name.
private static readonly Regex s_normalizationRegex = new Regex(
"(?<=[A-Z])(?=[A-Z][a-z]) | (?<=[^A-Z])(?=[A-Z]) | (?<=[A-Za-z])(?=[^A-Za-z])",
RegexOptions.IgnorePatternWhitespace | RegexOptions.Compiled);
}
internal struct Production : IComparable<Production>
{
public readonly string Text;
public readonly ImmutableArray<string> ReferencedRules;
public Production(string text, IEnumerable<string> referencedRules = null)
{
Text = text;
ReferencedRules = referencedRules?.ToImmutableArray() ?? ImmutableArray<string>.Empty;
}
public override string ToString() => Text;
public int CompareTo(Production other) => StringComparer.Ordinal.Compare(this.Text, other.Text);
public Production Prefix(string prefix) => new Production(prefix + this, ReferencedRules);
public Production Suffix(string suffix, bool when = true) => when ? new Production(this + suffix, ReferencedRules) : this;
public Production Parenthesize(bool when = true) => when ? Prefix("(").Suffix(")") : this;
}
}
namespace Microsoft.CodeAnalysis
{
internal static class GreenNode
{
internal const int ListKind = 1; // See SyntaxKind.
}
}
#endif
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/LanguageServer/Protocol/CSharpVisualBasicLanguageServerFactory.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Composition;
using Microsoft.CodeAnalysis.Host.Mef;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Shared.TestHooks;
using StreamJsonRpc;
namespace Microsoft.CodeAnalysis.LanguageServer
{
[Export(typeof(ILanguageServerFactory)), Shared]
internal class CSharpVisualBasicLanguageServerFactory : ILanguageServerFactory
{
public const string UserVisibleName = "Roslyn Language Server Client";
private readonly RequestDispatcherFactory _dispatcherFactory;
private readonly IAsynchronousOperationListenerProvider _listenerProvider;
private readonly IGlobalOptionService _globalOptions;
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public CSharpVisualBasicLanguageServerFactory(
RequestDispatcherFactory dispatcherFactory,
IAsynchronousOperationListenerProvider listenerProvider,
IGlobalOptionService globalOptions)
{
_dispatcherFactory = dispatcherFactory;
_listenerProvider = listenerProvider;
_globalOptions = globalOptions;
}
public ILanguageServerTarget Create(
JsonRpc jsonRpc,
ICapabilitiesProvider capabilitiesProvider,
ILspWorkspaceRegistrationService workspaceRegistrationService,
ILspLogger logger)
{
return new LanguageServerTarget(
_dispatcherFactory,
jsonRpc,
capabilitiesProvider,
workspaceRegistrationService,
_globalOptions,
_listenerProvider,
logger,
ProtocolConstants.RoslynLspLanguages,
clientName: null,
userVisibleServerName: UserVisibleName,
telemetryServerTypeName: this.GetType().Name);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Composition;
using Microsoft.CodeAnalysis.Host.Mef;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Shared.TestHooks;
using StreamJsonRpc;
namespace Microsoft.CodeAnalysis.LanguageServer
{
[Export(typeof(ILanguageServerFactory)), Shared]
internal class CSharpVisualBasicLanguageServerFactory : ILanguageServerFactory
{
public const string UserVisibleName = "Roslyn Language Server Client";
private readonly RequestDispatcherFactory _dispatcherFactory;
private readonly IAsynchronousOperationListenerProvider _listenerProvider;
private readonly IGlobalOptionService _globalOptions;
[ImportingConstructor]
[Obsolete(MefConstruction.ImportingConstructorMessage, error: true)]
public CSharpVisualBasicLanguageServerFactory(
RequestDispatcherFactory dispatcherFactory,
IAsynchronousOperationListenerProvider listenerProvider,
IGlobalOptionService globalOptions)
{
_dispatcherFactory = dispatcherFactory;
_listenerProvider = listenerProvider;
_globalOptions = globalOptions;
}
public ILanguageServerTarget Create(
JsonRpc jsonRpc,
ICapabilitiesProvider capabilitiesProvider,
ILspWorkspaceRegistrationService workspaceRegistrationService,
ILspLogger logger)
{
return new LanguageServerTarget(
_dispatcherFactory,
jsonRpc,
capabilitiesProvider,
workspaceRegistrationService,
_globalOptions,
_listenerProvider,
logger,
ProtocolConstants.RoslynLspLanguages,
clientName: null,
userVisibleServerName: UserVisibleName,
telemetryServerTypeName: this.GetType().Name);
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./eng/targets/Bootstrap.targets | <!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE file in the project root for more information. -->
<Project>
<Target Name="CheckBootstrapState" AfterTargets="CoreCompile">
<ValidateBootstrap TasksAssemblyFullPath="$(RoslynTasksAssembly)" />
</Target>
</Project>
| <!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE file in the project root for more information. -->
<Project>
<Target Name="CheckBootstrapState" AfterTargets="CoreCompile">
<ValidateBootstrap TasksAssemblyFullPath="$(RoslynTasksAssembly)" />
</Target>
</Project>
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/VisualBasic/Portable/Formatting/Engine/Trivia/TriviaDataFactory.FormattedComplexTrivia.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading
Imports Microsoft.CodeAnalysis.Formatting
Imports Microsoft.CodeAnalysis.Text
Namespace Microsoft.CodeAnalysis.VisualBasic.Formatting
Partial Friend Class TriviaDataFactory
Private Class FormattedComplexTrivia
Inherits TriviaDataWithList
Private ReadOnly _formatter As VisualBasicTriviaFormatter
Private ReadOnly _textChanges As IList(Of TextChange)
Public Sub New(context As FormattingContext,
formattingRules As ChainedFormattingRules,
token1 As SyntaxToken,
token2 As SyntaxToken,
lineBreaks As Integer,
spaces As Integer,
originalString As String,
cancellationToken As CancellationToken)
MyBase.New(context.Options, LanguageNames.VisualBasic)
Contract.ThrowIfNull(context)
Contract.ThrowIfNull(formattingRules)
Contract.ThrowIfNull(originalString)
Me.LineBreaks = Math.Max(0, lineBreaks)
Me.Spaces = Math.Max(0, spaces)
Dim lines = Me.LineBreaks
_formatter = New VisualBasicTriviaFormatter(context, formattingRules, token1, token2, originalString, Math.Max(0, lines), Me.Spaces)
_textChanges = _formatter.FormatToTextChanges(cancellationToken)
End Sub
Public Overrides ReadOnly Property TreatAsElastic() As Boolean
Get
Return False
End Get
End Property
Public Overrides ReadOnly Property IsWhitespaceOnlyTrivia() As Boolean
Get
Return False
End Get
End Property
Public Overrides ReadOnly Property ContainsChanges() As Boolean
Get
Return Me._textChanges.Count > 0
End Get
End Property
Public Overrides Function GetTextChanges(span As TextSpan) As IEnumerable(Of TextChange)
Return Me._textChanges
End Function
Public Overrides Function GetTriviaList(cancellationToken As CancellationToken) As SyntaxTriviaList
Return _formatter.FormatToSyntaxTrivia(cancellationToken)
End Function
Public Overrides Sub Format(context As FormattingContext,
formattingRules As ChainedFormattingRules,
formattingResultApplier As Action(Of Integer, TokenStream, TriviaData),
cancellationToken As CancellationToken,
Optional tokenPairIndex As Integer = TokenPairIndexNotNeeded)
Throw New NotImplementedException()
End Sub
Public Overrides Function WithIndentation(indentation As Integer, context As FormattingContext, formattingRules As ChainedFormattingRules, cancellationToken As CancellationToken) As TriviaData
Throw New NotImplementedException()
End Function
Public Overrides Function WithLine(line As Integer, indentation As Integer, context As FormattingContext, formattingRules As ChainedFormattingRules, cancellationToken As CancellationToken) As TriviaData
Throw New NotImplementedException()
End Function
Public Overrides Function WithSpace(space As Integer, context As FormattingContext, formattingRules As ChainedFormattingRules) As TriviaData
Throw New NotImplementedException()
End Function
End Class
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading
Imports Microsoft.CodeAnalysis.Formatting
Imports Microsoft.CodeAnalysis.Text
Namespace Microsoft.CodeAnalysis.VisualBasic.Formatting
Partial Friend Class TriviaDataFactory
Private Class FormattedComplexTrivia
Inherits TriviaDataWithList
Private ReadOnly _formatter As VisualBasicTriviaFormatter
Private ReadOnly _textChanges As IList(Of TextChange)
Public Sub New(context As FormattingContext,
formattingRules As ChainedFormattingRules,
token1 As SyntaxToken,
token2 As SyntaxToken,
lineBreaks As Integer,
spaces As Integer,
originalString As String,
cancellationToken As CancellationToken)
MyBase.New(context.Options, LanguageNames.VisualBasic)
Contract.ThrowIfNull(context)
Contract.ThrowIfNull(formattingRules)
Contract.ThrowIfNull(originalString)
Me.LineBreaks = Math.Max(0, lineBreaks)
Me.Spaces = Math.Max(0, spaces)
Dim lines = Me.LineBreaks
_formatter = New VisualBasicTriviaFormatter(context, formattingRules, token1, token2, originalString, Math.Max(0, lines), Me.Spaces)
_textChanges = _formatter.FormatToTextChanges(cancellationToken)
End Sub
Public Overrides ReadOnly Property TreatAsElastic() As Boolean
Get
Return False
End Get
End Property
Public Overrides ReadOnly Property IsWhitespaceOnlyTrivia() As Boolean
Get
Return False
End Get
End Property
Public Overrides ReadOnly Property ContainsChanges() As Boolean
Get
Return Me._textChanges.Count > 0
End Get
End Property
Public Overrides Function GetTextChanges(span As TextSpan) As IEnumerable(Of TextChange)
Return Me._textChanges
End Function
Public Overrides Function GetTriviaList(cancellationToken As CancellationToken) As SyntaxTriviaList
Return _formatter.FormatToSyntaxTrivia(cancellationToken)
End Function
Public Overrides Sub Format(context As FormattingContext,
formattingRules As ChainedFormattingRules,
formattingResultApplier As Action(Of Integer, TokenStream, TriviaData),
cancellationToken As CancellationToken,
Optional tokenPairIndex As Integer = TokenPairIndexNotNeeded)
Throw New NotImplementedException()
End Sub
Public Overrides Function WithIndentation(indentation As Integer, context As FormattingContext, formattingRules As ChainedFormattingRules, cancellationToken As CancellationToken) As TriviaData
Throw New NotImplementedException()
End Function
Public Overrides Function WithLine(line As Integer, indentation As Integer, context As FormattingContext, formattingRules As ChainedFormattingRules, cancellationToken As CancellationToken) As TriviaData
Throw New NotImplementedException()
End Function
Public Overrides Function WithSpace(space As Integer, context As FormattingContext, formattingRules As ChainedFormattingRules) As TriviaData
Throw New NotImplementedException()
End Function
End Class
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Test/IOperation/IOperation/IOperationTests_IEventAssignmentExpression.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Roslyn.Test.Utilities
Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests.Semantics
Partial Public Class IOperationTests
Inherits SemanticModelTestBase
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub AddEventHandler()
Dim source = <![CDATA[
Imports System
Class TestClass
Event TestEvent As Action
Sub Add()
AddHandler TestEvent, AddressOf M'BIND:"AddHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'TestEvent')
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub RemoveEventHandler()
Dim source = <![CDATA[
Imports System
Class TestClass
Event TestEvent As Action
Sub Remove()
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... AddressOf M')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'TestEvent')
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub AddEventHandler_StaticEvent()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Add()
AddHandler TestEvent, AddressOf M'BIND:"AddHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub RemoveEventHandler_StaticEvent()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Remove()
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... AddressOf M')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub RemoveEventHandler_DelegateTypeMismatch()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Remove()
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
End Sub
Sub M(x as Integer)
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'RemoveHandl ... AddressOf M')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'RemoveHandl ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsInvalid, IsImplicit) (Syntax: 'AddressOf M')
Target:
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'AddressOf M')
Children(1):
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'M')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsInvalid, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC31143: Method 'Public Sub M(x As Integer)' does not have a signature compatible with delegate 'Delegate Sub Action()'.
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
~
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub AddEventHandler_AssignToSharedEventOnInstance()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Remove()
AddHandler Me.TestEvent, AddressOf M 'BIND:"AddHandler Me.TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'Me.TestEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass) (Syntax: 'Me')
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC42025: Access of shared member, constant member, enum member or nested type through an instance; qualifying expression will not be evaluated.
AddHandler Me.TestEvent, AddressOf M 'BIND:"AddHandler Me.TestEvent, AddressOf M"
~~~~~~~~~~~~
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
<WorkItem(8909, "https://github.com/dotnet/roslyn/issues/8909")>
Public Sub AddEventHandler_AssignToNonSharedEventOnType()
Dim source = <![CDATA[
Imports System
Class TestClass
Event TestEvent As Action
Sub Remove()
AddHandler TestClass.TestEvent, AddressOf M 'BIND:"AddHandler TestClass.TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (OperationKind.EventReference, Type: System.Action, IsInvalid) (Syntax: 'TestClass.TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30469: Reference to a non-shared member requires an object reference.
AddHandler TestClass.TestEvent, AddressOf M 'BIND:"AddHandler TestClass.TestEvent, AddressOf M"
~~~~~~~~~~~~~~~~~~~
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_NoControlFlow()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(handler As EventHandler) 'BIND:"Sub M(handler As EventHandler)"
AddHandler MyEvent, handler
RemoveHandler MyEvent, handler
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (2)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... nt, handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... nt, handler')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInEventReference()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(c As C1, c2 As C1, handler As EventHandler) 'BIND:"Sub M(c As C1, c2 As C1, handler As EventHandler)"
AddHandler If(c, c2).MyEvent, handler
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1} {R2}
.locals {R1}
{
CaptureIds: [1]
.locals {R2}
{
CaptureIds: [0]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C1) (Syntax: 'c')
Jump if True (Regular) to Block[B3]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'c')
Operand:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Leaving: {R2}
Next (Regular) Block[B2]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Next (Regular) Block[B4]
Leaving: {R2}
}
Block[B3] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c2')
Value:
IParameterReferenceOperation: c2 (OperationKind.ParameterReference, Type: C1) (Syntax: 'c2')
Next (Regular) Block[B4]
Block[B4] - Block
Predecessors: [B2] [B3]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... nt, handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'If(c, c2).MyEvent')
Instance Receiver:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'If(c, c2)')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B5]
Leaving: {R1}
}
Block[B5] - Exit
Predecessors: [B4]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInEventReference_StaticEvent()
Dim source = <![CDATA[
Imports System
Class C1
Public Shared Event MyEvent As EventHandler
Sub M(c As C1, c2 As C1, handler As EventHandler) 'BIND:"Sub M(c As C1, c2 As C1, handler As EventHandler)"
AddHandler If(c, c2).MyEvent, handler
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... nt, handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (Static) (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'If(c, c2).MyEvent')
Instance Receiver:
null
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC42025: Access of shared member, constant member, enum member or nested type through an instance; qualifying expression will not be evaluated.
AddHandler If(c, c2).MyEvent, handler
~~~~~~~~~~~~~~~~~
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInHandler_InstanceReceiver()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(handler1 As EventHandler, handler2 As EventHandler) 'BIND:"Sub M(handler1 As EventHandler, handler2 As EventHandler)"
RemoveHandler MyEvent, If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1}
.locals {R1}
{
CaptureIds: [0] [2]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'MyEvent')
Value:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Next (Regular) Block[B2]
Entering: {R2}
.locals {R2}
{
CaptureIds: [1]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B4]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B3]
Block[B3] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B5]
Leaving: {R2}
}
Block[B4] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B3] [B4]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... , handler2)')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Handler:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B6]
Leaving: {R1}
}
Block[B6] - Exit
Predecessors: [B5]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInHandler_NullReceiver()
Dim source = <![CDATA[
Imports System
Class C1
Public Shared Event MyEvent As EventHandler
Sub M(handler1 As EventHandler, handler2 As EventHandler) 'BIND:"Sub M(handler1 As EventHandler, handler2 As EventHandler)"
RemoveHandler MyEvent, If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1} {R2}
.locals {R1}
{
CaptureIds: [1]
.locals {R2}
{
CaptureIds: [0]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B3]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B2]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B4]
Leaving: {R2}
}
Block[B3] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B4]
Block[B4] - Block
Predecessors: [B2] [B3]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... , handler2)')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (Static) (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
null
Handler:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B5]
Leaving: {R1}
}
Block[B5] - Exit
Predecessors: [B4]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInEventReferenceAndHandler()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(c As C1, c2 As C1, handler1 As EventHandler, handler2 As EventHandler) 'BIND:"Sub M(c As C1, c2 As C1, handler1 As EventHandler, handler2 As EventHandler)"
AddHandler If(c, c2).MyEvent, If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1} {R2}
.locals {R1}
{
CaptureIds: [1] [3]
.locals {R2}
{
CaptureIds: [0]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C1) (Syntax: 'c')
Jump if True (Regular) to Block[B3]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'c')
Operand:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Leaving: {R2}
Next (Regular) Block[B2]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Next (Regular) Block[B4]
Leaving: {R2}
Entering: {R3}
}
Block[B3] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c2')
Value:
IParameterReferenceOperation: c2 (OperationKind.ParameterReference, Type: C1) (Syntax: 'c2')
Next (Regular) Block[B4]
Entering: {R3}
.locals {R3}
{
CaptureIds: [2]
Block[B4] - Block
Predecessors: [B2] [B3]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B6]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R3}
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B4]
Statements (1)
IFlowCaptureOperation: 3 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B7]
Leaving: {R3}
}
Block[B6] - Block
Predecessors: [B4]
Statements (1)
IFlowCaptureOperation: 3 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B7]
Block[B7] - Block
Predecessors: [B5] [B6]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... , handler2)')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'If(c, c2).MyEvent')
Instance Receiver:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'If(c, c2)')
Handler:
IFlowCaptureReferenceOperation: 3 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B8]
Leaving: {R1}
}
Block[B8] - Exit
Predecessors: [B7]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub EventAssignment_ErrorCase_InaccessibleEvent()
Dim source = <![CDATA[
Public Class Form1
Private Event EventB As System.Action
End Class
Public Class Form2
Inherits Form1
Public Sub M()
AddHandler MyBase.EventB, Nothing 'BIND:"AddHandler MyBase.EventB, Nothing"
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30389: 'Form1.EventB' is not accessible in this context because it is 'Private'.
AddHandler MyBase.EventB, Nothing 'BIND:"AddHandler MyBase.EventB, Nothing"
~~~~~~~~~~~~~
]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... tB, Nothing')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... tB, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: null, IsInvalid) (Syntax: 'MyBase.EventB')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: Form1, IsInvalid) (Syntax: 'MyBase')
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub EventAssignment_ErrorCase_MissingEvent()
Dim source = <![CDATA[
Public Class Form1
Private Event EventB As System.Action
End Class
Public Class Form2
Inherits Form1
Public Sub M()
RemoveHandler EventX, Nothing'BIND:"RemoveHandler EventX, Nothing"
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30451: 'EventX' is not declared. It may be inaccessible due to its protection level.
RemoveHandler EventX, Nothing'BIND:"RemoveHandler EventX, Nothing"
~~~~~~
]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'RemoveHandl ... tX, Nothing')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'RemoveHandl ... tX, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'EventX')
Children(0)
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ErrorCases_NoControlFlow()
Dim source = <![CDATA[
Public Class Form1
Private Event EventB As System.Action
End Class
Public Class Form2
Inherits Form1
Public Sub M()'BIND:"Public Sub M()"
AddHandler MyBase.EventB, Nothing
RemoveHandler EventX, Nothing
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30389: 'Form1.EventB' is not accessible in this context because it is 'Private'.
AddHandler MyBase.EventB, Nothing
~~~~~~~~~~~~~
BC30451: 'EventX' is not declared. It may be inaccessible due to its protection level.
RemoveHandler EventX, Nothing
~~~~~~
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (2)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... tB, Nothing')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... tB, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: null, IsInvalid) (Syntax: 'MyBase.EventB')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: Form1, IsInvalid) (Syntax: 'MyBase')
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'RemoveHandl ... tX, Nothing')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'RemoveHandl ... tX, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'EventX')
Children(0)
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ErrorCases_ControlFlowInHandler()
Dim source = <![CDATA[
Imports System
Public Class Form1
Private Event EventB As EventHandler
End Class
Public Class Form2
Inherits Form1
Public Sub M(handler1 As EventHandler, handler2 As EventHandler)'BIND:"Public Sub M(handler1 As EventHandler, handler2 As EventHandler)"
AddHandler MyBase.EventB, If(handler1, handler2)
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30389: 'Form1.EventB' is not accessible in this context because it is 'Private'.
AddHandler MyBase.EventB, If(handler1, handler2)
~~~~~~~~~~~~~
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1}
.locals {R1}
{
CaptureIds: [0] [2]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsInvalid, IsImplicit) (Syntax: 'MyBase.EventB')
Value:
IInvalidOperation (OperationKind.Invalid, Type: null, IsInvalid) (Syntax: 'MyBase.EventB')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: Form1, IsInvalid) (Syntax: 'MyBase')
Next (Regular) Block[B2]
Entering: {R2}
.locals {R2}
{
CaptureIds: [1]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B4]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B3]
Block[B3] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B5]
Leaving: {R2}
}
Block[B4] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B3] [B4]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... , handler2)')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... , handler2)')
Event Reference:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: null, IsInvalid, IsImplicit) (Syntax: 'MyBase.EventB')
Handler:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B6]
Leaving: {R1}
}
Block[B6] - Exit
Predecessors: [B5]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub EventAssignment_ParenthesizedEventReference()
Dim source = <![CDATA[
Imports System
Class C
Event TestEvent As EventHandler
Public Sub M(c As C, handler As EventHandler)
AddHandler(c.TestEvent), handler 'BIND:"AddHandler(c.TestEvent), handler"
End Sub
Public Sub M2()
End Sub
End Class]]>.Value
Dim expectedDiagnostics = String.Empty
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler( ... t), handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler( ... t), handler')
Event Reference:
IParenthesizedOperation (OperationKind.Parenthesized, Type: System.EventHandler) (Syntax: '(c.TestEvent)')
Operand:
IEventReferenceOperation: Event C.TestEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'c.TestEvent')
Instance Receiver:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C) (Syntax: 'c')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ParenthesizedEventReference_NoControlFlow()
Dim source = <![CDATA[
Imports System
Class C
Event TestEvent As EventHandler
Public Sub M(c As C, handler As EventHandler)'BIND:"Public Sub M(c As C, handler As EventHandler)"
AddHandler(c.TestEvent), handler
End Sub
Public Sub M2()
End Sub
End Class
]]>.Value
Dim expectedDiagnostics = String.Empty
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler( ... t), handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler( ... t), handler')
Event Reference:
IEventReferenceOperation: Event C.TestEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: '(c.TestEvent)')
Instance Receiver:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C) (Syntax: 'c')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ParenthesizedInvalidEventReference_NoControlFlow()
Dim source = <![CDATA[
Imports System
Module M1
Sub Main(v As AppDomain, handler As EventHandler)'BIND:"Sub Main(v As AppDomain, handler As EventHandler)"
AddHandler (v.DomainUnload()), handler
End Sub
End Module
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30677: 'AddHandler' or 'RemoveHandler' statement event operand must be a dot-qualified expression or a simple name.
AddHandler (v.DomainUnload()), handler
~~~~~~~~~~~~~~~~
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... )), handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... )), handler')
Event Reference:
IParenthesizedOperation (OperationKind.Parenthesized, Type: ?, IsInvalid) (Syntax: '(v.DomainUnload())')
Operand:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'v.DomainUnload()')
Children(1):
IEventReferenceOperation: Event System.AppDomain.DomainUnload As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler, IsInvalid) (Syntax: 'v.DomainUnload')
Instance Receiver:
IParameterReferenceOperation: v (OperationKind.ParameterReference, Type: System.AppDomain, IsInvalid) (Syntax: 'v')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ParenthesizedEventReference_ControlFlowInHandler()
Dim source = <![CDATA[
Imports System
Class C
Event TestEvent As EventHandler
Public Sub M(c As C, handler1 As EventHandler, handler2 As EventHandler)'BIND:"Public Sub M(c As C, handler1 As EventHandler, handler2 As EventHandler)"
AddHandler(c.TestEvent), If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedDiagnostics = String.Empty
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1}
.locals {R1}
{
CaptureIds: [0] [2]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C) (Syntax: 'c')
Next (Regular) Block[B2]
Entering: {R2}
.locals {R2}
{
CaptureIds: [1]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B4]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B3]
Block[B3] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B5]
Leaving: {R2}
}
Block[B4] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B3] [B4]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler( ... , handler2)')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler( ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C.TestEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: '(c.TestEvent)')
Instance Receiver:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'c')
Handler:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B6]
Leaving: {R1}
}
Block[B6] - Exit
Predecessors: [B5]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Roslyn.Test.Utilities
Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests.Semantics
Partial Public Class IOperationTests
Inherits SemanticModelTestBase
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub AddEventHandler()
Dim source = <![CDATA[
Imports System
Class TestClass
Event TestEvent As Action
Sub Add()
AddHandler TestEvent, AddressOf M'BIND:"AddHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'TestEvent')
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub RemoveEventHandler()
Dim source = <![CDATA[
Imports System
Class TestClass
Event TestEvent As Action
Sub Remove()
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... AddressOf M')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'TestEvent')
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub AddEventHandler_StaticEvent()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Add()
AddHandler TestEvent, AddressOf M'BIND:"AddHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub RemoveEventHandler_StaticEvent()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Remove()
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... AddressOf M')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub RemoveEventHandler_DelegateTypeMismatch()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Remove()
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
End Sub
Sub M(x as Integer)
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'RemoveHandl ... AddressOf M')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'RemoveHandl ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsInvalid, IsImplicit) (Syntax: 'AddressOf M')
Target:
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'AddressOf M')
Children(1):
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'M')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsInvalid, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC31143: Method 'Public Sub M(x As Integer)' does not have a signature compatible with delegate 'Delegate Sub Action()'.
RemoveHandler TestEvent, AddressOf M'BIND:"RemoveHandler TestEvent, AddressOf M"
~
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub AddEventHandler_AssignToSharedEventOnInstance()
Dim source = <![CDATA[
Imports System
Class TestClass
Shared Event TestEvent As Action
Sub Remove()
AddHandler Me.TestEvent, AddressOf M 'BIND:"AddHandler Me.TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (Static) (OperationKind.EventReference, Type: System.Action) (Syntax: 'Me.TestEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass) (Syntax: 'Me')
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC42025: Access of shared member, constant member, enum member or nested type through an instance; qualifying expression will not be evaluated.
AddHandler Me.TestEvent, AddressOf M 'BIND:"AddHandler Me.TestEvent, AddressOf M"
~~~~~~~~~~~~
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
<WorkItem(8909, "https://github.com/dotnet/roslyn/issues/8909")>
Public Sub AddEventHandler_AssignToNonSharedEventOnType()
Dim source = <![CDATA[
Imports System
Class TestClass
Event TestEvent As Action
Sub Remove()
AddHandler TestClass.TestEvent, AddressOf M 'BIND:"AddHandler TestClass.TestEvent, AddressOf M"
End Sub
Sub M()
End Sub
End Class]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... AddressOf M')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... AddressOf M')
Event Reference:
IEventReferenceOperation: Event TestClass.TestEvent As System.Action (OperationKind.EventReference, Type: System.Action, IsInvalid) (Syntax: 'TestClass.TestEvent')
Instance Receiver:
null
Handler:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: System.Action, IsImplicit) (Syntax: 'AddressOf M')
Target:
IMethodReferenceOperation: Sub TestClass.M() (OperationKind.MethodReference, Type: null) (Syntax: 'AddressOf M')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: TestClass, IsImplicit) (Syntax: 'M')
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30469: Reference to a non-shared member requires an object reference.
AddHandler TestClass.TestEvent, AddressOf M 'BIND:"AddHandler TestClass.TestEvent, AddressOf M"
~~~~~~~~~~~~~~~~~~~
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_NoControlFlow()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(handler As EventHandler) 'BIND:"Sub M(handler As EventHandler)"
AddHandler MyEvent, handler
RemoveHandler MyEvent, handler
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (2)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... nt, handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... nt, handler')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInEventReference()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(c As C1, c2 As C1, handler As EventHandler) 'BIND:"Sub M(c As C1, c2 As C1, handler As EventHandler)"
AddHandler If(c, c2).MyEvent, handler
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1} {R2}
.locals {R1}
{
CaptureIds: [1]
.locals {R2}
{
CaptureIds: [0]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C1) (Syntax: 'c')
Jump if True (Regular) to Block[B3]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'c')
Operand:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Leaving: {R2}
Next (Regular) Block[B2]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Next (Regular) Block[B4]
Leaving: {R2}
}
Block[B3] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c2')
Value:
IParameterReferenceOperation: c2 (OperationKind.ParameterReference, Type: C1) (Syntax: 'c2')
Next (Regular) Block[B4]
Block[B4] - Block
Predecessors: [B2] [B3]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... nt, handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'If(c, c2).MyEvent')
Instance Receiver:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'If(c, c2)')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B5]
Leaving: {R1}
}
Block[B5] - Exit
Predecessors: [B4]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInEventReference_StaticEvent()
Dim source = <![CDATA[
Imports System
Class C1
Public Shared Event MyEvent As EventHandler
Sub M(c As C1, c2 As C1, handler As EventHandler) 'BIND:"Sub M(c As C1, c2 As C1, handler As EventHandler)"
AddHandler If(c, c2).MyEvent, handler
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... nt, handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... nt, handler')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (Static) (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'If(c, c2).MyEvent')
Instance Receiver:
null
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC42025: Access of shared member, constant member, enum member or nested type through an instance; qualifying expression will not be evaluated.
AddHandler If(c, c2).MyEvent, handler
~~~~~~~~~~~~~~~~~
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInHandler_InstanceReceiver()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(handler1 As EventHandler, handler2 As EventHandler) 'BIND:"Sub M(handler1 As EventHandler, handler2 As EventHandler)"
RemoveHandler MyEvent, If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1}
.locals {R1}
{
CaptureIds: [0] [2]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'MyEvent')
Value:
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Next (Regular) Block[B2]
Entering: {R2}
.locals {R2}
{
CaptureIds: [1]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B4]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B3]
Block[B3] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B5]
Leaving: {R2}
}
Block[B4] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B3] [B4]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... , handler2)')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'MyEvent')
Handler:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B6]
Leaving: {R1}
}
Block[B6] - Exit
Predecessors: [B5]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInHandler_NullReceiver()
Dim source = <![CDATA[
Imports System
Class C1
Public Shared Event MyEvent As EventHandler
Sub M(handler1 As EventHandler, handler2 As EventHandler) 'BIND:"Sub M(handler1 As EventHandler, handler2 As EventHandler)"
RemoveHandler MyEvent, If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1} {R2}
.locals {R1}
{
CaptureIds: [1]
.locals {R2}
{
CaptureIds: [0]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B3]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B2]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B4]
Leaving: {R2}
}
Block[B3] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B4]
Block[B4] - Block
Predecessors: [B2] [B3]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'RemoveHandl ... , handler2)')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'RemoveHandl ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (Static) (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'MyEvent')
Instance Receiver:
null
Handler:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B5]
Leaving: {R1}
}
Block[B5] - Exit
Predecessors: [B4]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact()>
Public Sub EventAssignment_ControlFlowInEventReferenceAndHandler()
Dim source = <![CDATA[
Imports System
Class C1
Public Event MyEvent As EventHandler
Sub M(c As C1, c2 As C1, handler1 As EventHandler, handler2 As EventHandler) 'BIND:"Sub M(c As C1, c2 As C1, handler1 As EventHandler, handler2 As EventHandler)"
AddHandler If(c, c2).MyEvent, If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1} {R2}
.locals {R1}
{
CaptureIds: [1] [3]
.locals {R2}
{
CaptureIds: [0]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C1) (Syntax: 'c')
Jump if True (Regular) to Block[B3]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'c')
Operand:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Leaving: {R2}
Next (Regular) Block[B2]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'c')
Next (Regular) Block[B4]
Leaving: {R2}
Entering: {R3}
}
Block[B3] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c2')
Value:
IParameterReferenceOperation: c2 (OperationKind.ParameterReference, Type: C1) (Syntax: 'c2')
Next (Regular) Block[B4]
Entering: {R3}
.locals {R3}
{
CaptureIds: [2]
Block[B4] - Block
Predecessors: [B2] [B3]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B6]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R3}
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B4]
Statements (1)
IFlowCaptureOperation: 3 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B7]
Leaving: {R3}
}
Block[B6] - Block
Predecessors: [B4]
Statements (1)
IFlowCaptureOperation: 3 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B7]
Block[B7] - Block
Predecessors: [B5] [B6]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler ... , handler2)')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C1.MyEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'If(c, c2).MyEvent')
Instance Receiver:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: C1, IsImplicit) (Syntax: 'If(c, c2)')
Handler:
IFlowCaptureReferenceOperation: 3 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B8]
Leaving: {R1}
}
Block[B8] - Exit
Predecessors: [B7]
Statements (0)
]]>.Value
Dim expectedDiagnostics = String.Empty
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub EventAssignment_ErrorCase_InaccessibleEvent()
Dim source = <![CDATA[
Public Class Form1
Private Event EventB As System.Action
End Class
Public Class Form2
Inherits Form1
Public Sub M()
AddHandler MyBase.EventB, Nothing 'BIND:"AddHandler MyBase.EventB, Nothing"
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30389: 'Form1.EventB' is not accessible in this context because it is 'Private'.
AddHandler MyBase.EventB, Nothing 'BIND:"AddHandler MyBase.EventB, Nothing"
~~~~~~~~~~~~~
]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... tB, Nothing')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... tB, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: null, IsInvalid) (Syntax: 'MyBase.EventB')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: Form1, IsInvalid) (Syntax: 'MyBase')
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub EventAssignment_ErrorCase_MissingEvent()
Dim source = <![CDATA[
Public Class Form1
Private Event EventB As System.Action
End Class
Public Class Form2
Inherits Form1
Public Sub M()
RemoveHandler EventX, Nothing'BIND:"RemoveHandler EventX, Nothing"
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30451: 'EventX' is not declared. It may be inaccessible due to its protection level.
RemoveHandler EventX, Nothing'BIND:"RemoveHandler EventX, Nothing"
~~~~~~
]]>.Value
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'RemoveHandl ... tX, Nothing')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'RemoveHandl ... tX, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'EventX')
Children(0)
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ErrorCases_NoControlFlow()
Dim source = <![CDATA[
Public Class Form1
Private Event EventB As System.Action
End Class
Public Class Form2
Inherits Form1
Public Sub M()'BIND:"Public Sub M()"
AddHandler MyBase.EventB, Nothing
RemoveHandler EventX, Nothing
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30389: 'Form1.EventB' is not accessible in this context because it is 'Private'.
AddHandler MyBase.EventB, Nothing
~~~~~~~~~~~~~
BC30451: 'EventX' is not declared. It may be inaccessible due to its protection level.
RemoveHandler EventX, Nothing
~~~~~~
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (2)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... tB, Nothing')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... tB, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: null, IsInvalid) (Syntax: 'MyBase.EventB')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: Form1, IsInvalid) (Syntax: 'MyBase')
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'RemoveHandl ... tX, Nothing')
Expression:
IEventAssignmentOperation (EventRemove) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'RemoveHandl ... tX, Nothing')
Event Reference:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'EventX')
Children(0)
Handler:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'Nothing')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ErrorCases_ControlFlowInHandler()
Dim source = <![CDATA[
Imports System
Public Class Form1
Private Event EventB As EventHandler
End Class
Public Class Form2
Inherits Form1
Public Sub M(handler1 As EventHandler, handler2 As EventHandler)'BIND:"Public Sub M(handler1 As EventHandler, handler2 As EventHandler)"
AddHandler MyBase.EventB, If(handler1, handler2)
End Sub
End Class]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30389: 'Form1.EventB' is not accessible in this context because it is 'Private'.
AddHandler MyBase.EventB, If(handler1, handler2)
~~~~~~~~~~~~~
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1}
.locals {R1}
{
CaptureIds: [0] [2]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsInvalid, IsImplicit) (Syntax: 'MyBase.EventB')
Value:
IInvalidOperation (OperationKind.Invalid, Type: null, IsInvalid) (Syntax: 'MyBase.EventB')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: Form1, IsInvalid) (Syntax: 'MyBase')
Next (Regular) Block[B2]
Entering: {R2}
.locals {R2}
{
CaptureIds: [1]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B4]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B3]
Block[B3] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B5]
Leaving: {R2}
}
Block[B4] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B3] [B4]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... , handler2)')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... , handler2)')
Event Reference:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: null, IsInvalid, IsImplicit) (Syntax: 'MyBase.EventB')
Handler:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B6]
Leaving: {R1}
}
Block[B6] - Exit
Predecessors: [B5]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation)>
<Fact>
Public Sub EventAssignment_ParenthesizedEventReference()
Dim source = <![CDATA[
Imports System
Class C
Event TestEvent As EventHandler
Public Sub M(c As C, handler As EventHandler)
AddHandler(c.TestEvent), handler 'BIND:"AddHandler(c.TestEvent), handler"
End Sub
Public Sub M2()
End Sub
End Class]]>.Value
Dim expectedDiagnostics = String.Empty
Dim expectedOperationTree = <![CDATA[
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler( ... t), handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler( ... t), handler')
Event Reference:
IParenthesizedOperation (OperationKind.Parenthesized, Type: System.EventHandler) (Syntax: '(c.TestEvent)')
Operand:
IEventReferenceOperation: Event C.TestEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: 'c.TestEvent')
Instance Receiver:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C) (Syntax: 'c')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
]]>.Value
VerifyOperationTreeAndDiagnosticsForTest(Of AddRemoveHandlerStatementSyntax)(source, expectedOperationTree, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ParenthesizedEventReference_NoControlFlow()
Dim source = <![CDATA[
Imports System
Class C
Event TestEvent As EventHandler
Public Sub M(c As C, handler As EventHandler)'BIND:"Public Sub M(c As C, handler As EventHandler)"
AddHandler(c.TestEvent), handler
End Sub
Public Sub M2()
End Sub
End Class
]]>.Value
Dim expectedDiagnostics = String.Empty
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler( ... t), handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler( ... t), handler')
Event Reference:
IEventReferenceOperation: Event C.TestEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: '(c.TestEvent)')
Instance Receiver:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C) (Syntax: 'c')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ParenthesizedInvalidEventReference_NoControlFlow()
Dim source = <![CDATA[
Imports System
Module M1
Sub Main(v As AppDomain, handler As EventHandler)'BIND:"Sub Main(v As AppDomain, handler As EventHandler)"
AddHandler (v.DomainUnload()), handler
End Sub
End Module
]]>.Value
Dim expectedDiagnostics = <![CDATA[
BC30677: 'AddHandler' or 'RemoveHandler' statement event operand must be a dot-qualified expression or a simple name.
AddHandler (v.DomainUnload()), handler
~~~~~~~~~~~~~~~~
]]>.Value
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null, IsInvalid) (Syntax: 'AddHandler ... )), handler')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsInvalid, IsImplicit) (Syntax: 'AddHandler ... )), handler')
Event Reference:
IParenthesizedOperation (OperationKind.Parenthesized, Type: ?, IsInvalid) (Syntax: '(v.DomainUnload())')
Operand:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'v.DomainUnload()')
Children(1):
IEventReferenceOperation: Event System.AppDomain.DomainUnload As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler, IsInvalid) (Syntax: 'v.DomainUnload')
Instance Receiver:
IParameterReferenceOperation: v (OperationKind.ParameterReference, Type: System.AppDomain, IsInvalid) (Syntax: 'v')
Handler:
IParameterReferenceOperation: handler (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler')
Next (Regular) Block[B2]
Block[B2] - Exit
Predecessors: [B1]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
<CompilerTrait(CompilerFeature.IOperation, CompilerFeature.Dataflow)>
<Fact>
Public Sub EventAssignment_ParenthesizedEventReference_ControlFlowInHandler()
Dim source = <![CDATA[
Imports System
Class C
Event TestEvent As EventHandler
Public Sub M(c As C, handler1 As EventHandler, handler2 As EventHandler)'BIND:"Public Sub M(c As C, handler1 As EventHandler, handler2 As EventHandler)"
AddHandler(c.TestEvent), If(handler1, handler2)
End Sub
End Class
]]>.Value
Dim expectedDiagnostics = String.Empty
Dim expectedFlowGraph = <![CDATA[
Block[B0] - Entry
Statements (0)
Next (Regular) Block[B1]
Entering: {R1}
.locals {R1}
{
CaptureIds: [0] [2]
Block[B1] - Block
Predecessors: [B0]
Statements (1)
IFlowCaptureOperation: 0 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'c')
Value:
IParameterReferenceOperation: c (OperationKind.ParameterReference, Type: C) (Syntax: 'c')
Next (Regular) Block[B2]
Entering: {R2}
.locals {R2}
{
CaptureIds: [1]
Block[B2] - Block
Predecessors: [B1]
Statements (1)
IFlowCaptureOperation: 1 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IParameterReferenceOperation: handler1 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler1')
Jump if True (Regular) to Block[B4]
IIsNullOperation (OperationKind.IsNull, Type: System.Boolean, IsImplicit) (Syntax: 'handler1')
Operand:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Leaving: {R2}
Next (Regular) Block[B3]
Block[B3] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler1')
Value:
IFlowCaptureReferenceOperation: 1 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'handler1')
Next (Regular) Block[B5]
Leaving: {R2}
}
Block[B4] - Block
Predecessors: [B2]
Statements (1)
IFlowCaptureOperation: 2 (OperationKind.FlowCapture, Type: null, IsImplicit) (Syntax: 'handler2')
Value:
IParameterReferenceOperation: handler2 (OperationKind.ParameterReference, Type: System.EventHandler) (Syntax: 'handler2')
Next (Regular) Block[B5]
Block[B5] - Block
Predecessors: [B3] [B4]
Statements (1)
IExpressionStatementOperation (OperationKind.ExpressionStatement, Type: null) (Syntax: 'AddHandler( ... , handler2)')
Expression:
IEventAssignmentOperation (EventAdd) (OperationKind.EventAssignment, Type: null, IsImplicit) (Syntax: 'AddHandler( ... , handler2)')
Event Reference:
IEventReferenceOperation: Event C.TestEvent As System.EventHandler (OperationKind.EventReference, Type: System.EventHandler) (Syntax: '(c.TestEvent)')
Instance Receiver:
IFlowCaptureReferenceOperation: 0 (OperationKind.FlowCaptureReference, Type: C, IsImplicit) (Syntax: 'c')
Handler:
IFlowCaptureReferenceOperation: 2 (OperationKind.FlowCaptureReference, Type: System.EventHandler, IsImplicit) (Syntax: 'If(handler1, handler2)')
Next (Regular) Block[B6]
Leaving: {R1}
}
Block[B6] - Exit
Predecessors: [B5]
Statements (0)
]]>.Value
VerifyFlowGraphAndDiagnosticsForTest(Of MethodBlockSyntax)(source, expectedFlowGraph, expectedDiagnostics)
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/VisualBasic/Impl/ObjectBrowser/VisualBasicSyncClassViewCommandHandler.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.ComponentModel.Composition
Imports Microsoft.CodeAnalysis.Editor
Imports Microsoft.CodeAnalysis.Editor.Shared.Utilities
Imports Microsoft.CodeAnalysis.Host.Mef
Imports Microsoft.VisualStudio.LanguageServices.Implementation.Library.ClassView
Imports Microsoft.VisualStudio.Shell
Imports Microsoft.VisualStudio.Utilities
Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.ObjectBrowser
<Export(GetType(Commanding.ICommandHandler))>
<ContentType(ContentTypeNames.VisualBasicContentType)>
<Name(PredefinedCommandHandlerNames.ClassView)>
Friend Class VisualBasicSyncClassViewCommandHandler
Inherits AbstractSyncClassViewCommandHandler
<ImportingConstructor>
<Obsolete(MefConstruction.ImportingConstructorMessage, True)>
Public Sub New(threadingContext As IThreadingContext, serviceProvider As SVsServiceProvider)
MyBase.New(threadingContext, serviceProvider)
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.ComponentModel.Composition
Imports Microsoft.CodeAnalysis.Editor
Imports Microsoft.CodeAnalysis.Editor.Shared.Utilities
Imports Microsoft.CodeAnalysis.Host.Mef
Imports Microsoft.VisualStudio.LanguageServices.Implementation.Library.ClassView
Imports Microsoft.VisualStudio.Shell
Imports Microsoft.VisualStudio.Utilities
Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.ObjectBrowser
<Export(GetType(Commanding.ICommandHandler))>
<ContentType(ContentTypeNames.VisualBasicContentType)>
<Name(PredefinedCommandHandlerNames.ClassView)>
Friend Class VisualBasicSyncClassViewCommandHandler
Inherits AbstractSyncClassViewCommandHandler
<ImportingConstructor>
<Obsolete(MefConstruction.ImportingConstructorMessage, True)>
Public Sub New(threadingContext As IThreadingContext, serviceProvider As SVsServiceProvider)
MyBase.New(threadingContext, serviceProvider)
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Test/Emit/Attributes/AttributeTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Immutable
Imports System.IO
Imports System.Reflection
Imports System.Runtime.InteropServices
Imports System.Xml.Linq
Imports Microsoft.CodeAnalysis.Emit
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.CodeAnalysis.VisualBasic
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols.Metadata.PE
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Roslyn.Test.Utilities
Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests.Semantics
Public Class AttributeTests
Inherits BasicTestBase
#Region "Function Tests"
<WorkItem(530310, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/530310")>
<Fact>
Public Sub PEParameterSymbolParamArrayAttribute()
Dim source1 = <![CDATA[
.assembly extern mscorlib { .ver 4:0:0:0 .publickeytoken = (B7 7A 5C 56 19 34 E0 89) }
.assembly '<<GeneratedFileName>>'
{
}
.class public A
{
.method public hidebysig specialname rtspecialname instance void .ctor() { ret }
.method public static void M(int32 x, int32[] y)
{
.param [2]
.custom instance void [mscorlib]System.ParamArrayAttribute::.ctor() = ( 01 00 00 00 )
ret
}
}]]>.Value
Dim reference1 = CompileIL(source1, prependDefaultHeader:=False)
Dim source2 =
<compilation>
<file name="a.vb">
<![CDATA[
Class C
Shared Sub Main(args As String())
A.M(1, 2, 3)
A.M(1, 2, 3, 4)
End Sub
End Class
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndReferences(source2, {reference1})
Dim method = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("A").GetMember(Of PEMethodSymbol)("M")
Dim yParam = method.Parameters.Item(1)
Assert.Equal(0, yParam.GetAttributes().Length)
Assert.True(yParam.IsParamArray)
CompilationUtils.AssertNoDiagnostics(comp)
End Sub
<Fact>
<WorkItem(20741, "https://github.com/dotnet/roslyn/issues/20741")>
Public Sub TestNamedArgumentOnStringParamsArgument()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class MarkAttribute
Inherits Attribute
Public Sub New(ByVal otherArg As Boolean, ParamArray args As Object())
End Sub
End Class
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
Module Program
Private Sub Test(ByVal otherArg As Boolean, ParamArray args As Object())
End Sub
Sub Main()
Console.WriteLine("Method call")
Test(args:=New String() {"Hello", "World"}, otherArg:=True)
End Sub
End Module
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndVBRuntime(source)
comp.AssertTheseDiagnostics(<errors><![CDATA[
BC30455: Argument not specified for parameter 'otherArg' of 'Public Sub New(otherArg As Boolean, ParamArray args As Object())'.
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
~~~~
BC30661: Field or property 'args' is not found.
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
~~~~
BC30661: Field or property 'otherArg' is not found.
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
~~~~~~~~
BC30587: Named argument cannot match a ParamArray parameter.
Test(args:=New String() {"Hello", "World"}, otherArg:=True)
~~~~
]]></errors>)
End Sub
''' <summary>
''' This function is the same as PEParameterSymbolParamArray
''' except that we check attributes first (to check for race
''' conditions).
''' </summary>
<WorkItem(530310, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/530310")>
<Fact>
Public Sub PEParameterSymbolParamArrayAttribute2()
Dim source1 = <![CDATA[
.assembly extern mscorlib { .ver 4:0:0:0 .publickeytoken = (B7 7A 5C 56 19 34 E0 89) }
.assembly '<<GeneratedFileName>>'
{
}
.class public A
{
.method public hidebysig specialname rtspecialname instance void .ctor() { ret }
.method public static void M(int32 x, int32[] y)
{
.param [2]
.custom instance void [mscorlib]System.ParamArrayAttribute::.ctor() = ( 01 00 00 00 )
ret
}
}]]>.Value
Dim reference1 = CompileIL(source1, prependDefaultHeader:=False)
Dim source2 =
<compilation>
<file name="a.vb">
<![CDATA[
Class C
Shared Sub Main(args As String())
A.M(1, 2, 3)
A.M(1, 2, 3, 4)
End Sub
End Class
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndReferences(source2, {reference1})
Dim method = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("A").GetMember(Of PEMethodSymbol)("M")
Dim yParam = method.Parameters.Item(1)
Assert.True(yParam.IsParamArray)
Assert.Equal(0, yParam.GetAttributes().Length)
CompilationUtils.AssertNoDiagnostics(comp)
End Sub
<Fact>
Public Sub BindingScope_Parameters()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Public Class A
Inherits System.Attribute
Public Sub New(value As Integer)
End Sub
End Class
Class C
Const Value As Integer = 0
Sub method1(<A(Value)> x As Integer)
End Sub
End Class
]]>
</file>
</compilation>
CompileAndVerify(source)
End Sub
<Fact>
Public Sub TestAssemblyAttributes()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.CompilerServices
<assembly: InternalsVisibleTo("Roslyn.Compilers.UnitTests")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.CSharp")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.CSharp.UnitTests")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.CSharp.Test.Utilities")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.VisualBasic")>
]]>
</file>
</compilation>
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim assembly = m.ContainingSymbol
Dim compilerServicesNS = GetSystemRuntimeCompilerServicesNamespace(m)
Dim internalsVisibleToAttr As NamedTypeSymbol = compilerServicesNS.GetTypeMembers("InternalsVisibleToAttribute").First()
Dim attrs = assembly.GetAttributes(internalsVisibleToAttr)
Assert.Equal(5, attrs.Count)
attrs(0).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.UnitTests")
attrs(1).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.CSharp")
attrs(2).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.CSharp.UnitTests")
attrs(3).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.CSharp.Test.Utilities")
attrs(4).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.VisualBasic")
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
Private Function GetSystemRuntimeCompilerServicesNamespace(m As ModuleSymbol) As NamespaceSymbol
Dim compilation = m.DeclaringCompilation
Dim globalNS = If(compilation Is Nothing, m.ContainingAssembly.CorLibrary.GlobalNamespace, compilation.GlobalNamespace)
Return globalNS.
GetMember(Of NamespaceSymbol)("System").
GetMember(Of NamespaceSymbol)("Runtime").
GetMember(Of NamespaceSymbol)("CompilerServices")
End Function
<Fact>
Public Sub TestAssemblyAttributesReflection()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="attr.vb"><![CDATA[
Imports System.Reflection
Imports System.Runtime.CompilerServices
Imports System.Runtime.InteropServices
' These are not pseudo attributes, but encoded as bits in metadata
<assembly: AssemblyAlgorithmId(System.Configuration.Assemblies.AssemblyHashAlgorithm.MD5)>
<assembly: AssemblyCultureAttribute("")>
<assembly: AssemblyDelaySign(true)>
<assembly: AssemblyFlags(AssemblyNameFlags.Retargetable)>
<assembly: AssemblyKeyFile("MyKey.snk")>
<assembly: AssemblyKeyName("Key Name")>
<assembly: AssemblyVersion("1.2.*")>
<assembly: AssemblyFileVersionAttribute("4.3.2.100")>
]]>
</file>
</compilation>)
Dim attrs = compilation.Assembly.GetAttributes()
Assert.Equal(8, attrs.Length)
For Each a In attrs
Select Case a.AttributeClass.Name
Case "AssemblyAlgorithmIdAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(0, a.CommonNamedArguments.Length)
Assert.Equal(TypedConstantKind.Enum, a.CommonConstructorArguments(0).Kind)
Assert.Equal("System.Configuration.Assemblies.AssemblyHashAlgorithm", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(Configuration.Assemblies.AssemblyHashAlgorithm.MD5, CType(a.CommonConstructorArguments(0).Value, Configuration.Assemblies.AssemblyHashAlgorithm))
Case "AssemblyCultureAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(0, a.CommonNamedArguments.Length)
Case "AssemblyDelaySignAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("Boolean", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(True, a.CommonConstructorArguments(0).Value)
Case "AssemblyFlagsAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Enum, a.CommonConstructorArguments(0).Kind)
Assert.Equal("System.Reflection.AssemblyNameFlags", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(AssemblyNameFlags.Retargetable, CType(a.CommonConstructorArguments(0).Value, AssemblyNameFlags))
Case "AssemblyKeyFileAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("MyKey.snk", a.CommonConstructorArguments(0).Value)
Case "AssemblyKeyNameAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("Key Name", a.CommonConstructorArguments(0).Value)
Case "AssemblyVersionAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("1.2.*", a.CommonConstructorArguments(0).Value)
Case "AssemblyFileVersionAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("4.3.2.100", a.CommonConstructorArguments(0).Value)
Case Else
Assert.Equal("Unexpected Attr", a.AttributeClass.Name)
End Select
Next
End Sub
' Verify that resolving an attribute defined within a class on a class does not cause infinite recursion
<Fact>
Public Sub TestAttributesOnClassDefinedInClass()
Dim compilation = CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.CompilerServices
<A.X()>
Public Class A
<AttributeUsage(AttributeTargets.All, allowMultiple:=true)>
Public Class XAttribute
Inherits Attribute
End Class
End Class]]>
</file>
</compilation>)
Dim attrs = compilation.SourceModule.GlobalNamespace.GetMember("A").GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal("A.XAttribute", attrs(0).AttributeClass.ToDisplayString)
End Sub
<WorkItem(540506, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540506")>
<Fact>
Public Sub TestAttributesOnClassWithConstantDefinedInClass()
Dim compilation = CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb"><![CDATA[
<Attr(Goo.p)>
Class Goo
Friend Const p As Object = 2 + 2
End Class
Friend Class AttrAttribute
Inherits Attribute
End Class
]]>
</file>
</compilation>)
Dim attrs = compilation.SourceModule.GlobalNamespace.GetMember("Goo").GetAttributes()
Assert.Equal(1, attrs.Length)
attrs(0).VerifyValue(0, TypedConstantKind.Primitive, 4)
End Sub
<WorkItem(540407, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540407")>
<Fact>
Public Sub TestAttributesOnProperty()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Public Class A
Inherits Attribute
End Class
Public Interface I
<A>
Property AP(<A()>a As Integer) As <A>Integer
End Interface
Public Class C
<A>
Public Property AP As <A>Integer
<A>
Public Property P(<A> a As Integer) As <A>Integer
<A>
Get
Return 0
End Get
<A>
Set(<A>value As Integer)
End Set
End Property
End Class
]]></file>
</compilation>
Dim attributeValidator =
Function(isFromSource As Boolean) _
Sub(m As ModuleSymbol)
Dim i = DirectCast(m.GlobalNamespace.GetMember("I"), NamedTypeSymbol)
Dim c = DirectCast(m.GlobalNamespace.GetMember("C"), NamedTypeSymbol)
' auto-property in interface
Dim ap = i.GetMember("AP")
Assert.Equal(1, ap.GetAttributes().Length)
Dim get_AP = DirectCast(i.GetMember("get_AP"), MethodSymbol)
Assert.Equal(0, get_AP.GetAttributes().Length)
Assert.Equal(1, get_AP.GetReturnTypeAttributes().Length)
Assert.Equal(1, get_AP.Parameters(0).GetAttributes().Length)
Dim set_AP = DirectCast(i.GetMember("set_AP"), MethodSymbol)
Assert.Equal(0, set_AP.GetAttributes().Length)
Assert.Equal(0, set_AP.GetReturnTypeAttributes().Length)
Assert.Equal(1, set_AP.Parameters(0).GetAttributes().Length)
Assert.Equal(0, set_AP.Parameters(1).GetAttributes().Length)
' auto-property on class
ap = c.GetMember("AP")
Assert.Equal(1, ap.GetAttributes().Length)
get_AP = DirectCast(c.GetMember("get_AP"), MethodSymbol)
If isFromSource Then
Assert.Equal(0, get_AP.GetAttributes().Length)
Else
AssertEx.Equal({"CompilerGeneratedAttribute"}, GetAttributeNames(get_AP.GetAttributes()))
End If
Assert.Equal(1, get_AP.GetReturnTypeAttributes().Length)
set_AP = DirectCast(c.GetMember("set_AP"), MethodSymbol)
If isFromSource Then
Assert.Equal(0, get_AP.GetAttributes().Length)
Else
AssertEx.Equal({"CompilerGeneratedAttribute"}, GetAttributeNames(set_AP.GetAttributes()))
End If
Assert.Equal(0, set_AP.GetReturnTypeAttributes().Length)
Assert.Equal(0, set_AP.Parameters(0).GetAttributes().Length)
' property
Dim p = c.GetMember("P")
Assert.Equal(1, p.GetAttributes().Length)
Dim get_P = DirectCast(c.GetMember("get_P"), MethodSymbol)
Assert.Equal(1, get_P.GetAttributes().Length)
Assert.Equal(1, get_P.GetReturnTypeAttributes().Length)
Assert.Equal(1, get_P.Parameters(0).GetAttributes().Length)
Dim set_P = DirectCast(c.GetMember("set_P"), MethodSymbol)
Assert.Equal(1, set_P.GetAttributes().Length)
Assert.Equal(0, set_P.GetReturnTypeAttributes().Length)
Assert.Equal(1, set_P.Parameters(0).GetAttributes().Length)
Assert.Equal(1, set_P.Parameters(1).GetAttributes().Length)
End Sub
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator(True), symbolValidator:=attributeValidator(False))
End Sub
<WorkItem(540407, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540407")>
<Fact>
Public Sub TestAttributesOnPropertyReturnType()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Public Class A
Inherits System.Attribute
End Class
Public Class B
Inherits System.Attribute
End Class
Public Interface I
Property Auto As <A> Integer
ReadOnly Property AutoRO As <A> Integer
WriteOnly Property AutoWO As <A> Integer ' warning
End Interface
Public Class C
Property Auto As <A> Integer
ReadOnly Property ROA As <A> Integer
Get
Return 0
End Get
End Property
WriteOnly Property WOA As <A> Integer ' warning
Set(value As Integer)
End Set
End Property
Property A As <A> Integer
Get
Return 0
End Get
Set(value As Integer)
End Set
End Property
Property AB As <A> Integer
Get
Return 0
End Get
Set(<B()> value As Integer)
End Set
End Property
End Class
]]></file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim i = DirectCast(m.GlobalNamespace.GetMember("I"), NamedTypeSymbol)
Dim c = DirectCast(m.GlobalNamespace.GetMember("C"), NamedTypeSymbol)
' auto-property in interface
Dim auto = DirectCast(i.GetMember("Auto"), PropertySymbol)
Assert.Equal(1, auto.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
Dim autoRO = DirectCast(i.GetMember("AutoRO"), PropertySymbol)
Assert.Equal(1, autoRO.GetMethod.GetReturnTypeAttributes().Length)
Assert.Null(autoRO.SetMethod)
Dim autoWO = DirectCast(i.GetMember("AutoWO"), PropertySymbol)
Assert.Null(autoWO.GetMethod)
Assert.Equal(0, autoWO.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
' auto-property in class
auto = DirectCast(c.GetMember("Auto"), PropertySymbol)
Assert.Equal(1, auto.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
' custom property in class
Dim roa = DirectCast(c.GetMember("ROA"), PropertySymbol)
Assert.Equal(1, roa.GetMethod.GetReturnTypeAttributes().Length)
Assert.Null(roa.SetMethod)
Dim woa = DirectCast(c.GetMember("WOA"), PropertySymbol)
Assert.Null(woa.GetMethod)
Assert.Equal(0, woa.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, woa.SetMethod.Parameters(0).GetAttributes().Length)
Dim a = DirectCast(c.GetMember("A"), PropertySymbol)
Assert.Equal(1, a.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, a.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, a.SetMethod.Parameters(0).GetAttributes().Length)
Dim ab = DirectCast(c.GetMember("AB"), PropertySymbol)
Assert.Equal(1, ab.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal("A", ab.GetMethod.GetReturnTypeAttributes()(0).AttributeClass.Name)
Assert.Equal(0, ab.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(1, ab.SetMethod.Parameters(0).GetAttributes().Length)
Assert.Equal("B", ab.SetMethod.Parameters(0).GetAttributes()(0).AttributeClass.Name)
End Sub
Dim verifier = CompileAndVerify(source, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
CompilationUtils.AssertTheseDiagnostics(verifier.Compilation,
<errors><![CDATA[
BC42364: Attributes applied on a return type of a WriteOnly Property have no effect.
WriteOnly Property AutoWO As <A> Integer ' warning
~
BC42364: Attributes applied on a return type of a WriteOnly Property have no effect.
WriteOnly Property WOA As <A> Integer ' warning
~
]]></errors>)
End Sub
<WorkItem(546779, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546779")>
<Fact>
Public Sub TestAttributesOnPropertyReturnType_MarshalAs()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Public Interface I
Property Auto As <MarshalAs(UnmanagedType.I4)> Integer
End Interface
]]></file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim i = DirectCast(m.GlobalNamespace.GetMember("I"), NamedTypeSymbol)
' auto-property in interface
Dim auto = DirectCast(i.GetMember("Auto"), PropertySymbol)
Assert.Equal(UnmanagedType.I4, auto.GetMethod.ReturnTypeMarshallingInformation.UnmanagedType)
Assert.Equal(1, auto.GetMethod.GetReturnTypeAttributes().Length)
Assert.Null(auto.SetMethod.ReturnTypeMarshallingInformation)
Assert.Equal(UnmanagedType.I4, auto.SetMethod.Parameters(0).MarshallingInformation.UnmanagedType)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
End Sub
' TODO (tomat): implement reading from PE: symbolValidator:=attributeValidator
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator)
End Sub
<WorkItem(540433, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540433")>
<Fact>
Public Sub TestAttributesOnPropertyAndGetSet()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
<AObject(GetType(Object), O:=A.obj)>
Public Class A
Public Const obj As Object = Nothing
Public ReadOnly Property RProp As String
<AObject(New Object() {GetType(String)})>
Get
Return Nothing
End Get
End Property
<AObject(New Object() {1, "two", GetType(String), 3.1415926})>
Public WriteOnly Property WProp
<AObject(New Object() {New Object() {GetType(String)}})>
Set(value)
End Set
End Property
End Class
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.MDTestAttributeDefLib.AsImmutableOrNull())},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim type = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = type.GetAttributes()
Assert.Equal("AObjectAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Type, GetType(Object))
attrs(0).VerifyValue(Of Object)(0, "O", TypedConstantKind.Primitive, Nothing)
Dim prop = type.GetMember(Of PropertySymbol)("RProp")
attrs = prop.GetMethod.GetAttributes()
attrs(0).VerifyValue(0, TypedConstantKind.Array, {GetType(String)})
prop = type.GetMember(Of PropertySymbol)("WProp")
attrs = prop.GetAttributes()
attrs(0).VerifyValue(Of Object())(0, TypedConstantKind.Array, {1, "two", GetType(String), 3.1415926})
attrs = prop.SetMethod.GetAttributes()
attrs(0).VerifyValue(0, TypedConstantKind.Array, {New Object() {GetType(String)}})
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestAttributesOnPropertyParameters()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Public Class A
Inherits Attribute
End Class
Public Class X
Public Property P(<A>a As Integer) As <A>Integer
Get
Return 0
End Get
Set(<A>value As Integer)
End Set
End Property
End Class
]]>
</file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim type = DirectCast(m.GlobalNamespace.GetMember("X"), NamedTypeSymbol)
Dim getter = DirectCast(type.GetMember("get_P"), MethodSymbol)
Dim setter = DirectCast(type.GetMember("set_P"), MethodSymbol)
' getter
Assert.Equal(1, getter.Parameters.Length)
Assert.Equal(1, getter.Parameters(0).GetAttributes().Length)
Assert.Equal(1, getter.GetReturnTypeAttributes().Length)
' setter
Assert.Equal(2, setter.Parameters.Length)
Assert.Equal(1, setter.Parameters(0).GetAttributes().Length)
Assert.Equal(1, setter.Parameters(1).GetAttributes().Length)
End Sub
CompileAndVerify(source, symbolValidator:=attributeValidator, sourceSymbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestAttributesOnEnumField()
Dim source =
<compilation>
<file name="attr.vb"><![CDATA[
Option Strict On
Imports System
Imports system.Collections.Generic
Imports System.Reflection
Imports CustomAttribute
Imports AN = CustomAttribute.AttrName
' Use AttrName without Attribute suffix
<Assembly: AN(UShortField:=4321)>
<Assembly: AN(UShortField:=1234)>
<Module: AttrName(TypeField:=GetType(System.IO.FileStream))>
Namespace AttributeTest
Public Interface IGoo
Class NestedClass
' enum as object
<AllInheritMultiple(System.IO.FileMode.Open, BindingFlags.DeclaredOnly Or BindingFlags.Public, UIntField:=123 * Field)>
Public Const Field As UInteger = 10
End Class
<AllInheritMultiple(New Char() {"q"c, "c"c}, "")>
<AllInheritMultiple()>
Enum NestedEnum
zero
one = 1
<AllInheritMultiple(Nothing, 256, 0.0F, -1, AryField:=New ULong() {0, 1, 12345657})>
<AllInheritMultipleAttribute(GetType(Dictionary(Of String, Integer)), 255 + NestedClass.Field, -0.0001F, 3 - CShort(NestedEnum.oneagain))>
three = 3
oneagain = one
End Enum
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator =
Function(isFromSource As Boolean) _
Sub(m As ModuleSymbol)
Dim attrs = m.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal("CustomAttribute.AttrNameAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(0, "TypeField", TypedConstantKind.Type, GetType(FileStream))
Dim assembly = m.ContainingSymbol
attrs = assembly.GetAttributes()
If isFromSource Then
Assert.Equal(2, attrs.Length)
Assert.Equal("CustomAttribute.AttrName", attrs(0).AttributeClass.ToDisplayString)
attrs(1).VerifyValue(Of UShort)(0, "UShortField", TypedConstantKind.Primitive, 1234)
Else
Assert.Equal(5, attrs.Length) ' 3 synthesized assembly attributes
Assert.Equal("CustomAttribute.AttrName", attrs(3).AttributeClass.ToDisplayString)
attrs(4).VerifyValue(Of UShort)(0, "UShortField", TypedConstantKind.Primitive, 1234)
End If
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim top = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim type = top.GetMember(Of NamedTypeSymbol)("NestedClass")
Dim field = type.GetMember(Of FieldSymbol)("Field")
attrs = field.GetAttributes()
Assert.Equal("CustomAttribute.AllInheritMultipleAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(0, TypedConstantKind.Enum, CInt(FileMode.Open))
attrs(0).VerifyValue(1, TypedConstantKind.Enum, CInt(BindingFlags.DeclaredOnly Or BindingFlags.Public))
attrs(0).VerifyValue(0, "UIntField", TypedConstantKind.Primitive, 1230)
Dim nenum = top.GetMember(Of TypeSymbol)("NestedEnum")
attrs = nenum.GetAttributes()
Assert.Equal(2, attrs.Length)
attrs(0).VerifyValue(0, TypedConstantKind.Array, {"q"c, "c"c})
attrs = nenum.GetMember("three").GetAttributes()
Assert.Equal(2, attrs.Length)
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, Nothing)
attrs(0).VerifyValue(Of Long)(1, TypedConstantKind.Primitive, 256)
attrs(0).VerifyValue(Of Single)(2, TypedConstantKind.Primitive, 0)
attrs(0).VerifyValue(Of Short)(3, TypedConstantKind.Primitive, -1)
attrs(0).VerifyValue(Of ULong())(0, "AryField", TypedConstantKind.Array, New ULong() {0, 1, 12345657})
attrs(1).VerifyValue(Of Object)(0, TypedConstantKind.Type, GetType(Dictionary(Of String, Integer)))
attrs(1).VerifyValue(Of Long)(1, TypedConstantKind.Primitive, 265)
attrs(1).VerifyValue(Of Single)(2, TypedConstantKind.Primitive, -0.0001F)
attrs(1).VerifyValue(Of Short)(3, TypedConstantKind.Primitive, 2)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator(True), symbolValidator:=attributeValidator(False))
End Sub
<Fact>
Public Sub TestAttributesOnDelegate()
Dim source =
<compilation>
<file name="TestAttributesOnDelegate.vb"><![CDATA[
Imports System
Imports System.Collections.Generic
Imports CustomAttribute
Namespace AttributeTest
Public Interface IGoo
<AllInheritMultiple(New Object() {0, "", Nothing}, 255, -127 - 1, AryProp:=New Object() {New Object() {"", GetType(IList(Of String))}})>
Delegate Sub NestedSubDele(<AllInheritMultiple()> <Derived(GetType(String(,,)))> p As String)
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim dele = DirectCast(type.GetTypeMember("NestedSubDele"), NamedTypeSymbol)
Dim attrs = dele.GetAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Array, New Object() {0, "", Nothing})
attrs(0).VerifyValue(Of Byte)(1, TypedConstantKind.Primitive, 255)
attrs(0).VerifyValue(Of SByte)(2, TypedConstantKind.Primitive, -128)
attrs(0).VerifyValue(Of Object())(0, "AryProp", TypedConstantKind.Array, New Object() {New Object() {"", GetType(IList(Of String))}})
Dim mem = dele.GetMember(Of MethodSymbol)("Invoke")
' no attributes on the method:
Assert.Equal(0, mem.GetAttributes().Length)
' attributes on parameters:
attrs = mem.Parameters(0).GetAttributes()
Assert.Equal(2, attrs.Length)
attrs(1).VerifyValue(Of Object)(0, TypedConstantKind.Type, GetType(String(,,)))
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(540600, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540600")>
<Fact>
Public Sub TestAttributesUseBaseAttributeField()
Dim source =
<compilation>
<file name="TestAttributesUseBaseAttributeField.vb"><![CDATA[
Imports System
Namespace AttributeTest
Public Interface IGoo
<CustomAttribute.Derived(New Object() {1, Nothing, "Hi"}, ObjectField:=2)>
Function F(p As Integer) As Integer
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim attrs = type.GetMember(Of MethodSymbol)("F").GetAttributes()
Assert.Equal("CustomAttribute.DerivedAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Array, New Object() {1, Nothing, "Hi"})
attrs(0).VerifyValue(Of Object)(0, "ObjectField", TypedConstantKind.Primitive, 2)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact(), WorkItem(529421, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/529421")>
Public Sub TestAttributesWithParamArrayInCtor()
Dim source =
<compilation>
<file name="TestAttributesWithParamArrayInCtor.vb"><![CDATA[
Imports System
Imports CustomAttribute
Namespace AttributeTest
<AllInheritMultiple(New Char() {" "c, Nothing}, "")>
Public Interface IGoo
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim sourceAttributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim attrs = type.GetAttributes()
attrs(0).VerifyValue(Of Char())(0, TypedConstantKind.Array, New Char() {" "c, Nothing})
attrs(0).VerifyValue(Of String())(1, TypedConstantKind.Array, New String() {""})
Dim attrCtor = attrs(0).AttributeConstructor
Debug.Assert(attrCtor.Parameters.Last.IsParamArray)
End Sub
Dim mdAttributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim attrs = type.GetAttributes()
attrs(0).VerifyValue(Of Char())(0, TypedConstantKind.Array, New Char() {" "c, Nothing})
attrs(0).VerifyValue(Of String())(1, TypedConstantKind.Array, New String() {""})
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=sourceAttributeValidator, symbolValidator:=mdAttributeValidator)
End Sub
<WorkItem(540605, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540605")>
<Fact>
Public Sub TestAttributesOnReturnType()
Dim source =
<compilation>
<file name="TestAttributesOnReturnType.vb"><![CDATA[
Imports System
Imports System.Collections.Generic
Imports CustomAttribute
Namespace AttributeTest
Class XAttribute
inherits Attribute
Sub New(s as string)
End Sub
End Class
Public Interface IGoo
Function F1(i as integer) as <X("f1 return type")> string
Property P1 as <X("p1 return type")> string
End Interface
Class C1
Property P1 as <X("p1 return type")> string
ReadOnly Property P2 as <X("p2 return type")> string
Get
return nothing
End Get
End Property
Function F2(i as integer) As <X("f2 returns an integer")> integer
return 0
end function
End Class
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01.AsImmutableOrNull())},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim iGoo = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim f1 = DirectCast(iGoo.GetMember("F1"), MethodSymbol)
Dim attrs = f1.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "f1 return type")
Dim p1 = DirectCast(iGoo.GetMember("P1"), PropertySymbol)
attrs = p1.GetMethod.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "p1 return type")
Dim c1 = DirectCast(ns.GetMember("C1"), NamedTypeSymbol)
Dim p2 = DirectCast(c1.GetMember("P2"), PropertySymbol)
attrs = p2.GetMethod.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "p2 return type")
Dim f2 = DirectCast(c1.GetMember("F2"), MethodSymbol)
attrs = f2.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "f2 returns an integer")
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestAttributesUsageCasing()
Dim source =
<compilation>
<file name="TestAttributesOnReturnType.vb"><![CDATA[
Imports System
Imports System.Collections.Generic
Imports CustomAttribute
Namespace AttributeTest
<ATTributeUSageATTribute(AttributeTargets.ReturnValue, ALLowMulTiplE:=True, InHeRIteD:=false)>
Class XAttribute
Inherits Attribute
Sub New()
End Sub
End Class
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim xAttributeClass = DirectCast(ns.GetMember("XAttribute"), NamedTypeSymbol)
Dim attributeUsage = xAttributeClass.GetAttributeUsageInfo()
Assert.Equal(AttributeTargets.ReturnValue, attributeUsage.ValidTargets)
Assert.Equal(True, attributeUsage.AllowMultiple)
Assert.Equal(False, attributeUsage.Inherited)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(540940, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540940")>
<Fact>
Public Sub TestAttributeWithParamArray()
Dim source =
<compilation>
<file name="TestAttributeWithParamArray.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(ParamArray x As Integer())
End Sub
End Class
<A>
Module M
Sub Main()
End Sub
End Module
]]></file>
</compilation>
CompileAndVerify(source)
End Sub
<WorkItem(528469, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/528469")>
<Fact()>
Public Sub TestAttributeWithAttributeTargets()
Dim source =
<compilation>
<file name="TestAttributeWithParamArray.vb"><![CDATA[
Imports System
<System.AttributeUsage(AttributeTargets.All)> _
Class ZAttribute
Inherits Attribute
End Class
<Z()> _
Class scen1
End Class
Module M1
Sub goo()
<Z()> _
Static x1 As Object
End Sub
End Module
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
CompileAndVerify(compilation)
End Sub
<WorkItem(541277, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541277")>
<Fact>
Public Sub TestAttributeEmitObjectValue()
Dim source =
<compilation>
<file name="TestAttributeEmitObjectValue.vb"><![CDATA[
Imports System
<AttributeUsageAttribute(AttributeTargets.All, AllowMultiple:=True)>
Class A
Inherits Attribute
Public Property X As Object
Public Sub New()
End Sub
Public Sub New(o As Object)
End Sub
End Class
<A(1)>
<A(New String() {"a", "b"})>
<A(X:=1), A(X:=New String() {"a", "b"})>
Class B
Shared Sub Main()
Dim b As New B()
Dim a As A = b.GetType().GetCustomAttributes(False)(0)
Console.WriteLine(a.X)
End Sub
End Class
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim bClass = DirectCast(m.GlobalNamespace.GetMember("B"), NamedTypeSymbol)
Dim attrs = bClass.GetAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, 1)
attrs(1).VerifyValue(Of Object)(0, TypedConstantKind.Array, New String() {"a", "b"})
attrs(2).VerifyValue(Of Object)(0, "X", TypedConstantKind.Primitive, 1)
attrs(3).VerifyValue(Of Object)(0, "X", TypedConstantKind.Array, New String() {"a", "b"})
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(541278, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541278")>
<Fact>
Public Sub TestAttributeEmitGenericEnumValue()
Dim source =
<compilation>
<file name="TestAttributeEmitObjectValue.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(x As Object)
Y = x
End Sub
Public Property Y As Object
End Class
Class B(Of T)
Class D
End Class
Enum E
A = &HABCDEF
End Enum
End Class
<A(B(Of Integer).E.A)>
Class C
End Class
Module m1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim cClass = DirectCast(m.GlobalNamespace.GetMember("C"), NamedTypeSymbol)
Dim attrs = cClass.GetAttributes()
Dim tc = attrs(0).CommonConstructorArguments(0)
Assert.Equal(tc.Kind, TypedConstantKind.Enum)
Assert.Equal(CType(tc.Value, Int32), &HABCDEF)
Assert.Equal(tc.Type.ToDisplayString, "B(Of Integer).E")
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(546380, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546380")>
<Fact()>
Public Sub TestAttributeEmitOpenGeneric()
Dim source =
<compilation>
<file name="TestAttributeEmitObjectValue.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(x As Object)
Y = x
End Sub
Public Property Y As Object
End Class
<A(GetType(B(Of)))>
Class B(Of T)
End Class
Module m1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim bClass = DirectCast(m.GlobalNamespace.GetMember("B"), NamedTypeSymbol)
Dim attrs = bClass.GetAttributes()
attrs(0).VerifyValue(0, TypedConstantKind.Type, bClass.ConstructUnboundGenericType())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(541278, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541278")>
<Fact>
Public Sub TestAttributeToString()
Dim source =
<compilation>
<file name="TestAttributeToString.vb"><![CDATA[
Imports System
<AttributeUsageAttribute(AttributeTargets.Class Or AttributeTargets.Struct, AllowMultiple:=True)>
Class A
Inherits Attribute
Public Property X As Object
Public Property T As Type
Public Sub New()
End Sub
Public Sub New(ByVal o As Object)
End Sub
Public Sub New(ByVal y As Y)
End Sub
End Class
Public Enum Y
One = 1
Two = 2
Three = 3
End Enum
<A()>
Class B1
Shared Sub Main()
End Sub
End Class
<A(1)>
Class B2
End Class
<A(New String() {"a", "b"})>
Class B3
End Class
<A(X:=1)>
Class B4
End Class
<A(T:=GetType(String))>
Class B5
End Class
<A(1, X:=1, T:=GetType(String))>
Class B6
End Class
<A(Y.Three)>
Class B7
End Class
<A(DirectCast(5, Y))>
Class B8
End Class
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim aClass = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = aClass.GetAttributes()
Assert.Equal("System.AttributeUsageAttribute(System.AttributeTargets.Class Or System.AttributeTargets.Struct, AllowMultiple:=True)",
attrs(0).ToString())
Dim bClass = DirectCast(m.GlobalNamespace.GetMember("B1"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B2"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(1)", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B3"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A({""a"", ""b""})", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B4"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(X:=1)", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B5"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(T:=GetType(String))", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B6"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(1, X:=1, T:=GetType(String))", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B7"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(Y.Three)", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B8"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(5)", attrs(0).ToString())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(541687, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541687")>
<Fact>
Public Sub Bug_8524_NullAttributeArrayArgument()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Class A
Inherits Attribute
Public Property X As Object
End Class
<A(X:=CStr(Nothing))>
Class B
Shared Sub Main()
Dim b As New B()
Dim a As A = b.GetType().GetCustomAttributes(False)(0)
Console.Write(a.X Is Nothing)
End Sub
End Class
]]>
</file>
</compilation>
CompileAndVerify(source, expectedOutput:="True")
End Sub
<WorkItem(541964, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541964")>
<Fact>
Public Sub TestApplyNamedArgumentTwice()
Dim source =
<compilation>
<file name="TestApplyNamedArgumentTwice.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, AllowMultiple:=False, AllowMultiple:=True), A, A>
Class A
Inherits Attribute
End Class
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim aClass = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = aClass.GetAttributes()
Assert.Equal("System.AttributeUsageAttribute(System.AttributeTargets.All, AllowMultiple:=False, AllowMultiple:=True)",
attrs(0).ToString())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestApplyNamedArgumentCasing()
Dim source =
<compilation>
<file name="TestApplyNamedArgumentTwice.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, ALLOWMULTIPLE:=True), A, A>
Class A
Inherits Attribute
End Class
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim aClass = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = aClass.GetAttributes()
Assert.Equal("System.AttributeUsageAttribute(System.AttributeTargets.All, AllowMultiple:=True)",
attrs(0).ToString())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(542123, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542123")>
<Fact>
Public Sub TestApplyNestedDerivedAttribute()
Dim source =
<compilation>
<file name="TestApplyNestedDerivedAttribute.vb"><![CDATA[
Imports System
<First.Second.Third()>
Class First : Inherits Attribute
Class Second : Inherits First
End Class
Class Third : Inherits Second
End Class
End Class
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
compilation.VerifyDiagnostics()
End Sub
<WorkItem(542269, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542269")>
<Fact>
Public Sub TestApplyNestedDerivedAttributeOnTypeAndItsMember()
Dim source =
<compilation>
<file name="TestApplyNestedDerivedAttributeOnTypeAndItsMember.vb"><![CDATA[
Imports System
Public Class First : Inherits Attribute
<AttributeUsage(AttributeTargets.Class Or AttributeTargets.Method)>
Friend Class Second
Inherits First
End Class
End Class
<First.Second()>
Module Module1
<First.Second()>
Function ToString(x As Integer, y As Integer) As String
Return Nothing
End Function
Public Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
compilation.VerifyDiagnostics()
End Sub
<Fact>
Public Sub AttributeTargets_Method()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Method)>
Class Attr
Inherits Attribute
End Class
Public Class C
<Attr()>
Custom Event EvntWithAccessors As Action(Of Integer)
<Attr()>
AddHandler(value As Action(Of Integer))
End AddHandler
<Attr()>
RemoveHandler(value As Action(Of Integer))
End RemoveHandler
<Attr()>
RaiseEvent(obj As Integer)
End RaiseEvent
End Event
<Attr()>
Property PropertyWithAccessors As Integer
<Attr()>
Get
Return 0
End Get
<Attr()>
Set(value As Integer)
End Set
End Property
<Attr()>
Shared Sub Sub1()
End Sub
<Attr()>
Function Ftn2() As Integer
Return 1
End Function
<Attr()>
Declare Function DeclareFtn Lib "bar" () As Integer
<Attr()>
Declare Sub DeclareSub Lib "bar" ()
<Attr()>
Shared Operator -(a As C, b As C) As Integer
Return 0
End Operator
<Attr()>
Shared Narrowing Operator CType(a As C) As Integer
Return 0
End Operator
<Attr()>
Public Event Evnt As Action(Of Integer)
<Attr()>
Public Field As Integer
<Attr()>
Public WithEvents WE As NestedType
<Attr()>
Class NestedType
End Class
<Attr()>
Interface Iface
End Interface
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Evnt"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Field"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "WE"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "NestedType"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Iface"))
End Sub
<Fact>
Public Sub AttributeTargets_Field()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Field)>
Class Attr
Inherits Attribute
End Class
Public Class C
<Attr()>
Custom Event EvntWithAccessors As Action(Of Integer)
<Attr()>
AddHandler(value As Action(Of Integer))
End AddHandler
<Attr()>
RemoveHandler(value As Action(Of Integer))
End RemoveHandler
<Attr()>
RaiseEvent(obj As Integer)
End RaiseEvent
End Event
<Attr()>
Property PropertyWithAccessors As Integer
<Attr()>
Get
Return 0
End Get
<Attr()>
Set(value As Integer)
End Set
End Property
<Attr()>
Shared Sub Sub1()
End Sub
<Attr()>
Function Ftn2() As Integer
Return 1
End Function
<Attr()>
Declare Function DeclareFtn Lib "bar" () As Integer
<Attr()>
Declare Sub DeclareSub Lib "bar" ()
<Attr()>
Shared Operator -(a As C, b As C) As Integer
Return 0
End Operator
<Attr()>
Shared Narrowing Operator CType(a As C) As Integer
Return 0
End Operator
<Attr()>
Public Event Evnt As Action(Of Integer)
<Attr()>
Public Field As Integer
<Attr()>
Public WithEvents WE As NestedType
<Attr()>
Class NestedType
End Class
<Attr()>
Interface Iface
End Interface
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "AddHandler", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "RemoveHandler", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "RaiseEvent", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "Get", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "Set", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Sub1"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Ftn2"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "DeclareFtn"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "DeclareSub"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "-"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "CType"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Evnt"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "NestedType"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Iface"))
End Sub
<Fact>
Public Sub AttributeTargets_WithEvents()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Class A
Inherits Attribute
End Class
Class D
<A>
Public WithEvents myButton As Button
End Class
Class Button
Public Event OnClick()
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
Dim d = DirectCast(c.GlobalNamespace.GetMembers("D").Single(), NamedTypeSymbol)
Dim myButton = DirectCast(d.GetMembers("myButton").Single(), PropertySymbol)
Assert.Equal(0, myButton.GetAttributes().Length)
Dim attr = myButton.GetFieldAttributes().Single()
Assert.Equal("A", attr.AttributeClass.Name)
End Sub
<Fact>
Public Sub AttributeTargets_WithEventsGenericInstantiation()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Class A
Inherits Attribute
End Class
Class D(Of T As Button)
<A>
Public WithEvents myButton As T
End Class
Class Button
Public Event OnClick()
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
Dim d = DirectCast(c.GlobalNamespace.GetMembers("D").Single(), NamedTypeSymbol)
Dim button = DirectCast(c.GlobalNamespace.GetMembers("Button").Single(), NamedTypeSymbol)
Dim dOfButton = d.Construct(button)
Dim myButton = DirectCast(dOfButton.GetMembers("myButton").Single(), PropertySymbol)
Assert.Equal(0, myButton.GetAttributes().Length)
Dim attr = myButton.GetFieldAttributes().Single()
Assert.Equal("A", attr.AttributeClass.Name)
End Sub
<Fact>
Public Sub AttributeTargets_Events()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
End Class
<Serializable>
Class D
<A, NonSerialized>
Public Event OnClick As Action
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
c.VerifyDiagnostics()
Dim d = DirectCast(c.GlobalNamespace.GetMembers("D").Single(), NamedTypeSymbol)
Dim onClick = DirectCast(d.GetMembers("OnClick").Single(), EventSymbol)
' TODO (tomat): move NonSerialized attribute onto the associated field
Assert.Equal(2, onClick.GetAttributes().Length) ' should be 1
Assert.Equal(0, onClick.GetFieldAttributes().Length) ' should be 1
End Sub
<Fact, WorkItem(546769, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546769"), WorkItem(546770, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546770")>
Public Sub DiagnosticsOnEventParameters()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Class C
Event E(<MarshalAs()> x As Integer)
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
c.AssertTheseDiagnostics(<![CDATA[
BC30516: Overload resolution failed because no accessible 'New' accepts this number of arguments.
Event E(<MarshalAs()> x As Integer)
~~~~~~~~~
]]>)
End Sub
<Fact, WorkItem(528748, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/528748")>
Public Sub TestNonPublicConstructor()
Dim source =
<compilation>
<file name="TestNonPublicConstructor.vb"><![CDATA[
<Fred(1)>
Class Class1
End Class
Class FredAttribute : Inherits System.Attribute
Public Sub New(x As Integer, Optional y As Integer = 1)
End Sub
Friend Sub New(x As Integer)
End Sub
End Class
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_BadAttributeNonPublicConstructor, "Fred"))
End Sub
<WorkItem(542223, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542223")>
<Fact>
Public Sub AttributeArgumentAsEnumFromMetadata()
Dim metadata1 = VisualBasicCompilation.Create("bar.dll",
references:={MscorlibRef},
syntaxTrees:={Parse("Public Enum Bar : Baz : End Enum")}).EmitToArray(New EmitOptions(metadataOnly:=True))
Dim ref1 = MetadataReference.CreateFromImage(metadata1)
Dim metadata2 = VisualBasicCompilation.Create(
"goo.dll",
references:={MscorlibRef, ref1},
syntaxTrees:={
VisualBasicSyntaxTree.ParseText(<![CDATA[
Public Class Ca : Inherits System.Attribute
Public Sub New(o As Object)
End Sub
End Class
<Ca(Bar.Baz)>
Public Class Goo
End Class]]>.Value)}).EmitToArray(options:=New EmitOptions(metadataOnly:=True))
Dim ref2 = MetadataReference.CreateFromImage(metadata2)
Dim comp = VisualBasicCompilation.Create("moo.dll", references:={MscorlibRef, ref1, ref2})
Dim goo = comp.GetTypeByMetadataName("Goo")
Dim ca = goo.GetAttributes().First().CommonConstructorArguments.First()
Assert.Equal("Bar", ca.Type.Name)
End Sub
<Fact>
Public Sub TestAttributeWithNestedUnboundGeneric()
Dim library =
<file name="Library.vb"><![CDATA[
Namespace ClassLibrary1
Public Class C1(Of T1)
Public Class C2(Of T2, T3)
End Class
End Class
End Namespace
]]>
</file>
Dim compilation1 = VisualBasicCompilation.Create("library.dll",
{VisualBasicSyntaxTree.ParseText(library.Value)},
{MscorlibRef},
TestOptions.ReleaseDll)
Dim classLibrary = MetadataReference.CreateFromImage(compilation1.EmitToArray())
Dim source =
<compilation>
<file name="TestAttributeWithNestedUnboundGeneric.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(ClassLibrary1.C1(Of )))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef, classLibrary})
compilation2.VerifyDiagnostics()
Dim a = compilation2.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, UnboundGenericType)
Assert.Equal("ClassLibrary1.C1(Of )", arg.ToDisplayString)
Assert.False(DirectCast(arg, INamedTypeSymbol).IsSerializable)
End Sub
<Fact>
Public Sub TestAttributeWithAliasToUnboundGeneric()
Dim library =
<file name="Library.vb"><![CDATA[
Namespace ClassLibrary1
Public Class C1(Of T1)
Public Class C2(Of T2, T3)
End Class
End Class
End Namespace
]]>
</file>
Dim compilation1 = VisualBasicCompilation.Create("library.dll",
{VisualBasicSyntaxTree.ParseText(library.Value)},
{MscorlibRef},
TestOptions.ReleaseDll)
Dim classLibrary = MetadataReference.CreateFromImage(compilation1.EmitToArray())
Dim source =
<compilation>
<file name="TestAttributeWithAliasToUnboundGeneric.vb"><![CDATA[
Imports System
Imports x = ClassLibrary1
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(x.C1(Of )))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef, classLibrary})
compilation2.VerifyDiagnostics()
Dim a = compilation2.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, UnboundGenericType)
Assert.Equal("ClassLibrary1.C1(Of )", arg.ToDisplayString)
End Sub
<Fact>
Public Sub TestAttributeWithArrayOfUnboundGeneric()
Dim source =
<compilation>
<file name="TestAttributeWithArrayOfUnboundGeneric.vb"><![CDATA[
Imports System
Class C1(of T)
End Class
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(C1(Of )()))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef})
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_ArrayOfRawGenericInvalid, "()"))
Dim a = compilation.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, ArrayTypeSymbol)
Assert.Equal("C1(Of ?)()", arg.ToDisplayString)
End Sub
<Fact>
Public Sub TestAttributeWithNullableUnboundGeneric()
Dim source =
<compilation>
<file name="TestAttributeWithNullableUnboundGeneric.vb"><![CDATA[
Imports System
Class C1(of T)
End Class
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(C1(Of )?))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef})
CompilationUtils.AssertTheseDiagnostics(compilation,
<errors><![CDATA[
BC33101: Type 'C1(Of ?)' must be a value type or a type argument constrained to 'Structure' in order to be used with 'Nullable' or nullable modifier '?'.
<A(GetType(C1(Of )?))>
~~~~~~~
BC30182: Type expected.
<A(GetType(C1(Of )?))>
~
]]>
</errors>)
Dim a = compilation.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, SubstitutedNamedType)
Assert.Equal("C1(Of ?)?", arg.ToDisplayString)
End Sub
<Fact()>
Public Sub TestConstantValueInsideAttributes()
Dim tree = VisualBasicSyntaxTree.ParseText(<![CDATA[
Class c1
const A as integer = 1;
const B as integer = 2;
class MyAttribute : inherits Attribute
Sub New(i as integer)
End Sub
end class
<MyAttribute(A + B + 3)>
Sub Goo()
End Sub
End Class"]]>.Value)
Dim expr = tree.GetRoot().DescendantNodes().OfType(Of BinaryExpressionSyntax).First()
Dim comp = CreateCompilationWithMscorlib40({tree})
Dim constantValue = comp.GetSemanticModel(tree).GetConstantValue(expr)
Assert.True(constantValue.HasValue)
Assert.Equal(constantValue.Value, 6)
End Sub
<Fact>
Public Sub TestArrayTypeInAttributeArgument()
Dim source =
<compilation>
<file name="TestArrayTypeInAttributeArgument.vb"><![CDATA[
Imports System
Public Class W
End Class
Public Class Y(Of T)
Public Class F
End Class
Public Class Z(Of U)
End Class
End Class
Public Class XAttribute
Inherits Attribute
Public Sub New(y As Object)
End Sub
End Class
<X(GetType(W()))> _
Public Class C1
End Class
<X(GetType(W(,)))> _
Public Class C2
End Class
<X(GetType(W(,)()))> _
Public Class C3
End Class
<X(GetType(Y(Of W)()(,)))> _
Public Class C4
End Class
<X(GetType(Y(Of Integer).F(,)()(,,)))> _
Public Class C5
End Class
<X(GetType(Y(Of Integer).Z(Of W)(,)()))> _
Public Class C6
End Class
]]>
</file>
</compilation>
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim classW As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("W")
Dim classY As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("Y")
Dim classF As NamedTypeSymbol = classY.GetTypeMember("F")
Dim classZ As NamedTypeSymbol = classY.GetTypeMember("Z")
Dim classX As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("XAttribute")
Dim classC1 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C1")
Dim classC2 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C2")
Dim classC3 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C3")
Dim classC4 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C4")
Dim classC5 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C5")
Dim classC6 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C6")
Dim attrs = classC1.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim typeArg = ArrayTypeSymbol.CreateVBArray(classW, Nothing, 1, m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC2.GetAttributes()
Assert.Equal(1, attrs.Length)
typeArg = ArrayTypeSymbol.CreateVBArray(classW, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC3.GetAttributes()
Assert.Equal(1, attrs.Length)
typeArg = ArrayTypeSymbol.CreateVBArray(classW, Nothing, 1, m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC4.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim classYOfW As NamedTypeSymbol = classY.Construct(ImmutableArray.Create(Of TypeSymbol)(classW))
typeArg = ArrayTypeSymbol.CreateVBArray(classYOfW, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, Nothing, 1, m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC5.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim classYOfInt As NamedTypeSymbol = classY.Construct(ImmutableArray.Create(Of TypeSymbol)(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)))
Dim substNestedF As NamedTypeSymbol = classYOfInt.GetTypeMember("F")
typeArg = ArrayTypeSymbol.CreateVBArray(substNestedF, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=3, declaringAssembly:=m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, Nothing, 1, m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC6.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim substNestedZ As NamedTypeSymbol = classYOfInt.GetTypeMember("Z").Construct(ImmutableArray.Create(Of TypeSymbol)(classW))
typeArg = ArrayTypeSymbol.CreateVBArray(substNestedZ, Nothing, 1, m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
End Sub
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
#End Region
#Region "Error Tests"
<Fact>
Public Sub AttributeConstructorErrors1()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="AttributeConstructorErrors1.vb">
<![CDATA[
Imports System
Module m
Function NotAConstant() as integer
return 9
End Function
End Module
Enum e1
a
End Enum
<AttributeUsage(AttributeTargets.All, allowMultiple:=True)>
Class XAttribute
Inherits Attribute
Sub New()
End Sub
Sub New(ByVal d As Decimal)
End Sub
Sub New(ByRef i As Integer)
End Sub
Public Sub New(ByVal e As e1)
End Sub
End Class
<XDoesNotExist>
<X(1D)>
<X(1)>
<X(e1.a)>
<X(NotAConstant() + 2)>
Class A
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors><![CDATA[
BC30002: Type 'XDoesNotExist' is not defined.
<XDoesNotExist>
~~~~~~~~~~~~~
BC30045: Attribute constructor has a parameter of type 'Decimal', which is not an integral, floating-point or Enum type or one of Object, Char, String, Boolean, System.Type or 1-dimensional array of these types.
<X(1D)>
~
BC36006: Attribute constructor has a 'ByRef' parameter of type 'Integer'; cannot use constructors with byref parameters to apply the attribute.
<X(1)>
~
BC31516: Type 'e1' cannot be used in an attribute because it is not declared 'Public'.
<X(e1.a)>
~
BC36006: Attribute constructor has a 'ByRef' parameter of type 'Integer'; cannot use constructors with byref parameters to apply the attribute.
<X(NotAConstant() + 2)>
~
BC30059: Constant expression is required.
<X(NotAConstant() + 2)>
~~~~~~~~~~~~~~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub AttributeConversionsErrors()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="AttributeConversionsErrors.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, allowMultiple:=True)>
Class XAttribute
Inherits Attribute
Sub New()
End Sub
Sub New(i As Integer)
End Sub
End Class
<X("a")>
Class A
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors><![CDATA[
BC30934: Conversion from 'String' to 'Integer' cannot occur in a constant expression used as an argument to an attribute.
<X("a")>
~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub AttributeNamedArgumentErrors1()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="AttributeNamedArgumentErrors1.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, allowMultiple:=True)>
Class XAttribute
Inherits Attribute
Sub F1(i as integer)
End Sub
private PrivateField as integer
shared Property SharedProperty as integer
ReadOnly Property ReadOnlyProperty As Integer
Get
Return Nothing
End Get
End Property
Property BadDecimalType as decimal
Property BadDateType as date
Property BadArrayType As Attribute()
End Class
<X(NotFound := nothing)>
<X(F1 := nothing)>
<X(PrivateField := nothing)>
<X(SharedProperty := nothing)>
<X(ReadOnlyProperty := nothing)>
<X(BadDecimalType := nothing)>
<X(BadDateType := nothing)>
<X(BadArrayType:=Nothing)>
Class A
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30661: Field or property 'NotFound' is not found.
<X(NotFound := nothing)>
~~~~~~~~
BC32010: 'F1' cannot be named as a parameter in an attribute specifier because it is not a field or property.
<X(F1 := nothing)>
~~
BC30389: 'XAttribute.PrivateField' is not accessible in this context because it is 'Private'.
<X(PrivateField := nothing)>
~~~~~~~~~~~~
BC31500: 'Shared' attribute property 'SharedProperty' cannot be the target of an assignment.
<X(SharedProperty := nothing)>
~~~~~~~~~~~~~~
BC31501: 'ReadOnly' attribute property 'ReadOnlyProperty' cannot be the target of an assignment.
<X(ReadOnlyProperty := nothing)>
~~~~~~~~~~~~~~~~
BC30659: Property or field 'BadDecimalType' does not have a valid attribute type.
<X(BadDecimalType := nothing)>
~~~~~~~~~~~~~~
BC30659: Property or field 'BadDateType' does not have a valid attribute type.
<X(BadDateType := nothing)>
~~~~~~~~~~~
BC30659: Property or field 'BadArrayType' does not have a valid attribute type.
<X(BadArrayType:=Nothing)>
~~~~~~~~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<WorkItem(540939, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540939")>
<Fact>
Public Sub AttributeProtectedConstructorError()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<A()>
Class A
Inherits Attribute
Protected Sub New()
End Sub
End Class
<B("goo")>
Class B
Inherits Attribute
Protected Sub New()
End Sub
End Class
<C("goo")>
Class C
Inherits Attribute
Protected Sub New()
End Sub
Protected Sub New(b as string)
End Sub
End Class
<D(1S)>
Class D
Inherits Attribute
Protected Sub New()
End Sub
protected Sub New(b as Integer)
End Sub
protected Sub New(b as Long)
End Sub
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30517: Overload resolution failed because no 'New' is accessible.
<A()>
~~~
BC30517: Overload resolution failed because no 'New' is accessible.
<B("goo")>
~~~~~~~~
BC30517: Overload resolution failed because no 'New' is accessible.
<C("goo")>
~~~~~~~~
BC30517: Overload resolution failed because no 'New' is accessible.
<D(1S)>
~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
' TODO: after fixing LookupResults and changing the error handling for inaccessible attribute constructors,
' the error messages from above are expected to change to something like:
' Error BC30390 'A.Protected Sub New()' is not accessible in this context because it is 'Protected'.
End Sub
<WorkItem(540624, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540624")>
<Fact>
Public Sub AttributeNoMultipleAndInvalidTarget()
Dim source =
<compilation>
<file name="AttributeNoMultipleAndInvalidTarget.vb"><![CDATA[
Imports System
Imports CustomAttribute
<Base(1)>
<Base("SOS")>
Module AttributeMod
<Derived("Q"c)>
<Derived("C"c)>
Public Class Goo
End Class
End Module
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)})
' BC30663, BC30662
Dim expectedErrors =
<errors>
<![CDATA[
BC30663: Attribute 'BaseAttribute' cannot be applied multiple times.
<Base("SOS")>
~~~~~~~~~~~
BC30662: Attribute 'DerivedAttribute' cannot be applied to 'Goo' because the attribute is not valid on this declaration type.
<Derived("Q"c)>
~~~~~~~
BC30663: Attribute 'DerivedAttribute' cannot be applied multiple times.
<Derived("C"c)>
~~~~~~~~~~~~~
]]>
</errors>
CompilationUtils.AssertTheseDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub AttributeNameScoping()
Dim source =
<compilation>
<file name="AttributeNameScoping.vb"><![CDATA[
Imports System
' X1 should not be visible without qualification
<clscompliant(x1)>
Module m1
Const X1 as boolean = true
' C1 should not be visible without qualification
<clscompliant(C1)>
Public Class CGoo
Public Const C1 as Boolean = true
<clscompliant(c1)>
public Sub s()
end sub
End Class
' C1 should not be visible without qualification
<clscompliant(C1)>
Public Structure SGoo
Public Const C1 as Boolean = true
<clscompliant(c1)>
public Sub s()
end sub
End Structure
' s should not be visible without qualification
<clscompliant(s.GetType() isnot nothing)>
Public Interface IGoo
Sub s()
End Interface
' C1 should not be visible without qualification
<clscompliant(a = 1)>
Public Enum EGoo
A = 1
End Enum
End Module
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
compilation.VerifyDiagnostics(
Diagnostic(ERRID.ERR_InaccessibleSymbol2, "x1").WithArguments("m1.X1", "Private"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "C1").WithArguments("C1"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "C1").WithArguments("C1"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "s").WithArguments("s"),
Diagnostic(ERRID.ERR_RequiredConstExpr, "s.GetType() isnot nothing"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "a").WithArguments("a"),
Diagnostic(ERRID.ERR_RequiredConstExpr, "a = 1"))
End Sub
<WorkItem(541279, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541279")>
<Fact>
Public Sub AttributeArrayMissingInitializer()
Dim source =
<compilation>
<file name="AttributeArrayMissingInitializer.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, AllowMultiple:=true)>
Class A
Inherits Attribute
Public Sub New(x As Object())
End Sub
End Class
<A(New Object(5) {})>
<A(New Object(5) {1})>
Class B
Shared Sub Main()
End Sub
End Class
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
compilation.VerifyDiagnostics(
Diagnostic(ERRID.ERR_MissingValuesForArraysInApplAttrs, "{}"),
Diagnostic(ERRID.ERR_InitializerTooFewElements1, "{1}").WithArguments("5")
)
End Sub
<Fact>
Public Sub Bug8642()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<goo(Type.EmptyTypes)>
Module Program
Sub Main(args As String())
End Sub
End Module
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30002: Type 'goo' is not defined.
<goo(Type.EmptyTypes)>
~~~
BC30059: Constant expression is required.
<goo(Type.EmptyTypes)>
~~~~~~~~~~~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub ErrorsInMultipleSyntaxTrees()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<Module: A>
<AttributeUsage(AttributeTargets.Class)>
Class A
Inherits Attribute
End Class
<AttributeUsage(AttributeTargets.Method)>
Class B
Inherits Attribute
End Class
]]>
</file>
<file name="b.vb">
<![CDATA[
<Module: B>
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30549: Attribute 'A' cannot be applied to a module.
<Module: A>
~
BC30549: Attribute 'B' cannot be applied to a module.
<Module: B>
~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub ErrorsInMultiplePartialDeclarations()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Class)>
Class A1
Inherits Attribute
End Class
<AttributeUsage(AttributeTargets.Method)>
Class A2
Inherits Attribute
End Class
<A1>
Class B
End Class
]]>
</file>
<file name="b.vb">
<![CDATA[
<A1, A2>
Partial Class B
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30663: Attribute 'A1' cannot be applied multiple times.
<A1, A2>
~~
BC30662: Attribute 'A2' cannot be applied to 'B' because the attribute is not valid on this declaration type.
<A1, A2>
~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub PartialMethods()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Public Class A
Inherits Attribute
End Class
Public Class B
Inherits Attribute
End Class
Partial Class C
<A>
Private Partial Sub Goo()
End Sub
<B>
Private Sub Goo()
End Sub
End Class
]]>
</file>
</compilation>)
CompileAndVerify(compilation, sourceSymbolValidator:=
Sub(moduleSymbol)
Dim c = DirectCast(moduleSymbol.GlobalNamespace.GetMembers("C").Single(), NamedTypeSymbol)
Dim goo = DirectCast(c.GetMembers("Goo").Single(), MethodSymbol)
Dim attrs = goo.GetAttributes()
Assert.Equal(2, attrs.Length)
Assert.Equal("A", attrs(0).AttributeClass.Name)
Assert.Equal("B", attrs(1).AttributeClass.Name)
End Sub)
End Sub
<WorkItem(542020, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542020")>
<Fact>
Public Sub ErrorsAttributeNameResolutionWithNamespace()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class CAttribute
Inherits Attribute
End Class
Namespace Y.CAttribute
End Namespace
Namespace Y
Namespace X
<C>
Class C
Inherits Attribute
End Class
End Namespace
End Namespace
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30182: Type expected.
<C>
~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<WorkItem(542170, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542170")>
<Fact>
Public Sub GenericTypeParameterUsedAsAttribute()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module M
<T>
Sub Goo(Of T)
End Sub
Class T : Inherits Attribute
End Class
End Module
]]>
</file>
</compilation>)
'BC32067: Type parameters, generic types or types contained in generic types cannot be used as attributes.
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_AttrCannotBeGenerics, "T").WithArguments("T"))
End Sub
<WorkItem(542273, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542273")>
<Fact()>
Public Sub AnonymousTypeFieldAsAttributeNamedArgValue()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Class, AllowMultiple:=New With {.anonymousField = False}.anonymousField)>
Class ExtensionAttribute
Inherits Attribute
End Class
]]>
</file>
</compilation>)
'BC30059: Constant expression is required.
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_RequiredConstExpr, "New With {.anonymousField = False}.anonymousField"))
End Sub
<WorkItem(545073, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545073")>
<Fact>
Public Sub AttributeOnDelegateReturnTypeError()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Public Class ReturnTypeAttribute
Inherits System.Attribute
End Class
Class C
Public Delegate Function D() As <ReturnTypeAttribute(0)> Integer
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40AndVBRuntime(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_TooManyArgs1, "0").WithArguments("Public Sub New()"))
End Sub
<Fact>
Public Sub AttributeOnDelegateParameterError()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Public Class ReturnTypeAttribute
Inherits System.Attribute
End Class
Class C
Public Delegate Function D(<ReturnTypeAttribute(0)>ByRef a As Integer) As Integer
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40AndVBRuntime(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_TooManyArgs1, "0").WithArguments("Public Sub New()"))
End Sub
<WorkItem(545073, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545073")>
<Fact>
Public Sub AttributesOnDelegate()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Public Class A
Inherits System.Attribute
End Class
Public Class B
Inherits System.Attribute
End Class
Public Class C
Inherits System.Attribute
End Class
<A>
Public Delegate Function D(<C>a As Integer, <C>ByRef b As Integer) As <B> Integer
]]>
</file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim d = m.GlobalNamespace.GetTypeMember("D")
Dim invoke = DirectCast(d.GetMember("Invoke"), MethodSymbol)
Dim beginInvoke = DirectCast(d.GetMember("BeginInvoke"), MethodSymbol)
Dim endInvoke = DirectCast(d.GetMember("EndInvoke"), MethodSymbol)
Dim ctor = DirectCast(d.Constructors.Single(), MethodSymbol)
Dim p As ParameterSymbol
' no attributes on methods:
Assert.Equal(0, invoke.GetAttributes().Length)
Assert.Equal(0, beginInvoke.GetAttributes().Length)
Assert.Equal(0, endInvoke.GetAttributes().Length)
Assert.Equal(0, ctor.GetAttributes().Length)
' attributes on return types:
Assert.Equal(0, beginInvoke.GetReturnTypeAttributes().Length)
Assert.Equal(0, endInvoke.GetReturnTypeAttributes().Length)
Assert.Equal(0, ctor.GetReturnTypeAttributes().Length)
Dim attrs = invoke.GetReturnTypeAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "B")
' ctor parameters:
Assert.Equal(2, ctor.Parameters.Length)
Assert.Equal(0, ctor.Parameters(0).GetAttributes().Length)
Assert.Equal(0, ctor.Parameters(0).GetAttributes().Length)
' Invoke parameters:
Assert.Equal(2, invoke.Parameters.Length)
attrs = invoke.Parameters(0).GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
attrs = invoke.Parameters(1).GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
' BeginInvoke parameters:
Assert.Equal(4, beginInvoke.Parameters.Length)
p = beginInvoke.Parameters(0)
Assert.Equal("a", p.Name)
attrs = p.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
Assert.Equal(1, p.GetAttributes(attrs(0).AttributeClass).Count)
Assert.False(p.IsExplicitByRef)
Assert.False(p.IsByRef)
p = beginInvoke.Parameters(1)
Assert.Equal("b", p.Name)
attrs = p.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
Assert.Equal(1, p.GetAttributes(attrs(0).AttributeClass).Count)
Assert.True(p.IsExplicitByRef)
Assert.True(p.IsByRef)
Assert.Equal(0, beginInvoke.Parameters(2).GetAttributes().Length)
Assert.Equal(0, beginInvoke.Parameters(3).GetAttributes().Length)
' EndInvoke parameters:
Assert.Equal(2, endInvoke.Parameters.Length)
p = endInvoke.Parameters(0)
Assert.Equal("b", p.Name)
attrs = p.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
Assert.Equal(1, p.GetAttributes(attrs(0).AttributeClass).Count)
Assert.True(p.IsExplicitByRef)
Assert.True(p.IsByRef)
p = endInvoke.Parameters(1)
attrs = p.GetAttributes()
Assert.Equal(0, attrs.Length)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
#End Region
''' <summary>
''' Verify that inaccessible friend AAttribute is preferred over accessible A
''' </summary>
<Fact()>
Public Sub TestAttributeLookupInaccessibleFriend()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Class A
Inherits System.Attribute
End Class
<A()>
Class C
End Class
Module Module1
Sub Main()
End Sub
End Module]]>
</file>
</compilation>
Dim sourceWithAAttribute As XElement =
<compilation>
<file name="library.vb">
<![CDATA[
Class AAttribute
End Class
]]></file>
</compilation>
Dim compWithAAttribute = VisualBasicCompilation.Create(
"library.dll",
{VisualBasicSyntaxTree.ParseText(sourceWithAAttribute.Value)},
{MsvbRef, MscorlibRef, SystemCoreRef},
TestOptions.ReleaseDll)
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, {compWithAAttribute.ToMetadataReference()})
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_InaccessibleSymbol2, "A").WithArguments("AAttribute", "Friend"))
End Sub
''' <summary>
''' Verify that inaccessible inherited private is preferred
''' </summary>
<Fact()>
Public Sub TestAttributeLookupInaccessibleInheritedPrivate()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class C
Private Class NSAttribute
Inherits Attribute
End Class
End Class
Class d
Inherits C
<NS()>
Sub d()
End Sub
End Class
Module Module1
Sub Main()
End Sub
End Module]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_InaccessibleSymbol2, "NS").WithArguments("C.NSAttribute", "Private"))
End Sub
''' <summary>
''' Verify that ambiguous error is reported when A binds to two Attributes.
''' </summary>
''' <remarks>If this is run in the IDE make sure global namespace is empty or add
''' global namespace prefix to N1 and N2 or run test at command line.</remarks>
<Fact()>
Public Sub TestAttributeLookupAmbiguousAttributesWithPrefix()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Imports System
Imports N1
Imports N2
Namespace N1
Class AAttribute
End Class
End Namespace
Namespace N2
Class AAttribute
End Class
End Namespace
Class A
Inherits Attribute
End Class
<A()>
Class C
End Class]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_AmbiguousInImports2, "A").WithArguments("AAttribute", "N1, N2"))
End Sub
''' <summary>
''' Verify that source attribute takes precedence over metadata attribute with the same name
''' </summary>
<Fact()>
Public Sub TestAttributeLookupSourceOverridesMetadata()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Namespace System.Runtime.CompilerServices
<AttributeUsage(AttributeTargets.Assembly Or AttributeTargets.Class Or AttributeTargets.Method)>
Public Class extensionattribute : Inherits Attribute
End Class
End Namespace
Module m
<System.Runtime.CompilerServices.extension()>
Sub Test1(x As Integer)
System.Console.WriteLine(x)
End Sub
Sub Main()
Dim x = New System.Runtime.CompilerServices.extensionattribute()
End Sub
End Module]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source)
comp.VerifyDiagnostics()
End Sub
<WorkItem(543855, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543855")>
<Fact()>
Public Sub VariantArrayConversionInAttribute()
Dim vbCompilation = CreateVisualBasicCompilation("VariantArrayConversion",
<![CDATA[
Imports System
<Assembly: AObject(new Type() {GetType(string)})>
<AttributeUsage(AttributeTargets.All)>
Public Class AObjectAttribute
Inherits Attribute
Sub New(b As Object)
End Sub
Sub New(b As Object())
End Sub
End Class
]]>,
compilationOptions:=New VisualBasicCompilationOptions(OutputKind.DynamicallyLinkedLibrary))
CompileAndVerify(vbCompilation).VerifyDiagnostics()
End Sub
<Fact(), WorkItem(544199, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544199")>
Public Sub EnumsAllowedToViolateAttributeUsage()
CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
Imports System
Imports System.Runtime.InteropServices
<ComVisible(True)> _
<Guid("6f4eb02b-3469-424c-bbcc-2672f653e646")> _
<BestFitMapping(False)> _
<StructLayout(LayoutKind.Auto)> _
<TypeLibType(TypeLibTypeFlags.FRestricted)> _
<Flags()> _
Public Enum EnumHasAllSupportedAttributes
ID1
ID2
End Enum
</file>
</compilation>).VerifyDiagnostics()
End Sub
<Fact, WorkItem(544367, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544367")>
Public Sub AttributeOnPropertyParameter()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
Imports System
Module Module1
Sub Main()
Dim classAType As Type = GetType(A)
Dim itemGetter = classAType.GetMethod("get_Item")
ShowAttributes(itemGetter.GetParameters()(0))
Dim itemSetter = classAType.GetMethod("set_Item")
ShowAttributes(itemSetter.GetParameters()(0))
End Sub
Sub ShowAttributes(p As Reflection.ParameterInfo)
Dim attrs = p.GetCustomAttributes(False)
Console.WriteLine("param {1} in {0} has {2} attributes", p.Member, p.Name, attrs.Length)
For Each a In attrs
Console.WriteLine(" attribute of type {0}", a.GetType())
Next
End Sub
End Module
Class A
Default Public Property Item( <MyAttr(A.C)> index As Integer) As String
Get
Return ""
End Get
Set(value As String)
End Set
End Property
Public Const C as Integer = 4
End Class
Class MyAttr
Inherits Attribute
Public Sub New(x As Integer)
End Sub
End Class
</file>
</compilation>, TestOptions.ReleaseExe)
CompileAndVerify(comp, <![CDATA[
param index in System.String get_Item(Int32) has 1 attributes
attribute of type MyAttr
param index in Void set_Item(Int32, System.String) has 1 attributes
attribute of type MyAttr
]]>)
End Sub
<Fact, WorkItem(544367, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544367")>
Public Sub AttributeOnPropertyParameterWithError()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Module Module1
Sub Main()
End Sub
End Module
Class A
Default Public Property Item(<MyAttr> index As Integer) As String
Get
Return ""
End Get
Set(value As String)
End Set
End Property
End Class
Class MyAttr
' Does not inherit attribute
End Class
]]>
</file>
</compilation>, TestOptions.ReleaseExe)
CompilationUtils.AssertTheseDiagnostics(comp, <expected>
BC31504: 'MyAttr' cannot be used as an attribute because it does not inherit from 'System.Attribute'.
Default Public Property Item(<MyAttr> index As Integer) As String
~~~~~~
</expected>)
End Sub
<Fact, WorkItem(543810, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543810")>
Public Sub AttributeNamedArgumentWithEvent()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class Base
Event myEvent
End Class
Class Program
Inherits Base
<MyAttribute(t:=myEvent)>
Event MyEvent2
Sub Main(args As String())
End Sub
End Class
Class MyAttribute
Inherits Attribute
Public t As Object
Sub New(t As Integer, Optional x As Integer = 1.0D, Optional y As String = Nothing)
End Sub
End Class
Module m
Sub Main()
End Sub
End Module
]]></file>
</compilation>, TestOptions.ReleaseExe)
CompilationUtils.AssertTheseDiagnostics(comp, <expected><![CDATA[
BC30455: Argument not specified for parameter 't' of 'Public Sub New(t As Integer, [x As Integer = 1], [y As String = Nothing])'.
<MyAttribute(t:=myEvent)>
~~~~~~~~~~~
BC30369: Cannot refer to an instance member of a class from within a shared method or shared member initializer without an explicit instance of the class.
<MyAttribute(t:=myEvent)>
~~~~~~~
]]></expected>)
End Sub
<Fact, WorkItem(543955, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543955")>
Public Sub StringParametersInDeclareMethods_1()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Imports System.Reflection
Module Module1
Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, ByVal buffer As Integer) As Integer
Declare Unicode Function GetWindowsDirectory2 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, ByVal buffer As Integer) As Integer
Declare Auto Function GetWindowsDirectory3 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, ByVal buffer As Integer) As Integer
Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Declare Unicode Function GetWindowsDirectory5 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Declare Auto Function GetWindowsDirectory6 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Delegate Function D(ByRef buffer As String, ByVal buffer As Integer) As Integer
Sub Main()
Dim t = GetType(Module1)
Print(t.GetMethod("GetWindowsDirectory1"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory2"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory3"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory4"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory5"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory6"))
System.Console.WriteLine()
End Sub
Private Sub Print(m As MethodInfo)
System.Console.WriteLine(m.Name)
For Each p In m.GetParameters()
System.Console.WriteLine("{0} As {1}", p.Name, p.ParameterType)
For Each marshal In p.GetCustomAttributes(GetType(Runtime.InteropServices.MarshalAsAttribute), False)
System.Console.WriteLine(DirectCast(marshal, Runtime.InteropServices.MarshalAsAttribute).Value.ToString())
Next
Next
End Sub
Sub Test1(ByRef x As String)
GetWindowsDirectory1(x, 0)
End Sub
Sub Test2(ByRef x As String)
GetWindowsDirectory2(x, 0)
End Sub
Sub Test3(ByRef x As String)
GetWindowsDirectory3(x, 0)
End Sub
Sub Test4(ByRef x As String)
GetWindowsDirectory4(x, 0)
End Sub
Sub Test5(ByRef x As String)
GetWindowsDirectory5(x, 0)
End Sub
Sub Test6(ByRef x As String)
GetWindowsDirectory6(x, 0)
End Sub
Function Test11() As D
Return AddressOf GetWindowsDirectory1
End Function
Function Test12() As D
Return AddressOf GetWindowsDirectory2
End Function
Function Test13() As D
Return AddressOf GetWindowsDirectory3
End Function
Function Test14() As D
Return AddressOf GetWindowsDirectory4
End Function
Function Test15() As D
Return AddressOf GetWindowsDirectory5
End Function
Function Test16() As D
Return AddressOf GetWindowsDirectory6
End Function
End Module
]]></file>
</compilation>, TestOptions.ReleaseExe)
Dim verifier = CompileAndVerify(comp, expectedOutput:=
<![CDATA[
GetWindowsDirectory1
buffer As System.String&
VBByRefStr
buffer As System.Int32
GetWindowsDirectory2
buffer As System.String&
VBByRefStr
buffer As System.Int32
GetWindowsDirectory3
buffer As System.String&
VBByRefStr
buffer As System.Int32
GetWindowsDirectory4
buffer As System.String&
AnsiBStr
buffer As System.Int32
GetWindowsDirectory5
buffer As System.String&
BStr
buffer As System.Int32
GetWindowsDirectory6
buffer As System.String&
TBStr
buffer As System.Int32
]]>)
verifier.VerifyIL("Module1.Test1",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Ansi Function Module1.GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test2",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Unicode Function Module1.GetWindowsDirectory2 Lib "kernel32" Alias "GetWindowsDirectoryW" (String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test3",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Auto Function Module1.GetWindowsDirectory3 Lib "kernel32" Alias "GetWindowsDirectoryW" (String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test4",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Ansi Function Module1.GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test5",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Unicode Function Module1.GetWindowsDirectory5 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test6",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Auto Function Module1.GetWindowsDirectory6 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
End Sub
<Fact, WorkItem(543955, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543955")>
Public Sub StringParametersInDeclareMethods_3()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Imports System.Reflection
Module Module1
Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByVal buffer As String, ByVal buffer As Integer) As Integer
Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Delegate Function D3(buffer As String, ByVal buffer As Integer) As Integer
Delegate Function D4(buffer As Integer, ByVal buffer As Integer) As Integer
Function Test19() As D3
Return AddressOf GetWindowsDirectory1 ' 1
End Function
Function Test20() As D3
Return AddressOf GetWindowsDirectory4 ' 2
End Function
Function Test21() As D4
Return AddressOf GetWindowsDirectory1 ' 3
End Function
Function Test22() As D4
Return AddressOf GetWindowsDirectory4 ' 4
End Function
Sub Main()
End Sub
End Module
]]></file>
</compilation>, TestOptions.ReleaseExe)
AssertTheseDiagnostics(comp,
<expected>
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D3(buffer As String, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory1 ' 1
~~~~~~~~~~~~~~~~~~~~
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D3(buffer As String, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory4 ' 2
~~~~~~~~~~~~~~~~~~~~
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D4(buffer As Integer, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory1 ' 3
~~~~~~~~~~~~~~~~~~~~
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D4(buffer As Integer, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory4 ' 4
~~~~~~~~~~~~~~~~~~~~
</expected>)
End Sub
<WorkItem(529620, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/529620")>
<Fact()>
Public Sub TestFriendEnumInAttribute()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
' Friend Enum in an array in an attribute should be an error.
Imports System
Friend Enum e2
r
g
b
End Enum
Namespace Test2
<MyAttr1(New e2() {e2.g})>
Class C
End Class
Class MyAttr1
Inherits Attribute
Sub New(ByVal B As e2())
End Sub
End Class
End Namespace
]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_BadAttributeNonPublicType1, "MyAttr1").WithArguments("e2()"))
End Sub
<WorkItem(545558, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545558")>
<Fact()>
Public Sub TestUndefinedEnumInAttribute()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System.ComponentModel
Module Program
<EditorBrowsable(EditorBrowsableState.n)>
Sub Main(args As String())
End Sub
End Module
]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_NameNotMember2, "EditorBrowsableState.n").WithArguments("n", "System.ComponentModel.EditorBrowsableState"))
End Sub
<WorkItem(545697, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545697")>
<Fact>
Public Sub TestUnboundLambdaInNamedAttributeArgument()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module Program
<A(F:=Sub()
Dim x = Mid("1", 1)
End Sub)>
Sub Main(args As String())
Dim a As Action = Sub()
Dim x = Mid("1", 1)
End Sub
End Sub
End Module
]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, references:={SystemCoreRef})
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_UndefinedType1, "A").WithArguments("A"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "Mid").WithArguments("Mid"),
Diagnostic(ERRID.ERR_PropertyOrFieldNotDefined1, "F").WithArguments("F"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "Mid").WithArguments("Mid"))
End Sub
<Fact>
Public Sub SpecialNameAttributeFromSource()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System.Runtime.CompilerServices
<SpecialName()>
Public Structure S
<SpecialName()>
Friend Event E As Action(Of String)
<SpecialName()>
Default Property P(b As Byte) As Byte
Get
Return b
End Get
Set(value As Byte)
End Set
End Property
End Structure
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim globalNS = comp.SourceAssembly.GlobalNamespace
Dim typesym = DirectCast(globalNS.GetMember("S"), NamedTypeSymbol)
Assert.NotNull(typesym)
Assert.True(typesym.HasSpecialName)
Dim e = DirectCast(typesym.GetMember("E"), EventSymbol)
Assert.NotNull(e)
Assert.True(e.HasSpecialName)
Dim p = DirectCast(typesym.GetMember("P"), PropertySymbol)
Assert.NotNull(p)
Assert.True(p.HasSpecialName)
Assert.True(e.HasSpecialName)
Assert.Equal("Private EEvent As Action", e.AssociatedField.ToString)
Assert.True(e.HasAssociatedField)
Assert.Equal(ImmutableArray.Create(Of VisualBasicAttributeData)(), e.GetFieldAttributes)
Assert.Null(e.OverriddenEvent)
Assert.NotNull(p)
Assert.True(p.HasSpecialName)
Assert.Equal(ImmutableArray.Create(Of VisualBasicAttributeData)(), p.GetFieldAttributes)
End Sub
''' <summary>
''' Verify that attributeusage from base class is used by derived class
''' </summary>
<Fact()>
Public Sub TestAttributeUsageInheritedBaseAttribute()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module Module1
<DerivedAllowsMultiple()>
<DerivedAllowsMultiple()> ' Should allow multiple
Sub Main()
End Sub
End Module]]>
</file>
</compilation>
Dim sourceWithAttribute As XElement =
<compilation>
<file name="library.vb">
<![CDATA[
Imports System
Public Class DerivedAllowsMultiple
Inherits Base
End Class
<AttributeUsage(AttributeTargets.All, AllowMultiple:=True, Inherited:=true)>
Public Class Base
Inherits Attribute
End Class
]]></file>
</compilation>
Dim compWithAttribute = VisualBasicCompilation.Create(
"library.dll",
{VisualBasicSyntaxTree.ParseText(sourceWithAttribute.Value)},
{MsvbRef, MscorlibRef, SystemCoreRef},
TestOptions.ReleaseDll)
Dim sourceLibRef = compWithAttribute.ToMetadataReference()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, {sourceLibRef})
comp.AssertNoDiagnostics()
Dim metadataLibRef As MetadataReference = compWithAttribute.ToMetadataReference()
comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, {metadataLibRef})
comp.AssertNoDiagnostics()
Dim attributesOnMain = comp.GlobalNamespace.GetModuleMembers("Module1").Single().GetMembers("Main").Single().GetAttributes()
Assert.Equal(2, attributesOnMain.Length())
Assert.NotEqual(attributesOnMain(0).ApplicationSyntaxReference, attributesOnMain(1).ApplicationSyntaxReference)
Assert.NotNull(attributesOnMain(0).ApplicationSyntaxReference)
End Sub
<Fact(), WorkItem(546490, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546490")>
Public Sub Bug15984()
Dim customIL = <![CDATA[
.assembly extern mscorlib { .ver 4:0:0:0 .publickeytoken = (B7 7A 5C 56 19 34 E0 89) }
.assembly extern FSharp.Core {}
.assembly '<<GeneratedFileName>>'
{
}
.class public abstract auto ansi sealed Library1.Goo
extends [mscorlib]System.Object
{
.custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 )
.method public static int32 inc(int32 x) cil managed
{
// Code size 5 (0x5)
.maxstack 8
IL_0000: nop
IL_0001: ldarg.0
IL_0002: ldc.i4.1
IL_0003: add
IL_0004: ret
} // end of method Goo::inc
} // end of class Library1.Goo
]]>
Dim compilation = CompilationUtils.CreateCompilationWithCustomILSource(
<compilation>
<file name="a.vb">
</file>
</compilation>, customIL.Value, appendDefaultHeader:=False)
Dim type = compilation.GetTypeByMetadataName("Library1.Goo")
Assert.Equal(0, type.GetAttributes()(0).ConstructorArguments.Count)
End Sub
<Fact>
<WorkItem(569089, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/569089")>
Public Sub NullArrays()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class A
Inherits Attribute
Public Sub New(a As Object(), b As Integer())
End Sub
Public Property P As Object()
Public F As Integer()
End Class
<A(Nothing, Nothing, P:=Nothing, F:=Nothing)>
Class C
End Class
]]></file>
</compilation>
CompileAndVerify(source, symbolValidator:=
Sub(m)
Dim c = m.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C")
Dim attr = c.GetAttributes().Single()
Dim args = attr.ConstructorArguments.ToArray()
Assert.True(args(0).IsNull)
Assert.Equal("Object()", args(0).Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() args(0).Value)
Assert.True(args(1).IsNull)
Assert.Equal("Integer()", args(1).Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() args(1).Value)
Dim named = attr.NamedArguments.ToDictionary(Function(e) e.Key, Function(e) e.Value)
Assert.True(named("P").IsNull)
Assert.Equal("Object()", named("P").Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() named("P").Value)
Assert.True(named("F").IsNull)
Assert.Equal("Integer()", named("F").Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() named("F").Value)
End Sub)
End Sub
<Fact>
<WorkItem(688268, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/688268")>
Public Sub Bug688268()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Imports System.Security
Public Interface I
Sub _VtblGap1_30()
Sub _VtblGaX1_30()
End Interface
]]></file>
</compilation>
Dim metadataValidator As System.Action(Of ModuleSymbol) =
Sub([module] As ModuleSymbol)
Dim metadata = DirectCast([module], PEModuleSymbol).Module
Dim typeI = DirectCast([module].GlobalNamespace.GetTypeMembers("I").Single(), PENamedTypeSymbol)
Dim methods = metadata.GetMethodsOfTypeOrThrow(typeI.Handle)
Assert.Equal(2, methods.Count)
Dim e = methods.GetEnumerator()
e.MoveNext()
Dim flags = metadata.GetMethodDefFlagsOrThrow(e.Current)
Assert.Equal(
MethodAttributes.PrivateScope Or
MethodAttributes.Public Or
MethodAttributes.Virtual Or
MethodAttributes.VtableLayoutMask Or
MethodAttributes.CheckAccessOnOverride Or
MethodAttributes.Abstract Or
MethodAttributes.SpecialName Or
MethodAttributes.RTSpecialName,
flags)
e.MoveNext()
flags = metadata.GetMethodDefFlagsOrThrow(e.Current)
Assert.Equal(
MethodAttributes.PrivateScope Or
MethodAttributes.Public Or
MethodAttributes.Virtual Or
MethodAttributes.VtableLayoutMask Or
MethodAttributes.CheckAccessOnOverride Or
MethodAttributes.Abstract,
flags)
End Sub
CompileAndVerify(source, symbolValidator:=metadataValidator)
End Sub
<Fact>
Public Sub NullTypeAndString()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class A
Inherits Attribute
Public Sub New(t As Type, s As String)
End Sub
End Class
<A(Nothing, Nothing)>
Class C
End Class
]]></file>
</compilation>
CompileAndVerify(source, symbolValidator:=
Sub(m)
Dim c = m.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C")
Dim attr = c.GetAttributes().Single()
Dim args = attr.ConstructorArguments.ToArray()
Assert.Null(args(0).Value)
Assert.Equal("Type", args(0).Type.Name)
Assert.Throws(Of InvalidOperationException)(Function() args(0).Values)
Assert.Null(args(1).Value)
Assert.Equal("String", args(1).Type.Name)
Assert.Throws(Of InvalidOperationException)(Function() args(1).Values)
End Sub)
End Sub
<Fact>
<WorkItem(728865, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/728865")>
Public Sub Repro728865()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Reflection
Imports Microsoft.Yeti
Namespace PFxIntegration
Public Class ProducerConsumerScenario
Shared Sub Main()
Dim program = GetType(ProducerConsumerScenario)
Dim methodInfo = program.GetMethod("ProducerConsumer")
Dim myAttributes = methodInfo.GetCustomAttributes(False)
If myAttributes.Length > 0 Then
Console.WriteLine()
Console.WriteLine("The attributes for the method - {0} - are: ", methodInfo)
Console.WriteLine()
For j = 0 To myAttributes.Length - 1
Console.WriteLine("The type of the attribute is {0}", myAttributes(j))
Next
End If
End Sub
Public Enum CollectionType
[Default]
Queue
Stack
Bag
End Enum
Public Sub New()
End Sub
<CartesianRowData({5, 100, 100000}, {CollectionType.Default, CollectionType.Queue, CollectionType.Stack, CollectionType.Bag})>
Public Sub ProducerConsumer()
Console.WriteLine("Hello")
End Sub
End Class
End Namespace
Namespace Microsoft.Yeti
<AttributeUsage(AttributeTargets.Method, AllowMultiple:=True)>
Public Class CartesianRowDataAttribute
Inherits Attribute
Public Sub New()
End Sub
Public Sub New(ParamArray data As Object())
Dim asEnum As IEnumerable(Of Object)() = New IEnumerable(Of Object)(data.Length) {}
For i = 0 To data.Length - 1
WrapEnum(DirectCast(data(i), IEnumerable))
Next
End Sub
Shared Sub WrapEnum(x As IEnumerable)
For Each a In x
Console.WriteLine(" - {0} -", a)
Next
End Sub
End Class
End Namespace
]]></file>
</compilation>
CompileAndVerify(source, expectedOutput:=<![CDATA[
- 5 -
- 100 -
- 100000 -
- Default -
- Queue -
- Stack -
- Bag -
The attributes for the method - Void ProducerConsumer() - are:
The type of the attribute is Microsoft.Yeti.CartesianRowDataAttribute]]>)
End Sub
<Fact>
<WorkItem(728865, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/728865")>
Public Sub ParamArrayAttributeConstructor()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class MyAttribute
Inherits Attribute
Public Sub New(ParamArray array As Object())
End Sub
End Class
Public Class Test
<My({1, 2, 3})>
Sub M1()
End Sub
<My(1, 2, 3)>
Sub M2()
End Sub
<My({"A", "B", "C"})>
Sub M3()
End Sub
<My("A", "B", "C")>
Sub M4()
End Sub
<My({{1, 2, 3}, {"A", "B", "C"}})>
Sub M5()
End Sub
<My({1, 2, 3}, {"A", "B", "C"})>
Sub M6()
End Sub
End Class
]]></file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40(source)
Dim type = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Test")
Dim methods = Enumerable.Range(1, 6).Select(Function(i) type.GetMember(Of MethodSymbol)("M" & i)).ToArray()
methods(0).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Integer() {1, 2, 3})
methods(1).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {1, 2, 3})
methods(2).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New String() {"A", "B", "C"})
methods(3).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {"A", "B", "C"})
methods(4).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {}) ' Value was invalid.
methods(5).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {DirectCast({1, 2, 3}, Object), DirectCast({"A", "B", "C"}, Object)})
comp.AssertTheseDiagnostics(<errors><![CDATA[
BC30934: Conversion from 'Object(*,*)' to 'Object' cannot occur in a constant expression used as an argument to an attribute.
<My({{1, 2, 3}, {"A", "B", "C"}})>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
]]></errors>)
End Sub
<Fact>
<WorkItem(737021, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/737021")>
Public Sub NothingVersusEmptyArray()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class ArrayAttribute
Inherits Attribute
Public field As Integer()
Public Sub New(array As Integer())
End Sub
End Class
Public Class Test
<Array(Nothing)>
Sub M0()
End Sub
<Array({})>
Sub M1()
End Sub
<Array(Nothing, field:=Nothing)>
Sub M2()
End Sub
<Array({}, field:=Nothing)>
Sub M3()
End Sub
<Array(Nothing, field:={})>
Sub M4()
End Sub
<Array({}, field:={})>
Sub M5()
End Sub
End Class
]]></file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40(source)
Dim type = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Test")
Dim methods = Enumerable.Range(0, 6).Select(Function(i) type.GetMember(Of MethodSymbol)("M" & i))
Dim attrs = methods.Select(Function(m) m.GetAttributes().Single()).ToArray()
Const fieldName = "field"
Dim nullArray As Integer() = Nothing
Dim emptyArray As Integer() = {}
Assert.NotEqual(nullArray, emptyArray)
attrs(0).VerifyValue(0, TypedConstantKind.Array, nullArray)
attrs(1).VerifyValue(0, TypedConstantKind.Array, emptyArray)
attrs(2).VerifyValue(0, TypedConstantKind.Array, nullArray)
attrs(2).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, nullArray)
attrs(3).VerifyValue(0, TypedConstantKind.Array, emptyArray)
attrs(3).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, nullArray)
attrs(4).VerifyValue(0, TypedConstantKind.Array, nullArray)
attrs(4).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, emptyArray)
attrs(5).VerifyValue(0, TypedConstantKind.Array, emptyArray)
attrs(5).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, emptyArray)
End Sub
<Fact>
<WorkItem(530266, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/530266")>
Public Sub UnboundGenericTypeInTypedConstant()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class TestAttribute
Inherits Attribute
Sub New(x as Type)
End Sub
End Class
<TestAttribute(GetType(Target(Of )))>
Class Target(Of T)
End Class
]]></file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40(source, options:=TestOptions.ReleaseDll)
Dim type = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Target")
Dim typeInAttribute = DirectCast(type.GetAttributes()(0).ConstructorArguments(0).Value, NamedTypeSymbol)
Assert.True(typeInAttribute.IsUnboundGenericType)
Assert.True(DirectCast(typeInAttribute, INamedTypeSymbol).IsUnboundGenericType)
Assert.Equal("Target(Of )", typeInAttribute.ToTestDisplayString())
Dim comp2 = CreateCompilationWithMscorlib40AndReferences(<compilation><file></file></compilation>, {comp.EmitToImageReference()})
type = comp2.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Target")
Assert.IsAssignableFrom(Of PENamedTypeSymbol)(type)
typeInAttribute = DirectCast(type.GetAttributes()(0).ConstructorArguments(0).Value, NamedTypeSymbol)
Assert.True(typeInAttribute.IsUnboundGenericType)
Assert.True(DirectCast(typeInAttribute, INamedTypeSymbol).IsUnboundGenericType)
Assert.Equal("Target(Of )", typeInAttribute.ToTestDisplayString())
End Sub
<Fact, WorkItem(879792, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/879792")>
Public Sub Bug879792()
Dim source2 =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<Z>
Module Program
Sub Main()
End Sub
End Module
Interface ZatTribute(Of T)
End Interface
Class Z
Inherits Attribute
End Class
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndVBRuntime(source2)
CompilationUtils.AssertNoDiagnostics(comp)
Dim program = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Program")
Assert.Equal("Z", program.GetAttributes()(0).AttributeClass.ToTestDisplayString())
End Sub
<Fact, WorkItem(1020038, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1020038")>
Public Sub Bug1020038()
Dim source1 =
<compilation name="Bug1020038">
<file name="a.vb"><![CDATA[
Public Class CTest
End Class
]]>
</file>
</compilation>
Dim validator = Sub(m As ModuleSymbol)
Assert.Equal(2, m.ReferencedAssemblies.Length)
Assert.Equal("Bug1020038", m.ReferencedAssemblies(1).Name)
End Sub
Dim compilation1 = CreateCompilationWithMscorlib40(source1)
Dim source2 =
<compilation>
<file name="a.vb"><![CDATA[
Class CAttr
Inherits System.Attribute
Sub New(x as System.Type)
End Sub
End Class
<CAttr(GetType(CTest))>
Class Test
End Class
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source2, {New VisualBasicCompilationReference(compilation1)})
CompileAndVerify(compilation2, symbolValidator:=validator)
Dim source3 =
<compilation>
<file name="a.vb"><![CDATA[
Class CAttr
Inherits System.Attribute
Sub New(x as System.Type)
End Sub
End Class
<CAttr(GetType(System.Func(Of System.Action(Of CTest))))>
Class Test
End Class
]]>
</file>
</compilation>
Dim compilation3 = CreateCompilationWithMscorlib40AndReferences(source3, {New VisualBasicCompilationReference(compilation1)})
CompileAndVerify(compilation3, symbolValidator:=validator)
End Sub
<Fact, WorkItem(1144603, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1144603")>
Public Sub EmitMetadataOnlyInPresenceOfErrors()
Dim source1 =
<compilation>
<file name="a.vb"><![CDATA[
Public Class DiagnosticAnalyzerAttribute
Inherits System.Attribute
Public Sub New(firstLanguage As String, ParamArray additionalLanguages As String())
End Sub
End Class
Public Class LanguageNames
Public Const CSharp As xyz = "C#"
End Class
]]>
</file>
</compilation>
Dim compilation1 = CreateCompilationWithMscorlib40(source1, options:=TestOptions.DebugDll)
AssertTheseDiagnostics(compilation1, <![CDATA[
BC30002: Type 'xyz' is not defined.
Public Const CSharp As xyz = "C#"
~~~
]]>)
Dim source2 =
<compilation>
<file name="a.vb"><![CDATA[
<DiagnosticAnalyzer(LanguageNames.CSharp)>
Class CSharpCompilerDiagnosticAnalyzer
End Class
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source2, {New VisualBasicCompilationReference(compilation1)}, options:=TestOptions.DebugDll.WithModuleName("Test.dll"))
Assert.Same(compilation1.Assembly, compilation2.SourceModule.ReferencedAssemblySymbols(1))
AssertTheseDiagnostics(compilation2)
Dim emitResult2 = compilation2.Emit(peStream:=New MemoryStream(), options:=New EmitOptions(metadataOnly:=True))
Assert.False(emitResult2.Success)
AssertTheseDiagnostics(emitResult2.Diagnostics, <![CDATA[
BC36970: Failed to emit module 'Test.dll': Module has invalid attributes.
]]>)
' Use different mscorlib to test retargeting scenario
Dim compilation3 = CreateCompilationWithMscorlib45AndVBRuntime(source2, {New VisualBasicCompilationReference(compilation1)}, options:=TestOptions.DebugDll)
Assert.NotSame(compilation1.Assembly, compilation3.SourceModule.ReferencedAssemblySymbols(1))
AssertTheseDiagnostics(compilation3, <![CDATA[
BC30002: Type 'xyz' is not defined.
<DiagnosticAnalyzer(LanguageNames.CSharp)>
~~~~~~~~~~~~~~~~~~~~
]]>)
Dim emitResult3 = compilation3.Emit(peStream:=New MemoryStream(), options:=New EmitOptions(metadataOnly:=True))
Assert.False(emitResult3.Success)
AssertTheseDiagnostics(emitResult3.Diagnostics, <![CDATA[
BC30002: Type 'xyz' is not defined.
<DiagnosticAnalyzer(LanguageNames.CSharp)>
~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromADifferentAssemblyFails_Internal()
Dim reference =
<compilation>
<file name="a.vb"><![CDATA[
<Assembly: System.Runtime.CompilerServices.InternalsVisibleToAttribute("Source")>
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Friend Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Friend Class TestType2
End Class
Friend Class TestType3
End Class
End Namespace
]]>
</file>
</compilation>
Dim referenceCompilation = CreateCompilationWithMscorlib40(reference).ToMetadataReference()
Dim code = "
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3() ' This should be fine
End Sub
End Class"
Dim compilation = CreateCompilationWithMscorlib40(code, references:={referenceCompilation}, assemblyName:="Source")
AssertTheseDiagnostics(compilation, <![CDATA[
BC30002: Type 'TestReference.TestType1' is not defined.
Dim obj1 = New TestReference.TestType1()
~~~~~~~~~~~~~~~~~~~~~~~
BC30002: Type 'TestReference.TestType2' is not defined.
Dim obj2 = New TestReference.TestType2()
~~~~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromADifferentAssemblyFails_Public()
Dim reference =
<compilation>
<file name="a.vb"><![CDATA[
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Public Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Public Class TestType2
End Class
Public Class TestType3
End Class
End Namespace
]]>
</file>
</compilation>
Dim referenceCompilation = CreateCompilationWithMscorlib40(reference).ToMetadataReference()
Dim code = "
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3() ' This should be fine
End Sub
End Class"
Dim compilation = CreateCompilationWithMscorlib40(code, references:={referenceCompilation})
AssertTheseDiagnostics(compilation, <![CDATA[
BC30002: Type 'TestReference.TestType1' is not defined.
Dim obj1 = New TestReference.TestType1()
~~~~~~~~~~~~~~~~~~~~~~~
BC30002: Type 'TestReference.TestType2' is not defined.
Dim obj2 = New TestReference.TestType2()
~~~~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromADifferentAssemblyFails_Module()
Dim moduleCode = CreateCompilationWithMscorlib40(options:=TestOptions.ReleaseModule, source:="
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Public Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Public Class TestType2
End Class
Public Class TestType3
End Class
End Namespace")
Dim reference = ModuleMetadata.CreateFromImage(moduleCode.EmitToArray()).GetReference()
Dim code = "
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3() ' This should be fine
End Sub
End Class"
Dim compilation = CreateCompilationWithMscorlib40(code, references:={reference})
AssertTheseDiagnostics(compilation, <![CDATA[
BC30002: Type 'TestReference.TestType1' is not defined.
Dim obj1 = New TestReference.TestType1()
~~~~~~~~~~~~~~~~~~~~~~~
BC30002: Type 'TestReference.TestType2' is not defined.
Dim obj2 = New TestReference.TestType2()
~~~~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromTheSameAssemblySucceeds()
Dim compilation = CreateCompilationWithMscorlib40(source:="
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Public Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Public Class TestType2
End Class
Public Class TestType3
End Class
End Namespace
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3()
End Sub
End Class")
AssertTheseEmitDiagnostics(compilation)
End Sub
<Fact>
Public Sub EmbeddedAttributeInSourceIsAllowedIfCompilerDoesNotNeedToGenerateOne()
Dim compilation = CreateCompilationWithMscorlib40(options:=TestOptions.ReleaseExe, source:=
<compilation>
<file name="a.vb"><![CDATA[
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace OtherNamespace
<Microsoft.CodeAnalysis.Embedded>
Public Class TestReference
Public Shared Function GetValue() As Integer
Return 3
End Function
End Class
End Namespace
Public Class Program
Public Shared Sub Main()
' This should be fine, as the compiler doesn't need to use an embedded attribute for this compilation
System.Console.Write(OtherNamespace.TestReference.GetValue())
End Sub
End Class
]]>
</file>
</compilation>)
CompileAndVerify(compilation, expectedOutput:="3")
End Sub
<Fact>
Public Sub EmbeddedTypesInAnAssemblyAreNotExposedExternally()
Dim compilation1 = CreateCompilationWithMscorlib40(options:=TestOptions.ReleaseDll, source:=
<compilation>
<file name="a.vb"><![CDATA[
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
<Microsoft.CodeAnalysis.Embedded>
Public Class TestReference1
End Class
Public Class TestReference2
End Class
]]>
</file>
</compilation>)
Assert.NotNull(compilation1.GetTypeByMetadataName("TestReference1"))
Assert.NotNull(compilation1.GetTypeByMetadataName("TestReference2"))
Dim compilation2 = CreateCompilationWithMscorlib40("", references:={compilation1.EmitToImageReference()})
Assert.Null(compilation2.GetTypeByMetadataName("TestReference1"))
Assert.NotNull(compilation2.GetTypeByMetadataName("TestReference2"))
End Sub
<Fact>
Public Sub AttributeWithTaskDelegateParameter()
Dim code = "
Imports System
Imports System.Threading.Tasks
Namespace a
Public Class Class1
<AttributeUsage(AttributeTargets.Class, AllowMultiple:=True)>
Public Class CommandAttribute
Inherits Attribute
Public Delegate Function FxCommand() As Task
Public Sub New(Fx As FxCommand)
Me.Fx = Fx
End Sub
Public Property Fx As FxCommand
End Class
<Command(AddressOf UserInfo)>
Public Shared Async Function UserInfo() As Task
Await New Task(
Sub()
End Sub)
End Function
End Class
End Namespace
"
CreateCompilationWithMscorlib45(code).VerifyDiagnostics(
Diagnostic(ERRID.ERR_BadAttributeConstructor1, "Command").WithArguments("a.Class1.CommandAttribute.FxCommand").WithLocation(20, 10),
Diagnostic(ERRID.ERR_RequiredConstExpr, "AddressOf UserInfo").WithLocation(20, 18))
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Collections.Immutable
Imports System.IO
Imports System.Reflection
Imports System.Runtime.InteropServices
Imports System.Xml.Linq
Imports Microsoft.CodeAnalysis.Emit
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.CodeAnalysis.VisualBasic
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols.Metadata.PE
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Roslyn.Test.Utilities
Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests.Semantics
Public Class AttributeTests
Inherits BasicTestBase
#Region "Function Tests"
<WorkItem(530310, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/530310")>
<Fact>
Public Sub PEParameterSymbolParamArrayAttribute()
Dim source1 = <![CDATA[
.assembly extern mscorlib { .ver 4:0:0:0 .publickeytoken = (B7 7A 5C 56 19 34 E0 89) }
.assembly '<<GeneratedFileName>>'
{
}
.class public A
{
.method public hidebysig specialname rtspecialname instance void .ctor() { ret }
.method public static void M(int32 x, int32[] y)
{
.param [2]
.custom instance void [mscorlib]System.ParamArrayAttribute::.ctor() = ( 01 00 00 00 )
ret
}
}]]>.Value
Dim reference1 = CompileIL(source1, prependDefaultHeader:=False)
Dim source2 =
<compilation>
<file name="a.vb">
<![CDATA[
Class C
Shared Sub Main(args As String())
A.M(1, 2, 3)
A.M(1, 2, 3, 4)
End Sub
End Class
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndReferences(source2, {reference1})
Dim method = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("A").GetMember(Of PEMethodSymbol)("M")
Dim yParam = method.Parameters.Item(1)
Assert.Equal(0, yParam.GetAttributes().Length)
Assert.True(yParam.IsParamArray)
CompilationUtils.AssertNoDiagnostics(comp)
End Sub
<Fact>
<WorkItem(20741, "https://github.com/dotnet/roslyn/issues/20741")>
Public Sub TestNamedArgumentOnStringParamsArgument()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class MarkAttribute
Inherits Attribute
Public Sub New(ByVal otherArg As Boolean, ParamArray args As Object())
End Sub
End Class
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
Module Program
Private Sub Test(ByVal otherArg As Boolean, ParamArray args As Object())
End Sub
Sub Main()
Console.WriteLine("Method call")
Test(args:=New String() {"Hello", "World"}, otherArg:=True)
End Sub
End Module
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndVBRuntime(source)
comp.AssertTheseDiagnostics(<errors><![CDATA[
BC30455: Argument not specified for parameter 'otherArg' of 'Public Sub New(otherArg As Boolean, ParamArray args As Object())'.
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
~~~~
BC30661: Field or property 'args' is not found.
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
~~~~
BC30661: Field or property 'otherArg' is not found.
<Mark(args:=New String() {"Hello", "World"}, otherArg:=True)>
~~~~~~~~
BC30587: Named argument cannot match a ParamArray parameter.
Test(args:=New String() {"Hello", "World"}, otherArg:=True)
~~~~
]]></errors>)
End Sub
''' <summary>
''' This function is the same as PEParameterSymbolParamArray
''' except that we check attributes first (to check for race
''' conditions).
''' </summary>
<WorkItem(530310, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/530310")>
<Fact>
Public Sub PEParameterSymbolParamArrayAttribute2()
Dim source1 = <![CDATA[
.assembly extern mscorlib { .ver 4:0:0:0 .publickeytoken = (B7 7A 5C 56 19 34 E0 89) }
.assembly '<<GeneratedFileName>>'
{
}
.class public A
{
.method public hidebysig specialname rtspecialname instance void .ctor() { ret }
.method public static void M(int32 x, int32[] y)
{
.param [2]
.custom instance void [mscorlib]System.ParamArrayAttribute::.ctor() = ( 01 00 00 00 )
ret
}
}]]>.Value
Dim reference1 = CompileIL(source1, prependDefaultHeader:=False)
Dim source2 =
<compilation>
<file name="a.vb">
<![CDATA[
Class C
Shared Sub Main(args As String())
A.M(1, 2, 3)
A.M(1, 2, 3, 4)
End Sub
End Class
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndReferences(source2, {reference1})
Dim method = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("A").GetMember(Of PEMethodSymbol)("M")
Dim yParam = method.Parameters.Item(1)
Assert.True(yParam.IsParamArray)
Assert.Equal(0, yParam.GetAttributes().Length)
CompilationUtils.AssertNoDiagnostics(comp)
End Sub
<Fact>
Public Sub BindingScope_Parameters()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Public Class A
Inherits System.Attribute
Public Sub New(value As Integer)
End Sub
End Class
Class C
Const Value As Integer = 0
Sub method1(<A(Value)> x As Integer)
End Sub
End Class
]]>
</file>
</compilation>
CompileAndVerify(source)
End Sub
<Fact>
Public Sub TestAssemblyAttributes()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.CompilerServices
<assembly: InternalsVisibleTo("Roslyn.Compilers.UnitTests")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.CSharp")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.CSharp.UnitTests")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.CSharp.Test.Utilities")>
<assembly: InternalsVisibleTo("Roslyn.Compilers.VisualBasic")>
]]>
</file>
</compilation>
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim assembly = m.ContainingSymbol
Dim compilerServicesNS = GetSystemRuntimeCompilerServicesNamespace(m)
Dim internalsVisibleToAttr As NamedTypeSymbol = compilerServicesNS.GetTypeMembers("InternalsVisibleToAttribute").First()
Dim attrs = assembly.GetAttributes(internalsVisibleToAttr)
Assert.Equal(5, attrs.Count)
attrs(0).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.UnitTests")
attrs(1).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.CSharp")
attrs(2).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.CSharp.UnitTests")
attrs(3).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.CSharp.Test.Utilities")
attrs(4).VerifyValue(0, TypedConstantKind.Primitive, "Roslyn.Compilers.VisualBasic")
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
Private Function GetSystemRuntimeCompilerServicesNamespace(m As ModuleSymbol) As NamespaceSymbol
Dim compilation = m.DeclaringCompilation
Dim globalNS = If(compilation Is Nothing, m.ContainingAssembly.CorLibrary.GlobalNamespace, compilation.GlobalNamespace)
Return globalNS.
GetMember(Of NamespaceSymbol)("System").
GetMember(Of NamespaceSymbol)("Runtime").
GetMember(Of NamespaceSymbol)("CompilerServices")
End Function
<Fact>
Public Sub TestAssemblyAttributesReflection()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="attr.vb"><![CDATA[
Imports System.Reflection
Imports System.Runtime.CompilerServices
Imports System.Runtime.InteropServices
' These are not pseudo attributes, but encoded as bits in metadata
<assembly: AssemblyAlgorithmId(System.Configuration.Assemblies.AssemblyHashAlgorithm.MD5)>
<assembly: AssemblyCultureAttribute("")>
<assembly: AssemblyDelaySign(true)>
<assembly: AssemblyFlags(AssemblyNameFlags.Retargetable)>
<assembly: AssemblyKeyFile("MyKey.snk")>
<assembly: AssemblyKeyName("Key Name")>
<assembly: AssemblyVersion("1.2.*")>
<assembly: AssemblyFileVersionAttribute("4.3.2.100")>
]]>
</file>
</compilation>)
Dim attrs = compilation.Assembly.GetAttributes()
Assert.Equal(8, attrs.Length)
For Each a In attrs
Select Case a.AttributeClass.Name
Case "AssemblyAlgorithmIdAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(0, a.CommonNamedArguments.Length)
Assert.Equal(TypedConstantKind.Enum, a.CommonConstructorArguments(0).Kind)
Assert.Equal("System.Configuration.Assemblies.AssemblyHashAlgorithm", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(Configuration.Assemblies.AssemblyHashAlgorithm.MD5, CType(a.CommonConstructorArguments(0).Value, Configuration.Assemblies.AssemblyHashAlgorithm))
Case "AssemblyCultureAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(0, a.CommonNamedArguments.Length)
Case "AssemblyDelaySignAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("Boolean", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(True, a.CommonConstructorArguments(0).Value)
Case "AssemblyFlagsAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Enum, a.CommonConstructorArguments(0).Kind)
Assert.Equal("System.Reflection.AssemblyNameFlags", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal(AssemblyNameFlags.Retargetable, CType(a.CommonConstructorArguments(0).Value, AssemblyNameFlags))
Case "AssemblyKeyFileAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("MyKey.snk", a.CommonConstructorArguments(0).Value)
Case "AssemblyKeyNameAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("Key Name", a.CommonConstructorArguments(0).Value)
Case "AssemblyVersionAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("1.2.*", a.CommonConstructorArguments(0).Value)
Case "AssemblyFileVersionAttribute"
Assert.Equal(1, a.CommonConstructorArguments.Length)
Assert.Equal(TypedConstantKind.Primitive, a.CommonConstructorArguments(0).Kind)
Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString)
Assert.Equal("4.3.2.100", a.CommonConstructorArguments(0).Value)
Case Else
Assert.Equal("Unexpected Attr", a.AttributeClass.Name)
End Select
Next
End Sub
' Verify that resolving an attribute defined within a class on a class does not cause infinite recursion
<Fact>
Public Sub TestAttributesOnClassDefinedInClass()
Dim compilation = CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.CompilerServices
<A.X()>
Public Class A
<AttributeUsage(AttributeTargets.All, allowMultiple:=true)>
Public Class XAttribute
Inherits Attribute
End Class
End Class]]>
</file>
</compilation>)
Dim attrs = compilation.SourceModule.GlobalNamespace.GetMember("A").GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal("A.XAttribute", attrs(0).AttributeClass.ToDisplayString)
End Sub
<WorkItem(540506, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540506")>
<Fact>
Public Sub TestAttributesOnClassWithConstantDefinedInClass()
Dim compilation = CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb"><![CDATA[
<Attr(Goo.p)>
Class Goo
Friend Const p As Object = 2 + 2
End Class
Friend Class AttrAttribute
Inherits Attribute
End Class
]]>
</file>
</compilation>)
Dim attrs = compilation.SourceModule.GlobalNamespace.GetMember("Goo").GetAttributes()
Assert.Equal(1, attrs.Length)
attrs(0).VerifyValue(0, TypedConstantKind.Primitive, 4)
End Sub
<WorkItem(540407, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540407")>
<Fact>
Public Sub TestAttributesOnProperty()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Public Class A
Inherits Attribute
End Class
Public Interface I
<A>
Property AP(<A()>a As Integer) As <A>Integer
End Interface
Public Class C
<A>
Public Property AP As <A>Integer
<A>
Public Property P(<A> a As Integer) As <A>Integer
<A>
Get
Return 0
End Get
<A>
Set(<A>value As Integer)
End Set
End Property
End Class
]]></file>
</compilation>
Dim attributeValidator =
Function(isFromSource As Boolean) _
Sub(m As ModuleSymbol)
Dim i = DirectCast(m.GlobalNamespace.GetMember("I"), NamedTypeSymbol)
Dim c = DirectCast(m.GlobalNamespace.GetMember("C"), NamedTypeSymbol)
' auto-property in interface
Dim ap = i.GetMember("AP")
Assert.Equal(1, ap.GetAttributes().Length)
Dim get_AP = DirectCast(i.GetMember("get_AP"), MethodSymbol)
Assert.Equal(0, get_AP.GetAttributes().Length)
Assert.Equal(1, get_AP.GetReturnTypeAttributes().Length)
Assert.Equal(1, get_AP.Parameters(0).GetAttributes().Length)
Dim set_AP = DirectCast(i.GetMember("set_AP"), MethodSymbol)
Assert.Equal(0, set_AP.GetAttributes().Length)
Assert.Equal(0, set_AP.GetReturnTypeAttributes().Length)
Assert.Equal(1, set_AP.Parameters(0).GetAttributes().Length)
Assert.Equal(0, set_AP.Parameters(1).GetAttributes().Length)
' auto-property on class
ap = c.GetMember("AP")
Assert.Equal(1, ap.GetAttributes().Length)
get_AP = DirectCast(c.GetMember("get_AP"), MethodSymbol)
If isFromSource Then
Assert.Equal(0, get_AP.GetAttributes().Length)
Else
AssertEx.Equal({"CompilerGeneratedAttribute"}, GetAttributeNames(get_AP.GetAttributes()))
End If
Assert.Equal(1, get_AP.GetReturnTypeAttributes().Length)
set_AP = DirectCast(c.GetMember("set_AP"), MethodSymbol)
If isFromSource Then
Assert.Equal(0, get_AP.GetAttributes().Length)
Else
AssertEx.Equal({"CompilerGeneratedAttribute"}, GetAttributeNames(set_AP.GetAttributes()))
End If
Assert.Equal(0, set_AP.GetReturnTypeAttributes().Length)
Assert.Equal(0, set_AP.Parameters(0).GetAttributes().Length)
' property
Dim p = c.GetMember("P")
Assert.Equal(1, p.GetAttributes().Length)
Dim get_P = DirectCast(c.GetMember("get_P"), MethodSymbol)
Assert.Equal(1, get_P.GetAttributes().Length)
Assert.Equal(1, get_P.GetReturnTypeAttributes().Length)
Assert.Equal(1, get_P.Parameters(0).GetAttributes().Length)
Dim set_P = DirectCast(c.GetMember("set_P"), MethodSymbol)
Assert.Equal(1, set_P.GetAttributes().Length)
Assert.Equal(0, set_P.GetReturnTypeAttributes().Length)
Assert.Equal(1, set_P.Parameters(0).GetAttributes().Length)
Assert.Equal(1, set_P.Parameters(1).GetAttributes().Length)
End Sub
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator(True), symbolValidator:=attributeValidator(False))
End Sub
<WorkItem(540407, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540407")>
<Fact>
Public Sub TestAttributesOnPropertyReturnType()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Public Class A
Inherits System.Attribute
End Class
Public Class B
Inherits System.Attribute
End Class
Public Interface I
Property Auto As <A> Integer
ReadOnly Property AutoRO As <A> Integer
WriteOnly Property AutoWO As <A> Integer ' warning
End Interface
Public Class C
Property Auto As <A> Integer
ReadOnly Property ROA As <A> Integer
Get
Return 0
End Get
End Property
WriteOnly Property WOA As <A> Integer ' warning
Set(value As Integer)
End Set
End Property
Property A As <A> Integer
Get
Return 0
End Get
Set(value As Integer)
End Set
End Property
Property AB As <A> Integer
Get
Return 0
End Get
Set(<B()> value As Integer)
End Set
End Property
End Class
]]></file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim i = DirectCast(m.GlobalNamespace.GetMember("I"), NamedTypeSymbol)
Dim c = DirectCast(m.GlobalNamespace.GetMember("C"), NamedTypeSymbol)
' auto-property in interface
Dim auto = DirectCast(i.GetMember("Auto"), PropertySymbol)
Assert.Equal(1, auto.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
Dim autoRO = DirectCast(i.GetMember("AutoRO"), PropertySymbol)
Assert.Equal(1, autoRO.GetMethod.GetReturnTypeAttributes().Length)
Assert.Null(autoRO.SetMethod)
Dim autoWO = DirectCast(i.GetMember("AutoWO"), PropertySymbol)
Assert.Null(autoWO.GetMethod)
Assert.Equal(0, autoWO.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
' auto-property in class
auto = DirectCast(c.GetMember("Auto"), PropertySymbol)
Assert.Equal(1, auto.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
' custom property in class
Dim roa = DirectCast(c.GetMember("ROA"), PropertySymbol)
Assert.Equal(1, roa.GetMethod.GetReturnTypeAttributes().Length)
Assert.Null(roa.SetMethod)
Dim woa = DirectCast(c.GetMember("WOA"), PropertySymbol)
Assert.Null(woa.GetMethod)
Assert.Equal(0, woa.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, woa.SetMethod.Parameters(0).GetAttributes().Length)
Dim a = DirectCast(c.GetMember("A"), PropertySymbol)
Assert.Equal(1, a.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, a.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(0, a.SetMethod.Parameters(0).GetAttributes().Length)
Dim ab = DirectCast(c.GetMember("AB"), PropertySymbol)
Assert.Equal(1, ab.GetMethod.GetReturnTypeAttributes().Length)
Assert.Equal("A", ab.GetMethod.GetReturnTypeAttributes()(0).AttributeClass.Name)
Assert.Equal(0, ab.SetMethod.GetReturnTypeAttributes().Length)
Assert.Equal(1, ab.SetMethod.Parameters(0).GetAttributes().Length)
Assert.Equal("B", ab.SetMethod.Parameters(0).GetAttributes()(0).AttributeClass.Name)
End Sub
Dim verifier = CompileAndVerify(source, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
CompilationUtils.AssertTheseDiagnostics(verifier.Compilation,
<errors><![CDATA[
BC42364: Attributes applied on a return type of a WriteOnly Property have no effect.
WriteOnly Property AutoWO As <A> Integer ' warning
~
BC42364: Attributes applied on a return type of a WriteOnly Property have no effect.
WriteOnly Property WOA As <A> Integer ' warning
~
]]></errors>)
End Sub
<WorkItem(546779, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546779")>
<Fact>
Public Sub TestAttributesOnPropertyReturnType_MarshalAs()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Public Interface I
Property Auto As <MarshalAs(UnmanagedType.I4)> Integer
End Interface
]]></file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim i = DirectCast(m.GlobalNamespace.GetMember("I"), NamedTypeSymbol)
' auto-property in interface
Dim auto = DirectCast(i.GetMember("Auto"), PropertySymbol)
Assert.Equal(UnmanagedType.I4, auto.GetMethod.ReturnTypeMarshallingInformation.UnmanagedType)
Assert.Equal(1, auto.GetMethod.GetReturnTypeAttributes().Length)
Assert.Null(auto.SetMethod.ReturnTypeMarshallingInformation)
Assert.Equal(UnmanagedType.I4, auto.SetMethod.Parameters(0).MarshallingInformation.UnmanagedType)
Assert.Equal(0, auto.SetMethod.Parameters(0).GetAttributes().Length)
End Sub
' TODO (tomat): implement reading from PE: symbolValidator:=attributeValidator
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator)
End Sub
<WorkItem(540433, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540433")>
<Fact>
Public Sub TestAttributesOnPropertyAndGetSet()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
<AObject(GetType(Object), O:=A.obj)>
Public Class A
Public Const obj As Object = Nothing
Public ReadOnly Property RProp As String
<AObject(New Object() {GetType(String)})>
Get
Return Nothing
End Get
End Property
<AObject(New Object() {1, "two", GetType(String), 3.1415926})>
Public WriteOnly Property WProp
<AObject(New Object() {New Object() {GetType(String)}})>
Set(value)
End Set
End Property
End Class
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.MDTestAttributeDefLib.AsImmutableOrNull())},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim type = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = type.GetAttributes()
Assert.Equal("AObjectAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Type, GetType(Object))
attrs(0).VerifyValue(Of Object)(0, "O", TypedConstantKind.Primitive, Nothing)
Dim prop = type.GetMember(Of PropertySymbol)("RProp")
attrs = prop.GetMethod.GetAttributes()
attrs(0).VerifyValue(0, TypedConstantKind.Array, {GetType(String)})
prop = type.GetMember(Of PropertySymbol)("WProp")
attrs = prop.GetAttributes()
attrs(0).VerifyValue(Of Object())(0, TypedConstantKind.Array, {1, "two", GetType(String), 3.1415926})
attrs = prop.SetMethod.GetAttributes()
attrs(0).VerifyValue(0, TypedConstantKind.Array, {New Object() {GetType(String)}})
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestAttributesOnPropertyParameters()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Public Class A
Inherits Attribute
End Class
Public Class X
Public Property P(<A>a As Integer) As <A>Integer
Get
Return 0
End Get
Set(<A>value As Integer)
End Set
End Property
End Class
]]>
</file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim type = DirectCast(m.GlobalNamespace.GetMember("X"), NamedTypeSymbol)
Dim getter = DirectCast(type.GetMember("get_P"), MethodSymbol)
Dim setter = DirectCast(type.GetMember("set_P"), MethodSymbol)
' getter
Assert.Equal(1, getter.Parameters.Length)
Assert.Equal(1, getter.Parameters(0).GetAttributes().Length)
Assert.Equal(1, getter.GetReturnTypeAttributes().Length)
' setter
Assert.Equal(2, setter.Parameters.Length)
Assert.Equal(1, setter.Parameters(0).GetAttributes().Length)
Assert.Equal(1, setter.Parameters(1).GetAttributes().Length)
End Sub
CompileAndVerify(source, symbolValidator:=attributeValidator, sourceSymbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestAttributesOnEnumField()
Dim source =
<compilation>
<file name="attr.vb"><![CDATA[
Option Strict On
Imports System
Imports system.Collections.Generic
Imports System.Reflection
Imports CustomAttribute
Imports AN = CustomAttribute.AttrName
' Use AttrName without Attribute suffix
<Assembly: AN(UShortField:=4321)>
<Assembly: AN(UShortField:=1234)>
<Module: AttrName(TypeField:=GetType(System.IO.FileStream))>
Namespace AttributeTest
Public Interface IGoo
Class NestedClass
' enum as object
<AllInheritMultiple(System.IO.FileMode.Open, BindingFlags.DeclaredOnly Or BindingFlags.Public, UIntField:=123 * Field)>
Public Const Field As UInteger = 10
End Class
<AllInheritMultiple(New Char() {"q"c, "c"c}, "")>
<AllInheritMultiple()>
Enum NestedEnum
zero
one = 1
<AllInheritMultiple(Nothing, 256, 0.0F, -1, AryField:=New ULong() {0, 1, 12345657})>
<AllInheritMultipleAttribute(GetType(Dictionary(Of String, Integer)), 255 + NestedClass.Field, -0.0001F, 3 - CShort(NestedEnum.oneagain))>
three = 3
oneagain = one
End Enum
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator =
Function(isFromSource As Boolean) _
Sub(m As ModuleSymbol)
Dim attrs = m.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal("CustomAttribute.AttrNameAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(0, "TypeField", TypedConstantKind.Type, GetType(FileStream))
Dim assembly = m.ContainingSymbol
attrs = assembly.GetAttributes()
If isFromSource Then
Assert.Equal(2, attrs.Length)
Assert.Equal("CustomAttribute.AttrName", attrs(0).AttributeClass.ToDisplayString)
attrs(1).VerifyValue(Of UShort)(0, "UShortField", TypedConstantKind.Primitive, 1234)
Else
Assert.Equal(5, attrs.Length) ' 3 synthesized assembly attributes
Assert.Equal("CustomAttribute.AttrName", attrs(3).AttributeClass.ToDisplayString)
attrs(4).VerifyValue(Of UShort)(0, "UShortField", TypedConstantKind.Primitive, 1234)
End If
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim top = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim type = top.GetMember(Of NamedTypeSymbol)("NestedClass")
Dim field = type.GetMember(Of FieldSymbol)("Field")
attrs = field.GetAttributes()
Assert.Equal("CustomAttribute.AllInheritMultipleAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(0, TypedConstantKind.Enum, CInt(FileMode.Open))
attrs(0).VerifyValue(1, TypedConstantKind.Enum, CInt(BindingFlags.DeclaredOnly Or BindingFlags.Public))
attrs(0).VerifyValue(0, "UIntField", TypedConstantKind.Primitive, 1230)
Dim nenum = top.GetMember(Of TypeSymbol)("NestedEnum")
attrs = nenum.GetAttributes()
Assert.Equal(2, attrs.Length)
attrs(0).VerifyValue(0, TypedConstantKind.Array, {"q"c, "c"c})
attrs = nenum.GetMember("three").GetAttributes()
Assert.Equal(2, attrs.Length)
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, Nothing)
attrs(0).VerifyValue(Of Long)(1, TypedConstantKind.Primitive, 256)
attrs(0).VerifyValue(Of Single)(2, TypedConstantKind.Primitive, 0)
attrs(0).VerifyValue(Of Short)(3, TypedConstantKind.Primitive, -1)
attrs(0).VerifyValue(Of ULong())(0, "AryField", TypedConstantKind.Array, New ULong() {0, 1, 12345657})
attrs(1).VerifyValue(Of Object)(0, TypedConstantKind.Type, GetType(Dictionary(Of String, Integer)))
attrs(1).VerifyValue(Of Long)(1, TypedConstantKind.Primitive, 265)
attrs(1).VerifyValue(Of Single)(2, TypedConstantKind.Primitive, -0.0001F)
attrs(1).VerifyValue(Of Short)(3, TypedConstantKind.Primitive, 2)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator(True), symbolValidator:=attributeValidator(False))
End Sub
<Fact>
Public Sub TestAttributesOnDelegate()
Dim source =
<compilation>
<file name="TestAttributesOnDelegate.vb"><![CDATA[
Imports System
Imports System.Collections.Generic
Imports CustomAttribute
Namespace AttributeTest
Public Interface IGoo
<AllInheritMultiple(New Object() {0, "", Nothing}, 255, -127 - 1, AryProp:=New Object() {New Object() {"", GetType(IList(Of String))}})>
Delegate Sub NestedSubDele(<AllInheritMultiple()> <Derived(GetType(String(,,)))> p As String)
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim dele = DirectCast(type.GetTypeMember("NestedSubDele"), NamedTypeSymbol)
Dim attrs = dele.GetAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Array, New Object() {0, "", Nothing})
attrs(0).VerifyValue(Of Byte)(1, TypedConstantKind.Primitive, 255)
attrs(0).VerifyValue(Of SByte)(2, TypedConstantKind.Primitive, -128)
attrs(0).VerifyValue(Of Object())(0, "AryProp", TypedConstantKind.Array, New Object() {New Object() {"", GetType(IList(Of String))}})
Dim mem = dele.GetMember(Of MethodSymbol)("Invoke")
' no attributes on the method:
Assert.Equal(0, mem.GetAttributes().Length)
' attributes on parameters:
attrs = mem.Parameters(0).GetAttributes()
Assert.Equal(2, attrs.Length)
attrs(1).VerifyValue(Of Object)(0, TypedConstantKind.Type, GetType(String(,,)))
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(540600, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540600")>
<Fact>
Public Sub TestAttributesUseBaseAttributeField()
Dim source =
<compilation>
<file name="TestAttributesUseBaseAttributeField.vb"><![CDATA[
Imports System
Namespace AttributeTest
Public Interface IGoo
<CustomAttribute.Derived(New Object() {1, Nothing, "Hi"}, ObjectField:=2)>
Function F(p As Integer) As Integer
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim attrs = type.GetMember(Of MethodSymbol)("F").GetAttributes()
Assert.Equal("CustomAttribute.DerivedAttribute", attrs(0).AttributeClass.ToDisplayString)
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Array, New Object() {1, Nothing, "Hi"})
attrs(0).VerifyValue(Of Object)(0, "ObjectField", TypedConstantKind.Primitive, 2)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact(), WorkItem(529421, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/529421")>
Public Sub TestAttributesWithParamArrayInCtor()
Dim source =
<compilation>
<file name="TestAttributesWithParamArrayInCtor.vb"><![CDATA[
Imports System
Imports CustomAttribute
Namespace AttributeTest
<AllInheritMultiple(New Char() {" "c, Nothing}, "")>
Public Interface IGoo
End Interface
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim sourceAttributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim attrs = type.GetAttributes()
attrs(0).VerifyValue(Of Char())(0, TypedConstantKind.Array, New Char() {" "c, Nothing})
attrs(0).VerifyValue(Of String())(1, TypedConstantKind.Array, New String() {""})
Dim attrCtor = attrs(0).AttributeConstructor
Debug.Assert(attrCtor.Parameters.Last.IsParamArray)
End Sub
Dim mdAttributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim type = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim attrs = type.GetAttributes()
attrs(0).VerifyValue(Of Char())(0, TypedConstantKind.Array, New Char() {" "c, Nothing})
attrs(0).VerifyValue(Of String())(1, TypedConstantKind.Array, New String() {""})
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=sourceAttributeValidator, symbolValidator:=mdAttributeValidator)
End Sub
<WorkItem(540605, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540605")>
<Fact>
Public Sub TestAttributesOnReturnType()
Dim source =
<compilation>
<file name="TestAttributesOnReturnType.vb"><![CDATA[
Imports System
Imports System.Collections.Generic
Imports CustomAttribute
Namespace AttributeTest
Class XAttribute
inherits Attribute
Sub New(s as string)
End Sub
End Class
Public Interface IGoo
Function F1(i as integer) as <X("f1 return type")> string
Property P1 as <X("p1 return type")> string
End Interface
Class C1
Property P1 as <X("p1 return type")> string
ReadOnly Property P2 as <X("p2 return type")> string
Get
return nothing
End Get
End Property
Function F2(i as integer) As <X("f2 returns an integer")> integer
return 0
end function
End Class
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01.AsImmutableOrNull())},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim iGoo = DirectCast(ns.GetMember("IGoo"), NamedTypeSymbol)
Dim f1 = DirectCast(iGoo.GetMember("F1"), MethodSymbol)
Dim attrs = f1.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "f1 return type")
Dim p1 = DirectCast(iGoo.GetMember("P1"), PropertySymbol)
attrs = p1.GetMethod.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "p1 return type")
Dim c1 = DirectCast(ns.GetMember("C1"), NamedTypeSymbol)
Dim p2 = DirectCast(c1.GetMember("P2"), PropertySymbol)
attrs = p2.GetMethod.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "p2 return type")
Dim f2 = DirectCast(c1.GetMember("F2"), MethodSymbol)
attrs = f2.GetReturnTypeAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, "f2 returns an integer")
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestAttributesUsageCasing()
Dim source =
<compilation>
<file name="TestAttributesOnReturnType.vb"><![CDATA[
Imports System
Imports System.Collections.Generic
Imports CustomAttribute
Namespace AttributeTest
<ATTributeUSageATTribute(AttributeTargets.ReturnValue, ALLowMulTiplE:=True, InHeRIteD:=false)>
Class XAttribute
Inherits Attribute
Sub New()
End Sub
End Class
End Namespace
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(
source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)},
TestOptions.ReleaseDll)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim ns = DirectCast(m.GlobalNamespace.GetMember("AttributeTest"), NamespaceSymbol)
Dim xAttributeClass = DirectCast(ns.GetMember("XAttribute"), NamedTypeSymbol)
Dim attributeUsage = xAttributeClass.GetAttributeUsageInfo()
Assert.Equal(AttributeTargets.ReturnValue, attributeUsage.ValidTargets)
Assert.Equal(True, attributeUsage.AllowMultiple)
Assert.Equal(False, attributeUsage.Inherited)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(540940, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540940")>
<Fact>
Public Sub TestAttributeWithParamArray()
Dim source =
<compilation>
<file name="TestAttributeWithParamArray.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(ParamArray x As Integer())
End Sub
End Class
<A>
Module M
Sub Main()
End Sub
End Module
]]></file>
</compilation>
CompileAndVerify(source)
End Sub
<WorkItem(528469, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/528469")>
<Fact()>
Public Sub TestAttributeWithAttributeTargets()
Dim source =
<compilation>
<file name="TestAttributeWithParamArray.vb"><![CDATA[
Imports System
<System.AttributeUsage(AttributeTargets.All)> _
Class ZAttribute
Inherits Attribute
End Class
<Z()> _
Class scen1
End Class
Module M1
Sub goo()
<Z()> _
Static x1 As Object
End Sub
End Module
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
CompileAndVerify(compilation)
End Sub
<WorkItem(541277, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541277")>
<Fact>
Public Sub TestAttributeEmitObjectValue()
Dim source =
<compilation>
<file name="TestAttributeEmitObjectValue.vb"><![CDATA[
Imports System
<AttributeUsageAttribute(AttributeTargets.All, AllowMultiple:=True)>
Class A
Inherits Attribute
Public Property X As Object
Public Sub New()
End Sub
Public Sub New(o As Object)
End Sub
End Class
<A(1)>
<A(New String() {"a", "b"})>
<A(X:=1), A(X:=New String() {"a", "b"})>
Class B
Shared Sub Main()
Dim b As New B()
Dim a As A = b.GetType().GetCustomAttributes(False)(0)
Console.WriteLine(a.X)
End Sub
End Class
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim bClass = DirectCast(m.GlobalNamespace.GetMember("B"), NamedTypeSymbol)
Dim attrs = bClass.GetAttributes()
attrs(0).VerifyValue(Of Object)(0, TypedConstantKind.Primitive, 1)
attrs(1).VerifyValue(Of Object)(0, TypedConstantKind.Array, New String() {"a", "b"})
attrs(2).VerifyValue(Of Object)(0, "X", TypedConstantKind.Primitive, 1)
attrs(3).VerifyValue(Of Object)(0, "X", TypedConstantKind.Array, New String() {"a", "b"})
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(541278, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541278")>
<Fact>
Public Sub TestAttributeEmitGenericEnumValue()
Dim source =
<compilation>
<file name="TestAttributeEmitObjectValue.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(x As Object)
Y = x
End Sub
Public Property Y As Object
End Class
Class B(Of T)
Class D
End Class
Enum E
A = &HABCDEF
End Enum
End Class
<A(B(Of Integer).E.A)>
Class C
End Class
Module m1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim cClass = DirectCast(m.GlobalNamespace.GetMember("C"), NamedTypeSymbol)
Dim attrs = cClass.GetAttributes()
Dim tc = attrs(0).CommonConstructorArguments(0)
Assert.Equal(tc.Kind, TypedConstantKind.Enum)
Assert.Equal(CType(tc.Value, Int32), &HABCDEF)
Assert.Equal(tc.Type.ToDisplayString, "B(Of Integer).E")
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(546380, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546380")>
<Fact()>
Public Sub TestAttributeEmitOpenGeneric()
Dim source =
<compilation>
<file name="TestAttributeEmitObjectValue.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(x As Object)
Y = x
End Sub
Public Property Y As Object
End Class
<A(GetType(B(Of)))>
Class B(Of T)
End Class
Module m1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim bClass = DirectCast(m.GlobalNamespace.GetMember("B"), NamedTypeSymbol)
Dim attrs = bClass.GetAttributes()
attrs(0).VerifyValue(0, TypedConstantKind.Type, bClass.ConstructUnboundGenericType())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(541278, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541278")>
<Fact>
Public Sub TestAttributeToString()
Dim source =
<compilation>
<file name="TestAttributeToString.vb"><![CDATA[
Imports System
<AttributeUsageAttribute(AttributeTargets.Class Or AttributeTargets.Struct, AllowMultiple:=True)>
Class A
Inherits Attribute
Public Property X As Object
Public Property T As Type
Public Sub New()
End Sub
Public Sub New(ByVal o As Object)
End Sub
Public Sub New(ByVal y As Y)
End Sub
End Class
Public Enum Y
One = 1
Two = 2
Three = 3
End Enum
<A()>
Class B1
Shared Sub Main()
End Sub
End Class
<A(1)>
Class B2
End Class
<A(New String() {"a", "b"})>
Class B3
End Class
<A(X:=1)>
Class B4
End Class
<A(T:=GetType(String))>
Class B5
End Class
<A(1, X:=1, T:=GetType(String))>
Class B6
End Class
<A(Y.Three)>
Class B7
End Class
<A(DirectCast(5, Y))>
Class B8
End Class
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim aClass = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = aClass.GetAttributes()
Assert.Equal("System.AttributeUsageAttribute(System.AttributeTargets.Class Or System.AttributeTargets.Struct, AllowMultiple:=True)",
attrs(0).ToString())
Dim bClass = DirectCast(m.GlobalNamespace.GetMember("B1"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B2"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(1)", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B3"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A({""a"", ""b""})", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B4"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(X:=1)", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B5"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(T:=GetType(String))", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B6"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(1, X:=1, T:=GetType(String))", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B7"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(Y.Three)", attrs(0).ToString())
bClass = DirectCast(m.GlobalNamespace.GetMember("B8"), NamedTypeSymbol)
attrs = bClass.GetAttributes()
Assert.Equal("A(5)", attrs(0).ToString())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(541687, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541687")>
<Fact>
Public Sub Bug_8524_NullAttributeArrayArgument()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Class A
Inherits Attribute
Public Property X As Object
End Class
<A(X:=CStr(Nothing))>
Class B
Shared Sub Main()
Dim b As New B()
Dim a As A = b.GetType().GetCustomAttributes(False)(0)
Console.Write(a.X Is Nothing)
End Sub
End Class
]]>
</file>
</compilation>
CompileAndVerify(source, expectedOutput:="True")
End Sub
<WorkItem(541964, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541964")>
<Fact>
Public Sub TestApplyNamedArgumentTwice()
Dim source =
<compilation>
<file name="TestApplyNamedArgumentTwice.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, AllowMultiple:=False, AllowMultiple:=True), A, A>
Class A
Inherits Attribute
End Class
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim aClass = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = aClass.GetAttributes()
Assert.Equal("System.AttributeUsageAttribute(System.AttributeTargets.All, AllowMultiple:=False, AllowMultiple:=True)",
attrs(0).ToString())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<Fact>
Public Sub TestApplyNamedArgumentCasing()
Dim source =
<compilation>
<file name="TestApplyNamedArgumentTwice.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, ALLOWMULTIPLE:=True), A, A>
Class A
Inherits Attribute
End Class
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim aClass = DirectCast(m.GlobalNamespace.GetMember("A"), NamedTypeSymbol)
Dim attrs = aClass.GetAttributes()
Assert.Equal("System.AttributeUsageAttribute(System.AttributeTargets.All, AllowMultiple:=True)",
attrs(0).ToString())
End Sub
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
<WorkItem(542123, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542123")>
<Fact>
Public Sub TestApplyNestedDerivedAttribute()
Dim source =
<compilation>
<file name="TestApplyNestedDerivedAttribute.vb"><![CDATA[
Imports System
<First.Second.Third()>
Class First : Inherits Attribute
Class Second : Inherits First
End Class
Class Third : Inherits Second
End Class
End Class
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
compilation.VerifyDiagnostics()
End Sub
<WorkItem(542269, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542269")>
<Fact>
Public Sub TestApplyNestedDerivedAttributeOnTypeAndItsMember()
Dim source =
<compilation>
<file name="TestApplyNestedDerivedAttributeOnTypeAndItsMember.vb"><![CDATA[
Imports System
Public Class First : Inherits Attribute
<AttributeUsage(AttributeTargets.Class Or AttributeTargets.Method)>
Friend Class Second
Inherits First
End Class
End Class
<First.Second()>
Module Module1
<First.Second()>
Function ToString(x As Integer, y As Integer) As String
Return Nothing
End Function
Public Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
compilation.VerifyDiagnostics()
End Sub
<Fact>
Public Sub AttributeTargets_Method()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Method)>
Class Attr
Inherits Attribute
End Class
Public Class C
<Attr()>
Custom Event EvntWithAccessors As Action(Of Integer)
<Attr()>
AddHandler(value As Action(Of Integer))
End AddHandler
<Attr()>
RemoveHandler(value As Action(Of Integer))
End RemoveHandler
<Attr()>
RaiseEvent(obj As Integer)
End RaiseEvent
End Event
<Attr()>
Property PropertyWithAccessors As Integer
<Attr()>
Get
Return 0
End Get
<Attr()>
Set(value As Integer)
End Set
End Property
<Attr()>
Shared Sub Sub1()
End Sub
<Attr()>
Function Ftn2() As Integer
Return 1
End Function
<Attr()>
Declare Function DeclareFtn Lib "bar" () As Integer
<Attr()>
Declare Sub DeclareSub Lib "bar" ()
<Attr()>
Shared Operator -(a As C, b As C) As Integer
Return 0
End Operator
<Attr()>
Shared Narrowing Operator CType(a As C) As Integer
Return 0
End Operator
<Attr()>
Public Event Evnt As Action(Of Integer)
<Attr()>
Public Field As Integer
<Attr()>
Public WithEvents WE As NestedType
<Attr()>
Class NestedType
End Class
<Attr()>
Interface Iface
End Interface
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Evnt"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Field"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "WE"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "NestedType"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Iface"))
End Sub
<Fact>
Public Sub AttributeTargets_Field()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Field)>
Class Attr
Inherits Attribute
End Class
Public Class C
<Attr()>
Custom Event EvntWithAccessors As Action(Of Integer)
<Attr()>
AddHandler(value As Action(Of Integer))
End AddHandler
<Attr()>
RemoveHandler(value As Action(Of Integer))
End RemoveHandler
<Attr()>
RaiseEvent(obj As Integer)
End RaiseEvent
End Event
<Attr()>
Property PropertyWithAccessors As Integer
<Attr()>
Get
Return 0
End Get
<Attr()>
Set(value As Integer)
End Set
End Property
<Attr()>
Shared Sub Sub1()
End Sub
<Attr()>
Function Ftn2() As Integer
Return 1
End Function
<Attr()>
Declare Function DeclareFtn Lib "bar" () As Integer
<Attr()>
Declare Sub DeclareSub Lib "bar" ()
<Attr()>
Shared Operator -(a As C, b As C) As Integer
Return 0
End Operator
<Attr()>
Shared Narrowing Operator CType(a As C) As Integer
Return 0
End Operator
<Attr()>
Public Event Evnt As Action(Of Integer)
<Attr()>
Public Field As Integer
<Attr()>
Public WithEvents WE As NestedType
<Attr()>
Class NestedType
End Class
<Attr()>
Interface Iface
End Interface
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "AddHandler", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "RemoveHandler", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "RaiseEvent", "EvntWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "Get", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsageOnAccessor, "Attr").WithArguments("Attr", "Set", "PropertyWithAccessors"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Sub1"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Ftn2"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "DeclareFtn"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "DeclareSub"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "-"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "CType"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Evnt"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "NestedType"),
Diagnostic(ERRID.ERR_InvalidAttributeUsage2, "Attr").WithArguments("Attr", "Iface"))
End Sub
<Fact>
Public Sub AttributeTargets_WithEvents()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Class A
Inherits Attribute
End Class
Class D
<A>
Public WithEvents myButton As Button
End Class
Class Button
Public Event OnClick()
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
Dim d = DirectCast(c.GlobalNamespace.GetMembers("D").Single(), NamedTypeSymbol)
Dim myButton = DirectCast(d.GetMembers("myButton").Single(), PropertySymbol)
Assert.Equal(0, myButton.GetAttributes().Length)
Dim attr = myButton.GetFieldAttributes().Single()
Assert.Equal("A", attr.AttributeClass.Name)
End Sub
<Fact>
Public Sub AttributeTargets_WithEventsGenericInstantiation()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Class A
Inherits Attribute
End Class
Class D(Of T As Button)
<A>
Public WithEvents myButton As T
End Class
Class Button
Public Event OnClick()
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
Dim d = DirectCast(c.GlobalNamespace.GetMembers("D").Single(), NamedTypeSymbol)
Dim button = DirectCast(c.GlobalNamespace.GetMembers("Button").Single(), NamedTypeSymbol)
Dim dOfButton = d.Construct(button)
Dim myButton = DirectCast(dOfButton.GetMembers("myButton").Single(), PropertySymbol)
Assert.Equal(0, myButton.GetAttributes().Length)
Dim attr = myButton.GetFieldAttributes().Single()
Assert.Equal("A", attr.AttributeClass.Name)
End Sub
<Fact>
Public Sub AttributeTargets_Events()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
End Class
<Serializable>
Class D
<A, NonSerialized>
Public Event OnClick As Action
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
c.VerifyDiagnostics()
Dim d = DirectCast(c.GlobalNamespace.GetMembers("D").Single(), NamedTypeSymbol)
Dim onClick = DirectCast(d.GetMembers("OnClick").Single(), EventSymbol)
' TODO (tomat): move NonSerialized attribute onto the associated field
Assert.Equal(2, onClick.GetAttributes().Length) ' should be 1
Assert.Equal(0, onClick.GetFieldAttributes().Length) ' should be 1
End Sub
<Fact, WorkItem(546769, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546769"), WorkItem(546770, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546770")>
Public Sub DiagnosticsOnEventParameters()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Class C
Event E(<MarshalAs()> x As Integer)
End Class
]]>
</file>
</compilation>
Dim c = CreateCompilationWithMscorlib40(source)
c.AssertTheseDiagnostics(<![CDATA[
BC30516: Overload resolution failed because no accessible 'New' accepts this number of arguments.
Event E(<MarshalAs()> x As Integer)
~~~~~~~~~
]]>)
End Sub
<Fact, WorkItem(528748, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/528748")>
Public Sub TestNonPublicConstructor()
Dim source =
<compilation>
<file name="TestNonPublicConstructor.vb"><![CDATA[
<Fred(1)>
Class Class1
End Class
Class FredAttribute : Inherits System.Attribute
Public Sub New(x As Integer, Optional y As Integer = 1)
End Sub
Friend Sub New(x As Integer)
End Sub
End Class
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_BadAttributeNonPublicConstructor, "Fred"))
End Sub
<WorkItem(542223, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542223")>
<Fact>
Public Sub AttributeArgumentAsEnumFromMetadata()
Dim metadata1 = VisualBasicCompilation.Create("bar.dll",
references:={MscorlibRef},
syntaxTrees:={Parse("Public Enum Bar : Baz : End Enum")}).EmitToArray(New EmitOptions(metadataOnly:=True))
Dim ref1 = MetadataReference.CreateFromImage(metadata1)
Dim metadata2 = VisualBasicCompilation.Create(
"goo.dll",
references:={MscorlibRef, ref1},
syntaxTrees:={
VisualBasicSyntaxTree.ParseText(<![CDATA[
Public Class Ca : Inherits System.Attribute
Public Sub New(o As Object)
End Sub
End Class
<Ca(Bar.Baz)>
Public Class Goo
End Class]]>.Value)}).EmitToArray(options:=New EmitOptions(metadataOnly:=True))
Dim ref2 = MetadataReference.CreateFromImage(metadata2)
Dim comp = VisualBasicCompilation.Create("moo.dll", references:={MscorlibRef, ref1, ref2})
Dim goo = comp.GetTypeByMetadataName("Goo")
Dim ca = goo.GetAttributes().First().CommonConstructorArguments.First()
Assert.Equal("Bar", ca.Type.Name)
End Sub
<Fact>
Public Sub TestAttributeWithNestedUnboundGeneric()
Dim library =
<file name="Library.vb"><![CDATA[
Namespace ClassLibrary1
Public Class C1(Of T1)
Public Class C2(Of T2, T3)
End Class
End Class
End Namespace
]]>
</file>
Dim compilation1 = VisualBasicCompilation.Create("library.dll",
{VisualBasicSyntaxTree.ParseText(library.Value)},
{MscorlibRef},
TestOptions.ReleaseDll)
Dim classLibrary = MetadataReference.CreateFromImage(compilation1.EmitToArray())
Dim source =
<compilation>
<file name="TestAttributeWithNestedUnboundGeneric.vb"><![CDATA[
Imports System
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(ClassLibrary1.C1(Of )))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef, classLibrary})
compilation2.VerifyDiagnostics()
Dim a = compilation2.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, UnboundGenericType)
Assert.Equal("ClassLibrary1.C1(Of )", arg.ToDisplayString)
Assert.False(DirectCast(arg, INamedTypeSymbol).IsSerializable)
End Sub
<Fact>
Public Sub TestAttributeWithAliasToUnboundGeneric()
Dim library =
<file name="Library.vb"><![CDATA[
Namespace ClassLibrary1
Public Class C1(Of T1)
Public Class C2(Of T2, T3)
End Class
End Class
End Namespace
]]>
</file>
Dim compilation1 = VisualBasicCompilation.Create("library.dll",
{VisualBasicSyntaxTree.ParseText(library.Value)},
{MscorlibRef},
TestOptions.ReleaseDll)
Dim classLibrary = MetadataReference.CreateFromImage(compilation1.EmitToArray())
Dim source =
<compilation>
<file name="TestAttributeWithAliasToUnboundGeneric.vb"><![CDATA[
Imports System
Imports x = ClassLibrary1
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(x.C1(Of )))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef, classLibrary})
compilation2.VerifyDiagnostics()
Dim a = compilation2.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, UnboundGenericType)
Assert.Equal("ClassLibrary1.C1(Of )", arg.ToDisplayString)
End Sub
<Fact>
Public Sub TestAttributeWithArrayOfUnboundGeneric()
Dim source =
<compilation>
<file name="TestAttributeWithArrayOfUnboundGeneric.vb"><![CDATA[
Imports System
Class C1(of T)
End Class
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(C1(Of )()))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef})
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_ArrayOfRawGenericInvalid, "()"))
Dim a = compilation.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, ArrayTypeSymbol)
Assert.Equal("C1(Of ?)()", arg.ToDisplayString)
End Sub
<Fact>
Public Sub TestAttributeWithNullableUnboundGeneric()
Dim source =
<compilation>
<file name="TestAttributeWithNullableUnboundGeneric.vb"><![CDATA[
Imports System
Class C1(of T)
End Class
Class A
Inherits Attribute
Public Sub New(o As Object)
End Sub
End Class
<A(GetType(C1(Of )?))>
Module Module1
Sub Main()
End Sub
End Module
]]>
</file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndReferences(source, {SystemRef, MsvbRef})
CompilationUtils.AssertTheseDiagnostics(compilation,
<errors><![CDATA[
BC33101: Type 'C1(Of ?)' must be a value type or a type argument constrained to 'Structure' in order to be used with 'Nullable' or nullable modifier '?'.
<A(GetType(C1(Of )?))>
~~~~~~~
BC30182: Type expected.
<A(GetType(C1(Of )?))>
~
]]>
</errors>)
Dim a = compilation.GetTypeByMetadataName("Module1")
Dim gt = a.GetAttributes().First().CommonConstructorArguments.First()
Assert.False(DirectCast(gt.Value, TypeSymbol).IsErrorType)
Dim arg = DirectCast(gt.Value, SubstitutedNamedType)
Assert.Equal("C1(Of ?)?", arg.ToDisplayString)
End Sub
<Fact()>
Public Sub TestConstantValueInsideAttributes()
Dim tree = VisualBasicSyntaxTree.ParseText(<![CDATA[
Class c1
const A as integer = 1;
const B as integer = 2;
class MyAttribute : inherits Attribute
Sub New(i as integer)
End Sub
end class
<MyAttribute(A + B + 3)>
Sub Goo()
End Sub
End Class"]]>.Value)
Dim expr = tree.GetRoot().DescendantNodes().OfType(Of BinaryExpressionSyntax).First()
Dim comp = CreateCompilationWithMscorlib40({tree})
Dim constantValue = comp.GetSemanticModel(tree).GetConstantValue(expr)
Assert.True(constantValue.HasValue)
Assert.Equal(constantValue.Value, 6)
End Sub
<Fact>
Public Sub TestArrayTypeInAttributeArgument()
Dim source =
<compilation>
<file name="TestArrayTypeInAttributeArgument.vb"><![CDATA[
Imports System
Public Class W
End Class
Public Class Y(Of T)
Public Class F
End Class
Public Class Z(Of U)
End Class
End Class
Public Class XAttribute
Inherits Attribute
Public Sub New(y As Object)
End Sub
End Class
<X(GetType(W()))> _
Public Class C1
End Class
<X(GetType(W(,)))> _
Public Class C2
End Class
<X(GetType(W(,)()))> _
Public Class C3
End Class
<X(GetType(Y(Of W)()(,)))> _
Public Class C4
End Class
<X(GetType(Y(Of Integer).F(,)()(,,)))> _
Public Class C5
End Class
<X(GetType(Y(Of Integer).Z(Of W)(,)()))> _
Public Class C6
End Class
]]>
</file>
</compilation>
Dim attributeValidator = Sub(m As ModuleSymbol)
Dim classW As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("W")
Dim classY As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("Y")
Dim classF As NamedTypeSymbol = classY.GetTypeMember("F")
Dim classZ As NamedTypeSymbol = classY.GetTypeMember("Z")
Dim classX As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("XAttribute")
Dim classC1 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C1")
Dim classC2 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C2")
Dim classC3 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C3")
Dim classC4 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C4")
Dim classC5 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C5")
Dim classC6 As NamedTypeSymbol = m.GlobalNamespace.GetTypeMember("C6")
Dim attrs = classC1.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim typeArg = ArrayTypeSymbol.CreateVBArray(classW, Nothing, 1, m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC2.GetAttributes()
Assert.Equal(1, attrs.Length)
typeArg = ArrayTypeSymbol.CreateVBArray(classW, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC3.GetAttributes()
Assert.Equal(1, attrs.Length)
typeArg = ArrayTypeSymbol.CreateVBArray(classW, Nothing, 1, m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC4.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim classYOfW As NamedTypeSymbol = classY.Construct(ImmutableArray.Create(Of TypeSymbol)(classW))
typeArg = ArrayTypeSymbol.CreateVBArray(classYOfW, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, Nothing, 1, m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC5.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim classYOfInt As NamedTypeSymbol = classY.Construct(ImmutableArray.Create(Of TypeSymbol)(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)))
Dim substNestedF As NamedTypeSymbol = classYOfInt.GetTypeMember("F")
typeArg = ArrayTypeSymbol.CreateVBArray(substNestedF, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=3, declaringAssembly:=m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, Nothing, 1, m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
attrs = classC6.GetAttributes()
Assert.Equal(1, attrs.Length)
Dim substNestedZ As NamedTypeSymbol = classYOfInt.GetTypeMember("Z").Construct(ImmutableArray.Create(Of TypeSymbol)(classW))
typeArg = ArrayTypeSymbol.CreateVBArray(substNestedZ, Nothing, 1, m.ContainingAssembly)
typeArg = ArrayTypeSymbol.CreateVBArray(typeArg, CType(Nothing, ImmutableArray(Of CustomModifier)), rank:=2, declaringAssembly:=m.ContainingAssembly)
attrs.First().VerifyValue(Of Object)(0, TypedConstantKind.Type, typeArg)
End Sub
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
CompileAndVerify(compilation, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
#End Region
#Region "Error Tests"
<Fact>
Public Sub AttributeConstructorErrors1()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="AttributeConstructorErrors1.vb">
<![CDATA[
Imports System
Module m
Function NotAConstant() as integer
return 9
End Function
End Module
Enum e1
a
End Enum
<AttributeUsage(AttributeTargets.All, allowMultiple:=True)>
Class XAttribute
Inherits Attribute
Sub New()
End Sub
Sub New(ByVal d As Decimal)
End Sub
Sub New(ByRef i As Integer)
End Sub
Public Sub New(ByVal e As e1)
End Sub
End Class
<XDoesNotExist>
<X(1D)>
<X(1)>
<X(e1.a)>
<X(NotAConstant() + 2)>
Class A
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors><![CDATA[
BC30002: Type 'XDoesNotExist' is not defined.
<XDoesNotExist>
~~~~~~~~~~~~~
BC30045: Attribute constructor has a parameter of type 'Decimal', which is not an integral, floating-point or Enum type or one of Object, Char, String, Boolean, System.Type or 1-dimensional array of these types.
<X(1D)>
~
BC36006: Attribute constructor has a 'ByRef' parameter of type 'Integer'; cannot use constructors with byref parameters to apply the attribute.
<X(1)>
~
BC31516: Type 'e1' cannot be used in an attribute because it is not declared 'Public'.
<X(e1.a)>
~
BC36006: Attribute constructor has a 'ByRef' parameter of type 'Integer'; cannot use constructors with byref parameters to apply the attribute.
<X(NotAConstant() + 2)>
~
BC30059: Constant expression is required.
<X(NotAConstant() + 2)>
~~~~~~~~~~~~~~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub AttributeConversionsErrors()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="AttributeConversionsErrors.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, allowMultiple:=True)>
Class XAttribute
Inherits Attribute
Sub New()
End Sub
Sub New(i As Integer)
End Sub
End Class
<X("a")>
Class A
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors><![CDATA[
BC30934: Conversion from 'String' to 'Integer' cannot occur in a constant expression used as an argument to an attribute.
<X("a")>
~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub AttributeNamedArgumentErrors1()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="AttributeNamedArgumentErrors1.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, allowMultiple:=True)>
Class XAttribute
Inherits Attribute
Sub F1(i as integer)
End Sub
private PrivateField as integer
shared Property SharedProperty as integer
ReadOnly Property ReadOnlyProperty As Integer
Get
Return Nothing
End Get
End Property
Property BadDecimalType as decimal
Property BadDateType as date
Property BadArrayType As Attribute()
End Class
<X(NotFound := nothing)>
<X(F1 := nothing)>
<X(PrivateField := nothing)>
<X(SharedProperty := nothing)>
<X(ReadOnlyProperty := nothing)>
<X(BadDecimalType := nothing)>
<X(BadDateType := nothing)>
<X(BadArrayType:=Nothing)>
Class A
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30661: Field or property 'NotFound' is not found.
<X(NotFound := nothing)>
~~~~~~~~
BC32010: 'F1' cannot be named as a parameter in an attribute specifier because it is not a field or property.
<X(F1 := nothing)>
~~
BC30389: 'XAttribute.PrivateField' is not accessible in this context because it is 'Private'.
<X(PrivateField := nothing)>
~~~~~~~~~~~~
BC31500: 'Shared' attribute property 'SharedProperty' cannot be the target of an assignment.
<X(SharedProperty := nothing)>
~~~~~~~~~~~~~~
BC31501: 'ReadOnly' attribute property 'ReadOnlyProperty' cannot be the target of an assignment.
<X(ReadOnlyProperty := nothing)>
~~~~~~~~~~~~~~~~
BC30659: Property or field 'BadDecimalType' does not have a valid attribute type.
<X(BadDecimalType := nothing)>
~~~~~~~~~~~~~~
BC30659: Property or field 'BadDateType' does not have a valid attribute type.
<X(BadDateType := nothing)>
~~~~~~~~~~~
BC30659: Property or field 'BadArrayType' does not have a valid attribute type.
<X(BadArrayType:=Nothing)>
~~~~~~~~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<WorkItem(540939, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540939")>
<Fact>
Public Sub AttributeProtectedConstructorError()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<A()>
Class A
Inherits Attribute
Protected Sub New()
End Sub
End Class
<B("goo")>
Class B
Inherits Attribute
Protected Sub New()
End Sub
End Class
<C("goo")>
Class C
Inherits Attribute
Protected Sub New()
End Sub
Protected Sub New(b as string)
End Sub
End Class
<D(1S)>
Class D
Inherits Attribute
Protected Sub New()
End Sub
protected Sub New(b as Integer)
End Sub
protected Sub New(b as Long)
End Sub
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30517: Overload resolution failed because no 'New' is accessible.
<A()>
~~~
BC30517: Overload resolution failed because no 'New' is accessible.
<B("goo")>
~~~~~~~~
BC30517: Overload resolution failed because no 'New' is accessible.
<C("goo")>
~~~~~~~~
BC30517: Overload resolution failed because no 'New' is accessible.
<D(1S)>
~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
' TODO: after fixing LookupResults and changing the error handling for inaccessible attribute constructors,
' the error messages from above are expected to change to something like:
' Error BC30390 'A.Protected Sub New()' is not accessible in this context because it is 'Protected'.
End Sub
<WorkItem(540624, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540624")>
<Fact>
Public Sub AttributeNoMultipleAndInvalidTarget()
Dim source =
<compilation>
<file name="AttributeNoMultipleAndInvalidTarget.vb"><![CDATA[
Imports System
Imports CustomAttribute
<Base(1)>
<Base("SOS")>
Module AttributeMod
<Derived("Q"c)>
<Derived("C"c)>
Public Class Goo
End Class
End Module
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source,
{MetadataReference.CreateFromImage(TestResources.SymbolsTests.Metadata.AttributeTestDef01)})
' BC30663, BC30662
Dim expectedErrors =
<errors>
<![CDATA[
BC30663: Attribute 'BaseAttribute' cannot be applied multiple times.
<Base("SOS")>
~~~~~~~~~~~
BC30662: Attribute 'DerivedAttribute' cannot be applied to 'Goo' because the attribute is not valid on this declaration type.
<Derived("Q"c)>
~~~~~~~
BC30663: Attribute 'DerivedAttribute' cannot be applied multiple times.
<Derived("C"c)>
~~~~~~~~~~~~~
]]>
</errors>
CompilationUtils.AssertTheseDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub AttributeNameScoping()
Dim source =
<compilation>
<file name="AttributeNameScoping.vb"><![CDATA[
Imports System
' X1 should not be visible without qualification
<clscompliant(x1)>
Module m1
Const X1 as boolean = true
' C1 should not be visible without qualification
<clscompliant(C1)>
Public Class CGoo
Public Const C1 as Boolean = true
<clscompliant(c1)>
public Sub s()
end sub
End Class
' C1 should not be visible without qualification
<clscompliant(C1)>
Public Structure SGoo
Public Const C1 as Boolean = true
<clscompliant(c1)>
public Sub s()
end sub
End Structure
' s should not be visible without qualification
<clscompliant(s.GetType() isnot nothing)>
Public Interface IGoo
Sub s()
End Interface
' C1 should not be visible without qualification
<clscompliant(a = 1)>
Public Enum EGoo
A = 1
End Enum
End Module
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40AndVBRuntime(source)
compilation.VerifyDiagnostics(
Diagnostic(ERRID.ERR_InaccessibleSymbol2, "x1").WithArguments("m1.X1", "Private"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "C1").WithArguments("C1"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "C1").WithArguments("C1"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "s").WithArguments("s"),
Diagnostic(ERRID.ERR_RequiredConstExpr, "s.GetType() isnot nothing"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "a").WithArguments("a"),
Diagnostic(ERRID.ERR_RequiredConstExpr, "a = 1"))
End Sub
<WorkItem(541279, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/541279")>
<Fact>
Public Sub AttributeArrayMissingInitializer()
Dim source =
<compilation>
<file name="AttributeArrayMissingInitializer.vb"><![CDATA[
Imports System
<AttributeUsage(AttributeTargets.All, AllowMultiple:=true)>
Class A
Inherits Attribute
Public Sub New(x As Object())
End Sub
End Class
<A(New Object(5) {})>
<A(New Object(5) {1})>
Class B
Shared Sub Main()
End Sub
End Class
]]></file>
</compilation>
Dim compilation = CreateCompilationWithMscorlib40(source)
compilation.VerifyDiagnostics(
Diagnostic(ERRID.ERR_MissingValuesForArraysInApplAttrs, "{}"),
Diagnostic(ERRID.ERR_InitializerTooFewElements1, "{1}").WithArguments("5")
)
End Sub
<Fact>
Public Sub Bug8642()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<goo(Type.EmptyTypes)>
Module Program
Sub Main(args As String())
End Sub
End Module
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30002: Type 'goo' is not defined.
<goo(Type.EmptyTypes)>
~~~
BC30059: Constant expression is required.
<goo(Type.EmptyTypes)>
~~~~~~~~~~~~~~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub ErrorsInMultipleSyntaxTrees()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<Module: A>
<AttributeUsage(AttributeTargets.Class)>
Class A
Inherits Attribute
End Class
<AttributeUsage(AttributeTargets.Method)>
Class B
Inherits Attribute
End Class
]]>
</file>
<file name="b.vb">
<![CDATA[
<Module: B>
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30549: Attribute 'A' cannot be applied to a module.
<Module: A>
~
BC30549: Attribute 'B' cannot be applied to a module.
<Module: B>
~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub ErrorsInMultiplePartialDeclarations()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Class)>
Class A1
Inherits Attribute
End Class
<AttributeUsage(AttributeTargets.Method)>
Class A2
Inherits Attribute
End Class
<A1>
Class B
End Class
]]>
</file>
<file name="b.vb">
<![CDATA[
<A1, A2>
Partial Class B
End Class
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30663: Attribute 'A1' cannot be applied multiple times.
<A1, A2>
~~
BC30662: Attribute 'A2' cannot be applied to 'B' because the attribute is not valid on this declaration type.
<A1, A2>
~~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<Fact>
Public Sub PartialMethods()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Public Class A
Inherits Attribute
End Class
Public Class B
Inherits Attribute
End Class
Partial Class C
<A>
Private Partial Sub Goo()
End Sub
<B>
Private Sub Goo()
End Sub
End Class
]]>
</file>
</compilation>)
CompileAndVerify(compilation, sourceSymbolValidator:=
Sub(moduleSymbol)
Dim c = DirectCast(moduleSymbol.GlobalNamespace.GetMembers("C").Single(), NamedTypeSymbol)
Dim goo = DirectCast(c.GetMembers("Goo").Single(), MethodSymbol)
Dim attrs = goo.GetAttributes()
Assert.Equal(2, attrs.Length)
Assert.Equal("A", attrs(0).AttributeClass.Name)
Assert.Equal("B", attrs(1).AttributeClass.Name)
End Sub)
End Sub
<WorkItem(542020, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542020")>
<Fact>
Public Sub ErrorsAttributeNameResolutionWithNamespace()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class CAttribute
Inherits Attribute
End Class
Namespace Y.CAttribute
End Namespace
Namespace Y
Namespace X
<C>
Class C
Inherits Attribute
End Class
End Namespace
End Namespace
]]>
</file>
</compilation>)
Dim expectedErrors = <errors>
<![CDATA[
BC30182: Type expected.
<C>
~
]]></errors>
CompilationUtils.AssertTheseDeclarationDiagnostics(compilation, expectedErrors)
End Sub
<WorkItem(542170, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542170")>
<Fact>
Public Sub GenericTypeParameterUsedAsAttribute()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module M
<T>
Sub Goo(Of T)
End Sub
Class T : Inherits Attribute
End Class
End Module
]]>
</file>
</compilation>)
'BC32067: Type parameters, generic types or types contained in generic types cannot be used as attributes.
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_AttrCannotBeGenerics, "T").WithArguments("T"))
End Sub
<WorkItem(542273, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/542273")>
<Fact()>
Public Sub AnonymousTypeFieldAsAttributeNamedArgValue()
Dim compilation = CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<AttributeUsage(AttributeTargets.Class, AllowMultiple:=New With {.anonymousField = False}.anonymousField)>
Class ExtensionAttribute
Inherits Attribute
End Class
]]>
</file>
</compilation>)
'BC30059: Constant expression is required.
compilation.VerifyDiagnostics(Diagnostic(ERRID.ERR_RequiredConstExpr, "New With {.anonymousField = False}.anonymousField"))
End Sub
<WorkItem(545073, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545073")>
<Fact>
Public Sub AttributeOnDelegateReturnTypeError()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Public Class ReturnTypeAttribute
Inherits System.Attribute
End Class
Class C
Public Delegate Function D() As <ReturnTypeAttribute(0)> Integer
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40AndVBRuntime(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_TooManyArgs1, "0").WithArguments("Public Sub New()"))
End Sub
<Fact>
Public Sub AttributeOnDelegateParameterError()
Dim source =
<compilation>
<file name="a.vb"><![CDATA[
Public Class ReturnTypeAttribute
Inherits System.Attribute
End Class
Class C
Public Delegate Function D(<ReturnTypeAttribute(0)>ByRef a As Integer) As Integer
End Class
]]>
</file>
</compilation>
CreateCompilationWithMscorlib40AndVBRuntime(source).VerifyDiagnostics(
Diagnostic(ERRID.ERR_TooManyArgs1, "0").WithArguments("Public Sub New()"))
End Sub
<WorkItem(545073, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545073")>
<Fact>
Public Sub AttributesOnDelegate()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Public Class A
Inherits System.Attribute
End Class
Public Class B
Inherits System.Attribute
End Class
Public Class C
Inherits System.Attribute
End Class
<A>
Public Delegate Function D(<C>a As Integer, <C>ByRef b As Integer) As <B> Integer
]]>
</file>
</compilation>
Dim attributeValidator =
Sub(m As ModuleSymbol)
Dim d = m.GlobalNamespace.GetTypeMember("D")
Dim invoke = DirectCast(d.GetMember("Invoke"), MethodSymbol)
Dim beginInvoke = DirectCast(d.GetMember("BeginInvoke"), MethodSymbol)
Dim endInvoke = DirectCast(d.GetMember("EndInvoke"), MethodSymbol)
Dim ctor = DirectCast(d.Constructors.Single(), MethodSymbol)
Dim p As ParameterSymbol
' no attributes on methods:
Assert.Equal(0, invoke.GetAttributes().Length)
Assert.Equal(0, beginInvoke.GetAttributes().Length)
Assert.Equal(0, endInvoke.GetAttributes().Length)
Assert.Equal(0, ctor.GetAttributes().Length)
' attributes on return types:
Assert.Equal(0, beginInvoke.GetReturnTypeAttributes().Length)
Assert.Equal(0, endInvoke.GetReturnTypeAttributes().Length)
Assert.Equal(0, ctor.GetReturnTypeAttributes().Length)
Dim attrs = invoke.GetReturnTypeAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "B")
' ctor parameters:
Assert.Equal(2, ctor.Parameters.Length)
Assert.Equal(0, ctor.Parameters(0).GetAttributes().Length)
Assert.Equal(0, ctor.Parameters(0).GetAttributes().Length)
' Invoke parameters:
Assert.Equal(2, invoke.Parameters.Length)
attrs = invoke.Parameters(0).GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
attrs = invoke.Parameters(1).GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
' BeginInvoke parameters:
Assert.Equal(4, beginInvoke.Parameters.Length)
p = beginInvoke.Parameters(0)
Assert.Equal("a", p.Name)
attrs = p.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
Assert.Equal(1, p.GetAttributes(attrs(0).AttributeClass).Count)
Assert.False(p.IsExplicitByRef)
Assert.False(p.IsByRef)
p = beginInvoke.Parameters(1)
Assert.Equal("b", p.Name)
attrs = p.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
Assert.Equal(1, p.GetAttributes(attrs(0).AttributeClass).Count)
Assert.True(p.IsExplicitByRef)
Assert.True(p.IsByRef)
Assert.Equal(0, beginInvoke.Parameters(2).GetAttributes().Length)
Assert.Equal(0, beginInvoke.Parameters(3).GetAttributes().Length)
' EndInvoke parameters:
Assert.Equal(2, endInvoke.Parameters.Length)
p = endInvoke.Parameters(0)
Assert.Equal("b", p.Name)
attrs = p.GetAttributes()
Assert.Equal(1, attrs.Length)
Assert.Equal(attrs(0).AttributeClass.Name, "C")
Assert.Equal(1, p.GetAttributes(attrs(0).AttributeClass).Count)
Assert.True(p.IsExplicitByRef)
Assert.True(p.IsByRef)
p = endInvoke.Parameters(1)
attrs = p.GetAttributes()
Assert.Equal(0, attrs.Length)
End Sub
' Verify attributes from source and then load metadata to see attributes are written correctly.
CompileAndVerify(source, sourceSymbolValidator:=attributeValidator, symbolValidator:=attributeValidator)
End Sub
#End Region
''' <summary>
''' Verify that inaccessible friend AAttribute is preferred over accessible A
''' </summary>
<Fact()>
Public Sub TestAttributeLookupInaccessibleFriend()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Class A
Inherits System.Attribute
End Class
<A()>
Class C
End Class
Module Module1
Sub Main()
End Sub
End Module]]>
</file>
</compilation>
Dim sourceWithAAttribute As XElement =
<compilation>
<file name="library.vb">
<![CDATA[
Class AAttribute
End Class
]]></file>
</compilation>
Dim compWithAAttribute = VisualBasicCompilation.Create(
"library.dll",
{VisualBasicSyntaxTree.ParseText(sourceWithAAttribute.Value)},
{MsvbRef, MscorlibRef, SystemCoreRef},
TestOptions.ReleaseDll)
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, {compWithAAttribute.ToMetadataReference()})
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_InaccessibleSymbol2, "A").WithArguments("AAttribute", "Friend"))
End Sub
''' <summary>
''' Verify that inaccessible inherited private is preferred
''' </summary>
<Fact()>
Public Sub TestAttributeLookupInaccessibleInheritedPrivate()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class C
Private Class NSAttribute
Inherits Attribute
End Class
End Class
Class d
Inherits C
<NS()>
Sub d()
End Sub
End Class
Module Module1
Sub Main()
End Sub
End Module]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_InaccessibleSymbol2, "NS").WithArguments("C.NSAttribute", "Private"))
End Sub
''' <summary>
''' Verify that ambiguous error is reported when A binds to two Attributes.
''' </summary>
''' <remarks>If this is run in the IDE make sure global namespace is empty or add
''' global namespace prefix to N1 and N2 or run test at command line.</remarks>
<Fact()>
Public Sub TestAttributeLookupAmbiguousAttributesWithPrefix()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Imports System
Imports N1
Imports N2
Namespace N1
Class AAttribute
End Class
End Namespace
Namespace N2
Class AAttribute
End Class
End Namespace
Class A
Inherits Attribute
End Class
<A()>
Class C
End Class]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_AmbiguousInImports2, "A").WithArguments("AAttribute", "N1, N2"))
End Sub
''' <summary>
''' Verify that source attribute takes precedence over metadata attribute with the same name
''' </summary>
<Fact()>
Public Sub TestAttributeLookupSourceOverridesMetadata()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Namespace System.Runtime.CompilerServices
<AttributeUsage(AttributeTargets.Assembly Or AttributeTargets.Class Or AttributeTargets.Method)>
Public Class extensionattribute : Inherits Attribute
End Class
End Namespace
Module m
<System.Runtime.CompilerServices.extension()>
Sub Test1(x As Integer)
System.Console.WriteLine(x)
End Sub
Sub Main()
Dim x = New System.Runtime.CompilerServices.extensionattribute()
End Sub
End Module]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source)
comp.VerifyDiagnostics()
End Sub
<WorkItem(543855, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543855")>
<Fact()>
Public Sub VariantArrayConversionInAttribute()
Dim vbCompilation = CreateVisualBasicCompilation("VariantArrayConversion",
<![CDATA[
Imports System
<Assembly: AObject(new Type() {GetType(string)})>
<AttributeUsage(AttributeTargets.All)>
Public Class AObjectAttribute
Inherits Attribute
Sub New(b As Object)
End Sub
Sub New(b As Object())
End Sub
End Class
]]>,
compilationOptions:=New VisualBasicCompilationOptions(OutputKind.DynamicallyLinkedLibrary))
CompileAndVerify(vbCompilation).VerifyDiagnostics()
End Sub
<Fact(), WorkItem(544199, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544199")>
Public Sub EnumsAllowedToViolateAttributeUsage()
CompilationUtils.CreateCompilationWithMscorlib40(
<compilation>
<file name="a.vb">
Imports System
Imports System.Runtime.InteropServices
<ComVisible(True)> _
<Guid("6f4eb02b-3469-424c-bbcc-2672f653e646")> _
<BestFitMapping(False)> _
<StructLayout(LayoutKind.Auto)> _
<TypeLibType(TypeLibTypeFlags.FRestricted)> _
<Flags()> _
Public Enum EnumHasAllSupportedAttributes
ID1
ID2
End Enum
</file>
</compilation>).VerifyDiagnostics()
End Sub
<Fact, WorkItem(544367, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544367")>
Public Sub AttributeOnPropertyParameter()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
Imports System
Module Module1
Sub Main()
Dim classAType As Type = GetType(A)
Dim itemGetter = classAType.GetMethod("get_Item")
ShowAttributes(itemGetter.GetParameters()(0))
Dim itemSetter = classAType.GetMethod("set_Item")
ShowAttributes(itemSetter.GetParameters()(0))
End Sub
Sub ShowAttributes(p As Reflection.ParameterInfo)
Dim attrs = p.GetCustomAttributes(False)
Console.WriteLine("param {1} in {0} has {2} attributes", p.Member, p.Name, attrs.Length)
For Each a In attrs
Console.WriteLine(" attribute of type {0}", a.GetType())
Next
End Sub
End Module
Class A
Default Public Property Item( <MyAttr(A.C)> index As Integer) As String
Get
Return ""
End Get
Set(value As String)
End Set
End Property
Public Const C as Integer = 4
End Class
Class MyAttr
Inherits Attribute
Public Sub New(x As Integer)
End Sub
End Class
</file>
</compilation>, TestOptions.ReleaseExe)
CompileAndVerify(comp, <![CDATA[
param index in System.String get_Item(Int32) has 1 attributes
attribute of type MyAttr
param index in Void set_Item(Int32, System.String) has 1 attributes
attribute of type MyAttr
]]>)
End Sub
<Fact, WorkItem(544367, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544367")>
Public Sub AttributeOnPropertyParameterWithError()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb"><![CDATA[
Imports System
Module Module1
Sub Main()
End Sub
End Module
Class A
Default Public Property Item(<MyAttr> index As Integer) As String
Get
Return ""
End Get
Set(value As String)
End Set
End Property
End Class
Class MyAttr
' Does not inherit attribute
End Class
]]>
</file>
</compilation>, TestOptions.ReleaseExe)
CompilationUtils.AssertTheseDiagnostics(comp, <expected>
BC31504: 'MyAttr' cannot be used as an attribute because it does not inherit from 'System.Attribute'.
Default Public Property Item(<MyAttr> index As Integer) As String
~~~~~~
</expected>)
End Sub
<Fact, WorkItem(543810, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543810")>
Public Sub AttributeNamedArgumentWithEvent()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Class Base
Event myEvent
End Class
Class Program
Inherits Base
<MyAttribute(t:=myEvent)>
Event MyEvent2
Sub Main(args As String())
End Sub
End Class
Class MyAttribute
Inherits Attribute
Public t As Object
Sub New(t As Integer, Optional x As Integer = 1.0D, Optional y As String = Nothing)
End Sub
End Class
Module m
Sub Main()
End Sub
End Module
]]></file>
</compilation>, TestOptions.ReleaseExe)
CompilationUtils.AssertTheseDiagnostics(comp, <expected><![CDATA[
BC30455: Argument not specified for parameter 't' of 'Public Sub New(t As Integer, [x As Integer = 1], [y As String = Nothing])'.
<MyAttribute(t:=myEvent)>
~~~~~~~~~~~
BC30369: Cannot refer to an instance member of a class from within a shared method or shared member initializer without an explicit instance of the class.
<MyAttribute(t:=myEvent)>
~~~~~~~
]]></expected>)
End Sub
<Fact, WorkItem(543955, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543955")>
Public Sub StringParametersInDeclareMethods_1()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Imports System.Reflection
Module Module1
Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, ByVal buffer As Integer) As Integer
Declare Unicode Function GetWindowsDirectory2 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, ByVal buffer As Integer) As Integer
Declare Auto Function GetWindowsDirectory3 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, ByVal buffer As Integer) As Integer
Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Declare Unicode Function GetWindowsDirectory5 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Declare Auto Function GetWindowsDirectory6 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Delegate Function D(ByRef buffer As String, ByVal buffer As Integer) As Integer
Sub Main()
Dim t = GetType(Module1)
Print(t.GetMethod("GetWindowsDirectory1"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory2"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory3"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory4"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory5"))
System.Console.WriteLine()
Print(t.GetMethod("GetWindowsDirectory6"))
System.Console.WriteLine()
End Sub
Private Sub Print(m As MethodInfo)
System.Console.WriteLine(m.Name)
For Each p In m.GetParameters()
System.Console.WriteLine("{0} As {1}", p.Name, p.ParameterType)
For Each marshal In p.GetCustomAttributes(GetType(Runtime.InteropServices.MarshalAsAttribute), False)
System.Console.WriteLine(DirectCast(marshal, Runtime.InteropServices.MarshalAsAttribute).Value.ToString())
Next
Next
End Sub
Sub Test1(ByRef x As String)
GetWindowsDirectory1(x, 0)
End Sub
Sub Test2(ByRef x As String)
GetWindowsDirectory2(x, 0)
End Sub
Sub Test3(ByRef x As String)
GetWindowsDirectory3(x, 0)
End Sub
Sub Test4(ByRef x As String)
GetWindowsDirectory4(x, 0)
End Sub
Sub Test5(ByRef x As String)
GetWindowsDirectory5(x, 0)
End Sub
Sub Test6(ByRef x As String)
GetWindowsDirectory6(x, 0)
End Sub
Function Test11() As D
Return AddressOf GetWindowsDirectory1
End Function
Function Test12() As D
Return AddressOf GetWindowsDirectory2
End Function
Function Test13() As D
Return AddressOf GetWindowsDirectory3
End Function
Function Test14() As D
Return AddressOf GetWindowsDirectory4
End Function
Function Test15() As D
Return AddressOf GetWindowsDirectory5
End Function
Function Test16() As D
Return AddressOf GetWindowsDirectory6
End Function
End Module
]]></file>
</compilation>, TestOptions.ReleaseExe)
Dim verifier = CompileAndVerify(comp, expectedOutput:=
<![CDATA[
GetWindowsDirectory1
buffer As System.String&
VBByRefStr
buffer As System.Int32
GetWindowsDirectory2
buffer As System.String&
VBByRefStr
buffer As System.Int32
GetWindowsDirectory3
buffer As System.String&
VBByRefStr
buffer As System.Int32
GetWindowsDirectory4
buffer As System.String&
AnsiBStr
buffer As System.Int32
GetWindowsDirectory5
buffer As System.String&
BStr
buffer As System.Int32
GetWindowsDirectory6
buffer As System.String&
TBStr
buffer As System.Int32
]]>)
verifier.VerifyIL("Module1.Test1",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Ansi Function Module1.GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test2",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Unicode Function Module1.GetWindowsDirectory2 Lib "kernel32" Alias "GetWindowsDirectoryW" (String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test3",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Auto Function Module1.GetWindowsDirectory3 Lib "kernel32" Alias "GetWindowsDirectoryW" (String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test4",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Ansi Function Module1.GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test5",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Unicode Function Module1.GetWindowsDirectory5 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
verifier.VerifyIL("Module1.Test6",
<![CDATA[
{
// Code size 9 (0x9)
.maxstack 2
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: call "Declare Auto Function Module1.GetWindowsDirectory6 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef String, Integer) As Integer"
IL_0007: pop
IL_0008: ret
}
]]>)
End Sub
<Fact, WorkItem(543955, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/543955")>
Public Sub StringParametersInDeclareMethods_3()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Imports System.Reflection
Module Module1
Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByVal buffer As String, ByVal buffer As Integer) As Integer
Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, ByVal buffer As Integer) As Integer
Delegate Function D3(buffer As String, ByVal buffer As Integer) As Integer
Delegate Function D4(buffer As Integer, ByVal buffer As Integer) As Integer
Function Test19() As D3
Return AddressOf GetWindowsDirectory1 ' 1
End Function
Function Test20() As D3
Return AddressOf GetWindowsDirectory4 ' 2
End Function
Function Test21() As D4
Return AddressOf GetWindowsDirectory1 ' 3
End Function
Function Test22() As D4
Return AddressOf GetWindowsDirectory4 ' 4
End Function
Sub Main()
End Sub
End Module
]]></file>
</compilation>, TestOptions.ReleaseExe)
AssertTheseDiagnostics(comp,
<expected>
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D3(buffer As String, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory1 ' 1
~~~~~~~~~~~~~~~~~~~~
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D3(buffer As String, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory4 ' 2
~~~~~~~~~~~~~~~~~~~~
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory1 Lib "kernel32" Alias "GetWindowsDirectoryW" (buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D4(buffer As Integer, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory1 ' 3
~~~~~~~~~~~~~~~~~~~~
BC31143: Method 'Public Declare Ansi Function GetWindowsDirectory4 Lib "kernel32" Alias "GetWindowsDirectoryW" (ByRef buffer As String, buffer As Integer) As Integer' does not have a signature compatible with delegate 'Delegate Function Module1.D4(buffer As Integer, buffer As Integer) As Integer'.
Return AddressOf GetWindowsDirectory4 ' 4
~~~~~~~~~~~~~~~~~~~~
</expected>)
End Sub
<WorkItem(529620, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/529620")>
<Fact()>
Public Sub TestFriendEnumInAttribute()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
' Friend Enum in an array in an attribute should be an error.
Imports System
Friend Enum e2
r
g
b
End Enum
Namespace Test2
<MyAttr1(New e2() {e2.g})>
Class C
End Class
Class MyAttr1
Inherits Attribute
Sub New(ByVal B As e2())
End Sub
End Class
End Namespace
]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_BadAttributeNonPublicType1, "MyAttr1").WithArguments("e2()"))
End Sub
<WorkItem(545558, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545558")>
<Fact()>
Public Sub TestUndefinedEnumInAttribute()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System.ComponentModel
Module Program
<EditorBrowsable(EditorBrowsableState.n)>
Sub Main(args As String())
End Sub
End Module
]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntime(source)
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_NameNotMember2, "EditorBrowsableState.n").WithArguments("n", "System.ComponentModel.EditorBrowsableState"))
End Sub
<WorkItem(545697, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/545697")>
<Fact>
Public Sub TestUnboundLambdaInNamedAttributeArgument()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module Program
<A(F:=Sub()
Dim x = Mid("1", 1)
End Sub)>
Sub Main(args As String())
Dim a As Action = Sub()
Dim x = Mid("1", 1)
End Sub
End Sub
End Module
]]>
</file>
</compilation>
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, references:={SystemCoreRef})
comp.VerifyDiagnostics(Diagnostic(ERRID.ERR_UndefinedType1, "A").WithArguments("A"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "Mid").WithArguments("Mid"),
Diagnostic(ERRID.ERR_PropertyOrFieldNotDefined1, "F").WithArguments("F"),
Diagnostic(ERRID.ERR_NameNotDeclared1, "Mid").WithArguments("Mid"))
End Sub
<Fact>
Public Sub SpecialNameAttributeFromSource()
Dim source =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System.Runtime.CompilerServices
<SpecialName()>
Public Structure S
<SpecialName()>
Friend Event E As Action(Of String)
<SpecialName()>
Default Property P(b As Byte) As Byte
Get
Return b
End Get
Set(value As Byte)
End Set
End Property
End Structure
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndVBRuntime(source)
Dim globalNS = comp.SourceAssembly.GlobalNamespace
Dim typesym = DirectCast(globalNS.GetMember("S"), NamedTypeSymbol)
Assert.NotNull(typesym)
Assert.True(typesym.HasSpecialName)
Dim e = DirectCast(typesym.GetMember("E"), EventSymbol)
Assert.NotNull(e)
Assert.True(e.HasSpecialName)
Dim p = DirectCast(typesym.GetMember("P"), PropertySymbol)
Assert.NotNull(p)
Assert.True(p.HasSpecialName)
Assert.True(e.HasSpecialName)
Assert.Equal("Private EEvent As Action", e.AssociatedField.ToString)
Assert.True(e.HasAssociatedField)
Assert.Equal(ImmutableArray.Create(Of VisualBasicAttributeData)(), e.GetFieldAttributes)
Assert.Null(e.OverriddenEvent)
Assert.NotNull(p)
Assert.True(p.HasSpecialName)
Assert.Equal(ImmutableArray.Create(Of VisualBasicAttributeData)(), p.GetFieldAttributes)
End Sub
''' <summary>
''' Verify that attributeusage from base class is used by derived class
''' </summary>
<Fact()>
Public Sub TestAttributeUsageInheritedBaseAttribute()
Dim source = <compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module Module1
<DerivedAllowsMultiple()>
<DerivedAllowsMultiple()> ' Should allow multiple
Sub Main()
End Sub
End Module]]>
</file>
</compilation>
Dim sourceWithAttribute As XElement =
<compilation>
<file name="library.vb">
<![CDATA[
Imports System
Public Class DerivedAllowsMultiple
Inherits Base
End Class
<AttributeUsage(AttributeTargets.All, AllowMultiple:=True, Inherited:=true)>
Public Class Base
Inherits Attribute
End Class
]]></file>
</compilation>
Dim compWithAttribute = VisualBasicCompilation.Create(
"library.dll",
{VisualBasicSyntaxTree.ParseText(sourceWithAttribute.Value)},
{MsvbRef, MscorlibRef, SystemCoreRef},
TestOptions.ReleaseDll)
Dim sourceLibRef = compWithAttribute.ToMetadataReference()
Dim comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, {sourceLibRef})
comp.AssertNoDiagnostics()
Dim metadataLibRef As MetadataReference = compWithAttribute.ToMetadataReference()
comp = CompilationUtils.CreateCompilationWithMscorlib40AndVBRuntimeAndReferences(source, {metadataLibRef})
comp.AssertNoDiagnostics()
Dim attributesOnMain = comp.GlobalNamespace.GetModuleMembers("Module1").Single().GetMembers("Main").Single().GetAttributes()
Assert.Equal(2, attributesOnMain.Length())
Assert.NotEqual(attributesOnMain(0).ApplicationSyntaxReference, attributesOnMain(1).ApplicationSyntaxReference)
Assert.NotNull(attributesOnMain(0).ApplicationSyntaxReference)
End Sub
<Fact(), WorkItem(546490, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/546490")>
Public Sub Bug15984()
Dim customIL = <![CDATA[
.assembly extern mscorlib { .ver 4:0:0:0 .publickeytoken = (B7 7A 5C 56 19 34 E0 89) }
.assembly extern FSharp.Core {}
.assembly '<<GeneratedFileName>>'
{
}
.class public abstract auto ansi sealed Library1.Goo
extends [mscorlib]System.Object
{
.custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 )
.method public static int32 inc(int32 x) cil managed
{
// Code size 5 (0x5)
.maxstack 8
IL_0000: nop
IL_0001: ldarg.0
IL_0002: ldc.i4.1
IL_0003: add
IL_0004: ret
} // end of method Goo::inc
} // end of class Library1.Goo
]]>
Dim compilation = CompilationUtils.CreateCompilationWithCustomILSource(
<compilation>
<file name="a.vb">
</file>
</compilation>, customIL.Value, appendDefaultHeader:=False)
Dim type = compilation.GetTypeByMetadataName("Library1.Goo")
Assert.Equal(0, type.GetAttributes()(0).ConstructorArguments.Count)
End Sub
<Fact>
<WorkItem(569089, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/569089")>
Public Sub NullArrays()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class A
Inherits Attribute
Public Sub New(a As Object(), b As Integer())
End Sub
Public Property P As Object()
Public F As Integer()
End Class
<A(Nothing, Nothing, P:=Nothing, F:=Nothing)>
Class C
End Class
]]></file>
</compilation>
CompileAndVerify(source, symbolValidator:=
Sub(m)
Dim c = m.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C")
Dim attr = c.GetAttributes().Single()
Dim args = attr.ConstructorArguments.ToArray()
Assert.True(args(0).IsNull)
Assert.Equal("Object()", args(0).Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() args(0).Value)
Assert.True(args(1).IsNull)
Assert.Equal("Integer()", args(1).Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() args(1).Value)
Dim named = attr.NamedArguments.ToDictionary(Function(e) e.Key, Function(e) e.Value)
Assert.True(named("P").IsNull)
Assert.Equal("Object()", named("P").Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() named("P").Value)
Assert.True(named("F").IsNull)
Assert.Equal("Integer()", named("F").Type.ToDisplayString())
Assert.Throws(Of InvalidOperationException)(Function() named("F").Value)
End Sub)
End Sub
<Fact>
<WorkItem(688268, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/688268")>
Public Sub Bug688268()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Imports System.Runtime.InteropServices
Imports System.Security
Public Interface I
Sub _VtblGap1_30()
Sub _VtblGaX1_30()
End Interface
]]></file>
</compilation>
Dim metadataValidator As System.Action(Of ModuleSymbol) =
Sub([module] As ModuleSymbol)
Dim metadata = DirectCast([module], PEModuleSymbol).Module
Dim typeI = DirectCast([module].GlobalNamespace.GetTypeMembers("I").Single(), PENamedTypeSymbol)
Dim methods = metadata.GetMethodsOfTypeOrThrow(typeI.Handle)
Assert.Equal(2, methods.Count)
Dim e = methods.GetEnumerator()
e.MoveNext()
Dim flags = metadata.GetMethodDefFlagsOrThrow(e.Current)
Assert.Equal(
MethodAttributes.PrivateScope Or
MethodAttributes.Public Or
MethodAttributes.Virtual Or
MethodAttributes.VtableLayoutMask Or
MethodAttributes.CheckAccessOnOverride Or
MethodAttributes.Abstract Or
MethodAttributes.SpecialName Or
MethodAttributes.RTSpecialName,
flags)
e.MoveNext()
flags = metadata.GetMethodDefFlagsOrThrow(e.Current)
Assert.Equal(
MethodAttributes.PrivateScope Or
MethodAttributes.Public Or
MethodAttributes.Virtual Or
MethodAttributes.VtableLayoutMask Or
MethodAttributes.CheckAccessOnOverride Or
MethodAttributes.Abstract,
flags)
End Sub
CompileAndVerify(source, symbolValidator:=metadataValidator)
End Sub
<Fact>
Public Sub NullTypeAndString()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class A
Inherits Attribute
Public Sub New(t As Type, s As String)
End Sub
End Class
<A(Nothing, Nothing)>
Class C
End Class
]]></file>
</compilation>
CompileAndVerify(source, symbolValidator:=
Sub(m)
Dim c = m.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C")
Dim attr = c.GetAttributes().Single()
Dim args = attr.ConstructorArguments.ToArray()
Assert.Null(args(0).Value)
Assert.Equal("Type", args(0).Type.Name)
Assert.Throws(Of InvalidOperationException)(Function() args(0).Values)
Assert.Null(args(1).Value)
Assert.Equal("String", args(1).Type.Name)
Assert.Throws(Of InvalidOperationException)(Function() args(1).Values)
End Sub)
End Sub
<Fact>
<WorkItem(728865, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/728865")>
Public Sub Repro728865()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Reflection
Imports Microsoft.Yeti
Namespace PFxIntegration
Public Class ProducerConsumerScenario
Shared Sub Main()
Dim program = GetType(ProducerConsumerScenario)
Dim methodInfo = program.GetMethod("ProducerConsumer")
Dim myAttributes = methodInfo.GetCustomAttributes(False)
If myAttributes.Length > 0 Then
Console.WriteLine()
Console.WriteLine("The attributes for the method - {0} - are: ", methodInfo)
Console.WriteLine()
For j = 0 To myAttributes.Length - 1
Console.WriteLine("The type of the attribute is {0}", myAttributes(j))
Next
End If
End Sub
Public Enum CollectionType
[Default]
Queue
Stack
Bag
End Enum
Public Sub New()
End Sub
<CartesianRowData({5, 100, 100000}, {CollectionType.Default, CollectionType.Queue, CollectionType.Stack, CollectionType.Bag})>
Public Sub ProducerConsumer()
Console.WriteLine("Hello")
End Sub
End Class
End Namespace
Namespace Microsoft.Yeti
<AttributeUsage(AttributeTargets.Method, AllowMultiple:=True)>
Public Class CartesianRowDataAttribute
Inherits Attribute
Public Sub New()
End Sub
Public Sub New(ParamArray data As Object())
Dim asEnum As IEnumerable(Of Object)() = New IEnumerable(Of Object)(data.Length) {}
For i = 0 To data.Length - 1
WrapEnum(DirectCast(data(i), IEnumerable))
Next
End Sub
Shared Sub WrapEnum(x As IEnumerable)
For Each a In x
Console.WriteLine(" - {0} -", a)
Next
End Sub
End Class
End Namespace
]]></file>
</compilation>
CompileAndVerify(source, expectedOutput:=<![CDATA[
- 5 -
- 100 -
- 100000 -
- Default -
- Queue -
- Stack -
- Bag -
The attributes for the method - Void ProducerConsumer() - are:
The type of the attribute is Microsoft.Yeti.CartesianRowDataAttribute]]>)
End Sub
<Fact>
<WorkItem(728865, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/728865")>
Public Sub ParamArrayAttributeConstructor()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class MyAttribute
Inherits Attribute
Public Sub New(ParamArray array As Object())
End Sub
End Class
Public Class Test
<My({1, 2, 3})>
Sub M1()
End Sub
<My(1, 2, 3)>
Sub M2()
End Sub
<My({"A", "B", "C"})>
Sub M3()
End Sub
<My("A", "B", "C")>
Sub M4()
End Sub
<My({{1, 2, 3}, {"A", "B", "C"}})>
Sub M5()
End Sub
<My({1, 2, 3}, {"A", "B", "C"})>
Sub M6()
End Sub
End Class
]]></file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40(source)
Dim type = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Test")
Dim methods = Enumerable.Range(1, 6).Select(Function(i) type.GetMember(Of MethodSymbol)("M" & i)).ToArray()
methods(0).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Integer() {1, 2, 3})
methods(1).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {1, 2, 3})
methods(2).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New String() {"A", "B", "C"})
methods(3).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {"A", "B", "C"})
methods(4).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {}) ' Value was invalid.
methods(5).GetAttributes().Single().VerifyValue(0, TypedConstantKind.Array, New Object() {DirectCast({1, 2, 3}, Object), DirectCast({"A", "B", "C"}, Object)})
comp.AssertTheseDiagnostics(<errors><![CDATA[
BC30934: Conversion from 'Object(*,*)' to 'Object' cannot occur in a constant expression used as an argument to an attribute.
<My({{1, 2, 3}, {"A", "B", "C"}})>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
]]></errors>)
End Sub
<Fact>
<WorkItem(737021, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/737021")>
Public Sub NothingVersusEmptyArray()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class ArrayAttribute
Inherits Attribute
Public field As Integer()
Public Sub New(array As Integer())
End Sub
End Class
Public Class Test
<Array(Nothing)>
Sub M0()
End Sub
<Array({})>
Sub M1()
End Sub
<Array(Nothing, field:=Nothing)>
Sub M2()
End Sub
<Array({}, field:=Nothing)>
Sub M3()
End Sub
<Array(Nothing, field:={})>
Sub M4()
End Sub
<Array({}, field:={})>
Sub M5()
End Sub
End Class
]]></file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40(source)
Dim type = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Test")
Dim methods = Enumerable.Range(0, 6).Select(Function(i) type.GetMember(Of MethodSymbol)("M" & i))
Dim attrs = methods.Select(Function(m) m.GetAttributes().Single()).ToArray()
Const fieldName = "field"
Dim nullArray As Integer() = Nothing
Dim emptyArray As Integer() = {}
Assert.NotEqual(nullArray, emptyArray)
attrs(0).VerifyValue(0, TypedConstantKind.Array, nullArray)
attrs(1).VerifyValue(0, TypedConstantKind.Array, emptyArray)
attrs(2).VerifyValue(0, TypedConstantKind.Array, nullArray)
attrs(2).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, nullArray)
attrs(3).VerifyValue(0, TypedConstantKind.Array, emptyArray)
attrs(3).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, nullArray)
attrs(4).VerifyValue(0, TypedConstantKind.Array, nullArray)
attrs(4).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, emptyArray)
attrs(5).VerifyValue(0, TypedConstantKind.Array, emptyArray)
attrs(5).VerifyNamedArgumentValue(0, fieldName, TypedConstantKind.Array, emptyArray)
End Sub
<Fact>
<WorkItem(530266, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/530266")>
Public Sub UnboundGenericTypeInTypedConstant()
Dim source =
<compilation>
<file><![CDATA[
Imports System
Public Class TestAttribute
Inherits Attribute
Sub New(x as Type)
End Sub
End Class
<TestAttribute(GetType(Target(Of )))>
Class Target(Of T)
End Class
]]></file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40(source, options:=TestOptions.ReleaseDll)
Dim type = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Target")
Dim typeInAttribute = DirectCast(type.GetAttributes()(0).ConstructorArguments(0).Value, NamedTypeSymbol)
Assert.True(typeInAttribute.IsUnboundGenericType)
Assert.True(DirectCast(typeInAttribute, INamedTypeSymbol).IsUnboundGenericType)
Assert.Equal("Target(Of )", typeInAttribute.ToTestDisplayString())
Dim comp2 = CreateCompilationWithMscorlib40AndReferences(<compilation><file></file></compilation>, {comp.EmitToImageReference()})
type = comp2.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Target")
Assert.IsAssignableFrom(Of PENamedTypeSymbol)(type)
typeInAttribute = DirectCast(type.GetAttributes()(0).ConstructorArguments(0).Value, NamedTypeSymbol)
Assert.True(typeInAttribute.IsUnboundGenericType)
Assert.True(DirectCast(typeInAttribute, INamedTypeSymbol).IsUnboundGenericType)
Assert.Equal("Target(Of )", typeInAttribute.ToTestDisplayString())
End Sub
<Fact, WorkItem(879792, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/879792")>
Public Sub Bug879792()
Dim source2 =
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
<Z>
Module Program
Sub Main()
End Sub
End Module
Interface ZatTribute(Of T)
End Interface
Class Z
Inherits Attribute
End Class
]]>
</file>
</compilation>
Dim comp = CreateCompilationWithMscorlib40AndVBRuntime(source2)
CompilationUtils.AssertNoDiagnostics(comp)
Dim program = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("Program")
Assert.Equal("Z", program.GetAttributes()(0).AttributeClass.ToTestDisplayString())
End Sub
<Fact, WorkItem(1020038, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1020038")>
Public Sub Bug1020038()
Dim source1 =
<compilation name="Bug1020038">
<file name="a.vb"><![CDATA[
Public Class CTest
End Class
]]>
</file>
</compilation>
Dim validator = Sub(m As ModuleSymbol)
Assert.Equal(2, m.ReferencedAssemblies.Length)
Assert.Equal("Bug1020038", m.ReferencedAssemblies(1).Name)
End Sub
Dim compilation1 = CreateCompilationWithMscorlib40(source1)
Dim source2 =
<compilation>
<file name="a.vb"><![CDATA[
Class CAttr
Inherits System.Attribute
Sub New(x as System.Type)
End Sub
End Class
<CAttr(GetType(CTest))>
Class Test
End Class
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source2, {New VisualBasicCompilationReference(compilation1)})
CompileAndVerify(compilation2, symbolValidator:=validator)
Dim source3 =
<compilation>
<file name="a.vb"><![CDATA[
Class CAttr
Inherits System.Attribute
Sub New(x as System.Type)
End Sub
End Class
<CAttr(GetType(System.Func(Of System.Action(Of CTest))))>
Class Test
End Class
]]>
</file>
</compilation>
Dim compilation3 = CreateCompilationWithMscorlib40AndReferences(source3, {New VisualBasicCompilationReference(compilation1)})
CompileAndVerify(compilation3, symbolValidator:=validator)
End Sub
<Fact, WorkItem(1144603, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1144603")>
Public Sub EmitMetadataOnlyInPresenceOfErrors()
Dim source1 =
<compilation>
<file name="a.vb"><![CDATA[
Public Class DiagnosticAnalyzerAttribute
Inherits System.Attribute
Public Sub New(firstLanguage As String, ParamArray additionalLanguages As String())
End Sub
End Class
Public Class LanguageNames
Public Const CSharp As xyz = "C#"
End Class
]]>
</file>
</compilation>
Dim compilation1 = CreateCompilationWithMscorlib40(source1, options:=TestOptions.DebugDll)
AssertTheseDiagnostics(compilation1, <![CDATA[
BC30002: Type 'xyz' is not defined.
Public Const CSharp As xyz = "C#"
~~~
]]>)
Dim source2 =
<compilation>
<file name="a.vb"><![CDATA[
<DiagnosticAnalyzer(LanguageNames.CSharp)>
Class CSharpCompilerDiagnosticAnalyzer
End Class
]]>
</file>
</compilation>
Dim compilation2 = CreateCompilationWithMscorlib40AndReferences(source2, {New VisualBasicCompilationReference(compilation1)}, options:=TestOptions.DebugDll.WithModuleName("Test.dll"))
Assert.Same(compilation1.Assembly, compilation2.SourceModule.ReferencedAssemblySymbols(1))
AssertTheseDiagnostics(compilation2)
Dim emitResult2 = compilation2.Emit(peStream:=New MemoryStream(), options:=New EmitOptions(metadataOnly:=True))
Assert.False(emitResult2.Success)
AssertTheseDiagnostics(emitResult2.Diagnostics, <![CDATA[
BC36970: Failed to emit module 'Test.dll': Module has invalid attributes.
]]>)
' Use different mscorlib to test retargeting scenario
Dim compilation3 = CreateCompilationWithMscorlib45AndVBRuntime(source2, {New VisualBasicCompilationReference(compilation1)}, options:=TestOptions.DebugDll)
Assert.NotSame(compilation1.Assembly, compilation3.SourceModule.ReferencedAssemblySymbols(1))
AssertTheseDiagnostics(compilation3, <![CDATA[
BC30002: Type 'xyz' is not defined.
<DiagnosticAnalyzer(LanguageNames.CSharp)>
~~~~~~~~~~~~~~~~~~~~
]]>)
Dim emitResult3 = compilation3.Emit(peStream:=New MemoryStream(), options:=New EmitOptions(metadataOnly:=True))
Assert.False(emitResult3.Success)
AssertTheseDiagnostics(emitResult3.Diagnostics, <![CDATA[
BC30002: Type 'xyz' is not defined.
<DiagnosticAnalyzer(LanguageNames.CSharp)>
~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromADifferentAssemblyFails_Internal()
Dim reference =
<compilation>
<file name="a.vb"><![CDATA[
<Assembly: System.Runtime.CompilerServices.InternalsVisibleToAttribute("Source")>
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Friend Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Friend Class TestType2
End Class
Friend Class TestType3
End Class
End Namespace
]]>
</file>
</compilation>
Dim referenceCompilation = CreateCompilationWithMscorlib40(reference).ToMetadataReference()
Dim code = "
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3() ' This should be fine
End Sub
End Class"
Dim compilation = CreateCompilationWithMscorlib40(code, references:={referenceCompilation}, assemblyName:="Source")
AssertTheseDiagnostics(compilation, <![CDATA[
BC30002: Type 'TestReference.TestType1' is not defined.
Dim obj1 = New TestReference.TestType1()
~~~~~~~~~~~~~~~~~~~~~~~
BC30002: Type 'TestReference.TestType2' is not defined.
Dim obj2 = New TestReference.TestType2()
~~~~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromADifferentAssemblyFails_Public()
Dim reference =
<compilation>
<file name="a.vb"><![CDATA[
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Public Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Public Class TestType2
End Class
Public Class TestType3
End Class
End Namespace
]]>
</file>
</compilation>
Dim referenceCompilation = CreateCompilationWithMscorlib40(reference).ToMetadataReference()
Dim code = "
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3() ' This should be fine
End Sub
End Class"
Dim compilation = CreateCompilationWithMscorlib40(code, references:={referenceCompilation})
AssertTheseDiagnostics(compilation, <![CDATA[
BC30002: Type 'TestReference.TestType1' is not defined.
Dim obj1 = New TestReference.TestType1()
~~~~~~~~~~~~~~~~~~~~~~~
BC30002: Type 'TestReference.TestType2' is not defined.
Dim obj2 = New TestReference.TestType2()
~~~~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromADifferentAssemblyFails_Module()
Dim moduleCode = CreateCompilationWithMscorlib40(options:=TestOptions.ReleaseModule, source:="
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Public Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Public Class TestType2
End Class
Public Class TestType3
End Class
End Namespace")
Dim reference = ModuleMetadata.CreateFromImage(moduleCode.EmitToArray()).GetReference()
Dim code = "
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3() ' This should be fine
End Sub
End Class"
Dim compilation = CreateCompilationWithMscorlib40(code, references:={reference})
AssertTheseDiagnostics(compilation, <![CDATA[
BC30002: Type 'TestReference.TestType1' is not defined.
Dim obj1 = New TestReference.TestType1()
~~~~~~~~~~~~~~~~~~~~~~~
BC30002: Type 'TestReference.TestType2' is not defined.
Dim obj2 = New TestReference.TestType2()
~~~~~~~~~~~~~~~~~~~~~~~
]]>)
End Sub
<Fact>
Public Sub ReferencingEmbeddedAttributesFromTheSameAssemblySucceeds()
Dim compilation = CreateCompilationWithMscorlib40(source:="
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace TestReference
<Microsoft.CodeAnalysis.Embedded>
Public Class TestType1
End Class
<Microsoft.CodeAnalysis.EmbeddedAttribute>
Public Class TestType2
End Class
Public Class TestType3
End Class
End Namespace
Public Class Program
Public Shared Sub Main()
Dim obj1 = New TestReference.TestType1()
Dim obj2 = New TestReference.TestType2()
Dim obj3 = New TestReference.TestType3()
End Sub
End Class")
AssertTheseEmitDiagnostics(compilation)
End Sub
<Fact>
Public Sub EmbeddedAttributeInSourceIsAllowedIfCompilerDoesNotNeedToGenerateOne()
Dim compilation = CreateCompilationWithMscorlib40(options:=TestOptions.ReleaseExe, source:=
<compilation>
<file name="a.vb"><![CDATA[
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
Namespace OtherNamespace
<Microsoft.CodeAnalysis.Embedded>
Public Class TestReference
Public Shared Function GetValue() As Integer
Return 3
End Function
End Class
End Namespace
Public Class Program
Public Shared Sub Main()
' This should be fine, as the compiler doesn't need to use an embedded attribute for this compilation
System.Console.Write(OtherNamespace.TestReference.GetValue())
End Sub
End Class
]]>
</file>
</compilation>)
CompileAndVerify(compilation, expectedOutput:="3")
End Sub
<Fact>
Public Sub EmbeddedTypesInAnAssemblyAreNotExposedExternally()
Dim compilation1 = CreateCompilationWithMscorlib40(options:=TestOptions.ReleaseDll, source:=
<compilation>
<file name="a.vb"><![CDATA[
Namespace Microsoft.CodeAnalysis
Friend Class EmbeddedAttribute
Inherits System.Attribute
End Class
End Namespace
<Microsoft.CodeAnalysis.Embedded>
Public Class TestReference1
End Class
Public Class TestReference2
End Class
]]>
</file>
</compilation>)
Assert.NotNull(compilation1.GetTypeByMetadataName("TestReference1"))
Assert.NotNull(compilation1.GetTypeByMetadataName("TestReference2"))
Dim compilation2 = CreateCompilationWithMscorlib40("", references:={compilation1.EmitToImageReference()})
Assert.Null(compilation2.GetTypeByMetadataName("TestReference1"))
Assert.NotNull(compilation2.GetTypeByMetadataName("TestReference2"))
End Sub
<Fact>
Public Sub AttributeWithTaskDelegateParameter()
Dim code = "
Imports System
Imports System.Threading.Tasks
Namespace a
Public Class Class1
<AttributeUsage(AttributeTargets.Class, AllowMultiple:=True)>
Public Class CommandAttribute
Inherits Attribute
Public Delegate Function FxCommand() As Task
Public Sub New(Fx As FxCommand)
Me.Fx = Fx
End Sub
Public Property Fx As FxCommand
End Class
<Command(AddressOf UserInfo)>
Public Shared Async Function UserInfo() As Task
Await New Task(
Sub()
End Sub)
End Function
End Class
End Namespace
"
CreateCompilationWithMscorlib45(code).VerifyDiagnostics(
Diagnostic(ERRID.ERR_BadAttributeConstructor1, "Command").WithArguments("a.Class1.CommandAttribute.FxCommand").WithLocation(20, 10),
Diagnostic(ERRID.ERR_RequiredConstExpr, "AddressOf UserInfo").WithLocation(20, 18))
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Test/Emit/ExpressionTrees/Results/CheckedComparisonOperators.txt | -=-=-=-=-=-=-=-=- SByte = SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte = SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte = SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte = Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short = Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short = Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? = Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short = Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? = Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort = UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort = UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort = UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer = Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long = Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long = Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? = Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long = Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? = Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong = ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong = ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong = ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single = Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single = Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? = Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single = Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
Equal(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? = Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double = Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double = Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? = Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double = Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
Equal(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? = Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String = String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
Equal(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object = Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <> SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <> Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short <> Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <> Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <> Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <> Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <> Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <> UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <> Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long <> Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <> Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <> Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <> Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <> Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <> ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <> Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <> Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <> Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <> Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <> Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double <> Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <> Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <> Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <> Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <> Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String <> String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
NotEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object <> Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectNotEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte < SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte < SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte < SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte < Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short < Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short < Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? < Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short < Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? < Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort < UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort < UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort < UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer < Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long < Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long < Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? < Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long < Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? < Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong < ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong < ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong < ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single < Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single < Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? < Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single < Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? < Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double < Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double < Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? < Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double < Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? < Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String < String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object < Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectLess(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short <= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <= Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long <= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <= Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <= Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double <= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <= Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String <= String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object <= Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectLessEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte >= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte >= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short >= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short >= Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? >= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short >= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? >= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort >= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer >= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long >= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long >= Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? >= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long >= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? >= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong >= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single >= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single >= Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? >= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single >= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? >= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double >= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double >= Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? >= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double >= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? >= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String >= String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object >= Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectGreaterEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte > SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte > SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte > SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte > Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short > Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short > Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? > Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short > Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? > Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort > UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort > UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort > UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer > Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long > Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long > Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? > Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long > Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? > Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong > ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong > ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong > ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single > Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single > Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? > Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single > Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? > Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double > Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double > Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? > Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double > Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? > Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String > String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object > Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectGreater(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte = SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte = SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte = SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte = SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? = SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? = SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte = Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte = Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? = Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? = Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short = Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short = Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short = Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short = Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? = Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? = Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? = Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? = Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort = UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort = UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort = UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort = UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? = UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? = UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer = Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer = Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? = Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? = Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long = Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long = Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long = Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long = Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? = Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? = Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? = Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? = Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong = ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong = ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong = ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong = ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? = ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? = ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single = Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single = Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single = Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single = Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? = Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? = Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? = Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? = Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double = Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double = Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double = Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double = Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? = Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? = Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? = Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? = Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String = String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Equal(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String = String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
Equal(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object = Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object = Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <> SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <> SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <> Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <> Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <> Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <> Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <> Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <> Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <> Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <> Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <> Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <> Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <> UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <> UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <> Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <> Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <> Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <> Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <> Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <> Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <> Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <> Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <> Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <> Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <> ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <> ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <> Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <> Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <> Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <> Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <> Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <> Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <> Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <> Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <> Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <> Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <> Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <> Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <> Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <> Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <> Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <> Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String <> String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
NotEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String <> String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
NotEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object <> Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectNotEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object <> Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectNotEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte < SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte < SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte < SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte < SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? < SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? < SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte < Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte < Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? < Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? < Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short < Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short < Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short < Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short < Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? < Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? < Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? < Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? < Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort < UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort < UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort < UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort < UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? < UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? < UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer < Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer < Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? < Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? < Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long < Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long < Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long < Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long < Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? < Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? < Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? < Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? < Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong < ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong < ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong < ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong < ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? < ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? < ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single < Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single < Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single < Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single < Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? < Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? < Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? < Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? < Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double < Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double < Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double < Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double < Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? < Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? < Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? < Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? < Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String < String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
LessThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String < String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object < Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLess(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object < Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLess(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String <= String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
LessThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String <= String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object <= Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLessEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object <= Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLessEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte >= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte >= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte >= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte >= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short >= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short >= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short >= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short >= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? >= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? >= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? >= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? >= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort >= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort >= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer >= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer >= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long >= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long >= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long >= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long >= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? >= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? >= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? >= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? >= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong >= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong >= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single >= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single >= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single >= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single >= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? >= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? >= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? >= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? >= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double >= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double >= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double >= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double >= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? >= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? >= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? >= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? >= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String >= String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
GreaterThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String >= String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object >= Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreaterEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object >= Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreaterEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte > SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte > SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte > SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte > SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? > SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? > SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte > Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte > Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? > Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? > Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short > Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short > Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short > Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short > Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? > Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? > Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? > Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? > Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort > UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort > UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort > UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort > UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? > UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? > UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer > Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer > Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? > Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? > Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long > Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long > Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long > Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long > Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? > Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? > Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? > Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? > Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong > ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong > ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong > ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong > ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? > ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? > ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single > Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single > Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single > Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single > Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? > Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? > Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? > Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? > Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double > Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double > Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double > Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double > Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? > Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? > Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? > Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? > Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String > String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
GreaterThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String > String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object > Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreater(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object > Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreater(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
) | -=-=-=-=-=-=-=-=- SByte = SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte = SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte = SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte = Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short = Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short = Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? = Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short = Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? = Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort = UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort = UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort = UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer = Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long = Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long = Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? = Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long = Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? = Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong = ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong = ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong = ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single = Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single = Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? = Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single = Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
Equal(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? = Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double = Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double = Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? = Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double = Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
Equal(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? = Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String = String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
Equal(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object = Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <> SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <> Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short <> Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <> Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <> Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <> Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <> Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <> UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <> Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long <> Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <> Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <> Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <> Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <> Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <> ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <> Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <> Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <> Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <> Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <> Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double <> Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <> Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <> Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <> Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <> Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String <> String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
NotEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object <> Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectNotEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte < SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte < SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte < SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte < Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short < Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short < Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? < Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short < Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? < Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort < UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort < UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort < UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer < Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long < Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long < Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? < Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long < Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? < Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong < ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong < ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong < ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single < Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single < Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? < Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single < Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? < Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double < Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double < Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? < Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double < Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? < Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String < String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object < Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectLess(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte <= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte <= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short <= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <= Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short <= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? <= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort <= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer <= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long <= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <= Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long <= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? <= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong <= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <= Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single <= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? <= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double <= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <= Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double <= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? <= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String <= String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object <= Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectLessEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte >= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte >= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short >= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short >= Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? >= Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short >= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? >= Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort >= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer >= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long >= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long >= Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? >= Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long >= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? >= Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong >= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single >= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single >= Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? >= Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single >= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? >= Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double >= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double >= Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? >= Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double >= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? >= Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String >= String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object >= Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectGreaterEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte > SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.SByte,System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte > SByte => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte => SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.SByte
)
}
return type: System.SByte
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.SByte]
)
-=-=-=-=-=-=-=-=- SByte > SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte? => SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
}
return type: System.Nullable`1[System.SByte]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[E_SByte,E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
method: System.Nullable`1[E_SByte] op_Implicit(E_SByte) in System.Nullable`1[E_SByte]
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte => E_SByte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_SByte
)
}
return type: E_SByte
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,E_SByte]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte? => E_SByte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_SByte]
)
}
return type: System.Nullable`1[E_SByte]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[E_SByte]]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Byte,System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte => Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.Byte
)
}
return type: System.Byte
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Byte]
)
-=-=-=-=-=-=-=-=- Byte > Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte? => Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
}
return type: System.Nullable`1[System.Byte]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[E_Byte,E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
method: System.Nullable`1[E_Byte] op_Implicit(E_Byte) in System.Nullable`1[E_Byte]
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte => E_Byte -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Byte
)
}
return type: E_Byte
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,E_Byte]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte? => E_Byte? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Byte]
)
}
return type: System.Nullable`1[E_Byte]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[E_Byte]]
)
-=-=-=-=-=-=-=-=- Short > Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Int16,System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short > Short => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? > Short => Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
}
return type: System.Int16
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Int16]
)
-=-=-=-=-=-=-=-=- Short > Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- Short? > Short? => Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
}
return type: System.Nullable`1[System.Int16]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Int16]]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[E_Short,E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
method: System.Nullable`1[E_Short] op_Implicit(E_Short) in System.Nullable`1[E_Short]
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short => E_Short -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_Short
)
}
return type: E_Short
type: System.Func`3[System.Nullable`1[E_Short],E_Short,E_Short]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short? => E_Short? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Short]
)
}
return type: System.Nullable`1[E_Short]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[E_Short]]
)
-=-=-=-=-=-=-=-=- UShort > UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.UInt16,System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort > UShort => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort => UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: System.UInt16
)
}
return type: System.UInt16
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.UInt16]
)
-=-=-=-=-=-=-=-=- UShort > UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort? => UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
}
return type: System.Nullable`1[System.UInt16]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16]]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[E_UShort,E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
method: System.Nullable`1[E_UShort] op_Implicit(E_UShort) in System.Nullable`1[E_UShort]
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort => E_UShort -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int16
)
type: System.Int16
)
type: E_UShort
)
}
return type: E_UShort
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,E_UShort]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort? => E_UShort? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int16
)
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UShort]
)
}
return type: System.Nullable`1[E_UShort]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[E_UShort]]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Int32,System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer => Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
}
return type: System.Int32
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Int32]
)
-=-=-=-=-=-=-=-=- Integer > Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer? => Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
}
return type: System.Nullable`1[System.Int32]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Int32]]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[E_Integer,E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
method: System.Nullable`1[E_Integer] op_Implicit(E_Integer) in System.Nullable`1[E_Integer]
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer => E_Integer -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_Integer
)
}
return type: E_Integer
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,E_Integer]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer? => E_Integer? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Integer]
)
}
return type: System.Nullable`1[E_Integer]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[E_Integer]]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.UInt32,System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger => UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: System.UInt32
)
}
return type: System.UInt32
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.UInt32]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger? => UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
}
return type: System.Nullable`1[System.UInt32]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32]]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[E_UInteger,E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
method: System.Nullable`1[E_UInteger] op_Implicit(E_UInteger) in System.Nullable`1[E_UInteger]
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger => E_UInteger -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int32
)
type: System.Int32
)
type: E_UInteger
)
}
return type: E_UInteger
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,E_UInteger]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger? => E_UInteger? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int32
)
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[E_UInteger]
)
}
return type: System.Nullable`1[E_UInteger]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger]]
)
-=-=-=-=-=-=-=-=- Long > Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Int64,System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long > Long => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? > Long => Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Negate(
ConvertChecked(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
}
return type: System.Int64
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Int64]
)
-=-=-=-=-=-=-=-=- Long > Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- Long? > Long? => Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Negate(
ConvertChecked(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
}
return type: System.Nullable`1[System.Int64]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Int64]]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[E_Long,E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
method: System.Nullable`1[E_Long] op_Implicit(E_Long) in System.Nullable`1[E_Long]
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long => E_Long -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
ConvertChecked(
Negate(
ConvertChecked(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_Long
)
}
return type: E_Long
type: System.Func`3[System.Nullable`1[E_Long],E_Long,E_Long]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long? => E_Long? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
ConvertChecked(
Negate(
ConvertChecked(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[E_Long]
)
}
return type: System.Nullable`1[E_Long]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[E_Long]]
)
-=-=-=-=-=-=-=-=- ULong > ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.UInt64,System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong > ULong => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong => ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: System.UInt64
)
}
return type: System.UInt64
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.UInt64]
)
-=-=-=-=-=-=-=-=- ULong > ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong? => ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
}
return type: System.Nullable`1[System.UInt64]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64]]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[E_ULong,E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
ConvertChecked(
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
method: System.Nullable`1[E_ULong] op_Implicit(E_ULong) in System.Nullable`1[E_ULong]
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong => E_ULong -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Negate(
Convert(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Int64
)
type: System.Int64
)
type: E_ULong
)
}
return type: E_ULong
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,E_ULong]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong? => E_ULong? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Negate(
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Int64
)
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[E_ULong]
)
}
return type: System.Nullable`1[E_ULong]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[E_ULong]]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single > Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Single,System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single > Single => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
method: System.Nullable`1[System.Single] op_Implicit(Single) in System.Nullable`1[System.Single]
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? > Single => Single -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Single
)
type: System.Single
)
}
return type: System.Single
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Single]
)
-=-=-=-=-=-=-=-=- Single > Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Single? > Single? => Single? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
}
return type: System.Nullable`1[System.Single]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Single]]
)
-=-=-=-=-=-=-=-=- Double > Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Double,System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double > Double => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
method: System.Nullable`1[System.Double] op_Implicit(Double) in System.Nullable`1[System.Double]
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? > Double => Double -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Negate(
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
type: System.Double
)
type: System.Double
)
}
return type: System.Double
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Double]
)
-=-=-=-=-=-=-=-=- Double > Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Double? > Double? => Double? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Negate(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
}
return type: System.Nullable`1[System.Double]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Double]]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Decimal,System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
method: System.Nullable`1[System.Decimal] op_Implicit(System.Decimal) in System.Nullable`1[System.Decimal]
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal => Decimal -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
method: Boolean op_Explicit(System.Nullable`1[System.Boolean]) in System.Nullable`1[System.Boolean]
type: System.Boolean
)
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Decimal
)
}
return type: System.Decimal
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Decimal]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal? => Decimal? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
method: System.Decimal ToDecimal(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Decimal]
)
}
return type: System.Nullable`1[System.Decimal]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal]]
)
-=-=-=-=-=-=-=-=- String > String => String -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
method: System.String ToString(Boolean) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.String
)
}
return type: System.String
type: System.Func`3[System.String,System.String,System.String]
)
-=-=-=-=-=-=-=-=- Object > Object => Object -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Call(
<NULL>
method: System.Object CompareObjectGreater(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
}
return type: System.Object
type: System.Func`3[System.Object,System.Object,System.Object]
)
-=-=-=-=-=-=-=-=- SByte = SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte = SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Equal(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte = SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte = SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? = SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? = SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? = SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte = E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? = E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte = Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Equal(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte = Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte = Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? = Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? = Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? = Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte = E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? = E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short = Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short = Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
Equal(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short = Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short = Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? = Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? = Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? = Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? = Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short = E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? = E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort = UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort = UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Equal(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort = UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort = UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? = UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? = UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? = UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort = E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? = E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer = Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
Equal(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer = Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer = Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? = Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? = Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? = Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer = E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? = E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Equal(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger = UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? = UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger = E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? = E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long = Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long = Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
Equal(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long = Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long = Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? = Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? = Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? = Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? = Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long = E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? = E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong = ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong = ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Equal(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong = ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong = ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? = ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? = ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? = ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong = E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Equal(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? = E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Equal(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? = Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single = Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single = Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
Equal(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single = Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single = Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? = Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? = Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? = Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? = Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double = Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double = Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
Equal(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double = Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double = Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? = Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? = Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? = Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? = Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Equal(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal = Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Equal(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? = Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Equal(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Equality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String = String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Equal(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String = String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
Equal(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object = Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object = Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <> SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <> SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <> SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <> SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <> E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <> E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <> Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <> Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <> Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <> Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <> E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <> E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <> Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <> Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <> Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <> Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <> Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <> Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <> Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <> Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <> E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <> E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <> UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <> UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <> UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <> UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <> E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <> E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <> Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <> Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <> Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <> Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <> E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <> E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <> UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <> UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <> E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <> E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <> Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <> Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <> Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <> Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <> Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <> Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <> Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <> Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <> E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <> E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <> ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <> ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <> ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <> ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <> E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
NotEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <> E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
NotEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <> Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <> Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <> Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <> Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <> Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <> Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <> Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <> Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <> Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <> Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <> Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <> Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <> Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <> Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <> Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <> Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <> Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <> Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
NotEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <> Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
NotEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_Inequality(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String <> String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
NotEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String <> String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
NotEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object <> Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectNotEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object <> Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectNotEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte < SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte < SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte < SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte < SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? < SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? < SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? < SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte < E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? < E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte < Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte < Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte < Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? < Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? < Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? < Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte < E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? < E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short < Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short < Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short < Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short < Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? < Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? < Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? < Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? < Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short < E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? < E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort < UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort < UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort < UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort < UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? < UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? < UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? < UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort < E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? < E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer < Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer < Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer < Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? < Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? < Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? < Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer < E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? < E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger < UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? < UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger < E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? < E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long < Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long < Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long < Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long < Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? < Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? < Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? < Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? < Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long < E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? < E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong < ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong < ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong < ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong < ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? < ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? < ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? < ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong < E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? < E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? < Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single < Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single < Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single < Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single < Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? < Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? < Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? < Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? < Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double < Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double < Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double < Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double < Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? < Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? < Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? < Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? < Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal < Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? < Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String < String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
LessThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String < String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object < Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLess(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object < Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLess(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte <= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte <= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? <= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte <= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? <= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte <= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte <= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? <= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte <= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? <= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short <= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short <= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? <= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? <= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short <= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? <= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort <= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort <= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? <= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort <= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? <= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer <= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer <= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? <= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer <= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? <= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger <= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? <= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger <= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? <= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long <= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long <= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? <= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? <= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long <= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? <= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong <= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong <= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? <= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong <= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? <= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? <= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single <= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single <= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? <= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? <= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double <= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double <= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? <= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? <= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal <= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? <= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
LessThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_LessThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String <= String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
LessThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String <= String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
LessThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object <= Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLessEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object <= Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectLessEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte >= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte >= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte >= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? >= SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte >= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? >= E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte >= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte >= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte >= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? >= Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte >= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? >= E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short >= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short >= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short >= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short >= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? >= Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? >= Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? >= Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? >= Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short >= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? >= E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort >= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort >= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort >= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? >= UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort >= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? >= E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer >= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer >= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer >= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? >= Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer >= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? >= E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger >= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? >= UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger >= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? >= E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long >= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long >= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long >= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long >= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? >= Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? >= Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? >= Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? >= Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long >= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? >= E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong >= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong >= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong >= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? >= ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong >= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThanOrEqual(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? >= E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? >= Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThanOrEqual(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single >= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single >= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single >= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single >= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? >= Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? >= Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? >= Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? >= Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double >= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double >= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double >= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double >= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? >= Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? >= Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? >= Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? >= Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal >= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThanOrEqual(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? >= Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThanOrEqual(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThanOrEqual(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String >= String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
GreaterThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String >= String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThanOrEqual(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object >= Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreaterEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object >= Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreaterEqual(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte > SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte > SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte > SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte > SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.SByte
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.SByte,System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? > SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.SByte
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.SByte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- SByte? > SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- SByte? > SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.SByte]
)
Parameter(
y
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.SByte],System.Nullable`1[System.SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte > E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_SByte
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_SByte,System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: E_SByte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_SByte
)
type: System.SByte
)
method: System.Nullable`1[System.SByte] op_Implicit(SByte) in System.Nullable`1[System.SByte]
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],E_SByte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_SByte? > E_SByte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Parameter(
y
type: System.Nullable`1[E_SByte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.SByte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_SByte],System.Nullable`1[E_SByte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte > Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte > Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte > Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Byte
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Byte,System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? > Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Byte
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Byte
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Byte? > Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- Byte? > Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Byte]
)
Parameter(
y
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Byte],System.Nullable`1[System.Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte > E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Byte
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Byte,System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: E_Byte
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Byte
)
type: System.Byte
)
method: System.Nullable`1[System.Byte] op_Implicit(Byte) in System.Nullable`1[System.Byte]
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],E_Byte,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Byte? > E_Byte? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Parameter(
y
type: System.Nullable`1[E_Byte]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Byte]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Byte],System.Nullable`1[E_Byte],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short > Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short > Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short > Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short > Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int16
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int16,System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? > Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? > Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Int16
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Int16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Int16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Short? > Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Boolean]
)
-=-=-=-=-=-=-=-=- Short? > Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int16]
)
Parameter(
y
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int16],System.Nullable`1[System.Int16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short > E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Short
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Short,System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: E_Short
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Short
)
type: System.Int16
)
method: System.Nullable`1[System.Int16] op_Implicit(Int16) in System.Nullable`1[System.Int16]
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],E_Short,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Short? > E_Short? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Parameter(
y
type: System.Nullable`1[E_Short]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Short]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Short],System.Nullable`1[E_Short],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort > UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort > UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort > UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort > UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt16
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt16,System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? > UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.UInt16
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.UInt16
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.UInt16,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UShort? > UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Boolean]
)
-=-=-=-=-=-=-=-=- UShort? > UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt16]
)
Parameter(
y
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt16],System.Nullable`1[System.UInt16],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort > E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UShort
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UShort,System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: E_UShort
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UShort
)
type: System.UInt16
)
method: System.Nullable`1[System.UInt16] op_Implicit(UInt16) in System.Nullable`1[System.UInt16]
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],E_UShort,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UShort? > E_UShort? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Parameter(
y
type: System.Nullable`1[E_UShort]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UShort]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt16]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UShort],System.Nullable`1[E_UShort],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer > Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer > Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer > Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int32
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int32,System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? > Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Int32
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Int32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Int32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Integer? > Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Boolean]
)
-=-=-=-=-=-=-=-=- Integer? > Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int32]
)
Parameter(
y
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int32],System.Nullable`1[System.Int32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer > E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Integer
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Integer,System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: E_Integer
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Integer
)
type: System.Int32
)
method: System.Nullable`1[System.Int32] op_Implicit(Int32) in System.Nullable`1[System.Int32]
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],E_Integer,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Integer? > E_Integer? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Parameter(
y
type: System.Nullable`1[E_Integer]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Integer]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Integer],System.Nullable`1[E_Integer],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger > UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt32
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt32,System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.UInt32
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.UInt32
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.UInt32,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Boolean]
)
-=-=-=-=-=-=-=-=- UInteger? > UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt32]
)
Parameter(
y
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt32],System.Nullable`1[System.UInt32],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger > E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_UInteger
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_UInteger,System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: E_UInteger
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_UInteger
)
type: System.UInt32
)
method: System.Nullable`1[System.UInt32] op_Implicit(UInt32) in System.Nullable`1[System.UInt32]
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],E_UInteger,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_UInteger? > E_UInteger? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_UInteger]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_UInteger],System.Nullable`1[E_UInteger],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long > Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long > Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long > Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long > Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Int64
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Int64,System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? > Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? > Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Int64
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Int64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Int64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Long? > Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Boolean]
)
-=-=-=-=-=-=-=-=- Long? > Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Int64]
)
Parameter(
y
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Int64],System.Nullable`1[System.Int64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long > E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_Long
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_Long,System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: E_Long
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_Long
)
type: System.Int64
)
method: System.Nullable`1[System.Int64] op_Implicit(Int64) in System.Nullable`1[System.Int64]
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],E_Long,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_Long? > E_Long? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Parameter(
y
type: System.Nullable`1[E_Long]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_Long]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_Long],System.Nullable`1[E_Long],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong > ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong > ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong > ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong > ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.UInt64
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.UInt64,System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? > ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.UInt64
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.UInt64
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.UInt64,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- ULong? > ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Boolean]
)
-=-=-=-=-=-=-=-=- ULong? > ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.UInt64]
)
Parameter(
y
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.UInt64],System.Nullable`1[System.UInt64],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong > E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: E_ULong
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThan(
ConvertChecked(
ConvertChecked(
Parameter(
x
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[E_ULong,System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: E_ULong
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
ConvertChecked(
Parameter(
y
type: E_ULong
)
type: System.UInt64
)
method: System.Nullable`1[System.UInt64] op_Implicit(UInt64) in System.Nullable`1[System.UInt64]
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],E_ULong,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
Convert(
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Boolean]
)
-=-=-=-=-=-=-=-=- E_ULong? > E_ULong? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Parameter(
y
type: System.Nullable`1[E_ULong]
)
body {
GreaterThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[E_ULong]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.UInt64]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[E_ULong],System.Nullable`1[E_ULong],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Boolean
)
type: System.Int32
)
ConvertChecked(
Parameter(
y
type: System.Boolean
)
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Boolean
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Convert(
Parameter(
x
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Boolean,System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Boolean
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Convert(
Parameter(
y
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Boolean,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
Convert(
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Boolean]
)
-=-=-=-=-=-=-=-=- Boolean? > Boolean? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
body {
LessThan(
ConvertChecked(
Parameter(
x
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
ConvertChecked(
Parameter(
y
type: System.Nullable`1[System.Boolean]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Int32]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single > Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single > Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Single
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single > Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single > Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Single
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThan(
Convert(
Parameter(
x
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Single,System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? > Single => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? > Single => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Single
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Convert(
Parameter(
y
type: System.Single
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Single,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Single? > Single? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Boolean]
)
-=-=-=-=-=-=-=-=- Single? > Single? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Single]
)
Parameter(
y
type: System.Nullable`1[System.Single]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Single],System.Nullable`1[System.Single],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double > Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double > Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Double
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double > Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double > Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Double
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThan(
Convert(
Parameter(
x
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Double,System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? > Double => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? > Double => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Double
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Convert(
Parameter(
y
type: System.Double
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Double,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Double? > Double? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Boolean]
)
-=-=-=-=-=-=-=-=- Double? > Double? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Double]
)
Parameter(
y
type: System.Nullable`1[System.Double]
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Double],System.Nullable`1[System.Double],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Decimal
)
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal > Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Decimal
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThan(
Convert(
Parameter(
x
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Decimal,System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Decimal
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Convert(
Parameter(
y
type: System.Decimal
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Decimal,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal? => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
Convert(
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
Lifted
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Boolean]
)
-=-=-=-=-=-=-=-=- Decimal? > Decimal? => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
body {
GreaterThan(
Parameter(
x
type: System.Nullable`1[System.Decimal]
)
Parameter(
y
type: System.Nullable`1[System.Decimal]
)
Lifted
LiftedToNull
method: Boolean op_GreaterThan(System.Decimal, System.Decimal) in System.Decimal
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Nullable`1[System.Decimal],System.Nullable`1[System.Decimal],System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- String > String => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
GreaterThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.String,System.String,System.Boolean]
)
-=-=-=-=-=-=-=-=- String > String => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
body {
Convert(
GreaterThan(
Call(
<NULL>
method: Int32 CompareString(System.String, System.String, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.String
)
Parameter(
y
type: System.String
)
Constant(
False
type: System.Boolean
)
)
type: System.Int32
)
Constant(
0
type: System.Int32
)
type: System.Boolean
)
Lifted
LiftedToNull
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.String,System.String,System.Nullable`1[System.Boolean]]
)
-=-=-=-=-=-=-=-=- Object > Object => Boolean -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreater(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Boolean
)
}
return type: System.Boolean
type: System.Func`3[System.Object,System.Object,System.Boolean]
)
-=-=-=-=-=-=-=-=- Object > Object => Boolean? -=-=-=-=-=-=-=-=-
Lambda(
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
body {
Convert(
Call(
<NULL>
method: System.Object CompareObjectGreater(System.Object, System.Object, Boolean) in Microsoft.VisualBasic.CompilerServices.Operators (
Parameter(
x
type: System.Object
)
Parameter(
y
type: System.Object
)
Constant(
False
type: System.Boolean
)
)
type: System.Object
)
Lifted
LiftedToNull
method: Boolean ToBoolean(System.Object) in Microsoft.VisualBasic.CompilerServices.Conversions
type: System.Nullable`1[System.Boolean]
)
}
return type: System.Nullable`1[System.Boolean]
type: System.Func`3[System.Object,System.Object,System.Nullable`1[System.Boolean]]
) | -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Test/Perf/tests/helloworld/hello_world.csx | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#r "../../Perf.Utilities/Roslyn.Test.Performance.Utilities.dll"
using System.IO;
using Roslyn.Test.Performance.Utilities;
using static Roslyn.Test.Performance.Utilities.TestUtilities;
class HelloWorldTest : PerfTest
{
private string _pathToHelloWorld;
private string _pathToOutput;
private ILogger _logger;
public HelloWorldTest(): base()
{
_logger = new ConsoleAndFileLogger();
}
public override void Setup()
{
_pathToHelloWorld = Path.Combine(MyWorkingDirectory, "HelloWorld.cs");
_pathToOutput = Path.Combine(TempDirectory, "HelloWorld.exe");
}
public override void Test()
{
ShellOutVital(Path.Combine(MyBinaries(), "Exes", "csc", "net46", @"csc.exe"), _pathToHelloWorld + " /out:" + _pathToOutput, MyWorkingDirectory);
_logger.Flush();
}
public override int Iterations => 3;
public override string Name => "hello world";
public override string MeasuredProc => "csc";
public override bool ProvidesScenarios => false;
public override string[] GetScenarios()
{
throw new System.NotImplementedException();
}
}
TestThisPlease(new HelloWorldTest());
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#r "../../Perf.Utilities/Roslyn.Test.Performance.Utilities.dll"
using System.IO;
using Roslyn.Test.Performance.Utilities;
using static Roslyn.Test.Performance.Utilities.TestUtilities;
class HelloWorldTest : PerfTest
{
private string _pathToHelloWorld;
private string _pathToOutput;
private ILogger _logger;
public HelloWorldTest(): base()
{
_logger = new ConsoleAndFileLogger();
}
public override void Setup()
{
_pathToHelloWorld = Path.Combine(MyWorkingDirectory, "HelloWorld.cs");
_pathToOutput = Path.Combine(TempDirectory, "HelloWorld.exe");
}
public override void Test()
{
ShellOutVital(Path.Combine(MyBinaries(), "Exes", "csc", "net46", @"csc.exe"), _pathToHelloWorld + " /out:" + _pathToOutput, MyWorkingDirectory);
_logger.Flush();
}
public override int Iterations => 3;
public override string Name => "hello world";
public override string MeasuredProc => "csc";
public override bool ProvidesScenarios => false;
public override string[] GetScenarios()
{
throw new System.NotImplementedException();
}
}
TestThisPlease(new HelloWorldTest());
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/CSharp/Test/Emit/PDB/CheckSumTest.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Text;
using Microsoft.CodeAnalysis.CSharp.Test.Utilities;
using Microsoft.CodeAnalysis.Emit;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.CSharp.UnitTests.PDB
{
public class CheckSumTest : CSharpTestBase
{
private static CSharpCompilation CreateCompilationWithChecksums(string source, string filePath, string baseDirectory)
{
return CSharpCompilation.Create(
GetUniqueName(),
new[] { Parse(source, filePath) },
new[] { MscorlibRef },
TestOptions.DebugDll.WithSourceReferenceResolver(new SourceFileResolver(ImmutableArray.Create<string>(), baseDirectory)));
}
[Fact]
public void ChecksumAlgorithms()
{
var source1 = "public class C1 { public C1() { } }";
var source256 = "public class C256 { public C256() { } }";
var tree1 = SyntaxFactory.ParseSyntaxTree(StringText.From(source1, Encoding.UTF8, SourceHashAlgorithm.Sha1), path: "sha1.cs");
var tree256 = SyntaxFactory.ParseSyntaxTree(StringText.From(source256, Encoding.UTF8, SourceHashAlgorithm.Sha256), path: "sha256.cs");
var compilation = CreateCompilation(new[] { tree1, tree256 });
compilation.VerifyPdb(@"
<symbols>
<files>
<file id=""1"" name=""sha1.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""8E-37-F3-94-ED-18-24-3F-35-EC-1B-70-25-29-42-1C-B0-84-9B-C8"" />
<file id=""2"" name=""sha256.cs"" language=""C#"" checksumAlgorithm=""SHA256"" checksum=""83-31-5B-52-08-2D-68-54-14-88-0E-E3-3A-5E-B7-83-86-53-83-B4-5A-3F-36-9E-5F-1B-60-33-27-0A-8A-EC"" />
</files>
<methods>
<method containingType=""C1"" name="".ctor"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""1"" startColumn=""19"" endLine=""1"" endColumn=""30"" document=""1"" />
<entry offset=""0x6"" startLine=""1"" startColumn=""33"" endLine=""1"" endColumn=""34"" document=""1"" />
</sequencePoints>
</method>
<method containingType=""C256"" name="".ctor"">
<customDebugInfo>
<forward declaringType=""C1"" methodName="".ctor"" />
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""1"" startColumn=""21"" endLine=""1"" endColumn=""34"" document=""2"" />
<entry offset=""0x6"" startLine=""1"" startColumn=""37"" endLine=""1"" endColumn=""38"" document=""2"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[Fact]
public void CheckSumPragmaClashesSameTree()
{
var text =
@"
class C
{
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// same
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// different case in Hex numerics, but otherwise same
#pragma checksum ""bogus.cs"" ""{406ea660-64cf-4C82-B6F0-42D48172A799}"" ""AB007f1d23d9""
// different case in path, so not a clash
#pragma checksum ""bogUs.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A788}"" ""ab007f1d23d9""
// whitespace in path, so not a clash
#pragma checksum ""bogUs.cs "" ""{406EA660-64CF-4C82-B6F0-42D48172A788}"" ""ab007f1d23d9""
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// and now a clash in Guid
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A798}"" ""ab007f1d23d9""
// and now a clash in CheckSum
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d8""
static void Main(string[] args)
{
}
}
";
CompileAndVerify(text, options: TestOptions.DebugExe).
VerifyDiagnostics(
// (20,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A798}" "ab007f1d23d9"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A798}"" ""ab007f1d23d9""").WithArguments("bogus1.cs"),
// (22,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23d8"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d8""").WithArguments("bogus1.cs"));
}
[Fact]
public void CheckSumPragmaClashesDifferentLength()
{
var text =
@"
class C
{
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" """"
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// odd length, parsing warning, ignored by emit.
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d""
// bad Guid, parsing warning, ignored by emit.
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A79}"" ""ab007f1d23d9""
static void Main(string[] args)
{
}
}
";
CompileAndVerify(text).
VerifyDiagnostics(
// (11,71): warning CS1695: Invalid #pragma checksum syntax; should be #pragma checksum "filename" "{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}" "XXXX..."
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23d"
Diagnostic(ErrorCode.WRN_IllegalPPChecksum, @"""ab007f1d23d"""),
// (14,30): warning CS1695: Invalid #pragma checksum syntax; should be #pragma checksum "filename" "{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}" "XXXX..."
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A79}" "ab007f1d23d9"
Diagnostic(ErrorCode.WRN_IllegalPPChecksum, @"""{406EA660-64CF-4C82-B6F0-42D48172A79}"""),
// (6,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""").WithArguments("bogus1.cs"),
// (7,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" ""
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" """"").WithArguments("bogus1.cs"));
}
[Fact]
public void CheckSumPragmaClashesDifferentTrees()
{
var text1 =
@"
class C
{
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// same
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
static void Main(string[] args)
{
}
}
";
var text2 =
@"
class C1
{
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// same
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// different
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""
}
";
CompileAndVerify(new string[] { text1, text2 }).
VerifyDiagnostics(
// (11,1): warning CS1697: Different checksum values given for 'bogus.cs'
// #pragma checksum "bogus.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""").WithArguments("bogus.cs"));
}
[Fact]
[WorkItem(50611, "https://github.com/dotnet/roslyn/issues/50611")]
public void TestPartialClassFieldInitializers()
{
var text1 = WithWindowsLineBreaks(@"
public partial class C
{
int x = 1;
}
#pragma checksum ""UNUSED.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
#pragma checksum ""USED1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
");
var text2 = WithWindowsLineBreaks(@"
public partial class C
{
#pragma checksum ""USED2.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
int y = 1;
static void Main()
{
#line 112 ""USED1.cs""
C c = new C();
#line 112 ""USED2.cs""
C c1 = new C();
#line default
}
}
");
var compilation = CreateCompilation(new[] { Parse(text1, "a.cs"), Parse(text2, "b.cs") });
compilation.VerifyPdb("C.Main", @"
<symbols>
<files>
<file id=""1"" name=""a.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""F0-C4-23-63-A5-89-B9-29-AF-94-07-85-2F-3A-40-D3-70-14-8F-9B"" />
<file id=""2"" name=""b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""C0-51-F0-6F-D3-ED-44-A2-11-4D-03-70-89-20-A6-05-11-62-14-BE"" />
<file id=""3"" name=""USED1.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
<file id=""4"" name=""USED2.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
<file id=""5"" name=""UNUSED.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
</files>
<methods>
<method containingType=""C"" name=""Main"">
<sequencePoints>
<entry offset=""0x0"" startLine=""112"" startColumn=""9"" endLine=""112"" endColumn=""23"" document=""3"" />
<entry offset=""0x6"" startLine=""112"" startColumn=""9"" endLine=""112"" endColumn=""24"" document=""4"" />
<entry offset=""0xc"" startLine=""19"" startColumn=""5"" endLine=""19"" endColumn=""6"" document=""2"" />
</sequencePoints>
</method>
</methods>
</symbols>", format: DebugInformationFormat.PortablePdb);
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_Tree()
{
var source = @"
class C
{
void M()
{
}
}
";
var comp = CreateCompilationWithChecksums(source, "b.cs", @"b:\base");
// Verify the value of name attribute in file element.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""b:\base\b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""05-25-26-AE-53-A0-54-46-AC-A6-1D-8A-3B-1E-3F-C3-43-39-FB-59"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""5"" startColumn=""5"" endLine=""5"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""6"" startColumn=""5"" endLine=""6"" endColumn=""6"" document=""1"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[ConditionalFact(typeof(WindowsOnly))]
[WorkItem(50611, "https://github.com/dotnet/roslyn/issues/50611")]
public void NoResolver()
{
var comp = CSharpCompilation.Create(
GetUniqueName(),
new[] { Parse(@"
#pragma checksum ""a\..\a.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d5""
#line 10 ""a\..\a.cs""
class C { void M() { } }
", @"C:\a\..\b.cs") },
new[] { MscorlibRef },
TestOptions.DebugDll.WithSourceReferenceResolver(null));
// Verify the value of name attribute in file element.
comp.VerifyPdb(@"
<symbols>
<files>
<file id=""1"" name=""C:\a\..\b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""36-39-3C-83-56-97-F2-F0-60-95-A4-A0-32-C6-32-C7-B2-4B-16-92"" />
<file id=""2"" name=""a\..\a.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D5"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<sequencePoints>
<entry offset=""0x0"" startLine=""10"" startColumn=""20"" endLine=""10"" endColumn=""21"" document=""2"" />
<entry offset=""0x1"" startLine=""10"" startColumn=""22"" endLine=""10"" endColumn=""23"" document=""2"" />
</sequencePoints>
</method>
</methods>
</symbols>", format: DebugInformationFormat.PortablePdb);
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_LineDirective()
{
var source = @"
class C
{
void M()
{
M();
#line 1 ""line.cs""
M();
#line 2 ""./line.cs""
M();
#line 3 "".\line.cs""
M();
#line 4 ""q\..\line.cs""
M();
#line 5 ""q:\absolute\file.cs""
M();
}
}
";
var comp = CreateCompilationWithChecksums(source, "b.cs", @"b:\base");
// Verify the fact that there's a single file element for "line.cs" and it has an absolute path.
// Verify the fact that the path that was already absolute wasn't affected by the base directory.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""b:\base\b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""B6-C3-C8-D1-2D-F4-BD-FA-F7-25-AC-F8-17-E1-83-BE-CC-9B-40-84"" />
<file id=""2"" name=""b:\base\line.cs"" language=""C#"" />
<file id=""3"" name=""q:\absolute\file.cs"" language=""C#"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""5"" startColumn=""5"" endLine=""5"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""6"" startColumn=""9"" endLine=""6"" endColumn=""13"" document=""1"" />
<entry offset=""0x8"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""2"" />
<entry offset=""0xf"" startLine=""2"" startColumn=""9"" endLine=""2"" endColumn=""13"" document=""2"" />
<entry offset=""0x16"" startLine=""3"" startColumn=""9"" endLine=""3"" endColumn=""13"" document=""2"" />
<entry offset=""0x1d"" startLine=""4"" startColumn=""9"" endLine=""4"" endColumn=""13"" document=""2"" />
<entry offset=""0x24"" startLine=""5"" startColumn=""9"" endLine=""5"" endColumn=""13"" document=""3"" />
<entry offset=""0x2b"" startLine=""6"" startColumn=""5"" endLine=""6"" endColumn=""6"" document=""3"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_ChecksumDirective()
{
var source = @"
class C
{
#pragma checksum ""a.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d5""
#pragma checksum ""./b.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d6""
#pragma checksum "".\c.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d7""
#pragma checksum ""q\..\d.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d8""
#pragma checksum ""b:\base\e.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
void M()
{
M();
#line 1 ""a.cs""
M();
#line 1 ""b.cs""
M();
#line 1 ""c.cs""
M();
#line 1 ""d.cs""
M();
#line 1 ""e.cs""
M();
}
}
";
var comp = CreateCompilationWithChecksums(source, "file.cs", @"b:\base");
comp.VerifyDiagnostics();
// Verify the fact that all pragmas are referenced, even though the paths differ before normalization.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""b:\base\file.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""2B-34-42-7D-32-E5-0A-24-3D-01-43-BF-42-FB-38-57-62-60-8B-14"" />
<file id=""2"" name=""b:\base\a.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D5"" />
<file id=""3"" name=""b:\base\b.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D6"" />
<file id=""4"" name=""b:\base\c.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D7"" />
<file id=""5"" name=""b:\base\d.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D8"" />
<file id=""6"" name=""b:\base\e.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""10"" startColumn=""5"" endLine=""10"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""11"" startColumn=""9"" endLine=""11"" endColumn=""13"" document=""1"" />
<entry offset=""0x8"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""2"" />
<entry offset=""0xf"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""3"" />
<entry offset=""0x16"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""4"" />
<entry offset=""0x1d"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""5"" />
<entry offset=""0x24"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""6"" />
<entry offset=""0x2b"" startLine=""2"" startColumn=""5"" endLine=""2"" endColumn=""6"" document=""6"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_NoBaseDirectory()
{
var source = @"
class C
{
#pragma checksum ""a.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d5""
void M()
{
M();
#line 1 ""a.cs""
M();
#line 1 ""./a.cs""
M();
#line 1 ""b.cs""
M();
}
}
";
var comp = CreateCompilationWithChecksums(source, "file.cs", null);
comp.VerifyDiagnostics();
// Verify nothing blew up.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""file.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""9B-81-4F-A7-E1-1F-D2-45-8B-00-F3-82-65-DF-E4-BF-A1-3A-3B-29"" />
<file id=""2"" name=""a.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D5"" />
<file id=""3"" name=""./a.cs"" language=""C#"" />
<file id=""4"" name=""b.cs"" language=""C#"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""6"" startColumn=""5"" endLine=""6"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""7"" startColumn=""9"" endLine=""7"" endColumn=""13"" document=""1"" />
<entry offset=""0x8"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""2"" />
<entry offset=""0xf"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""3"" />
<entry offset=""0x16"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""4"" />
<entry offset=""0x1d"" startLine=""2"" startColumn=""5"" endLine=""2"" endColumn=""6"" document=""4"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Text;
using Microsoft.CodeAnalysis.CSharp.Test.Utilities;
using Microsoft.CodeAnalysis.Emit;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.CSharp.UnitTests.PDB
{
public class CheckSumTest : CSharpTestBase
{
private static CSharpCompilation CreateCompilationWithChecksums(string source, string filePath, string baseDirectory)
{
return CSharpCompilation.Create(
GetUniqueName(),
new[] { Parse(source, filePath) },
new[] { MscorlibRef },
TestOptions.DebugDll.WithSourceReferenceResolver(new SourceFileResolver(ImmutableArray.Create<string>(), baseDirectory)));
}
[Fact]
public void ChecksumAlgorithms()
{
var source1 = "public class C1 { public C1() { } }";
var source256 = "public class C256 { public C256() { } }";
var tree1 = SyntaxFactory.ParseSyntaxTree(StringText.From(source1, Encoding.UTF8, SourceHashAlgorithm.Sha1), path: "sha1.cs");
var tree256 = SyntaxFactory.ParseSyntaxTree(StringText.From(source256, Encoding.UTF8, SourceHashAlgorithm.Sha256), path: "sha256.cs");
var compilation = CreateCompilation(new[] { tree1, tree256 });
compilation.VerifyPdb(@"
<symbols>
<files>
<file id=""1"" name=""sha1.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""8E-37-F3-94-ED-18-24-3F-35-EC-1B-70-25-29-42-1C-B0-84-9B-C8"" />
<file id=""2"" name=""sha256.cs"" language=""C#"" checksumAlgorithm=""SHA256"" checksum=""83-31-5B-52-08-2D-68-54-14-88-0E-E3-3A-5E-B7-83-86-53-83-B4-5A-3F-36-9E-5F-1B-60-33-27-0A-8A-EC"" />
</files>
<methods>
<method containingType=""C1"" name="".ctor"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""1"" startColumn=""19"" endLine=""1"" endColumn=""30"" document=""1"" />
<entry offset=""0x6"" startLine=""1"" startColumn=""33"" endLine=""1"" endColumn=""34"" document=""1"" />
</sequencePoints>
</method>
<method containingType=""C256"" name="".ctor"">
<customDebugInfo>
<forward declaringType=""C1"" methodName="".ctor"" />
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""1"" startColumn=""21"" endLine=""1"" endColumn=""34"" document=""2"" />
<entry offset=""0x6"" startLine=""1"" startColumn=""37"" endLine=""1"" endColumn=""38"" document=""2"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[Fact]
public void CheckSumPragmaClashesSameTree()
{
var text =
@"
class C
{
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// same
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// different case in Hex numerics, but otherwise same
#pragma checksum ""bogus.cs"" ""{406ea660-64cf-4C82-B6F0-42D48172A799}"" ""AB007f1d23d9""
// different case in path, so not a clash
#pragma checksum ""bogUs.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A788}"" ""ab007f1d23d9""
// whitespace in path, so not a clash
#pragma checksum ""bogUs.cs "" ""{406EA660-64CF-4C82-B6F0-42D48172A788}"" ""ab007f1d23d9""
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// and now a clash in Guid
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A798}"" ""ab007f1d23d9""
// and now a clash in CheckSum
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d8""
static void Main(string[] args)
{
}
}
";
CompileAndVerify(text, options: TestOptions.DebugExe).
VerifyDiagnostics(
// (20,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A798}" "ab007f1d23d9"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A798}"" ""ab007f1d23d9""").WithArguments("bogus1.cs"),
// (22,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23d8"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d8""").WithArguments("bogus1.cs"));
}
[Fact]
public void CheckSumPragmaClashesDifferentLength()
{
var text =
@"
class C
{
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" """"
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// odd length, parsing warning, ignored by emit.
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d""
// bad Guid, parsing warning, ignored by emit.
#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A79}"" ""ab007f1d23d9""
static void Main(string[] args)
{
}
}
";
CompileAndVerify(text).
VerifyDiagnostics(
// (11,71): warning CS1695: Invalid #pragma checksum syntax; should be #pragma checksum "filename" "{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}" "XXXX..."
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23d"
Diagnostic(ErrorCode.WRN_IllegalPPChecksum, @"""ab007f1d23d"""),
// (14,30): warning CS1695: Invalid #pragma checksum syntax; should be #pragma checksum "filename" "{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}" "XXXX..."
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A79}" "ab007f1d23d9"
Diagnostic(ErrorCode.WRN_IllegalPPChecksum, @"""{406EA660-64CF-4C82-B6F0-42D48172A79}"""),
// (6,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""").WithArguments("bogus1.cs"),
// (7,1): warning CS1697: Different checksum values given for 'bogus1.cs'
// #pragma checksum "bogus1.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" ""
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" """"").WithArguments("bogus1.cs"));
}
[Fact]
public void CheckSumPragmaClashesDifferentTrees()
{
var text1 =
@"
class C
{
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// same
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
static void Main(string[] args)
{
}
}
";
var text2 =
@"
class C1
{
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// same
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
// different
#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""
}
";
CompileAndVerify(new string[] { text1, text2 }).
VerifyDiagnostics(
// (11,1): warning CS1697: Different checksum values given for 'bogus.cs'
// #pragma checksum "bogus.cs" "{406EA660-64CF-4C82-B6F0-42D48172A799}" "ab007f1d23"
Diagnostic(ErrorCode.WRN_ConflictingChecksum, @"#pragma checksum ""bogus.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23""").WithArguments("bogus.cs"));
}
[Fact]
[WorkItem(50611, "https://github.com/dotnet/roslyn/issues/50611")]
public void TestPartialClassFieldInitializers()
{
var text1 = WithWindowsLineBreaks(@"
public partial class C
{
int x = 1;
}
#pragma checksum ""UNUSED.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
#pragma checksum ""USED1.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
");
var text2 = WithWindowsLineBreaks(@"
public partial class C
{
#pragma checksum ""USED2.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
int y = 1;
static void Main()
{
#line 112 ""USED1.cs""
C c = new C();
#line 112 ""USED2.cs""
C c1 = new C();
#line default
}
}
");
var compilation = CreateCompilation(new[] { Parse(text1, "a.cs"), Parse(text2, "b.cs") });
compilation.VerifyPdb("C.Main", @"
<symbols>
<files>
<file id=""1"" name=""a.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""F0-C4-23-63-A5-89-B9-29-AF-94-07-85-2F-3A-40-D3-70-14-8F-9B"" />
<file id=""2"" name=""b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""C0-51-F0-6F-D3-ED-44-A2-11-4D-03-70-89-20-A6-05-11-62-14-BE"" />
<file id=""3"" name=""USED1.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
<file id=""4"" name=""USED2.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
<file id=""5"" name=""UNUSED.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
</files>
<methods>
<method containingType=""C"" name=""Main"">
<sequencePoints>
<entry offset=""0x0"" startLine=""112"" startColumn=""9"" endLine=""112"" endColumn=""23"" document=""3"" />
<entry offset=""0x6"" startLine=""112"" startColumn=""9"" endLine=""112"" endColumn=""24"" document=""4"" />
<entry offset=""0xc"" startLine=""19"" startColumn=""5"" endLine=""19"" endColumn=""6"" document=""2"" />
</sequencePoints>
</method>
</methods>
</symbols>", format: DebugInformationFormat.PortablePdb);
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_Tree()
{
var source = @"
class C
{
void M()
{
}
}
";
var comp = CreateCompilationWithChecksums(source, "b.cs", @"b:\base");
// Verify the value of name attribute in file element.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""b:\base\b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""05-25-26-AE-53-A0-54-46-AC-A6-1D-8A-3B-1E-3F-C3-43-39-FB-59"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""5"" startColumn=""5"" endLine=""5"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""6"" startColumn=""5"" endLine=""6"" endColumn=""6"" document=""1"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[ConditionalFact(typeof(WindowsOnly))]
[WorkItem(50611, "https://github.com/dotnet/roslyn/issues/50611")]
public void NoResolver()
{
var comp = CSharpCompilation.Create(
GetUniqueName(),
new[] { Parse(@"
#pragma checksum ""a\..\a.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d5""
#line 10 ""a\..\a.cs""
class C { void M() { } }
", @"C:\a\..\b.cs") },
new[] { MscorlibRef },
TestOptions.DebugDll.WithSourceReferenceResolver(null));
// Verify the value of name attribute in file element.
comp.VerifyPdb(@"
<symbols>
<files>
<file id=""1"" name=""C:\a\..\b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""36-39-3C-83-56-97-F2-F0-60-95-A4-A0-32-C6-32-C7-B2-4B-16-92"" />
<file id=""2"" name=""a\..\a.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D5"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<sequencePoints>
<entry offset=""0x0"" startLine=""10"" startColumn=""20"" endLine=""10"" endColumn=""21"" document=""2"" />
<entry offset=""0x1"" startLine=""10"" startColumn=""22"" endLine=""10"" endColumn=""23"" document=""2"" />
</sequencePoints>
</method>
</methods>
</symbols>", format: DebugInformationFormat.PortablePdb);
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_LineDirective()
{
var source = @"
class C
{
void M()
{
M();
#line 1 ""line.cs""
M();
#line 2 ""./line.cs""
M();
#line 3 "".\line.cs""
M();
#line 4 ""q\..\line.cs""
M();
#line 5 ""q:\absolute\file.cs""
M();
}
}
";
var comp = CreateCompilationWithChecksums(source, "b.cs", @"b:\base");
// Verify the fact that there's a single file element for "line.cs" and it has an absolute path.
// Verify the fact that the path that was already absolute wasn't affected by the base directory.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""b:\base\b.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""B6-C3-C8-D1-2D-F4-BD-FA-F7-25-AC-F8-17-E1-83-BE-CC-9B-40-84"" />
<file id=""2"" name=""b:\base\line.cs"" language=""C#"" />
<file id=""3"" name=""q:\absolute\file.cs"" language=""C#"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""5"" startColumn=""5"" endLine=""5"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""6"" startColumn=""9"" endLine=""6"" endColumn=""13"" document=""1"" />
<entry offset=""0x8"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""2"" />
<entry offset=""0xf"" startLine=""2"" startColumn=""9"" endLine=""2"" endColumn=""13"" document=""2"" />
<entry offset=""0x16"" startLine=""3"" startColumn=""9"" endLine=""3"" endColumn=""13"" document=""2"" />
<entry offset=""0x1d"" startLine=""4"" startColumn=""9"" endLine=""4"" endColumn=""13"" document=""2"" />
<entry offset=""0x24"" startLine=""5"" startColumn=""9"" endLine=""5"" endColumn=""13"" document=""3"" />
<entry offset=""0x2b"" startLine=""6"" startColumn=""5"" endLine=""6"" endColumn=""6"" document=""3"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_ChecksumDirective()
{
var source = @"
class C
{
#pragma checksum ""a.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d5""
#pragma checksum ""./b.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d6""
#pragma checksum "".\c.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d7""
#pragma checksum ""q\..\d.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d8""
#pragma checksum ""b:\base\e.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d9""
void M()
{
M();
#line 1 ""a.cs""
M();
#line 1 ""b.cs""
M();
#line 1 ""c.cs""
M();
#line 1 ""d.cs""
M();
#line 1 ""e.cs""
M();
}
}
";
var comp = CreateCompilationWithChecksums(source, "file.cs", @"b:\base");
comp.VerifyDiagnostics();
// Verify the fact that all pragmas are referenced, even though the paths differ before normalization.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""b:\base\file.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""2B-34-42-7D-32-E5-0A-24-3D-01-43-BF-42-FB-38-57-62-60-8B-14"" />
<file id=""2"" name=""b:\base\a.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D5"" />
<file id=""3"" name=""b:\base\b.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D6"" />
<file id=""4"" name=""b:\base\c.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D7"" />
<file id=""5"" name=""b:\base\d.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D8"" />
<file id=""6"" name=""b:\base\e.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D9"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""10"" startColumn=""5"" endLine=""10"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""11"" startColumn=""9"" endLine=""11"" endColumn=""13"" document=""1"" />
<entry offset=""0x8"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""2"" />
<entry offset=""0xf"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""3"" />
<entry offset=""0x16"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""4"" />
<entry offset=""0x1d"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""5"" />
<entry offset=""0x24"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""6"" />
<entry offset=""0x2b"" startLine=""2"" startColumn=""5"" endLine=""2"" endColumn=""6"" document=""6"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
[WorkItem(729235, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/729235")]
[ConditionalFact(typeof(WindowsOnly))]
public void NormalizedPath_NoBaseDirectory()
{
var source = @"
class C
{
#pragma checksum ""a.cs"" ""{406EA660-64CF-4C82-B6F0-42D48172A799}"" ""ab007f1d23d5""
void M()
{
M();
#line 1 ""a.cs""
M();
#line 1 ""./a.cs""
M();
#line 1 ""b.cs""
M();
}
}
";
var comp = CreateCompilationWithChecksums(source, "file.cs", null);
comp.VerifyDiagnostics();
// Verify nothing blew up.
comp.VerifyPdb("C.M", @"
<symbols>
<files>
<file id=""1"" name=""file.cs"" language=""C#"" checksumAlgorithm=""SHA1"" checksum=""9B-81-4F-A7-E1-1F-D2-45-8B-00-F3-82-65-DF-E4-BF-A1-3A-3B-29"" />
<file id=""2"" name=""a.cs"" language=""C#"" checksumAlgorithm=""406ea660-64cf-4c82-b6f0-42d48172a799"" checksum=""AB-00-7F-1D-23-D5"" />
<file id=""3"" name=""./a.cs"" language=""C#"" />
<file id=""4"" name=""b.cs"" language=""C#"" />
</files>
<methods>
<method containingType=""C"" name=""M"">
<customDebugInfo>
<using>
<namespace usingCount=""0"" />
</using>
</customDebugInfo>
<sequencePoints>
<entry offset=""0x0"" startLine=""6"" startColumn=""5"" endLine=""6"" endColumn=""6"" document=""1"" />
<entry offset=""0x1"" startLine=""7"" startColumn=""9"" endLine=""7"" endColumn=""13"" document=""1"" />
<entry offset=""0x8"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""2"" />
<entry offset=""0xf"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""3"" />
<entry offset=""0x16"" startLine=""1"" startColumn=""9"" endLine=""1"" endColumn=""13"" document=""4"" />
<entry offset=""0x1d"" startLine=""2"" startColumn=""5"" endLine=""2"" endColumn=""6"" document=""4"" />
</sequencePoints>
</method>
</methods>
</symbols>");
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/CSharpTest/Diagnostics/AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.Editor.UnitTests;
using Microsoft.CodeAnalysis.Editor.UnitTests.CodeActions;
using Microsoft.CodeAnalysis.Editor.UnitTests.Diagnostics;
using Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces;
using Microsoft.CodeAnalysis.Test.Utilities;
using Xunit.Abstractions;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Diagnostics
{
public abstract partial class AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest : AbstractDiagnosticProviderBasedUserDiagnosticTest
{
protected AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest(ITestOutputHelper logger)
: base(logger)
{
}
protected override ParseOptions GetScriptOptions() => Options.Script;
protected internal override string GetLanguage() => LanguageNames.CSharp;
protected const string IAsyncEnumerable = @"
namespace System
{
public interface IAsyncDisposable
{
System.Threading.Tasks.ValueTask DisposeAsync();
}
}
namespace System.Runtime.CompilerServices
{
using System.Threading.Tasks;
public sealed class AsyncMethodBuilderAttribute : Attribute
{
public AsyncMethodBuilderAttribute(Type builderType) { }
public Type BuilderType { get; }
}
public struct AsyncValueTaskMethodBuilder
{
public ValueTask Task => default;
public static AsyncValueTaskMethodBuilder Create() => default;
public void AwaitOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine {}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine {}
public void SetException(Exception exception) {}
public void SetResult() {}
public void SetStateMachine(IAsyncStateMachine stateMachine) {}
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine {}
}
public readonly struct ValueTaskAwaiter : ICriticalNotifyCompletion, INotifyCompletion
{
public bool IsCompleted => default;
public void GetResult() { }
public void OnCompleted(Action continuation) { }
public void UnsafeOnCompleted(Action continuation) { }
}
public readonly struct ValueTaskAwaiter<TResult> : ICriticalNotifyCompletion, INotifyCompletion
{
public bool IsCompleted => default;
public TResult GetResult() => default;
public void OnCompleted(Action continuation) { }
public void UnsafeOnCompleted(Action continuation) { }
}
}
namespace System.Threading.Tasks
{
using System.Runtime.CompilerServices;
[AsyncMethodBuilder(typeof(AsyncValueTaskMethodBuilder))]
public readonly struct ValueTask : IEquatable<ValueTask>
{
public ValueTask(Task task) {}
public ValueTask(IValueTaskSource source, short token) {}
public bool IsCompleted => default;
public bool IsCompletedSuccessfully => default;
public bool IsFaulted => default;
public bool IsCanceled => default;
public Task AsTask() => default;
public ConfiguredValueTaskAwaitable ConfigureAwait(bool continueOnCapturedContext) => default;
public override bool Equals(object obj) => default;
public bool Equals(ValueTask other) => default;
public ValueTaskAwaiter GetAwaiter() => default;
public override int GetHashCode() => default;
public ValueTask Preserve() => default;
public static bool operator ==(ValueTask left, ValueTask right) => default;
public static bool operator !=(ValueTask left, ValueTask right) => default;
}
[AsyncMethodBuilder(typeof(AsyncValueTaskMethodBuilder<>))]
public readonly struct ValueTask<TResult> : IEquatable<ValueTask<TResult>>
{
public ValueTask(TResult result) {}
public ValueTask(Task<TResult> task) {}
public ValueTask(IValueTaskSource<TResult> source, short token) {}
public bool IsFaulted => default;
public bool IsCompletedSuccessfully => default;
public bool IsCompleted => default;
public bool IsCanceled => default;
public TResult Result => default;
public Task<TResult> AsTask() => default;
public ConfiguredValueTaskAwaitable<TResult> ConfigureAwait(bool continueOnCapturedContext) => default;
public bool Equals(ValueTask<TResult> other) => default;
public override bool Equals(object obj) => default;
public ValueTaskAwaiter<TResult> GetAwaiter() => default;
public override int GetHashCode() => default;
public ValueTask<TResult> Preserve() => default;
public override string ToString() => default;
public static bool operator ==(ValueTask<TResult> left, ValueTask<TResult> right) => default;
public static bool operator !=(ValueTask<TResult> left, ValueTask<TResult> right) => default;
}
}
namespace System.Collections.Generic
{
public interface IAsyncEnumerable<out T>
{
IAsyncEnumerator<T> GetAsyncEnumerator();
}
public interface IAsyncEnumerator<out T> : IAsyncDisposable
{
System.Threading.Tasks.ValueTask<bool> MoveNextAsync();
T Current { get; }
}
}";
internal OptionsCollection RequireArithmeticBinaryParenthesesForClarity => ParenthesesOptionsProvider.RequireArithmeticBinaryParenthesesForClarity;
internal OptionsCollection RequireRelationalBinaryParenthesesForClarity => ParenthesesOptionsProvider.RequireRelationalBinaryParenthesesForClarity;
internal OptionsCollection RequireOtherBinaryParenthesesForClarity => ParenthesesOptionsProvider.RequireOtherBinaryParenthesesForClarity;
internal OptionsCollection IgnoreAllParentheses => ParenthesesOptionsProvider.IgnoreAllParentheses;
internal OptionsCollection RemoveAllUnnecessaryParentheses => ParenthesesOptionsProvider.RemoveAllUnnecessaryParentheses;
internal OptionsCollection RequireAllParenthesesForClarity => ParenthesesOptionsProvider.RequireAllParenthesesForClarity;
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.Editor.UnitTests;
using Microsoft.CodeAnalysis.Editor.UnitTests.CodeActions;
using Microsoft.CodeAnalysis.Editor.UnitTests.Diagnostics;
using Microsoft.CodeAnalysis.Editor.UnitTests.Workspaces;
using Microsoft.CodeAnalysis.Test.Utilities;
using Xunit.Abstractions;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.Diagnostics
{
public abstract partial class AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest : AbstractDiagnosticProviderBasedUserDiagnosticTest
{
protected AbstractCSharpDiagnosticProviderBasedUserDiagnosticTest(ITestOutputHelper logger)
: base(logger)
{
}
protected override ParseOptions GetScriptOptions() => Options.Script;
protected internal override string GetLanguage() => LanguageNames.CSharp;
protected const string IAsyncEnumerable = @"
namespace System
{
public interface IAsyncDisposable
{
System.Threading.Tasks.ValueTask DisposeAsync();
}
}
namespace System.Runtime.CompilerServices
{
using System.Threading.Tasks;
public sealed class AsyncMethodBuilderAttribute : Attribute
{
public AsyncMethodBuilderAttribute(Type builderType) { }
public Type BuilderType { get; }
}
public struct AsyncValueTaskMethodBuilder
{
public ValueTask Task => default;
public static AsyncValueTaskMethodBuilder Create() => default;
public void AwaitOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine {}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine {}
public void SetException(Exception exception) {}
public void SetResult() {}
public void SetStateMachine(IAsyncStateMachine stateMachine) {}
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine {}
}
public readonly struct ValueTaskAwaiter : ICriticalNotifyCompletion, INotifyCompletion
{
public bool IsCompleted => default;
public void GetResult() { }
public void OnCompleted(Action continuation) { }
public void UnsafeOnCompleted(Action continuation) { }
}
public readonly struct ValueTaskAwaiter<TResult> : ICriticalNotifyCompletion, INotifyCompletion
{
public bool IsCompleted => default;
public TResult GetResult() => default;
public void OnCompleted(Action continuation) { }
public void UnsafeOnCompleted(Action continuation) { }
}
}
namespace System.Threading.Tasks
{
using System.Runtime.CompilerServices;
[AsyncMethodBuilder(typeof(AsyncValueTaskMethodBuilder))]
public readonly struct ValueTask : IEquatable<ValueTask>
{
public ValueTask(Task task) {}
public ValueTask(IValueTaskSource source, short token) {}
public bool IsCompleted => default;
public bool IsCompletedSuccessfully => default;
public bool IsFaulted => default;
public bool IsCanceled => default;
public Task AsTask() => default;
public ConfiguredValueTaskAwaitable ConfigureAwait(bool continueOnCapturedContext) => default;
public override bool Equals(object obj) => default;
public bool Equals(ValueTask other) => default;
public ValueTaskAwaiter GetAwaiter() => default;
public override int GetHashCode() => default;
public ValueTask Preserve() => default;
public static bool operator ==(ValueTask left, ValueTask right) => default;
public static bool operator !=(ValueTask left, ValueTask right) => default;
}
[AsyncMethodBuilder(typeof(AsyncValueTaskMethodBuilder<>))]
public readonly struct ValueTask<TResult> : IEquatable<ValueTask<TResult>>
{
public ValueTask(TResult result) {}
public ValueTask(Task<TResult> task) {}
public ValueTask(IValueTaskSource<TResult> source, short token) {}
public bool IsFaulted => default;
public bool IsCompletedSuccessfully => default;
public bool IsCompleted => default;
public bool IsCanceled => default;
public TResult Result => default;
public Task<TResult> AsTask() => default;
public ConfiguredValueTaskAwaitable<TResult> ConfigureAwait(bool continueOnCapturedContext) => default;
public bool Equals(ValueTask<TResult> other) => default;
public override bool Equals(object obj) => default;
public ValueTaskAwaiter<TResult> GetAwaiter() => default;
public override int GetHashCode() => default;
public ValueTask<TResult> Preserve() => default;
public override string ToString() => default;
public static bool operator ==(ValueTask<TResult> left, ValueTask<TResult> right) => default;
public static bool operator !=(ValueTask<TResult> left, ValueTask<TResult> right) => default;
}
}
namespace System.Collections.Generic
{
public interface IAsyncEnumerable<out T>
{
IAsyncEnumerator<T> GetAsyncEnumerator();
}
public interface IAsyncEnumerator<out T> : IAsyncDisposable
{
System.Threading.Tasks.ValueTask<bool> MoveNextAsync();
T Current { get; }
}
}";
internal OptionsCollection RequireArithmeticBinaryParenthesesForClarity => ParenthesesOptionsProvider.RequireArithmeticBinaryParenthesesForClarity;
internal OptionsCollection RequireRelationalBinaryParenthesesForClarity => ParenthesesOptionsProvider.RequireRelationalBinaryParenthesesForClarity;
internal OptionsCollection RequireOtherBinaryParenthesesForClarity => ParenthesesOptionsProvider.RequireOtherBinaryParenthesesForClarity;
internal OptionsCollection IgnoreAllParentheses => ParenthesesOptionsProvider.IgnoreAllParentheses;
internal OptionsCollection RemoveAllUnnecessaryParentheses => ParenthesesOptionsProvider.RemoveAllUnnecessaryParentheses;
internal OptionsCollection RequireAllParenthesesForClarity => ParenthesesOptionsProvider.RequireAllParenthesesForClarity;
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/VisualBasic/Portable/MetadataAsSource/VisualBasicMetadataAsSourceServiceFactory.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Composition
Imports Microsoft.CodeAnalysis.Host
Imports Microsoft.CodeAnalysis.Host.Mef
Imports Microsoft.CodeAnalysis.MetadataAsSource
Namespace Microsoft.CodeAnalysis.VisualBasic.MetadataAsSource
<ExportLanguageServiceFactory(GetType(IMetadataAsSourceService), LanguageNames.VisualBasic), [Shared]>
Friend Class VisualBasicMetadataAsSourceServiceFactory
Implements ILanguageServiceFactory
<ImportingConstructor>
<Obsolete(MefConstruction.ImportingConstructorMessage, True)>
Public Sub New()
End Sub
Public Function CreateLanguageService(provider As HostLanguageServices) As ILanguageService Implements ILanguageServiceFactory.CreateLanguageService
Return VisualBasicMetadataAsSourceService.Instance
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Composition
Imports Microsoft.CodeAnalysis.Host
Imports Microsoft.CodeAnalysis.Host.Mef
Imports Microsoft.CodeAnalysis.MetadataAsSource
Namespace Microsoft.CodeAnalysis.VisualBasic.MetadataAsSource
<ExportLanguageServiceFactory(GetType(IMetadataAsSourceService), LanguageNames.VisualBasic), [Shared]>
Friend Class VisualBasicMetadataAsSourceServiceFactory
Implements ILanguageServiceFactory
<ImportingConstructor>
<Obsolete(MefConstruction.ImportingConstructorMessage, True)>
Public Sub New()
End Sub
Public Function CreateLanguageService(provider As HostLanguageServices) As ILanguageService Implements ILanguageServiceFactory.CreateLanguageService
Return VisualBasicMetadataAsSourceService.Instance
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/IntegrationTest/IntegrationTests/Workspace/WorkspacesDesktop.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
using ProjectUtils = Microsoft.VisualStudio.IntegrationTest.Utilities.Common.ProjectUtils;
namespace Roslyn.VisualStudio.IntegrationTests.Workspace
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class WorkspacesDesktop : WorkspaceBase
{
public WorkspacesDesktop(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory, WellKnownProjectTemplates.ClassLibrary)
{
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void OpenCSharpThenVBSolution()
{
base.OpenCSharpThenVBSolution();
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void MetadataReference()
{
base.MetadataReference();
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void ProjectReference()
{
base.ProjectReference();
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void ProjectProperties()
{
VisualStudio.SolutionExplorer.CreateSolution(nameof(WorkspacesDesktop));
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.AddProject(project, WellKnownProjectTemplates.ClassLibrary, LanguageNames.VisualBasic);
base.ProjectProperties();
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
using ProjectUtils = Microsoft.VisualStudio.IntegrationTest.Utilities.Common.ProjectUtils;
namespace Roslyn.VisualStudio.IntegrationTests.Workspace
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class WorkspacesDesktop : WorkspaceBase
{
public WorkspacesDesktop(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory, WellKnownProjectTemplates.ClassLibrary)
{
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void OpenCSharpThenVBSolution()
{
base.OpenCSharpThenVBSolution();
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void MetadataReference()
{
base.MetadataReference();
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void ProjectReference()
{
base.ProjectReference();
}
[WpfFact, Trait(Traits.Feature, Traits.Features.Workspace)]
public override void ProjectProperties()
{
VisualStudio.SolutionExplorer.CreateSolution(nameof(WorkspacesDesktop));
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.AddProject(project, WellKnownProjectTemplates.ClassLibrary, LanguageNames.VisualBasic);
base.ProjectProperties();
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Core/Portable/DiagnosticAnalyzer/CompilerDiagnosticAnalyzer.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
namespace Microsoft.CodeAnalysis.Diagnostics
{
/// <summary>
/// DiagnosticAnalyzer for compiler's syntax/semantic/compilation diagnostics.
/// </summary>
internal abstract partial class CompilerDiagnosticAnalyzer : DiagnosticAnalyzer
{
internal abstract CommonMessageProvider MessageProvider { get; }
internal abstract ImmutableArray<int> GetSupportedErrorCodes();
public sealed override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics
{
get
{
// DiagnosticAnalyzer.SupportedDiagnostics should be invoked only once per analyzer,
// so we don't need to store the computed descriptors array into a field.
var messageProvider = this.MessageProvider;
var errorCodes = this.GetSupportedErrorCodes();
var builder = ImmutableArray.CreateBuilder<DiagnosticDescriptor>(errorCodes.Length);
foreach (var errorCode in errorCodes)
{
var descriptor = DiagnosticInfo.GetDescriptor(errorCode, messageProvider);
builder.Add(descriptor);
}
builder.Add(AnalyzerExecutor.GetAnalyzerExceptionDiagnosticDescriptor());
return builder.ToImmutable();
}
}
public sealed override void Initialize(AnalysisContext context)
{
context.EnableConcurrentExecution();
context.ConfigureGeneratedCodeAnalysis(GeneratedCodeAnalysisFlags.Analyze | GeneratedCodeAnalysisFlags.ReportDiagnostics);
context.RegisterCompilationStartAction(c =>
{
var analyzer = new CompilationAnalyzer(c.Compilation);
c.RegisterSyntaxTreeAction(analyzer.AnalyzeSyntaxTree);
c.RegisterSemanticModelAction(CompilationAnalyzer.AnalyzeSemanticModel);
});
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
namespace Microsoft.CodeAnalysis.Diagnostics
{
/// <summary>
/// DiagnosticAnalyzer for compiler's syntax/semantic/compilation diagnostics.
/// </summary>
internal abstract partial class CompilerDiagnosticAnalyzer : DiagnosticAnalyzer
{
internal abstract CommonMessageProvider MessageProvider { get; }
internal abstract ImmutableArray<int> GetSupportedErrorCodes();
public sealed override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics
{
get
{
// DiagnosticAnalyzer.SupportedDiagnostics should be invoked only once per analyzer,
// so we don't need to store the computed descriptors array into a field.
var messageProvider = this.MessageProvider;
var errorCodes = this.GetSupportedErrorCodes();
var builder = ImmutableArray.CreateBuilder<DiagnosticDescriptor>(errorCodes.Length);
foreach (var errorCode in errorCodes)
{
var descriptor = DiagnosticInfo.GetDescriptor(errorCode, messageProvider);
builder.Add(descriptor);
}
builder.Add(AnalyzerExecutor.GetAnalyzerExceptionDiagnosticDescriptor());
return builder.ToImmutable();
}
}
public sealed override void Initialize(AnalysisContext context)
{
context.EnableConcurrentExecution();
context.ConfigureGeneratedCodeAnalysis(GeneratedCodeAnalysisFlags.Analyze | GeneratedCodeAnalysisFlags.ReportDiagnostics);
context.RegisterCompilationStartAction(c =>
{
var analyzer = new CompilationAnalyzer(c.Compilation);
c.RegisterSyntaxTreeAction(analyzer.AnalyzeSyntaxTree);
c.RegisterSemanticModelAction(CompilationAnalyzer.AnalyzeSemanticModel);
});
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Core/Portable/ReferenceManager/ModuleReferences.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using Microsoft.CodeAnalysis.Symbols;
using Microsoft.CodeAnalysis.Text;
namespace Microsoft.CodeAnalysis
{
/// <summary>
/// A record of the assemblies referenced by a module (their identities, symbols, and unification).
/// </summary>
internal sealed class ModuleReferences<TAssemblySymbol>
where TAssemblySymbol : class, IAssemblySymbolInternal
{
/// <summary>
/// Identities of referenced assemblies (those that are or will be emitted to metadata).
/// </summary>
/// <remarks>
/// Names[i] is the identity of assembly Symbols[i].
/// </remarks>
public readonly ImmutableArray<AssemblyIdentity> Identities;
/// <summary>
/// Assembly symbols that the identities are resolved against.
/// </summary>
/// <remarks>
/// Names[i] is the identity of assembly Symbols[i].
/// Unresolved references are represented as MissingAssemblySymbols.
/// </remarks>
public readonly ImmutableArray<TAssemblySymbol> Symbols;
/// <summary>
/// A subset of <see cref="Symbols"/> that correspond to references with non-matching (unified)
/// version along with unification details.
/// </summary>
public readonly ImmutableArray<UnifiedAssembly<TAssemblySymbol>> UnifiedAssemblies;
public ModuleReferences(
ImmutableArray<AssemblyIdentity> identities,
ImmutableArray<TAssemblySymbol> symbols,
ImmutableArray<UnifiedAssembly<TAssemblySymbol>> unifiedAssemblies)
{
Debug.Assert(!identities.IsDefault);
Debug.Assert(!symbols.IsDefault);
Debug.Assert(identities.Length == symbols.Length);
Debug.Assert(!unifiedAssemblies.IsDefault);
this.Identities = identities;
this.Symbols = symbols;
this.UnifiedAssemblies = unifiedAssemblies;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Collections.Immutable;
using System.Diagnostics;
using Microsoft.CodeAnalysis.Symbols;
using Microsoft.CodeAnalysis.Text;
namespace Microsoft.CodeAnalysis
{
/// <summary>
/// A record of the assemblies referenced by a module (their identities, symbols, and unification).
/// </summary>
internal sealed class ModuleReferences<TAssemblySymbol>
where TAssemblySymbol : class, IAssemblySymbolInternal
{
/// <summary>
/// Identities of referenced assemblies (those that are or will be emitted to metadata).
/// </summary>
/// <remarks>
/// Names[i] is the identity of assembly Symbols[i].
/// </remarks>
public readonly ImmutableArray<AssemblyIdentity> Identities;
/// <summary>
/// Assembly symbols that the identities are resolved against.
/// </summary>
/// <remarks>
/// Names[i] is the identity of assembly Symbols[i].
/// Unresolved references are represented as MissingAssemblySymbols.
/// </remarks>
public readonly ImmutableArray<TAssemblySymbol> Symbols;
/// <summary>
/// A subset of <see cref="Symbols"/> that correspond to references with non-matching (unified)
/// version along with unification details.
/// </summary>
public readonly ImmutableArray<UnifiedAssembly<TAssemblySymbol>> UnifiedAssemblies;
public ModuleReferences(
ImmutableArray<AssemblyIdentity> identities,
ImmutableArray<TAssemblySymbol> symbols,
ImmutableArray<UnifiedAssembly<TAssemblySymbol>> unifiedAssemblies)
{
Debug.Assert(!identities.IsDefault);
Debug.Assert(!symbols.IsDefault);
Debug.Assert(identities.Length == symbols.Length);
Debug.Assert(!unifiedAssemblies.IsDefault);
this.Identities = identities;
this.Symbols = symbols;
this.UnifiedAssemblies = unifiedAssemblies;
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Test/Emit/CodeGen/CodeGenVbRuntime.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Microsoft.CodeAnalysis.VisualBasic.UnitTests.Emit
Imports Roslyn.Test.Utilities
Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests
Public Class CodeGenVbRuntime
Inherits BasicTestBase
<Fact()>
Public Sub ObjValueOnAssign()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Structure S1
Public x As Integer
Public Overrides Function GetHashCode() As Integer
x += 1
Return x
End Function
End Structure
Module EmitTest
Sub Main()
Dim o As Object = New S1
Dim oo As Object = o
System.Console.Write(o.GetHashCode())
System.Console.Write(o.GetHashCode())
System.Console.Write(oo.GetHashCode())
System.Console.Write(oo.GetHashCode())
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="1234").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 60 (0x3c)
.maxstack 2
.locals init (Object V_0, //oo
S1 V_1)
IL_0000: ldloca.s V_1
IL_0002: initobj "S1"
IL_0008: ldloc.1
IL_0009: box "S1"
IL_000e: dup
IL_000f: stloc.0
IL_0010: dup
IL_0011: callvirt "Function Object.GetHashCode() As Integer"
IL_0016: call "Sub System.Console.Write(Integer)"
IL_001b: callvirt "Function Object.GetHashCode() As Integer"
IL_0020: call "Sub System.Console.Write(Integer)"
IL_0025: ldloc.0
IL_0026: callvirt "Function Object.GetHashCode() As Integer"
IL_002b: call "Sub System.Console.Write(Integer)"
IL_0030: ldloc.0
IL_0031: callvirt "Function Object.GetHashCode() As Integer"
IL_0036: call "Sub System.Console.Write(Integer)"
IL_003b: ret
}
]]>)
End Sub
<Fact()>
Public Sub ObjValueOnPassByValue()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Structure S1
Public x As Integer
Public Overrides Function GetHashCode() As Integer
x += 1
Return x
End Function
End Structure
Module EmitTest
Sub Main()
Dim o As Object = New S1
Test(o)
Test(o)
Test(o)
Test(o)
End Sub
Private Sub Test(o As Object)
System.Console.Write(o.GetHashCode())
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="1234").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 38 (0x26)
.maxstack 2
.locals init (S1 V_0)
IL_0000: ldloca.s V_0
IL_0002: initobj "S1"
IL_0008: ldloc.0
IL_0009: box "S1"
IL_000e: dup
IL_000f: call "Sub EmitTest.Test(Object)"
IL_0014: dup
IL_0015: call "Sub EmitTest.Test(Object)"
IL_001a: dup
IL_001b: call "Sub EmitTest.Test(Object)"
IL_0020: call "Sub EmitTest.Test(Object)"
IL_0025: ret
}
]]>)
End Sub
<Fact()>
Public Sub ErrInCatch()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module EmitTest
Sub Main()
try
system.Console.Write("boo")
catch ex as exception
end try
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="boo").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 16 (0x10)
.maxstack 1
.locals init (System.Exception V_0) //ex
.try
{
IL_0000: ldstr "boo"
IL_0005: call "Sub System.Console.Write(String)"
IL_000a: leave.s IL_000f
}
catch System.Exception
{
IL_000c: stloc.0
IL_000d: leave.s IL_000f
}
IL_000f: ret
}
]]>)
End Sub
<Fact()>
Public Sub ErrInCatch1()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module EmitTest
Sub Main()
try
system.Console.Write("boo")
catch
end try
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="boo").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 16 (0x10)
.maxstack 1
.try
{
IL_0000: ldstr "boo"
IL_0005: call "Sub System.Console.Write(String)"
IL_000a: leave.s IL_000f
}
catch System.Exception
{
IL_000c: pop
IL_000d: leave.s IL_000f
}
IL_000f: ret
}
]]>)
End Sub
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.Test.Utilities
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Microsoft.CodeAnalysis.VisualBasic.UnitTests.Emit
Imports Roslyn.Test.Utilities
Namespace Microsoft.CodeAnalysis.VisualBasic.UnitTests
Public Class CodeGenVbRuntime
Inherits BasicTestBase
<Fact()>
Public Sub ObjValueOnAssign()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Structure S1
Public x As Integer
Public Overrides Function GetHashCode() As Integer
x += 1
Return x
End Function
End Structure
Module EmitTest
Sub Main()
Dim o As Object = New S1
Dim oo As Object = o
System.Console.Write(o.GetHashCode())
System.Console.Write(o.GetHashCode())
System.Console.Write(oo.GetHashCode())
System.Console.Write(oo.GetHashCode())
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="1234").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 60 (0x3c)
.maxstack 2
.locals init (Object V_0, //oo
S1 V_1)
IL_0000: ldloca.s V_1
IL_0002: initobj "S1"
IL_0008: ldloc.1
IL_0009: box "S1"
IL_000e: dup
IL_000f: stloc.0
IL_0010: dup
IL_0011: callvirt "Function Object.GetHashCode() As Integer"
IL_0016: call "Sub System.Console.Write(Integer)"
IL_001b: callvirt "Function Object.GetHashCode() As Integer"
IL_0020: call "Sub System.Console.Write(Integer)"
IL_0025: ldloc.0
IL_0026: callvirt "Function Object.GetHashCode() As Integer"
IL_002b: call "Sub System.Console.Write(Integer)"
IL_0030: ldloc.0
IL_0031: callvirt "Function Object.GetHashCode() As Integer"
IL_0036: call "Sub System.Console.Write(Integer)"
IL_003b: ret
}
]]>)
End Sub
<Fact()>
Public Sub ObjValueOnPassByValue()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Structure S1
Public x As Integer
Public Overrides Function GetHashCode() As Integer
x += 1
Return x
End Function
End Structure
Module EmitTest
Sub Main()
Dim o As Object = New S1
Test(o)
Test(o)
Test(o)
Test(o)
End Sub
Private Sub Test(o As Object)
System.Console.Write(o.GetHashCode())
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="1234").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 38 (0x26)
.maxstack 2
.locals init (S1 V_0)
IL_0000: ldloca.s V_0
IL_0002: initobj "S1"
IL_0008: ldloc.0
IL_0009: box "S1"
IL_000e: dup
IL_000f: call "Sub EmitTest.Test(Object)"
IL_0014: dup
IL_0015: call "Sub EmitTest.Test(Object)"
IL_001a: dup
IL_001b: call "Sub EmitTest.Test(Object)"
IL_0020: call "Sub EmitTest.Test(Object)"
IL_0025: ret
}
]]>)
End Sub
<Fact()>
Public Sub ErrInCatch()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module EmitTest
Sub Main()
try
system.Console.Write("boo")
catch ex as exception
end try
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="boo").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 16 (0x10)
.maxstack 1
.locals init (System.Exception V_0) //ex
.try
{
IL_0000: ldstr "boo"
IL_0005: call "Sub System.Console.Write(String)"
IL_000a: leave.s IL_000f
}
catch System.Exception
{
IL_000c: stloc.0
IL_000d: leave.s IL_000f
}
IL_000f: ret
}
]]>)
End Sub
<Fact()>
Public Sub ErrInCatch1()
CompileAndVerify(
<compilation>
<file name="a.vb">
<![CDATA[
Imports System
Module EmitTest
Sub Main()
try
system.Console.Write("boo")
catch
end try
End Sub
End Module
Namespace Microsoft
Namespace VisualBasic
Namespace CompilerServices
<AttributeUsage(AttributeTargets.[Class], Inherited:=False, AllowMultiple:=False)>
Public Class StandardModuleAttribute
Inherits Attribute
Public Sub New()
End Sub
End Class
End Namespace
End Namespace
End Namespace
]]>
</file>
</compilation>,
expectedOutput:="boo").
VerifyIL("EmitTest.Main",
<![CDATA[
{
// Code size 16 (0x10)
.maxstack 1
.try
{
IL_0000: ldstr "boo"
IL_0005: call "Sub System.Console.Write(String)"
IL_000a: leave.s IL_000f
}
catch System.Exception
{
IL_000c: pop
IL_000d: leave.s IL_000f
}
IL_000f: ret
}
]]>)
End Sub
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Core/Portable/Syntax/SyntaxList.WithTwoChildren.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Syntax
{
internal partial class SyntaxList
{
internal class WithTwoChildren : SyntaxList
{
private SyntaxNode? _child0;
private SyntaxNode? _child1;
internal WithTwoChildren(InternalSyntax.SyntaxList green, SyntaxNode? parent, int position)
: base(green, parent, position)
{
}
internal override SyntaxNode? GetNodeSlot(int index)
{
switch (index)
{
case 0:
return this.GetRedElement(ref _child0, 0);
case 1:
return this.GetRedElementIfNotToken(ref _child1);
default:
return null;
}
}
internal override SyntaxNode? GetCachedSlot(int index)
{
switch (index)
{
case 0:
return _child0;
case 1:
return _child1;
default:
return null;
}
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Syntax
{
internal partial class SyntaxList
{
internal class WithTwoChildren : SyntaxList
{
private SyntaxNode? _child0;
private SyntaxNode? _child1;
internal WithTwoChildren(InternalSyntax.SyntaxList green, SyntaxNode? parent, int position)
: base(green, parent, position)
{
}
internal override SyntaxNode? GetNodeSlot(int index)
{
switch (index)
{
case 0:
return this.GetRedElement(ref _child0, 0);
case 1:
return this.GetRedElementIfNotToken(ref _child1);
default:
return null;
}
}
internal override SyntaxNode? GetCachedSlot(int index)
{
switch (index)
{
case 0:
return _child0;
case 1:
return _child1;
default:
return null;
}
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/IntegrationTest/TestUtilities/OutOfProcess/InteractiveWindow_OutOfProc.Verifier.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Xunit;
namespace Microsoft.VisualStudio.IntegrationTest.Utilities.OutOfProcess
{
/// <summary>
/// Provides a means of interacting with the interactive window in the Visual Studio host.
/// </summary>
public abstract partial class InteractiveWindow_OutOfProc : TextViewWindow_OutOfProc
{
public class Verifier : Verifier<InteractiveWindow_OutOfProc>
{
private static readonly char[] LineSeparators = { '\r', '\n' };
public Verifier(InteractiveWindow_OutOfProc interactiveWindow, VisualStudioInstance instance)
: base(interactiveWindow, instance)
{
}
public void LastReplInput(string expectedReplInput)
{
var lastReplInput = _textViewWindow.GetLastReplInput();
Assert.Equal(expectedReplInput, lastReplInput);
}
public void ReplPromptConsistency(string prompt, string output)
{
var replText = _textViewWindow.GetReplText();
var replTextLines = replText.Split(LineSeparators, StringSplitOptions.RemoveEmptyEntries);
foreach (var replTextLine in replTextLines)
{
if (!replTextLine.Contains(prompt))
{
continue;
}
// The prompt must be at the beginning of the line
Assert.StartsWith(prompt, replTextLine);
var promptIndex = replTextLine.IndexOf(prompt, prompt.Length);
// A 'subsequent' prompt is only allowed on a line containing #prompt
if (promptIndex >= 0)
{
Assert.StartsWith(prompt + "#prompt", replTextLine);
Assert.False(replTextLine.IndexOf(prompt, promptIndex + prompt.Length) >= 0);
}
// There must be no output on a prompt line.
Assert.DoesNotContain(output, replTextLine);
}
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Xunit;
namespace Microsoft.VisualStudio.IntegrationTest.Utilities.OutOfProcess
{
/// <summary>
/// Provides a means of interacting with the interactive window in the Visual Studio host.
/// </summary>
public abstract partial class InteractiveWindow_OutOfProc : TextViewWindow_OutOfProc
{
public class Verifier : Verifier<InteractiveWindow_OutOfProc>
{
private static readonly char[] LineSeparators = { '\r', '\n' };
public Verifier(InteractiveWindow_OutOfProc interactiveWindow, VisualStudioInstance instance)
: base(interactiveWindow, instance)
{
}
public void LastReplInput(string expectedReplInput)
{
var lastReplInput = _textViewWindow.GetLastReplInput();
Assert.Equal(expectedReplInput, lastReplInput);
}
public void ReplPromptConsistency(string prompt, string output)
{
var replText = _textViewWindow.GetReplText();
var replTextLines = replText.Split(LineSeparators, StringSplitOptions.RemoveEmptyEntries);
foreach (var replTextLine in replTextLines)
{
if (!replTextLine.Contains(prompt))
{
continue;
}
// The prompt must be at the beginning of the line
Assert.StartsWith(prompt, replTextLine);
var promptIndex = replTextLine.IndexOf(prompt, prompt.Length);
// A 'subsequent' prompt is only allowed on a line containing #prompt
if (promptIndex >= 0)
{
Assert.StartsWith(prompt + "#prompt", replTextLine);
Assert.False(replTextLine.IndexOf(prompt, promptIndex + prompt.Length) >= 0);
}
// There must be no output on a prompt line.
Assert.DoesNotContain(output, replTextLine);
}
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/Core/Portable/GenerateType/IGenerateTypeOptionService.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.LanguageServices;
using Microsoft.CodeAnalysis.Notification;
using Microsoft.CodeAnalysis.ProjectManagement;
namespace Microsoft.CodeAnalysis.GenerateType
{
internal interface IGenerateTypeOptionsService : IWorkspaceService
{
GenerateTypeOptionsResult GetGenerateTypeOptions(
string className,
GenerateTypeDialogOptions generateTypeDialogOptions,
Document document,
INotificationService notificationService,
IProjectManagementService projectManagementService,
ISyntaxFactsService syntaxFactsService);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.LanguageServices;
using Microsoft.CodeAnalysis.Notification;
using Microsoft.CodeAnalysis.ProjectManagement;
namespace Microsoft.CodeAnalysis.GenerateType
{
internal interface IGenerateTypeOptionsService : IWorkspaceService
{
GenerateTypeOptionsResult GetGenerateTypeOptions(
string className,
GenerateTypeDialogOptions generateTypeDialogOptions,
Document document,
INotificationService notificationService,
IProjectManagementService projectManagementService,
ISyntaxFactsService syntaxFactsService);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/Shared/GlobalAssemblyCacheHelpers/GlobalAssemblyCacheLocation.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Runtime.InteropServices;
namespace Microsoft.CodeAnalysis
{
internal static class GlobalAssemblyCacheLocation
{
internal enum ASM_CACHE
{
ZAP = 0x1,
GAC = 0x2, // C:\Windows\Assembly\GAC
DOWNLOAD = 0x4,
ROOT = 0x8, // C:\Windows\Assembly
GAC_MSIL = 0x10,
GAC_32 = 0x20, // C:\Windows\Assembly\GAC_32
GAC_64 = 0x40, // C:\Windows\Assembly\GAC_64
ROOT_EX = 0x80, // C:\Windows\Microsoft.NET\assembly
}
[DllImport("clr", PreserveSig = true)]
private static extern unsafe int GetCachePath(ASM_CACHE id, byte* path, ref int length);
public static ImmutableArray<string> s_rootLocations;
public static ImmutableArray<string> RootLocations
{
get
{
if (s_rootLocations.IsDefault)
{
s_rootLocations = ImmutableArray.Create(GetLocation(ASM_CACHE.ROOT), GetLocation(ASM_CACHE.ROOT_EX));
}
return s_rootLocations;
}
}
private static unsafe string GetLocation(ASM_CACHE gacId)
{
const int ERROR_INSUFFICIENT_BUFFER = unchecked((int)0x8007007A);
int characterCount = 0;
int hr = GetCachePath(gacId, null, ref characterCount);
if (hr != ERROR_INSUFFICIENT_BUFFER)
{
throw Marshal.GetExceptionForHR(hr);
}
byte[] data = new byte[(characterCount + 1) * 2];
fixed (byte* p = data)
{
hr = GetCachePath(gacId, p, ref characterCount);
if (hr != 0)
{
throw Marshal.GetExceptionForHR(hr);
}
return Marshal.PtrToStringUni((IntPtr)p);
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Runtime.InteropServices;
namespace Microsoft.CodeAnalysis
{
internal static class GlobalAssemblyCacheLocation
{
internal enum ASM_CACHE
{
ZAP = 0x1,
GAC = 0x2, // C:\Windows\Assembly\GAC
DOWNLOAD = 0x4,
ROOT = 0x8, // C:\Windows\Assembly
GAC_MSIL = 0x10,
GAC_32 = 0x20, // C:\Windows\Assembly\GAC_32
GAC_64 = 0x40, // C:\Windows\Assembly\GAC_64
ROOT_EX = 0x80, // C:\Windows\Microsoft.NET\assembly
}
[DllImport("clr", PreserveSig = true)]
private static extern unsafe int GetCachePath(ASM_CACHE id, byte* path, ref int length);
public static ImmutableArray<string> s_rootLocations;
public static ImmutableArray<string> RootLocations
{
get
{
if (s_rootLocations.IsDefault)
{
s_rootLocations = ImmutableArray.Create(GetLocation(ASM_CACHE.ROOT), GetLocation(ASM_CACHE.ROOT_EX));
}
return s_rootLocations;
}
}
private static unsafe string GetLocation(ASM_CACHE gacId)
{
const int ERROR_INSUFFICIENT_BUFFER = unchecked((int)0x8007007A);
int characterCount = 0;
int hr = GetCachePath(gacId, null, ref characterCount);
if (hr != ERROR_INSUFFICIENT_BUFFER)
{
throw Marshal.GetExceptionForHR(hr);
}
byte[] data = new byte[(characterCount + 1) * 2];
fixed (byte* p = data)
{
hr = GetCachePath(gacId, p, ref characterCount);
if (hr != 0)
{
throw Marshal.GetExceptionForHR(hr);
}
return Marshal.PtrToStringUni((IntPtr)p);
}
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/IntegrationTest/IntegrationTests/CSharp/CSharpUpdateProjectToAllowUnsafe.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
using ProjectUtils = Microsoft.VisualStudio.IntegrationTest.Utilities.Common.ProjectUtils;
namespace Roslyn.VisualStudio.IntegrationTests.CSharp
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class CSharpUpdateProjectToAllowUnsafe : AbstractUpdateProjectTest
{
public CSharpUpdateProjectToAllowUnsafe(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory)
{
}
private void InvokeFix()
{
VisualStudio.Editor.SetText(@"
unsafe class C
{
}");
VisualStudio.Editor.Activate();
VisualStudio.Editor.PlaceCaret("C");
VisualStudio.Editor.InvokeCodeActionList();
VisualStudio.Editor.Verify.CodeAction("Allow unsafe code in this project", applyFix: true);
}
[WpfFact(Skip = "https://github.com/dotnet/roslyn/issues/44301"), Trait(Traits.Feature, Traits.Features.CodeActionsUpdateProjectToAllowUnsafe)]
public void CPSProject_GeneralPropertyGroupUpdated()
{
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.CreateSolution(SolutionName);
VisualStudio.SolutionExplorer.AddProject(project, WellKnownProjectTemplates.CSharpNetStandardClassLibrary, LanguageNames.CSharp);
VisualStudio.SolutionExplorer.RestoreNuGetPackages(project);
InvokeFix();
VerifyPropertyOutsideConfiguration(GetProjectFileElement(project), "AllowUnsafeBlocks", "true");
}
[WpfFact, Trait(Traits.Feature, Traits.Features.CodeActionsUpdateProjectToAllowUnsafe)]
public void LegacyProject_AllConfigurationsUpdated()
{
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.CreateSolution(SolutionName);
VisualStudio.SolutionExplorer.AddProject(project, WellKnownProjectTemplates.ClassLibrary, LanguageNames.CSharp);
InvokeFix();
VerifyPropertyInEachConfiguration(GetProjectFileElement(project), "AllowUnsafeBlocks", "true");
}
[WorkItem(23342, "https://github.com/dotnet/roslyn/issues/23342")]
[WpfFact, Trait(Traits.Feature, Traits.Features.CodeActionsUpdateProjectToAllowUnsafe)]
public void LegacyProject_MultiplePlatforms_AllConfigurationsUpdated()
{
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.CreateSolution(SolutionName);
VisualStudio.SolutionExplorer.AddCustomProject(project, ".csproj", $@"<?xml version=""1.0"" encoding=""utf-8""?>
<Project ToolsVersion=""15.0"" xmlns=""http://schemas.microsoft.com/developer/msbuild/2003"">
<Import Project=""$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props"" Condition=""Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')"" />
<PropertyGroup>
<Configuration Condition=""'$(Configuration)' == ''"">Debug</Configuration>
<Platform Condition=""'$(Platform)' == ''"">x64</Platform>
<ProjectGuid>{{F4233BA4-A4CB-498B-BBC1-65A42206B1BA}}</ProjectGuid>
<OutputType>Library</OutputType>
<RootNamespace>{ProjectName}</RootNamespace>
<AssemblyName>{ProjectName}</AssemblyName>
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Debug|x86'"">
<OutputPath>bin\x86\Debug\</OutputPath>
<PlatformTarget>x86</PlatformTarget>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Release|x86'"">
<OutputPath>bin\x86\Release\</OutputPath>
<PlatformTarget>x86</PlatformTarget>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Debug|x64'"">
<OutputPath>bin\x64\Debug\</OutputPath>
<PlatformTarget>x64</PlatformTarget>
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Release|x64'"">
<OutputPath>bin\x64\Release\</OutputPath>
<PlatformTarget>x64</PlatformTarget>
</PropertyGroup>
<ItemGroup>
</ItemGroup>
<Import Project=""$(MSBuildToolsPath)\Microsoft.CSharp.targets"" />
</Project>");
VisualStudio.SolutionExplorer.AddFile(project, "C.cs", open: true);
InvokeFix();
VerifyPropertyInEachConfiguration(GetProjectFileElement(project), "AllowUnsafeBlocks", "true");
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
using ProjectUtils = Microsoft.VisualStudio.IntegrationTest.Utilities.Common.ProjectUtils;
namespace Roslyn.VisualStudio.IntegrationTests.CSharp
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class CSharpUpdateProjectToAllowUnsafe : AbstractUpdateProjectTest
{
public CSharpUpdateProjectToAllowUnsafe(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory)
{
}
private void InvokeFix()
{
VisualStudio.Editor.SetText(@"
unsafe class C
{
}");
VisualStudio.Editor.Activate();
VisualStudio.Editor.PlaceCaret("C");
VisualStudio.Editor.InvokeCodeActionList();
VisualStudio.Editor.Verify.CodeAction("Allow unsafe code in this project", applyFix: true);
}
[WpfFact(Skip = "https://github.com/dotnet/roslyn/issues/44301"), Trait(Traits.Feature, Traits.Features.CodeActionsUpdateProjectToAllowUnsafe)]
public void CPSProject_GeneralPropertyGroupUpdated()
{
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.CreateSolution(SolutionName);
VisualStudio.SolutionExplorer.AddProject(project, WellKnownProjectTemplates.CSharpNetStandardClassLibrary, LanguageNames.CSharp);
VisualStudio.SolutionExplorer.RestoreNuGetPackages(project);
InvokeFix();
VerifyPropertyOutsideConfiguration(GetProjectFileElement(project), "AllowUnsafeBlocks", "true");
}
[WpfFact, Trait(Traits.Feature, Traits.Features.CodeActionsUpdateProjectToAllowUnsafe)]
public void LegacyProject_AllConfigurationsUpdated()
{
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.CreateSolution(SolutionName);
VisualStudio.SolutionExplorer.AddProject(project, WellKnownProjectTemplates.ClassLibrary, LanguageNames.CSharp);
InvokeFix();
VerifyPropertyInEachConfiguration(GetProjectFileElement(project), "AllowUnsafeBlocks", "true");
}
[WorkItem(23342, "https://github.com/dotnet/roslyn/issues/23342")]
[WpfFact, Trait(Traits.Feature, Traits.Features.CodeActionsUpdateProjectToAllowUnsafe)]
public void LegacyProject_MultiplePlatforms_AllConfigurationsUpdated()
{
var project = new ProjectUtils.Project(ProjectName);
VisualStudio.SolutionExplorer.CreateSolution(SolutionName);
VisualStudio.SolutionExplorer.AddCustomProject(project, ".csproj", $@"<?xml version=""1.0"" encoding=""utf-8""?>
<Project ToolsVersion=""15.0"" xmlns=""http://schemas.microsoft.com/developer/msbuild/2003"">
<Import Project=""$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props"" Condition=""Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')"" />
<PropertyGroup>
<Configuration Condition=""'$(Configuration)' == ''"">Debug</Configuration>
<Platform Condition=""'$(Platform)' == ''"">x64</Platform>
<ProjectGuid>{{F4233BA4-A4CB-498B-BBC1-65A42206B1BA}}</ProjectGuid>
<OutputType>Library</OutputType>
<RootNamespace>{ProjectName}</RootNamespace>
<AssemblyName>{ProjectName}</AssemblyName>
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Debug|x86'"">
<OutputPath>bin\x86\Debug\</OutputPath>
<PlatformTarget>x86</PlatformTarget>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Release|x86'"">
<OutputPath>bin\x86\Release\</OutputPath>
<PlatformTarget>x86</PlatformTarget>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Debug|x64'"">
<OutputPath>bin\x64\Debug\</OutputPath>
<PlatformTarget>x64</PlatformTarget>
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition=""'$(Configuration)|$(Platform)' == 'Release|x64'"">
<OutputPath>bin\x64\Release\</OutputPath>
<PlatformTarget>x64</PlatformTarget>
</PropertyGroup>
<ItemGroup>
</ItemGroup>
<Import Project=""$(MSBuildToolsPath)\Microsoft.CSharp.targets"" />
</Project>");
VisualStudio.SolutionExplorer.AddFile(project, "C.cs", open: true);
InvokeFix();
VerifyPropertyInEachConfiguration(GetProjectFileElement(project), "AllowUnsafeBlocks", "true");
}
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Core/Def/Implementation/AnalyzerDependency/IgnorableAssemblyIdentityList.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Generic;
using System.Diagnostics;
using Microsoft.CodeAnalysis;
namespace Microsoft.VisualStudio.LanguageServices.Implementation
{
internal sealed class IgnorableAssemblyIdentityList : IIgnorableAssemblyList
{
private readonly HashSet<AssemblyIdentity> _assemblyIdentities;
public IgnorableAssemblyIdentityList(IEnumerable<AssemblyIdentity> assemblyIdentities)
{
Debug.Assert(assemblyIdentities != null);
_assemblyIdentities = new HashSet<AssemblyIdentity>(assemblyIdentities);
}
public bool Includes(AssemblyIdentity assemblyIdentity)
=> _assemblyIdentities.Contains(assemblyIdentity);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Generic;
using System.Diagnostics;
using Microsoft.CodeAnalysis;
namespace Microsoft.VisualStudio.LanguageServices.Implementation
{
internal sealed class IgnorableAssemblyIdentityList : IIgnorableAssemblyList
{
private readonly HashSet<AssemblyIdentity> _assemblyIdentities;
public IgnorableAssemblyIdentityList(IEnumerable<AssemblyIdentity> assemblyIdentities)
{
Debug.Assert(assemblyIdentities != null);
_assemblyIdentities = new HashSet<AssemblyIdentity>(assemblyIdentities);
}
public bool Includes(AssemblyIdentity assemblyIdentity)
=> _assemblyIdentities.Contains(assemblyIdentity);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/EditorFeatures/VisualBasicTest/AddDebuggerDisplay/AddDebuggerDisplayTests.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports VerifyVB = Microsoft.CodeAnalysis.Editor.UnitTests.CodeActions.VisualBasicCodeRefactoringVerifier(Of
Microsoft.CodeAnalysis.VisualBasic.AddDebuggerDisplay.VisualBasicAddDebuggerDisplayCodeRefactoringProvider)
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.AddDebuggerDisplay
<Trait(Traits.Feature, Traits.Features.CodeActionsAddDebuggerDisplay)>
Public NotInheritable Class AddDebuggerDisplayTests
<Fact>
Public Async Function OfferedOnEmptyClass() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Class C
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function OfferedOnEmptyStruct() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Structure Foo
End Structure", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Structure Foo
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Structure")
End Function
<Fact>
Public Async Function NotOfferedOnModule() As Task
Dim code = "
[||]Module Foo
End Module"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnInterfaceWithToString() As Task
Dim code = "
[||]Interface IFoo
Function ToString() As String
End Interface"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnEnum() As Task
Dim code = "
[||]Enum Foo
None
End Enum"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnDelegate() As Task
Dim code = "
[||]Delegate Sub Foo()"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnUnrelatedClassMembers() As Task
Dim code = "
Class C
[||]Public ReadOnly Property Foo As Integer
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedOnToString() As Task
Await VerifyVB.VerifyRefactoringAsync("
Class C
Public Overrides Function [||]ToString() As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Public Overrides Function ToString() As String
Return ""Foo""
End Function
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function OfferedOnShadowedToString() As Task
Await VerifyVB.VerifyRefactoringAsync("
Class C
Public Shadows Function [||]ToString() As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Public Shadows Function ToString() As String
Return ""Foo""
End Function
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function NotOfferedOnWrongOverloadOfToString() As Task
Dim code = "
Class A
Public Overridable Function ToString(Optional bar As Integer = 0) As String
Return ""Foo""
End Function
End Class
Class B
Inherits A
Public Overrides Function [||]ToString(Optional bar As Integer = 0) As String
Return ""Bar""
End Function
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedOnExistingDebuggerDisplayMethod() As Task
Await VerifyVB.VerifyRefactoringAsync("
Class C
Private Function [||]GetDebuggerDisplay() As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ""Foo""
End Function
End Class")
End Function
<Fact>
Public Async Function NotOfferedOnWrongOverloadOfDebuggerDisplayMethod() As Task
Dim code = "
Class C
Private Function [||]GetDebuggerDisplay(Optional bar As Integer = 0) As String
Return ""Foo""
End Function
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NamespaceImportIsNotDuplicated() As Task
Await VerifyVB.VerifyRefactoringAsync("
Imports System.Diagnostics
[||]Class C
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function NamespaceImportIsSorted() As Task
Await VerifyVB.VerifyRefactoringAsync("
Imports System.Xml
[||]Class C
End Class", "
Imports System.Diagnostics
Imports System.Xml
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function NotOfferedWhenAlreadySpecified() As Task
Dim code = "
<System.Diagnostics.DebuggerDisplay(""Foo"")>
[||]Class C
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedWhenAlreadySpecifiedWithSuffix() As Task
Dim code = "
<System.Diagnostics.DebuggerDisplayAttribute(""Foo"")>
[||]Class C
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedWhenAttributeWithTheSameNameIsSpecified() As Task
Await VerifyVB.VerifyRefactoringAsync("
<{|BC30002:BrokenCode.DebuggerDisplay|}(""Foo"")>
[||]Class C
End Class", "
Imports System.Diagnostics
<{|BC30002:BrokenCode.DebuggerDisplay|}(""Foo"")>
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function OfferedWhenAttributeWithTheSameNameIsSpecifiedWithSuffix() As Task
Await VerifyVB.VerifyRefactoringAsync("
<{|BC30002:BrokenCode.DebuggerDisplayAttribute|}(""Foo"")>
[||]Class C
End Class", "
Imports System.Diagnostics
<{|BC30002:BrokenCode.DebuggerDisplayAttribute|}(""Foo"")>
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function AliasedTypeIsRecognized() As Task
Dim code = "
Imports DD = System.Diagnostics.DebuggerDisplayAttribute
<DD(""Foo"")>
[||]Class C
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedWhenBaseClassHasDebuggerDisplay() As Task
Await VerifyVB.VerifyRefactoringAsync("
Imports System.Diagnostics
<DebuggerDisplay(""Foo"")>
Class A
End Class
[||]Class B
Inherits A
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""Foo"")>
Class A
End Class
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class B
Inherits A
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function ExistingDebuggerDisplayMethodIsUsedEvenWhenPublicSharedNonString() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Class C
Public Shared Function GetDebuggerDisplay() As Object
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Public Shared Function GetDebuggerDisplay() As Object
Return ""Foo""
End Function
End Class")
End Function
<Fact>
Public Async Function ExistingDebuggerDisplayMethodWithParameterIsNotUsed() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Class C
Private Function GetDebuggerDisplay(Optional foo As Integer = 0) As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay(Optional foo As Integer = 0) As String
Return ""Foo""
End Function
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports VerifyVB = Microsoft.CodeAnalysis.Editor.UnitTests.CodeActions.VisualBasicCodeRefactoringVerifier(Of
Microsoft.CodeAnalysis.VisualBasic.AddDebuggerDisplay.VisualBasicAddDebuggerDisplayCodeRefactoringProvider)
Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.UnitTests.AddDebuggerDisplay
<Trait(Traits.Feature, Traits.Features.CodeActionsAddDebuggerDisplay)>
Public NotInheritable Class AddDebuggerDisplayTests
<Fact>
Public Async Function OfferedOnEmptyClass() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Class C
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function OfferedOnEmptyStruct() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Structure Foo
End Structure", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Structure Foo
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Structure")
End Function
<Fact>
Public Async Function NotOfferedOnModule() As Task
Dim code = "
[||]Module Foo
End Module"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnInterfaceWithToString() As Task
Dim code = "
[||]Interface IFoo
Function ToString() As String
End Interface"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnEnum() As Task
Dim code = "
[||]Enum Foo
None
End Enum"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnDelegate() As Task
Dim code = "
[||]Delegate Sub Foo()"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedOnUnrelatedClassMembers() As Task
Dim code = "
Class C
[||]Public ReadOnly Property Foo As Integer
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedOnToString() As Task
Await VerifyVB.VerifyRefactoringAsync("
Class C
Public Overrides Function [||]ToString() As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Public Overrides Function ToString() As String
Return ""Foo""
End Function
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function OfferedOnShadowedToString() As Task
Await VerifyVB.VerifyRefactoringAsync("
Class C
Public Shadows Function [||]ToString() As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Public Shadows Function ToString() As String
Return ""Foo""
End Function
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function NotOfferedOnWrongOverloadOfToString() As Task
Dim code = "
Class A
Public Overridable Function ToString(Optional bar As Integer = 0) As String
Return ""Foo""
End Function
End Class
Class B
Inherits A
Public Overrides Function [||]ToString(Optional bar As Integer = 0) As String
Return ""Bar""
End Function
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedOnExistingDebuggerDisplayMethod() As Task
Await VerifyVB.VerifyRefactoringAsync("
Class C
Private Function [||]GetDebuggerDisplay() As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ""Foo""
End Function
End Class")
End Function
<Fact>
Public Async Function NotOfferedOnWrongOverloadOfDebuggerDisplayMethod() As Task
Dim code = "
Class C
Private Function [||]GetDebuggerDisplay(Optional bar As Integer = 0) As String
Return ""Foo""
End Function
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NamespaceImportIsNotDuplicated() As Task
Await VerifyVB.VerifyRefactoringAsync("
Imports System.Diagnostics
[||]Class C
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function NamespaceImportIsSorted() As Task
Await VerifyVB.VerifyRefactoringAsync("
Imports System.Xml
[||]Class C
End Class", "
Imports System.Diagnostics
Imports System.Xml
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function NotOfferedWhenAlreadySpecified() As Task
Dim code = "
<System.Diagnostics.DebuggerDisplay(""Foo"")>
[||]Class C
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function NotOfferedWhenAlreadySpecifiedWithSuffix() As Task
Dim code = "
<System.Diagnostics.DebuggerDisplayAttribute(""Foo"")>
[||]Class C
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedWhenAttributeWithTheSameNameIsSpecified() As Task
Await VerifyVB.VerifyRefactoringAsync("
<{|BC30002:BrokenCode.DebuggerDisplay|}(""Foo"")>
[||]Class C
End Class", "
Imports System.Diagnostics
<{|BC30002:BrokenCode.DebuggerDisplay|}(""Foo"")>
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function OfferedWhenAttributeWithTheSameNameIsSpecifiedWithSuffix() As Task
Await VerifyVB.VerifyRefactoringAsync("
<{|BC30002:BrokenCode.DebuggerDisplayAttribute|}(""Foo"")>
[||]Class C
End Class", "
Imports System.Diagnostics
<{|BC30002:BrokenCode.DebuggerDisplayAttribute|}(""Foo"")>
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function AliasedTypeIsRecognized() As Task
Dim code = "
Imports DD = System.Diagnostics.DebuggerDisplayAttribute
<DD(""Foo"")>
[||]Class C
End Class"
Await VerifyVB.VerifyRefactoringAsync(code, code)
End Function
<Fact>
Public Async Function OfferedWhenBaseClassHasDebuggerDisplay() As Task
Await VerifyVB.VerifyRefactoringAsync("
Imports System.Diagnostics
<DebuggerDisplay(""Foo"")>
Class A
End Class
[||]Class B
Inherits A
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""Foo"")>
Class A
End Class
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class B
Inherits A
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
<Fact>
Public Async Function ExistingDebuggerDisplayMethodIsUsedEvenWhenPublicSharedNonString() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Class C
Public Shared Function GetDebuggerDisplay() As Object
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Public Shared Function GetDebuggerDisplay() As Object
Return ""Foo""
End Function
End Class")
End Function
<Fact>
Public Async Function ExistingDebuggerDisplayMethodWithParameterIsNotUsed() As Task
Await VerifyVB.VerifyRefactoringAsync("
[||]Class C
Private Function GetDebuggerDisplay(Optional foo As Integer = 0) As String
Return ""Foo""
End Function
End Class", "
Imports System.Diagnostics
<DebuggerDisplay(""{GetDebuggerDisplay(),nq}"")>
Class C
Private Function GetDebuggerDisplay(Optional foo As Integer = 0) As String
Return ""Foo""
End Function
Private Function GetDebuggerDisplay() As String
Return ToString()
End Function
End Class")
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/VisualBasic/Impl/CodeModel/Extenders/CodeTypeLocationExtender.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Runtime.InteropServices
Imports Microsoft.VisualStudio.LanguageServices.Implementation.Interop
Imports Microsoft.VisualStudio.LanguageServices.VisualBasic.CodeModel.Interop
Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.CodeModel.Extenders
<ComVisible(True)>
<ComDefaultInterface(GetType(IVBCodeTypeLocation))>
Public Class CodeTypeLocationExtender
Implements IVBCodeTypeLocation
Friend Shared Function Create(externalLocation As String) As IVBCodeTypeLocation
Dim result = New CodeTypeLocationExtender(externalLocation)
Return CType(ComAggregate.CreateAggregatedObject(result), IVBCodeTypeLocation)
End Function
Private ReadOnly _externalLocation As String
Private Sub New(externalLocation As String)
_externalLocation = externalLocation
End Sub
Public ReadOnly Property ExternalLocation As String Implements IVBCodeTypeLocation.ExternalLocation
Get
Return _externalLocation
End Get
End Property
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Runtime.InteropServices
Imports Microsoft.VisualStudio.LanguageServices.Implementation.Interop
Imports Microsoft.VisualStudio.LanguageServices.VisualBasic.CodeModel.Interop
Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.CodeModel.Extenders
<ComVisible(True)>
<ComDefaultInterface(GetType(IVBCodeTypeLocation))>
Public Class CodeTypeLocationExtender
Implements IVBCodeTypeLocation
Friend Shared Function Create(externalLocation As String) As IVBCodeTypeLocation
Dim result = New CodeTypeLocationExtender(externalLocation)
Return CType(ComAggregate.CreateAggregatedObject(result), IVBCodeTypeLocation)
End Function
Private ReadOnly _externalLocation As String
Private Sub New(externalLocation As String)
_externalLocation = externalLocation
End Sub
Public ReadOnly Property ExternalLocation As String Implements IVBCodeTypeLocation.ExternalLocation
Get
Return _externalLocation
End Get
End Property
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/Core/Portable/RQName/RQNameStrings.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
namespace Microsoft.CodeAnalysis.Features.RQName
{
internal sealed class RQNameStrings
{
internal const string Namespace = "Ns";
internal const string Agg = "Agg";
internal const string MembVar = "Membvar";
internal const string Event = "Event";
internal const string Meth = "Meth";
internal const string Prop = "Prop";
internal const string Params = "Params";
internal const string Param = "Param";
internal const string ParamMod = "ParamMod";
internal const string AggType = "AggType";
internal const string TypeParams = "TypeParams";
internal const string Array = "Array";
internal const string Pointer = "Ptr";
internal const string Ref = "Ref";
internal const string Out = "Out";
internal const string TyVar = "TyVar";
internal const string Void = "Void";
internal const string Error = "Error";
internal const string Null = "Null";
internal const string Dynamic = "::dynamic";
internal const string NsName = "NsName";
internal const string AggName = "AggName";
internal const string MembVarName = "MembvarName";
internal const string MethName = "MethName";
internal const string PropName = "PropName";
internal const string EventName = "EventName";
internal const string IntfExplName = "IntfExplName";
internal const string TypeVarCnt = "TypeVarCnt";
internal const string MemberParamIndex = "MemberParamIndex";
internal const string NotPartial = "NotPartial";
internal const string PartialSignature = "PartialSignature";
internal const string PartialImplementation = "PartialImplementation";
// special names used by the compiler
internal const string SpecialIndexerName = "$Item$";
internal const string SpecialConstructorName = ".ctor";
internal const string SpecialDestructorName = "Finalize";
internal const string SpecialStaticConstructorName = ".cctor";
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
namespace Microsoft.CodeAnalysis.Features.RQName
{
internal sealed class RQNameStrings
{
internal const string Namespace = "Ns";
internal const string Agg = "Agg";
internal const string MembVar = "Membvar";
internal const string Event = "Event";
internal const string Meth = "Meth";
internal const string Prop = "Prop";
internal const string Params = "Params";
internal const string Param = "Param";
internal const string ParamMod = "ParamMod";
internal const string AggType = "AggType";
internal const string TypeParams = "TypeParams";
internal const string Array = "Array";
internal const string Pointer = "Ptr";
internal const string Ref = "Ref";
internal const string Out = "Out";
internal const string TyVar = "TyVar";
internal const string Void = "Void";
internal const string Error = "Error";
internal const string Null = "Null";
internal const string Dynamic = "::dynamic";
internal const string NsName = "NsName";
internal const string AggName = "AggName";
internal const string MembVarName = "MembvarName";
internal const string MethName = "MethName";
internal const string PropName = "PropName";
internal const string EventName = "EventName";
internal const string IntfExplName = "IntfExplName";
internal const string TypeVarCnt = "TypeVarCnt";
internal const string MemberParamIndex = "MemberParamIndex";
internal const string NotPartial = "NotPartial";
internal const string PartialSignature = "PartialSignature";
internal const string PartialImplementation = "PartialImplementation";
// special names used by the compiler
internal const string SpecialIndexerName = "$Item$";
internal const string SpecialConstructorName = ".ctor";
internal const string SpecialDestructorName = "Finalize";
internal const string SpecialStaticConstructorName = ".cctor";
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Compilers/VisualBasic/Portable/Locations/EmbeddedTreeLocation.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic
''' <summary>
''' A program location in source code.
''' </summary>
Friend NotInheritable Class EmbeddedTreeLocation
Inherits VBLocation
Friend ReadOnly _embeddedKind As EmbeddedSymbolKind
Friend ReadOnly _span As TextSpan
Public Overrides ReadOnly Property Kind As LocationKind
Get
Return LocationKind.None
End Get
End Property
Friend Overrides ReadOnly Property EmbeddedKind As EmbeddedSymbolKind
Get
Return _embeddedKind
End Get
End Property
Friend Overrides ReadOnly Property PossiblyEmbeddedOrMySourceSpan As TextSpan
Get
Return _span
End Get
End Property
Friend Overrides ReadOnly Property PossiblyEmbeddedOrMySourceTree As SyntaxTree
Get
Return EmbeddedSymbolManager.GetEmbeddedTree(Me._embeddedKind)
End Get
End Property
Public Sub New(embeddedKind As EmbeddedSymbolKind, span As TextSpan)
Debug.Assert(embeddedKind = EmbeddedSymbolKind.VbCore OrElse
embeddedKind = EmbeddedSymbolKind.XmlHelper OrElse
embeddedKind = EmbeddedSymbolKind.EmbeddedAttribute)
_embeddedKind = embeddedKind
_span = span
End Sub
Public Overloads Function Equals(other As EmbeddedTreeLocation) As Boolean
If Me Is other Then
Return True
End If
Return other IsNot Nothing AndAlso other.EmbeddedKind = Me._embeddedKind AndAlso other._span.Equals(Me._span)
End Function
Public Overloads Overrides Function Equals(obj As Object) As Boolean
Return Me.Equals(TryCast(obj, EmbeddedTreeLocation))
End Function
Public Overrides Function GetHashCode() As Integer
Return Hash.Combine(CInt(_embeddedKind).GetHashCode(), _span.GetHashCode())
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports Microsoft.CodeAnalysis.Text
Imports Microsoft.CodeAnalysis.VisualBasic.Symbols
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Namespace Microsoft.CodeAnalysis.VisualBasic
''' <summary>
''' A program location in source code.
''' </summary>
Friend NotInheritable Class EmbeddedTreeLocation
Inherits VBLocation
Friend ReadOnly _embeddedKind As EmbeddedSymbolKind
Friend ReadOnly _span As TextSpan
Public Overrides ReadOnly Property Kind As LocationKind
Get
Return LocationKind.None
End Get
End Property
Friend Overrides ReadOnly Property EmbeddedKind As EmbeddedSymbolKind
Get
Return _embeddedKind
End Get
End Property
Friend Overrides ReadOnly Property PossiblyEmbeddedOrMySourceSpan As TextSpan
Get
Return _span
End Get
End Property
Friend Overrides ReadOnly Property PossiblyEmbeddedOrMySourceTree As SyntaxTree
Get
Return EmbeddedSymbolManager.GetEmbeddedTree(Me._embeddedKind)
End Get
End Property
Public Sub New(embeddedKind As EmbeddedSymbolKind, span As TextSpan)
Debug.Assert(embeddedKind = EmbeddedSymbolKind.VbCore OrElse
embeddedKind = EmbeddedSymbolKind.XmlHelper OrElse
embeddedKind = EmbeddedSymbolKind.EmbeddedAttribute)
_embeddedKind = embeddedKind
_span = span
End Sub
Public Overloads Function Equals(other As EmbeddedTreeLocation) As Boolean
If Me Is other Then
Return True
End If
Return other IsNot Nothing AndAlso other.EmbeddedKind = Me._embeddedKind AndAlso other._span.Equals(Me._span)
End Function
Public Overloads Overrides Function Equals(obj As Object) As Boolean
Return Me.Equals(TryCast(obj, EmbeddedTreeLocation))
End Function
Public Overrides Function GetHashCode() As Integer
Return Hash.Combine(CInt(_embeddedKind).GetHashCode(), _span.GetHashCode())
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./docs/wiki/Branch-Cleanup.md | This documents the various branches we've pruned and their HEAD value at the time of pruning
|Commit|Branch Name|
|--|--|
|a26198da1811337fc41e30ee1c7fcdf97d8fae76|refs/remotes/origin/OptimizeFlowAnalysis|
|0f86e670c29af3cd2352ac2372303694261463cc|refs/remotes/origin/dev/dpoeschl/0f86e670|
|1af7ade35b8cea6c3c57243d6bec10f48a3cdf20|refs/remotes/origin/dev/dpoeschl/1af7ade|
|3bdbd56045a21888b9cdd70b420f8ff5b711da77|refs/remotes/origin/dev/dpoeschl/3bdbd56|
|4f1fb3f049d08d958b0baaa6528c79665b6e90bb|refs/remotes/origin/dev/dpoeschl/4f1fb3f|
|77fcd78710737c6d5f27f4767a35997d853d2100|refs/remotes/origin/dev/dpoeschl/77fcd78|
|902d608f3b8837728eac5bc3171a56e82cafd268|refs/remotes/origin/dev/dpoeschl/902d608|
|902d608f3b8837728eac5bc3171a56e82cafd268|refs/remotes/origin/dev/dpoeschl/902d608f|
|94aca843f09b84dd129f5e8719e26abb09e34d93|refs/remotes/origin/dev/dpoeschl/95aca84|
|b252adb7e108e504b5594373ba91e08b15aef43f|refs/remotes/origin/dev/dpoeschl/b252adb|
|b252adb7e108e504b5594373ba91e08b15aef43f|refs/remotes/origin/dev/dpoeschl/b252adb7|
|f7cdea80d4ad7b10ef3c3bde761551d1b75a5138|refs/remotes/origin/dev/jaredpar/fix-official|
|e7b4c9e4324537f158dfd1cc4dd17d883fec6e89|refs/remotes/origin/dev/jaredpar/fix-pack|
|6285f29c24b03e84b66d2c69241bd56f9f19c449|refs/remotes/origin/dev/jaredpar/fix-process|
|25cb2c3fd309e7337645f5e234356cfe4e3a48fe|refs/remotes/origin/dev/jaredpar/fix-publish|
|02ffde64be39a723e1be7d5196346fd10adc010d|refs/remotes/origin/dev/jaredpar/fix-queue|
|ce4496abee2461b1d0aaadff424bf38b3d8d72af|refs/remotes/origin/dev/jaredpar/fix-sign|
|358e3eae5e7d70b9ecceef4e7a4682b49a8af05b|refs/remotes/origin/dev/jorobich/publish-dotnet-format|
|a10cc5bdd7fd69610445ea7ffdc9f7f3b6da84a8|refs/remotes/origin/dev/jorobich/skip-enc-tests|
|558ab26a6e49a350f28ae5af603ab7dce3bcbb59|refs/remotes/origin/dev/jorobich/skip-verifypreviousandnexthistory|
|5df75b1993db2973a7e9642c5420d323957066f2|refs/remotes/origin/dev/jorobich/update-build-sdk|
|be512b6966d06ff9ad641def121294ec6feea243|refs/remotes/origin/dev/jorobich/update-cert|
|97967e2b6e5f26bf86ce50bc987bf12f25de8115|refs/remotes/origin/dev/jorobich/update-dependencies|
|b3049770412849428df6691341a7fbcddfb37ea5|refs/remotes/origin/dev/rigibson/cloudbuild-triage-1|
|020f1a2af79b5a3ac0b573f5d3770893191d91df|refs/remotes/origin/dev/rigibson/optprof-triage|
|dc15c56d6fa884462de17ec440b9718840966fa1|refs/remotes/origin/dev/sharwell/vs-threading-analyzers|
|dcd571259aed1e4441f87a308305d3e29d2b3136|refs/remotes/origin/dev/shech/localization|
|3b369f41d440eb3fca98859b1ecd2678cd0331c1|refs/remotes/origin/dev15-rc2|
|b7d3e5b3527463259f9c5ac5817b3461200aff34|refs/remotes/origin/dev15-rc3|
|8f02e04893c4b53cf6ca11b064848888365914d3|refs/remotes/origin/dev15.3-preview1|
|3722bb710cae2b542cc2004aacd5ac21836592a4|refs/remotes/origin/dev15.3-preview2|
|291228b08260e8ca2d83368cace16c5f81d783ce|refs/remotes/origin/dev15.5-preview1-staging|
|4939752b756ad32cb2ce1bfeab1d4f1637966e08|refs/remotes/origin/dev15.6-preview1-vs-deps|
|c9179f863872ab69b6ecf82c056e31d6b28b4c59|refs/remotes/origin/dev15.6-preview2|
|494bbc7b05c81632a53b7875321de852f5772a52|refs/remotes/origin/dev15.6-preview2-vs-deps|
|a213194a975b4fb7d3327997eaf2e5c4b046b425|refs/remotes/origin/dev15.6-preview3|
|d04459093177b0e083f8c83b18269d3a866e924e|refs/remotes/origin/dev15.6-preview3-vs-deps|
|77bf781f9842082f09ba60a375e00922d018e060|refs/remotes/origin/dev15.7-preview1|
|1c225824f784723b351183e38cae410a920ccb02|refs/remotes/origin/dev15.7-preview1-vs-deps|
|25e40f0169a8047b7d3524b30339f89b3b428551|refs/remotes/origin/dev15.7-preview3|
|dcb76074e823074e0244631a99c114bf564aea4d|refs/remotes/origin/dev15.7-preview3-vs-deps|
|0c47f55c9b3d83f218af1535638d7a97551bbc9d|refs/remotes/origin/dev15.8-preview4|
|6ebf816edcd56f60277d1aa2500aa123565f43e4|refs/remotes/origin/dev15.8-preview4-vs-deps|
|567062dbe394c983861cb27b337b0a7f3b044638|refs/remotes/origin/dev15.9-preview1|
|8ea354e01fd4c1eefcbc62646ff24857f986e1b3|refs/remotes/origin/dev15.9-preview1-vs-deps|
|6f8f466fe841045827a068cda01870fa408c094c|refs/remotes/origin/dev15.9-preview2|
|e8e91648afe095b019b5347a2b1d0dca5696cbf1|refs/remotes/origin/dev15.9-preview2-vs-deps|
|0816fdc029f0f4b973ac6cbf08c398e91aa593e6|refs/remotes/origin/dev15.9-preview3|
|750236a7562d8fd0d5efe311c52ae0703093165f|refs/remotes/origin/dev15.9-preview3-vs-deps|
|7ae99c29074e5c3b69a761a0a94f9fd05d02c127|refs/remotes/origin/dev16.0-preview2|
|231aeb8be8357239499d45c0574e5a9a8c9174f0|refs/remotes/origin/dev16.0-preview2-vs-deps|
|5f1828a597d7bb5c50057fa6a3177ee27344b655|refs/remotes/origin/dev16.0-preview3|
|9ad945d6557416a83d1e6efea0e75b7e40786cd0|refs/remotes/origin/dev16.0-preview3-vs-deps|
|8c8228f836415435319ce6331d9baa592595f958|refs/remotes/origin/dev16.1-preview1|
|0d0406b2be22b6a544c77c3ee868ad8065765e96|refs/remotes/origin/dev16.1-preview2|
|c2ec4d9f980971823190ece3a158c398900944bf|refs/remotes/origin/dev16.1-preview3|
|d7c19ee5956b9f7debdd139c6606c44c598794a7|refs/remotes/origin/features/AnnotatedTypes|
|aee400d17aff7118ae908f4e9cd717751ae2d996|refs/remotes/origin/features/DefaultInterfaceImplementation|
|66df38c26d56de3e475ec16e5bc911c58705caf4|refs/remotes/origin/features/ExpressionVariables|
|34142dc2956248669605b2dc2e23996e174b662c|refs/remotes/origin/features/IVTCompletionTests|
|def06e4bd7f53ab7989bd0c86505aac6f80d9e95|refs/remotes/origin/features/NegatedConditionStatements|
|14505f0f026c6c139fe46bc7fb83c7c2e907e0bc|refs/remotes/origin/features/dataflow|
|416f53042eedcbc5cd620c4cd02caaccb35dc8c3|refs/remotes/origin/features/nullable-common|
|d27cfde4f19a171aef088b87afa67e7c5af1121b|refs/remotes/origin/features/ref-partial|
|f0c9802f78c5d4965577975a7d772845c95528a4|refs/remotes/origin/features/ref-reassignment|
|56502b6a68c8f9be3a19a2dd350404957809c6b3|refs/remotes/origin/features/verification|
|fbfa64c8d43af45c4122759c01becd5638b08b8f|refs/remotes/origin/ide-dataflow-analyzer|
|d36bbf81ddde6b54fb10807ae9e14f10c76804a0|refs/remotes/origin/infrastructure/optprof|
|ca83e06a93c75cfaf602112487fd471ab9e748c9|refs/remotes/origin/netcore2.1-preview2|
|f2f0c3553fbb5974e2cc978210f71b2863bbcac2|refs/remotes/origin/release/dev16.2-preview1|
|3add46757cb3d5c7844d889af24fa905656cf574|refs/remotes/origin/release/dev16.2-preview2|
|42ddc197c9bf47ef73b74c644522945646bb6b1f|refs/remotes/origin/release/dev16.2-preview3|
|d5db676f73abef4cf8d0d80703eca0392a10d7e3|refs/remotes/origin/remove-lspSupport|
|83bebeb607cb55e8fcacc83210636ebe3a403f8d|refs/remotes/origin/revert-36006-extract_open_file_tracker|
|8cc031276414977b79e604c4e2cf9d6670a15783|refs/remotes/origin/simpletagnostic| | This documents the various branches we've pruned and their HEAD value at the time of pruning
|Commit|Branch Name|
|--|--|
|a26198da1811337fc41e30ee1c7fcdf97d8fae76|refs/remotes/origin/OptimizeFlowAnalysis|
|0f86e670c29af3cd2352ac2372303694261463cc|refs/remotes/origin/dev/dpoeschl/0f86e670|
|1af7ade35b8cea6c3c57243d6bec10f48a3cdf20|refs/remotes/origin/dev/dpoeschl/1af7ade|
|3bdbd56045a21888b9cdd70b420f8ff5b711da77|refs/remotes/origin/dev/dpoeschl/3bdbd56|
|4f1fb3f049d08d958b0baaa6528c79665b6e90bb|refs/remotes/origin/dev/dpoeschl/4f1fb3f|
|77fcd78710737c6d5f27f4767a35997d853d2100|refs/remotes/origin/dev/dpoeschl/77fcd78|
|902d608f3b8837728eac5bc3171a56e82cafd268|refs/remotes/origin/dev/dpoeschl/902d608|
|902d608f3b8837728eac5bc3171a56e82cafd268|refs/remotes/origin/dev/dpoeschl/902d608f|
|94aca843f09b84dd129f5e8719e26abb09e34d93|refs/remotes/origin/dev/dpoeschl/95aca84|
|b252adb7e108e504b5594373ba91e08b15aef43f|refs/remotes/origin/dev/dpoeschl/b252adb|
|b252adb7e108e504b5594373ba91e08b15aef43f|refs/remotes/origin/dev/dpoeschl/b252adb7|
|f7cdea80d4ad7b10ef3c3bde761551d1b75a5138|refs/remotes/origin/dev/jaredpar/fix-official|
|e7b4c9e4324537f158dfd1cc4dd17d883fec6e89|refs/remotes/origin/dev/jaredpar/fix-pack|
|6285f29c24b03e84b66d2c69241bd56f9f19c449|refs/remotes/origin/dev/jaredpar/fix-process|
|25cb2c3fd309e7337645f5e234356cfe4e3a48fe|refs/remotes/origin/dev/jaredpar/fix-publish|
|02ffde64be39a723e1be7d5196346fd10adc010d|refs/remotes/origin/dev/jaredpar/fix-queue|
|ce4496abee2461b1d0aaadff424bf38b3d8d72af|refs/remotes/origin/dev/jaredpar/fix-sign|
|358e3eae5e7d70b9ecceef4e7a4682b49a8af05b|refs/remotes/origin/dev/jorobich/publish-dotnet-format|
|a10cc5bdd7fd69610445ea7ffdc9f7f3b6da84a8|refs/remotes/origin/dev/jorobich/skip-enc-tests|
|558ab26a6e49a350f28ae5af603ab7dce3bcbb59|refs/remotes/origin/dev/jorobich/skip-verifypreviousandnexthistory|
|5df75b1993db2973a7e9642c5420d323957066f2|refs/remotes/origin/dev/jorobich/update-build-sdk|
|be512b6966d06ff9ad641def121294ec6feea243|refs/remotes/origin/dev/jorobich/update-cert|
|97967e2b6e5f26bf86ce50bc987bf12f25de8115|refs/remotes/origin/dev/jorobich/update-dependencies|
|b3049770412849428df6691341a7fbcddfb37ea5|refs/remotes/origin/dev/rigibson/cloudbuild-triage-1|
|020f1a2af79b5a3ac0b573f5d3770893191d91df|refs/remotes/origin/dev/rigibson/optprof-triage|
|dc15c56d6fa884462de17ec440b9718840966fa1|refs/remotes/origin/dev/sharwell/vs-threading-analyzers|
|dcd571259aed1e4441f87a308305d3e29d2b3136|refs/remotes/origin/dev/shech/localization|
|3b369f41d440eb3fca98859b1ecd2678cd0331c1|refs/remotes/origin/dev15-rc2|
|b7d3e5b3527463259f9c5ac5817b3461200aff34|refs/remotes/origin/dev15-rc3|
|8f02e04893c4b53cf6ca11b064848888365914d3|refs/remotes/origin/dev15.3-preview1|
|3722bb710cae2b542cc2004aacd5ac21836592a4|refs/remotes/origin/dev15.3-preview2|
|291228b08260e8ca2d83368cace16c5f81d783ce|refs/remotes/origin/dev15.5-preview1-staging|
|4939752b756ad32cb2ce1bfeab1d4f1637966e08|refs/remotes/origin/dev15.6-preview1-vs-deps|
|c9179f863872ab69b6ecf82c056e31d6b28b4c59|refs/remotes/origin/dev15.6-preview2|
|494bbc7b05c81632a53b7875321de852f5772a52|refs/remotes/origin/dev15.6-preview2-vs-deps|
|a213194a975b4fb7d3327997eaf2e5c4b046b425|refs/remotes/origin/dev15.6-preview3|
|d04459093177b0e083f8c83b18269d3a866e924e|refs/remotes/origin/dev15.6-preview3-vs-deps|
|77bf781f9842082f09ba60a375e00922d018e060|refs/remotes/origin/dev15.7-preview1|
|1c225824f784723b351183e38cae410a920ccb02|refs/remotes/origin/dev15.7-preview1-vs-deps|
|25e40f0169a8047b7d3524b30339f89b3b428551|refs/remotes/origin/dev15.7-preview3|
|dcb76074e823074e0244631a99c114bf564aea4d|refs/remotes/origin/dev15.7-preview3-vs-deps|
|0c47f55c9b3d83f218af1535638d7a97551bbc9d|refs/remotes/origin/dev15.8-preview4|
|6ebf816edcd56f60277d1aa2500aa123565f43e4|refs/remotes/origin/dev15.8-preview4-vs-deps|
|567062dbe394c983861cb27b337b0a7f3b044638|refs/remotes/origin/dev15.9-preview1|
|8ea354e01fd4c1eefcbc62646ff24857f986e1b3|refs/remotes/origin/dev15.9-preview1-vs-deps|
|6f8f466fe841045827a068cda01870fa408c094c|refs/remotes/origin/dev15.9-preview2|
|e8e91648afe095b019b5347a2b1d0dca5696cbf1|refs/remotes/origin/dev15.9-preview2-vs-deps|
|0816fdc029f0f4b973ac6cbf08c398e91aa593e6|refs/remotes/origin/dev15.9-preview3|
|750236a7562d8fd0d5efe311c52ae0703093165f|refs/remotes/origin/dev15.9-preview3-vs-deps|
|7ae99c29074e5c3b69a761a0a94f9fd05d02c127|refs/remotes/origin/dev16.0-preview2|
|231aeb8be8357239499d45c0574e5a9a8c9174f0|refs/remotes/origin/dev16.0-preview2-vs-deps|
|5f1828a597d7bb5c50057fa6a3177ee27344b655|refs/remotes/origin/dev16.0-preview3|
|9ad945d6557416a83d1e6efea0e75b7e40786cd0|refs/remotes/origin/dev16.0-preview3-vs-deps|
|8c8228f836415435319ce6331d9baa592595f958|refs/remotes/origin/dev16.1-preview1|
|0d0406b2be22b6a544c77c3ee868ad8065765e96|refs/remotes/origin/dev16.1-preview2|
|c2ec4d9f980971823190ece3a158c398900944bf|refs/remotes/origin/dev16.1-preview3|
|d7c19ee5956b9f7debdd139c6606c44c598794a7|refs/remotes/origin/features/AnnotatedTypes|
|aee400d17aff7118ae908f4e9cd717751ae2d996|refs/remotes/origin/features/DefaultInterfaceImplementation|
|66df38c26d56de3e475ec16e5bc911c58705caf4|refs/remotes/origin/features/ExpressionVariables|
|34142dc2956248669605b2dc2e23996e174b662c|refs/remotes/origin/features/IVTCompletionTests|
|def06e4bd7f53ab7989bd0c86505aac6f80d9e95|refs/remotes/origin/features/NegatedConditionStatements|
|14505f0f026c6c139fe46bc7fb83c7c2e907e0bc|refs/remotes/origin/features/dataflow|
|416f53042eedcbc5cd620c4cd02caaccb35dc8c3|refs/remotes/origin/features/nullable-common|
|d27cfde4f19a171aef088b87afa67e7c5af1121b|refs/remotes/origin/features/ref-partial|
|f0c9802f78c5d4965577975a7d772845c95528a4|refs/remotes/origin/features/ref-reassignment|
|56502b6a68c8f9be3a19a2dd350404957809c6b3|refs/remotes/origin/features/verification|
|fbfa64c8d43af45c4122759c01becd5638b08b8f|refs/remotes/origin/ide-dataflow-analyzer|
|d36bbf81ddde6b54fb10807ae9e14f10c76804a0|refs/remotes/origin/infrastructure/optprof|
|ca83e06a93c75cfaf602112487fd471ab9e748c9|refs/remotes/origin/netcore2.1-preview2|
|f2f0c3553fbb5974e2cc978210f71b2863bbcac2|refs/remotes/origin/release/dev16.2-preview1|
|3add46757cb3d5c7844d889af24fa905656cf574|refs/remotes/origin/release/dev16.2-preview2|
|42ddc197c9bf47ef73b74c644522945646bb6b1f|refs/remotes/origin/release/dev16.2-preview3|
|d5db676f73abef4cf8d0d80703eca0392a10d7e3|refs/remotes/origin/remove-lspSupport|
|83bebeb607cb55e8fcacc83210636ebe3a403f8d|refs/remotes/origin/revert-36006-extract_open_file_tracker|
|8cc031276414977b79e604c4e2cf9d6670a15783|refs/remotes/origin/simpletagnostic| | -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Workspaces/Core/Portable/FindSymbols/IRemoteSymbolFinderService.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Remote;
using Microsoft.CodeAnalysis.Text;
namespace Microsoft.CodeAnalysis.FindSymbols
{
internal interface IRemoteSymbolFinderService
{
internal interface ICallback
{
ValueTask AddReferenceItemsAsync(RemoteServiceCallbackId callbackId, int count, CancellationToken cancellationToken);
ValueTask ReferenceItemCompletedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnStartedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnCompletedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnFindInDocumentStartedAsync(RemoteServiceCallbackId callbackId, DocumentId documentId, CancellationToken cancellationToken);
ValueTask OnFindInDocumentCompletedAsync(RemoteServiceCallbackId callbackId, DocumentId documentId, CancellationToken cancellationToken);
ValueTask OnDefinitionFoundAsync(RemoteServiceCallbackId callbackId, SerializableSymbolGroup group, CancellationToken cancellationToken);
ValueTask OnReferenceFoundAsync(RemoteServiceCallbackId callbackId, SerializableSymbolGroup group, SerializableSymbolAndProjectId definition, SerializableReferenceLocation reference, CancellationToken cancellationToken);
ValueTask AddLiteralItemsAsync(RemoteServiceCallbackId callbackId, int count, CancellationToken cancellationToken);
ValueTask LiteralItemCompletedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnLiteralReferenceFoundAsync(RemoteServiceCallbackId callbackId, DocumentId documentId, TextSpan span, CancellationToken cancellationToken);
}
ValueTask FindReferencesAsync(PinnedSolutionInfo solutionInfo, RemoteServiceCallbackId callbackId, SerializableSymbolAndProjectId symbolAndProjectIdArg, ImmutableArray<DocumentId> documentArgs,
FindReferencesSearchOptions options, CancellationToken cancellationToken);
ValueTask FindLiteralReferencesAsync(PinnedSolutionInfo solutionInfo, RemoteServiceCallbackId callbackId, object value, TypeCode typeCode, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindAllDeclarationsWithNormalQueryAsync(
PinnedSolutionInfo solutionInfo, ProjectId projectId, string name, SearchKind searchKind, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindSolutionSourceDeclarationsWithNormalQueryAsync(
PinnedSolutionInfo solutionInfo, string name, bool ignoreCase, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindProjectSourceDeclarationsWithNormalQueryAsync(
PinnedSolutionInfo solutionInfo, ProjectId projectId, string name, bool ignoreCase, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindSolutionSourceDeclarationsWithPatternAsync(
PinnedSolutionInfo solutionInfo, string pattern, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindProjectSourceDeclarationsWithPatternAsync(
PinnedSolutionInfo solutionInfo, ProjectId projectId, string pattern, SymbolFilter criteria, CancellationToken cancellationToken);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Remote;
using Microsoft.CodeAnalysis.Text;
namespace Microsoft.CodeAnalysis.FindSymbols
{
internal interface IRemoteSymbolFinderService
{
internal interface ICallback
{
ValueTask AddReferenceItemsAsync(RemoteServiceCallbackId callbackId, int count, CancellationToken cancellationToken);
ValueTask ReferenceItemCompletedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnStartedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnCompletedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnFindInDocumentStartedAsync(RemoteServiceCallbackId callbackId, DocumentId documentId, CancellationToken cancellationToken);
ValueTask OnFindInDocumentCompletedAsync(RemoteServiceCallbackId callbackId, DocumentId documentId, CancellationToken cancellationToken);
ValueTask OnDefinitionFoundAsync(RemoteServiceCallbackId callbackId, SerializableSymbolGroup group, CancellationToken cancellationToken);
ValueTask OnReferenceFoundAsync(RemoteServiceCallbackId callbackId, SerializableSymbolGroup group, SerializableSymbolAndProjectId definition, SerializableReferenceLocation reference, CancellationToken cancellationToken);
ValueTask AddLiteralItemsAsync(RemoteServiceCallbackId callbackId, int count, CancellationToken cancellationToken);
ValueTask LiteralItemCompletedAsync(RemoteServiceCallbackId callbackId, CancellationToken cancellationToken);
ValueTask OnLiteralReferenceFoundAsync(RemoteServiceCallbackId callbackId, DocumentId documentId, TextSpan span, CancellationToken cancellationToken);
}
ValueTask FindReferencesAsync(PinnedSolutionInfo solutionInfo, RemoteServiceCallbackId callbackId, SerializableSymbolAndProjectId symbolAndProjectIdArg, ImmutableArray<DocumentId> documentArgs,
FindReferencesSearchOptions options, CancellationToken cancellationToken);
ValueTask FindLiteralReferencesAsync(PinnedSolutionInfo solutionInfo, RemoteServiceCallbackId callbackId, object value, TypeCode typeCode, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindAllDeclarationsWithNormalQueryAsync(
PinnedSolutionInfo solutionInfo, ProjectId projectId, string name, SearchKind searchKind, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindSolutionSourceDeclarationsWithNormalQueryAsync(
PinnedSolutionInfo solutionInfo, string name, bool ignoreCase, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindProjectSourceDeclarationsWithNormalQueryAsync(
PinnedSolutionInfo solutionInfo, ProjectId projectId, string name, bool ignoreCase, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindSolutionSourceDeclarationsWithPatternAsync(
PinnedSolutionInfo solutionInfo, string pattern, SymbolFilter criteria, CancellationToken cancellationToken);
ValueTask<ImmutableArray<SerializableSymbolAndProjectId>> FindProjectSourceDeclarationsWithPatternAsync(
PinnedSolutionInfo solutionInfo, ProjectId projectId, string pattern, SymbolFilter criteria, CancellationToken cancellationToken);
}
}
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/Features/VisualBasic/Portable/Debugging/BreakpointResolver.vb | ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Microsoft.CodeAnalysis.Debugging
Namespace Microsoft.CodeAnalysis.VisualBasic.Debugging
Friend Class BreakpointResolver
Inherits AbstractBreakpointResolver
Private Shared ReadOnly s_identifierComparer As IEqualityComparer(Of String) = CaseInsensitiveComparison.Comparer
Public Sub New(solution As Solution, text As String)
MyBase.New(solution, text, LanguageNames.VisualBasic, s_identifierComparer)
End Sub
Protected Overrides Function GetMembers(type As INamedTypeSymbol, name As String) As IEnumerable(Of ISymbol)
Dim members = type.GetMembers(name)
Return If(s_identifierComparer.Equals(name, SyntaxFacts.GetText(SyntaxKind.NewKeyword)),
members.Concat(type.Constructors),
members)
End Function
Protected Overrides Function HasMethodBody(method As IMethodSymbol, cancellationToken As CancellationToken) As Boolean
Dim location = method.Locations.First(Function(loc) loc.IsInSource)
Dim tree = location.SourceTree
Dim token = tree.GetRoot(cancellationToken).FindToken(location.SourceSpan.Start)
Dim methodBlock = token.GetAncestor(Of MethodBlockBaseSyntax)()
' If there is no syntactic body then, obviously, False...
If methodBlock Is Nothing Then
Return False
End If
' In VB, Partial method definitions have a syntactic body, but for the purpose of setting breakpoints in code,
' they should not be considered to have a body (because there is no executable code associated with them).
If methodBlock.BlockStatement.Modifiers.Any(Function(t) t.IsKind(SyntaxKind.PartialKeyword)) Then
Return False
End If
Return True
End Function
Protected Overrides Sub ParseText(ByRef nameParts As IList(Of NameAndArity), ByRef parameterCount As Integer?)
Dim text As String = Me.Text
Debug.Assert(text IsNot Nothing)
Dim name = SyntaxFactory.ParseName(Me.Text, consumeFullText:=False)
Dim lengthOfParsedText = name.FullSpan.End
Dim parameterList = ParseParameterList(Me.Text, lengthOfParsedText)
Dim foundIncompleteParameterList = False
parameterCount = Nothing
If parameterList IsNot Nothing Then
If (parameterList.OpenParenToken.IsMissing OrElse parameterList.CloseParenToken.IsMissing) Then
foundIncompleteParameterList = True
Else
lengthOfParsedText += parameterList.FullSpan.End
parameterCount = parameterList.Parameters.Count
End If
End If
' It's not obvious, but this method can handle the case were name "IsMissing" (no suitable name was be parsed).
Dim parts = name.GetNameParts()
' If we could not parse a valid parameter list or there was additional trailing text that could not be
' interpreted, don't return any names or parameters.
' Also, "Break at Function" doesn't seem to support names prefixed with "Global" with the old language service.
' Since it doesn't seem necessary to disambiguate symbols in this scenario (there's UI to do it), I'm going to
' explicitly ignore names with a Global namespace prefix. If we want to correctly support Global, we'd need to
' also modify the logic in FindMembersAsync to support exact matches on type name. "Global" prefixes on
' parameters will be accepted, but we still only validate parameter count (as the old implementation did).
If Not foundIncompleteParameterList AndAlso (lengthOfParsedText = Me.Text.Length) AndAlso
Not parts.Where(Function(p) p.IsKind(SyntaxKind.GlobalName)).Any() Then
nameParts = parts.Cast(Of SimpleNameSyntax)().Select(Function(p) New NameAndArity(p.Identifier.ValueText, p.Arity)).ToList()
Else
nameParts = SpecializedCollections.EmptyList(Of NameAndArity)()
End If
End Sub
' TODO: This method can go away once https://roslyn.codeplex.com/workitem/231 is fixed.
Private Shared Function ParseParameterList(text As String, offset As Integer) As ParameterListSyntax
Return If(SyntaxFactory.ParseToken(text, offset).IsKind(SyntaxKind.OpenParenToken),
SyntaxFactory.ParseParameterList(text, offset, consumeFullText:=False),
Nothing)
End Function
End Class
End Namespace
| ' Licensed to the .NET Foundation under one or more agreements.
' The .NET Foundation licenses this file to you under the MIT license.
' See the LICENSE file in the project root for more information.
Imports System.Threading
Imports Microsoft.CodeAnalysis
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Microsoft.CodeAnalysis.Debugging
Namespace Microsoft.CodeAnalysis.VisualBasic.Debugging
Friend Class BreakpointResolver
Inherits AbstractBreakpointResolver
Private Shared ReadOnly s_identifierComparer As IEqualityComparer(Of String) = CaseInsensitiveComparison.Comparer
Public Sub New(solution As Solution, text As String)
MyBase.New(solution, text, LanguageNames.VisualBasic, s_identifierComparer)
End Sub
Protected Overrides Function GetMembers(type As INamedTypeSymbol, name As String) As IEnumerable(Of ISymbol)
Dim members = type.GetMembers(name)
Return If(s_identifierComparer.Equals(name, SyntaxFacts.GetText(SyntaxKind.NewKeyword)),
members.Concat(type.Constructors),
members)
End Function
Protected Overrides Function HasMethodBody(method As IMethodSymbol, cancellationToken As CancellationToken) As Boolean
Dim location = method.Locations.First(Function(loc) loc.IsInSource)
Dim tree = location.SourceTree
Dim token = tree.GetRoot(cancellationToken).FindToken(location.SourceSpan.Start)
Dim methodBlock = token.GetAncestor(Of MethodBlockBaseSyntax)()
' If there is no syntactic body then, obviously, False...
If methodBlock Is Nothing Then
Return False
End If
' In VB, Partial method definitions have a syntactic body, but for the purpose of setting breakpoints in code,
' they should not be considered to have a body (because there is no executable code associated with them).
If methodBlock.BlockStatement.Modifiers.Any(Function(t) t.IsKind(SyntaxKind.PartialKeyword)) Then
Return False
End If
Return True
End Function
Protected Overrides Sub ParseText(ByRef nameParts As IList(Of NameAndArity), ByRef parameterCount As Integer?)
Dim text As String = Me.Text
Debug.Assert(text IsNot Nothing)
Dim name = SyntaxFactory.ParseName(Me.Text, consumeFullText:=False)
Dim lengthOfParsedText = name.FullSpan.End
Dim parameterList = ParseParameterList(Me.Text, lengthOfParsedText)
Dim foundIncompleteParameterList = False
parameterCount = Nothing
If parameterList IsNot Nothing Then
If (parameterList.OpenParenToken.IsMissing OrElse parameterList.CloseParenToken.IsMissing) Then
foundIncompleteParameterList = True
Else
lengthOfParsedText += parameterList.FullSpan.End
parameterCount = parameterList.Parameters.Count
End If
End If
' It's not obvious, but this method can handle the case were name "IsMissing" (no suitable name was be parsed).
Dim parts = name.GetNameParts()
' If we could not parse a valid parameter list or there was additional trailing text that could not be
' interpreted, don't return any names or parameters.
' Also, "Break at Function" doesn't seem to support names prefixed with "Global" with the old language service.
' Since it doesn't seem necessary to disambiguate symbols in this scenario (there's UI to do it), I'm going to
' explicitly ignore names with a Global namespace prefix. If we want to correctly support Global, we'd need to
' also modify the logic in FindMembersAsync to support exact matches on type name. "Global" prefixes on
' parameters will be accepted, but we still only validate parameter count (as the old implementation did).
If Not foundIncompleteParameterList AndAlso (lengthOfParsedText = Me.Text.Length) AndAlso
Not parts.Where(Function(p) p.IsKind(SyntaxKind.GlobalName)).Any() Then
nameParts = parts.Cast(Of SimpleNameSyntax)().Select(Function(p) New NameAndArity(p.Identifier.ValueText, p.Arity)).ToList()
Else
nameParts = SpecializedCollections.EmptyList(Of NameAndArity)()
End If
End Sub
' TODO: This method can go away once https://roslyn.codeplex.com/workitem/231 is fixed.
Private Shared Function ParseParameterList(text As String, offset As Integer) As ParameterListSyntax
Return If(SyntaxFactory.ParseToken(text, offset).IsKind(SyntaxKind.OpenParenToken),
SyntaxFactory.ParseParameterList(text, offset, consumeFullText:=False),
Nothing)
End Function
End Class
End Namespace
| -1 |
dotnet/roslyn | 56,218 | Eliminate 75GB allocations during binding in a performance trace | Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | sharwell | "2021-09-07T16:51:03Z" | "2021-09-09T22:25:38Z" | e3e8c6e5196d73d1b7582d40a3c48a22c68e6441 | ba2203796b7906d6f53b53bc6fa93f1708e11944 | Eliminate 75GB allocations during binding in a performance trace. Fixes two of the most expensive allocation paths shown in the performance trace attached to [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013).
Fixes [AB#1389013](https://devdiv.visualstudio.com/0bdbc590-a062-4c3f-b0f6-9383f67865ee/_workitems/edit/1389013) | ./src/VisualStudio/Core/Def/Implementation/Snippets/IVsExpansionSessionExtensions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Diagnostics.CodeAnalysis;
using Microsoft.VisualStudio.TextManager.Interop;
using MSXML;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.Snippets
{
internal static class IVsExpansionSessionExtensions
{
public static bool TryGetHeaderNode(this IVsExpansionSession expansionSession, string name, [NotNullWhen(true)] out IXMLDOMNode? node)
{
var query = name is null ? null : $@"node()[local-name()=""{name}""]";
IXMLDOMNode? localNode = null;
if (!ErrorHandler.Succeeded(ErrorHandler.CallWithCOMConvention(() => expansionSession.GetHeaderNode(query, out localNode))))
{
node = null;
return false;
}
node = localNode;
return node is not null;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Diagnostics.CodeAnalysis;
using Microsoft.VisualStudio.TextManager.Interop;
using MSXML;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.Snippets
{
internal static class IVsExpansionSessionExtensions
{
public static bool TryGetHeaderNode(this IVsExpansionSession expansionSession, string name, [NotNullWhen(true)] out IXMLDOMNode? node)
{
var query = name is null ? null : $@"node()[local-name()=""{name}""]";
IXMLDOMNode? localNode = null;
if (!ErrorHandler.Succeeded(ErrorHandler.CallWithCOMConvention(() => expansionSession.GetHeaderNode(query, out localNode))))
{
node = null;
return false;
}
node = localNode;
return node is not null;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Features/LanguageServer/Protocol/Extensions/Extensions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Immutable;
using System.Diagnostics.CodeAnalysis;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.FindUsages;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Text;
using Microsoft.VisualStudio.LanguageServer.Protocol;
using Microsoft.VisualStudio.Text.Adornments;
namespace Microsoft.CodeAnalysis.LanguageServer
{
internal static class Extensions
{
public static Uri GetURI(this TextDocument document)
{
return ProtocolConversions.GetUriFromFilePath(document.FilePath);
}
public static ImmutableArray<Document> GetDocuments(this Solution solution, Uri documentUri)
=> GetDocuments(solution, documentUri, clientName: null, logger: null);
public static ImmutableArray<Document> GetDocuments(this Solution solution, Uri documentUri, string? clientName)
=> GetDocuments(solution, documentUri, clientName, logger: null);
public static ImmutableArray<Document> GetDocuments(this Solution solution, Uri documentUri, string? clientName, ILspLogger? logger)
{
var documentIds = GetDocumentIds(solution, documentUri);
var documents = documentIds.SelectAsArray(id => solution.GetRequiredDocument(id));
return FilterDocumentsByClientName(documents, clientName, logger);
}
public static ImmutableArray<DocumentId> GetDocumentIds(this Solution solution, Uri documentUri)
{
// TODO: we need to normalize this. but for now, we check both absolute and local path
// right now, based on who calls this, solution might has "/" or "\\" as directory
// separator
var documentIds = solution.GetDocumentIdsWithFilePath(documentUri.AbsolutePath);
if (!documentIds.Any())
{
documentIds = solution.GetDocumentIdsWithFilePath(documentUri.LocalPath);
}
return documentIds;
}
private static ImmutableArray<Document> FilterDocumentsByClientName(ImmutableArray<Document> documents, string? clientName, ILspLogger? logger)
{
// If we don't have a client name, then we're done filtering
if (clientName == null)
{
return documents;
}
// We have a client name, so we need to filter to only documents that match that name
return documents.WhereAsArray(document =>
{
var documentPropertiesService = document.Services.GetService<DocumentPropertiesService>();
// When a client name is specified, only return documents that have a matching client name.
// Allows the razor lsp server to return results only for razor documents.
// This workaround should be removed when https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1106064/
// is fixed (so that the razor language server is only asked about razor buffers).
var documentClientName = documentPropertiesService?.DiagnosticsLspClientName;
var clientNameMatch = Equals(documentClientName, clientName);
if (!clientNameMatch && logger is not null)
{
logger.TraceInformation($"Found matching document but it's client name '{documentClientName}' is not a match.");
}
return clientNameMatch;
});
}
public static Document? GetDocument(this Solution solution, TextDocumentIdentifier documentIdentifier)
=> solution.GetDocument(documentIdentifier, clientName: null);
public static Document? GetDocument(this Solution solution, TextDocumentIdentifier documentIdentifier, string? clientName)
{
var documents = solution.GetDocuments(documentIdentifier.Uri, clientName, logger: null);
if (documents.Length == 0)
{
return null;
}
return documents.FindDocumentInProjectContext(documentIdentifier);
}
public static Document FindDocumentInProjectContext(this ImmutableArray<Document> documents, TextDocumentIdentifier documentIdentifier)
{
if (documents.Length > 1)
{
// We have more than one document; try to find the one that matches the right context
if (documentIdentifier is VSTextDocumentIdentifier vsDocumentIdentifier && vsDocumentIdentifier.ProjectContext != null)
{
var projectId = ProtocolConversions.ProjectContextToProjectId(vsDocumentIdentifier.ProjectContext);
var matchingDocument = documents.FirstOrDefault(d => d.Project.Id == projectId);
if (matchingDocument != null)
{
return matchingDocument;
}
}
else
{
// We were not passed a project context. This can happen when the LSP powered NavBar is not enabled.
// This branch should be removed when we're using the LSP based navbar in all scenarios.
var solution = documents.First().Project.Solution;
// Lookup which of the linked documents is currently active in the workspace.
var documentIdInCurrentContext = solution.Workspace.GetDocumentIdInCurrentContext(documents.First().Id);
return solution.GetRequiredDocument(documentIdInCurrentContext);
}
}
// We either have only one document or have multiple, but none of them matched our context. In the
// latter case, we'll just return the first one arbitrarily since this might just be some temporary mis-sync
// of client and server state.
return documents[0];
}
public static async Task<int> GetPositionFromLinePositionAsync(this TextDocument document, LinePosition linePosition, CancellationToken cancellationToken)
{
var text = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
return text.Lines.GetPosition(linePosition);
}
public static bool HasVisualStudioLspCapability(this ClientCapabilities? clientCapabilities)
{
if (clientCapabilities is VSInternalClientCapabilities vsClientCapabilities)
{
return vsClientCapabilities.SupportsVisualStudioExtensions;
}
return false;
}
public static bool HasCompletionListDataCapability(this ClientCapabilities clientCapabilities)
{
if (!TryGetVSCompletionListSetting(clientCapabilities, out var completionListSetting))
{
return false;
}
return completionListSetting.Data;
}
public static bool HasCompletionListCommitCharactersCapability(this ClientCapabilities clientCapabilities)
{
if (!TryGetVSCompletionListSetting(clientCapabilities, out var completionListSetting))
{
return false;
}
return completionListSetting.CommitCharacters;
}
public static string GetMarkdownLanguageName(this Document document)
{
switch (document.Project.Language)
{
case LanguageNames.CSharp:
return "csharp";
case LanguageNames.VisualBasic:
return "vb";
case LanguageNames.FSharp:
return "fsharp";
case "TypeScript":
return "typescript";
default:
throw new ArgumentException(string.Format("Document project language {0} is not valid", document.Project.Language));
}
}
public static ClassifiedTextElement GetClassifiedText(this DefinitionItem definition)
=> new ClassifiedTextElement(definition.DisplayParts.Select(part => new ClassifiedTextRun(part.Tag.ToClassificationTypeName(), part.Text)));
public static bool IsRazorDocument(this Document document)
{
// Only razor docs have an ISpanMappingService, so we can use the presence of that to determine if this doc
// belongs to them.
var spanMapper = document.Services.GetService<ISpanMappingService>();
return spanMapper != null;
}
private static bool TryGetVSCompletionListSetting(ClientCapabilities clientCapabilities, [NotNullWhen(returnValue: true)] out VSInternalCompletionListSetting? completionListSetting)
{
if (clientCapabilities is not VSInternalClientCapabilities vsClientCapabilities)
{
completionListSetting = null;
return false;
}
var textDocumentCapability = vsClientCapabilities.TextDocument;
if (textDocumentCapability == null)
{
completionListSetting = null;
return false;
}
if (textDocumentCapability.Completion is not VSInternalCompletionSetting vsCompletionSetting)
{
completionListSetting = null;
return false;
}
completionListSetting = vsCompletionSetting.CompletionList;
if (completionListSetting == null)
{
return false;
}
return true;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Immutable;
using System.Diagnostics.CodeAnalysis;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.FindUsages;
using Microsoft.CodeAnalysis.Host;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Text;
using Microsoft.VisualStudio.LanguageServer.Protocol;
using Microsoft.VisualStudio.Text.Adornments;
namespace Microsoft.CodeAnalysis.LanguageServer
{
internal static class Extensions
{
public static Uri GetURI(this TextDocument document)
{
return ProtocolConversions.GetUriFromFilePath(document.FilePath);
}
public static ImmutableArray<Document> GetDocuments(this Solution solution, Uri documentUri)
=> GetDocuments(solution, documentUri, clientName: null, logger: null);
public static ImmutableArray<Document> GetDocuments(this Solution solution, Uri documentUri, string? clientName)
=> GetDocuments(solution, documentUri, clientName, logger: null);
public static ImmutableArray<Document> GetDocuments(this Solution solution, Uri documentUri, string? clientName, ILspLogger? logger)
{
var documentIds = GetDocumentIds(solution, documentUri);
var documents = documentIds.SelectAsArray(id => solution.GetRequiredDocument(id));
return FilterDocumentsByClientName(documents, clientName, logger);
}
public static ImmutableArray<DocumentId> GetDocumentIds(this Solution solution, Uri documentUri)
{
// TODO: we need to normalize this. but for now, we check both absolute and local path
// right now, based on who calls this, solution might has "/" or "\\" as directory
// separator
var documentIds = solution.GetDocumentIdsWithFilePath(documentUri.AbsolutePath);
if (!documentIds.Any())
{
documentIds = solution.GetDocumentIdsWithFilePath(documentUri.LocalPath);
}
return documentIds;
}
private static ImmutableArray<Document> FilterDocumentsByClientName(ImmutableArray<Document> documents, string? clientName, ILspLogger? logger)
{
// If we don't have a client name, then we're done filtering
if (clientName == null)
{
return documents;
}
// We have a client name, so we need to filter to only documents that match that name
return documents.WhereAsArray(document =>
{
var documentPropertiesService = document.Services.GetService<DocumentPropertiesService>();
// When a client name is specified, only return documents that have a matching client name.
// Allows the razor lsp server to return results only for razor documents.
// This workaround should be removed when https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1106064/
// is fixed (so that the razor language server is only asked about razor buffers).
var documentClientName = documentPropertiesService?.DiagnosticsLspClientName;
var clientNameMatch = Equals(documentClientName, clientName);
if (!clientNameMatch && logger is not null)
{
logger.TraceInformation($"Found matching document but it's client name '{documentClientName}' is not a match.");
}
return clientNameMatch;
});
}
public static Document? GetDocument(this Solution solution, TextDocumentIdentifier documentIdentifier)
=> solution.GetDocument(documentIdentifier, clientName: null);
public static Document? GetDocument(this Solution solution, TextDocumentIdentifier documentIdentifier, string? clientName)
{
var documents = solution.GetDocuments(documentIdentifier.Uri, clientName, logger: null);
if (documents.Length == 0)
{
return null;
}
return documents.FindDocumentInProjectContext(documentIdentifier);
}
public static Document FindDocumentInProjectContext(this ImmutableArray<Document> documents, TextDocumentIdentifier documentIdentifier)
{
if (documents.Length > 1)
{
// We have more than one document; try to find the one that matches the right context
if (documentIdentifier is VSTextDocumentIdentifier vsDocumentIdentifier && vsDocumentIdentifier.ProjectContext != null)
{
var projectId = ProtocolConversions.ProjectContextToProjectId(vsDocumentIdentifier.ProjectContext);
var matchingDocument = documents.FirstOrDefault(d => d.Project.Id == projectId);
if (matchingDocument != null)
{
return matchingDocument;
}
}
else
{
// We were not passed a project context. This can happen when the LSP powered NavBar is not enabled.
// This branch should be removed when we're using the LSP based navbar in all scenarios.
var solution = documents.First().Project.Solution;
// Lookup which of the linked documents is currently active in the workspace.
var documentIdInCurrentContext = solution.Workspace.GetDocumentIdInCurrentContext(documents.First().Id);
return solution.GetRequiredDocument(documentIdInCurrentContext);
}
}
// We either have only one document or have multiple, but none of them matched our context. In the
// latter case, we'll just return the first one arbitrarily since this might just be some temporary mis-sync
// of client and server state.
return documents[0];
}
public static async Task<int> GetPositionFromLinePositionAsync(this TextDocument document, LinePosition linePosition, CancellationToken cancellationToken)
{
var text = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
return text.Lines.GetPosition(linePosition);
}
public static bool HasVisualStudioLspCapability(this ClientCapabilities? clientCapabilities)
{
if (clientCapabilities is VSInternalClientCapabilities vsClientCapabilities)
{
return vsClientCapabilities.SupportsVisualStudioExtensions;
}
return false;
}
public static bool HasCompletionListDataCapability(this ClientCapabilities clientCapabilities)
{
if (!TryGetVSCompletionListSetting(clientCapabilities, out var completionListSetting))
{
return false;
}
return completionListSetting.Data;
}
public static bool HasCompletionListCommitCharactersCapability(this ClientCapabilities clientCapabilities)
{
if (!TryGetVSCompletionListSetting(clientCapabilities, out var completionListSetting))
{
return false;
}
return completionListSetting.CommitCharacters;
}
public static string GetMarkdownLanguageName(this Document document)
{
switch (document.Project.Language)
{
case LanguageNames.CSharp:
return "csharp";
case LanguageNames.VisualBasic:
return "vb";
case LanguageNames.FSharp:
return "fsharp";
case InternalLanguageNames.TypeScript:
return "typescript";
default:
throw new ArgumentException(string.Format("Document project language {0} is not valid", document.Project.Language));
}
}
public static ClassifiedTextElement GetClassifiedText(this DefinitionItem definition)
=> new ClassifiedTextElement(definition.DisplayParts.Select(part => new ClassifiedTextRun(part.Tag.ToClassificationTypeName(), part.Text)));
public static bool IsRazorDocument(this Document document)
{
// Only razor docs have an ISpanMappingService, so we can use the presence of that to determine if this doc
// belongs to them.
var spanMapper = document.Services.GetService<ISpanMappingService>();
return spanMapper != null;
}
private static bool TryGetVSCompletionListSetting(ClientCapabilities clientCapabilities, [NotNullWhen(returnValue: true)] out VSInternalCompletionListSetting? completionListSetting)
{
if (clientCapabilities is not VSInternalClientCapabilities vsClientCapabilities)
{
completionListSetting = null;
return false;
}
var textDocumentCapability = vsClientCapabilities.TextDocument;
if (textDocumentCapability == null)
{
completionListSetting = null;
return false;
}
if (textDocumentCapability.Completion is not VSInternalCompletionSetting vsCompletionSetting)
{
completionListSetting = null;
return false;
}
completionListSetting = vsCompletionSetting.CompletionList;
if (completionListSetting == null)
{
return false;
}
return true;
}
}
}
| 1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Tools/ExternalAccess/FSharp/Completion/FSharpCompletionOptions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using Microsoft.CodeAnalysis.Options;
namespace Microsoft.CodeAnalysis.ExternalAccess.FSharp.Completion
{
internal static class FSharpCompletionOptions
{
// Suppression due to https://github.com/dotnet/roslyn/issues/42614
public static PerLanguageOption<bool> BlockForCompletionItems { get; } = ((PerLanguageOption<bool>)Microsoft.CodeAnalysis.Completion.CompletionOptions.BlockForCompletionItems2)!;
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using Microsoft.CodeAnalysis.Completion;
using Microsoft.CodeAnalysis.Options;
namespace Microsoft.CodeAnalysis.ExternalAccess.FSharp.Completion
{
internal static class FSharpCompletionOptions
{
public static PerLanguageOption<bool> BlockForCompletionItems { get; } = (PerLanguageOption<bool>)CompletionOptions.BlockForCompletionItems2;
}
}
| 1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/VisualStudio/Core/Def/ExternalAccess/VSTypeScript/Api/VSTypeScriptContainedLanguageWrapper.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#pragma warning disable CS0618 // Type or member is obsolete
using System;
using Microsoft.CodeAnalysis;
using Microsoft.VisualStudio.ComponentModelHost;
using Microsoft.VisualStudio.LanguageServices.Implementation.ProjectSystem;
using Microsoft.VisualStudio.LanguageServices.Implementation.Venus;
using Microsoft.VisualStudio.Shell.Interop;
using Microsoft.VisualStudio.TextManager.Interop;
namespace Microsoft.VisualStudio.LanguageServices.ExternalAccess.VSTypeScript.Api
{
internal struct VSTypeScriptContainedLanguageWrapper
{
private readonly ContainedLanguage _underlyingObject;
[Obsolete("Remove once TypeScript has stopped using this.", error: true)]
public VSTypeScriptContainedLanguageWrapper(
IVsTextBufferCoordinator bufferCoordinator,
IComponentModel componentModel,
AbstractProject project,
IVsHierarchy hierarchy,
uint itemid,
Guid languageServiceGuid)
{
var workspace = componentModel.GetService<VisualStudioWorkspace>();
var filePath = ContainedLanguage.GetFilePathFromHierarchyAndItemId(hierarchy, itemid);
_underlyingObject = new ContainedLanguage(
bufferCoordinator,
componentModel,
workspace,
project.Id,
project.VisualStudioProject,
filePath,
languageServiceGuid,
vbHelperFormattingRule: null);
}
public VSTypeScriptContainedLanguageWrapper(
IVsTextBufferCoordinator bufferCoordinator,
IComponentModel componentModel,
VSTypeScriptVisualStudioProjectWrapper project,
IVsHierarchy hierarchy,
uint itemid,
Guid languageServiceGuid)
{
var workspace = componentModel.GetService<VisualStudioWorkspace>();
var filePath = ContainedLanguage.GetFilePathFromHierarchyAndItemId(hierarchy, itemid);
_underlyingObject = new ContainedLanguage(
bufferCoordinator,
componentModel,
workspace,
project.Project.Id,
project.Project,
filePath,
languageServiceGuid,
vbHelperFormattingRule: null);
}
public VSTypeScriptContainedLanguageWrapper(
IVsTextBufferCoordinator bufferCoordinator,
IComponentModel componentModel,
Workspace workspace,
IVsHierarchy hierarchy,
uint itemid,
Guid languageServiceGuid)
{
var filePath = ContainedLanguage.GetFilePathFromHierarchyAndItemId(hierarchy, itemid);
var projectId = ProjectId.CreateNewId($"Project for {filePath}");
workspace.OnProjectAdded(ProjectInfo.Create(projectId, VersionStamp.Default, filePath, string.Empty, "TypeScript"));
_underlyingObject = new ContainedLanguage(
bufferCoordinator,
componentModel,
workspace,
projectId,
null,
filePath,
languageServiceGuid,
vbHelperFormattingRule: null);
}
public bool IsDefault => _underlyingObject == null;
public void DisconnectHost()
=> _underlyingObject.SetHost(null);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#pragma warning disable CS0618 // Type or member is obsolete
using System;
using Microsoft.CodeAnalysis;
using Microsoft.VisualStudio.ComponentModelHost;
using Microsoft.VisualStudio.LanguageServices.Implementation.ProjectSystem;
using Microsoft.VisualStudio.LanguageServices.Implementation.Venus;
using Microsoft.VisualStudio.Shell.Interop;
using Microsoft.VisualStudio.TextManager.Interop;
namespace Microsoft.VisualStudio.LanguageServices.ExternalAccess.VSTypeScript.Api
{
internal struct VSTypeScriptContainedLanguageWrapper
{
private readonly ContainedLanguage _underlyingObject;
[Obsolete("Remove once TypeScript has stopped using this.", error: true)]
public VSTypeScriptContainedLanguageWrapper(
IVsTextBufferCoordinator bufferCoordinator,
IComponentModel componentModel,
AbstractProject project,
IVsHierarchy hierarchy,
uint itemid,
Guid languageServiceGuid)
{
var workspace = componentModel.GetService<VisualStudioWorkspace>();
var filePath = ContainedLanguage.GetFilePathFromHierarchyAndItemId(hierarchy, itemid);
_underlyingObject = new ContainedLanguage(
bufferCoordinator,
componentModel,
workspace,
project.Id,
project.VisualStudioProject,
filePath,
languageServiceGuid,
vbHelperFormattingRule: null);
}
public VSTypeScriptContainedLanguageWrapper(
IVsTextBufferCoordinator bufferCoordinator,
IComponentModel componentModel,
VSTypeScriptVisualStudioProjectWrapper project,
IVsHierarchy hierarchy,
uint itemid,
Guid languageServiceGuid)
{
var workspace = componentModel.GetService<VisualStudioWorkspace>();
var filePath = ContainedLanguage.GetFilePathFromHierarchyAndItemId(hierarchy, itemid);
_underlyingObject = new ContainedLanguage(
bufferCoordinator,
componentModel,
workspace,
project.Project.Id,
project.Project,
filePath,
languageServiceGuid,
vbHelperFormattingRule: null);
}
public VSTypeScriptContainedLanguageWrapper(
IVsTextBufferCoordinator bufferCoordinator,
IComponentModel componentModel,
Workspace workspace,
IVsHierarchy hierarchy,
uint itemid,
Guid languageServiceGuid)
{
var filePath = ContainedLanguage.GetFilePathFromHierarchyAndItemId(hierarchy, itemid);
var projectId = ProjectId.CreateNewId($"Project for {filePath}");
workspace.OnProjectAdded(ProjectInfo.Create(projectId, VersionStamp.Default, filePath, string.Empty, InternalLanguageNames.TypeScript));
_underlyingObject = new ContainedLanguage(
bufferCoordinator,
componentModel,
workspace,
projectId,
null,
filePath,
languageServiceGuid,
vbHelperFormattingRule: null);
}
public bool IsDefault => _underlyingObject == null;
public void DisconnectHost()
=> _underlyingObject.SetHost(null);
}
}
| 1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/VisualStudio/Core/Def/Implementation/LanguageService/AbstractLanguageService`2.VsCodeWindowManager.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Diagnostics;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Editor;
using Microsoft.CodeAnalysis.Editor.Options;
using Microsoft.CodeAnalysis.Editor.Shared.Extensions;
using Microsoft.CodeAnalysis.Editor.Shared.Utilities;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Shared.TestHooks;
using Microsoft.CodeAnalysis.Text;
using Microsoft.VisualStudio.LanguageServices.Implementation.NavigationBar;
using Microsoft.VisualStudio.TextManager.Interop;
using Microsoft.VisualStudio.Threading;
using Roslyn.Utilities;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.LanguageService
{
internal abstract partial class AbstractLanguageService<TPackage, TLanguageService>
{
internal class VsCodeWindowManager : IVsCodeWindowManager, IVsCodeWindowEvents
{
private readonly TLanguageService _languageService;
private readonly IVsCodeWindow _codeWindow;
private readonly ComEventSink _sink;
private readonly IThreadingContext _threadingContext;
private readonly IAsynchronousOperationListener _asynchronousOperationListener;
private IDisposable? _navigationBarController;
private IVsDropdownBarClient? _dropdownBarClient;
private IOptionService? _optionService;
private WorkspaceRegistration? _workspaceRegistration;
public VsCodeWindowManager(TLanguageService languageService, IVsCodeWindow codeWindow)
{
_languageService = languageService;
_codeWindow = codeWindow;
_threadingContext = languageService.Package.ComponentModel.GetService<IThreadingContext>();
var listenerProvider = languageService.Package.ComponentModel.GetService<IAsynchronousOperationListenerProvider>();
_asynchronousOperationListener = listenerProvider.GetListener(FeatureAttribute.NavigationBar);
_sink = ComEventSink.Advise<IVsCodeWindowEvents>(codeWindow, this);
}
private void OnWorkspaceRegistrationChanged(object sender, System.EventArgs e)
{
var token = _asynchronousOperationListener.BeginAsyncOperation(nameof(OnWorkspaceRegistrationChanged));
// Fire and forget to update the navbar based on the workspace registration
// to avoid blocking the caller and possible deadlocks workspace registration changed events under lock.
UpdateWorkspaceAsync().CompletesAsyncOperation(token).Forget();
}
private async Task UpdateWorkspaceAsync()
{
// This event may not be triggered on the main thread, but adding and removing the navbar
// must be done from the main thread.
await _threadingContext.JoinableTaskFactory.SwitchToMainThreadAsync();
// If the workspace registration is missing, addornments have been removed.
if (_workspaceRegistration == null)
{
return;
}
// There's a new workspace, so make sure we unsubscribe from the old workspace option changes and subscribe to new.
UpdateOptionChangedSource(_workspaceRegistration.Workspace);
// Trigger a check to see if the dropdown should be added / removed now that the buffer is in a different workspace.
AddOrRemoveDropdown();
}
private void UpdateOptionChangedSource(Workspace? newWorkspace)
{
if (_optionService != null)
{
_optionService.OptionChanged -= OnOptionChanged;
_optionService = null;
}
var optionService = newWorkspace?.Services.GetService<IOptionService>();
if (optionService != null)
{
_optionService = optionService;
_optionService.OptionChanged += OnOptionChanged;
}
}
private void SetupView(IVsTextView view)
=> _languageService.SetupNewTextView(view);
private void OnOptionChanged(object sender, OptionChangedEventArgs e)
{
// If the workspace registration is missing, addornments have been removed.
if (_workspaceRegistration == null)
{
return;
}
if (e.Language != _languageService.RoslynLanguageName ||
e.Option != NavigationBarOptions.ShowNavigationBar)
{
return;
}
AddOrRemoveDropdown();
}
private void AddOrRemoveDropdown()
{
if (!(_codeWindow is IVsDropdownBarManager dropdownManager))
{
return;
}
if (ErrorHandler.Failed(_codeWindow.GetBuffer(out var buffer)))
{
return;
}
var textBuffer = _languageService.EditorAdaptersFactoryService.GetDataBuffer(buffer);
var document = textBuffer?.AsTextContainer()?.GetRelatedDocuments().FirstOrDefault();
// TODO - Remove the TS check once they move the liveshare navbar to LSP. Then we can also switch to LSP
// for the local navbar implementation.
// https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1163360
if (textBuffer?.IsInLspEditorContext() == true && document!.Project!.Language != "TypeScript")
{
// Remove the existing dropdown bar if it is ours.
if (IsOurDropdownBar(dropdownManager, out var _))
{
RemoveDropdownBar(dropdownManager);
}
return;
}
var enabled = _optionService?.GetOption(NavigationBarOptions.ShowNavigationBar, _languageService.RoslynLanguageName);
if (enabled == true)
{
if (IsOurDropdownBar(dropdownManager, out var existingDropdownBar))
{
// The dropdown bar is already one of ours, do nothing.
return;
}
if (existingDropdownBar != null)
{
// Not ours, so remove the old one so that we can add ours.
RemoveDropdownBar(dropdownManager);
}
else
{
Contract.ThrowIfFalse(_navigationBarController == null, "We shouldn't have a controller manager if there isn't a dropdown");
Contract.ThrowIfFalse(_dropdownBarClient == null, "We shouldn't have a dropdown client if there isn't a dropdown");
}
AdddropdownBar(dropdownManager);
}
else
{
RemoveDropdownBar(dropdownManager);
}
bool IsOurDropdownBar(IVsDropdownBarManager dropdownBarManager, out IVsDropdownBar? existingDropdownBar)
{
existingDropdownBar = GetDropdownBar(dropdownBarManager);
if (existingDropdownBar != null)
{
if (_dropdownBarClient != null &&
_dropdownBarClient == GetDropdownBarClient(existingDropdownBar))
{
return true;
}
}
return false;
}
}
private static IVsDropdownBar GetDropdownBar(IVsDropdownBarManager dropdownManager)
{
ErrorHandler.ThrowOnFailure(dropdownManager.GetDropdownBar(out var existingDropdownBar));
return existingDropdownBar;
}
private static IVsDropdownBarClient GetDropdownBarClient(IVsDropdownBar dropdownBar)
{
ErrorHandler.ThrowOnFailure(dropdownBar.GetClient(out var dropdownBarClient));
return dropdownBarClient;
}
private void AdddropdownBar(IVsDropdownBarManager dropdownManager)
{
if (ErrorHandler.Failed(_codeWindow.GetBuffer(out var buffer)))
{
return;
}
var navigationBarClient = new NavigationBarClient(dropdownManager, _codeWindow, _languageService.SystemServiceProvider, _languageService.Workspace);
var textBuffer = _languageService.EditorAdaptersFactoryService.GetDataBuffer(buffer);
var controllerFactoryService = _languageService.Package.ComponentModel.GetService<INavigationBarControllerFactoryService>();
var newController = controllerFactoryService.CreateController(navigationBarClient, textBuffer);
var hr = dropdownManager.AddDropdownBar(cCombos: 3, pClient: navigationBarClient);
if (ErrorHandler.Failed(hr))
{
newController.Dispose();
ErrorHandler.ThrowOnFailure(hr);
}
_navigationBarController = newController;
_dropdownBarClient = navigationBarClient;
return;
}
private void RemoveDropdownBar(IVsDropdownBarManager dropdownManager)
{
if (ErrorHandler.Succeeded(dropdownManager.RemoveDropdownBar()))
{
if (_navigationBarController != null)
{
_navigationBarController.Dispose();
_navigationBarController = null;
}
_dropdownBarClient = null;
}
}
public int AddAdornments()
{
int hr;
if (ErrorHandler.Failed(hr = _codeWindow.GetPrimaryView(out var primaryView)))
{
Debug.Fail("GetPrimaryView failed in IVsCodeWindowManager.AddAdornments");
return hr;
}
SetupView(primaryView);
if (ErrorHandler.Succeeded(_codeWindow.GetSecondaryView(out var secondaryView)))
{
SetupView(secondaryView);
}
ErrorHandler.ThrowOnFailure(_codeWindow.GetBuffer(out var buffer));
var textContainer = _languageService.EditorAdaptersFactoryService.GetDataBuffer(buffer)?.AsTextContainer();
_workspaceRegistration = CodeAnalysis.Workspace.GetWorkspaceRegistration(textContainer);
_workspaceRegistration.WorkspaceChanged += OnWorkspaceRegistrationChanged;
UpdateOptionChangedSource(_workspaceRegistration.Workspace);
AddOrRemoveDropdown();
return VSConstants.S_OK;
}
public int OnCloseView(IVsTextView view)
{
return VSConstants.S_OK;
}
public int OnNewView(IVsTextView view)
{
SetupView(view);
return VSConstants.S_OK;
}
public int RemoveAdornments()
{
_sink.Unadvise();
if (_optionService != null)
{
_optionService.OptionChanged -= OnOptionChanged;
_optionService = null;
}
if (_workspaceRegistration != null)
{
_workspaceRegistration.WorkspaceChanged -= OnWorkspaceRegistrationChanged;
_workspaceRegistration = null;
}
if (_codeWindow is IVsDropdownBarManager dropdownManager)
{
RemoveDropdownBar(dropdownManager);
}
return VSConstants.S_OK;
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Diagnostics;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Editor;
using Microsoft.CodeAnalysis.Editor.Options;
using Microsoft.CodeAnalysis.Editor.Shared.Extensions;
using Microsoft.CodeAnalysis.Editor.Shared.Utilities;
using Microsoft.CodeAnalysis.Options;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Shared.TestHooks;
using Microsoft.CodeAnalysis.Text;
using Microsoft.VisualStudio.LanguageServices.Implementation.NavigationBar;
using Microsoft.VisualStudio.TextManager.Interop;
using Microsoft.VisualStudio.Threading;
using Roslyn.Utilities;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.LanguageService
{
internal abstract partial class AbstractLanguageService<TPackage, TLanguageService>
{
internal class VsCodeWindowManager : IVsCodeWindowManager, IVsCodeWindowEvents
{
private readonly TLanguageService _languageService;
private readonly IVsCodeWindow _codeWindow;
private readonly ComEventSink _sink;
private readonly IThreadingContext _threadingContext;
private readonly IAsynchronousOperationListener _asynchronousOperationListener;
private IDisposable? _navigationBarController;
private IVsDropdownBarClient? _dropdownBarClient;
private IOptionService? _optionService;
private WorkspaceRegistration? _workspaceRegistration;
public VsCodeWindowManager(TLanguageService languageService, IVsCodeWindow codeWindow)
{
_languageService = languageService;
_codeWindow = codeWindow;
_threadingContext = languageService.Package.ComponentModel.GetService<IThreadingContext>();
var listenerProvider = languageService.Package.ComponentModel.GetService<IAsynchronousOperationListenerProvider>();
_asynchronousOperationListener = listenerProvider.GetListener(FeatureAttribute.NavigationBar);
_sink = ComEventSink.Advise<IVsCodeWindowEvents>(codeWindow, this);
}
private void OnWorkspaceRegistrationChanged(object sender, System.EventArgs e)
{
var token = _asynchronousOperationListener.BeginAsyncOperation(nameof(OnWorkspaceRegistrationChanged));
// Fire and forget to update the navbar based on the workspace registration
// to avoid blocking the caller and possible deadlocks workspace registration changed events under lock.
UpdateWorkspaceAsync().CompletesAsyncOperation(token).Forget();
}
private async Task UpdateWorkspaceAsync()
{
// This event may not be triggered on the main thread, but adding and removing the navbar
// must be done from the main thread.
await _threadingContext.JoinableTaskFactory.SwitchToMainThreadAsync();
// If the workspace registration is missing, addornments have been removed.
if (_workspaceRegistration == null)
{
return;
}
// There's a new workspace, so make sure we unsubscribe from the old workspace option changes and subscribe to new.
UpdateOptionChangedSource(_workspaceRegistration.Workspace);
// Trigger a check to see if the dropdown should be added / removed now that the buffer is in a different workspace.
AddOrRemoveDropdown();
}
private void UpdateOptionChangedSource(Workspace? newWorkspace)
{
if (_optionService != null)
{
_optionService.OptionChanged -= OnOptionChanged;
_optionService = null;
}
var optionService = newWorkspace?.Services.GetService<IOptionService>();
if (optionService != null)
{
_optionService = optionService;
_optionService.OptionChanged += OnOptionChanged;
}
}
private void SetupView(IVsTextView view)
=> _languageService.SetupNewTextView(view);
private void OnOptionChanged(object sender, OptionChangedEventArgs e)
{
// If the workspace registration is missing, addornments have been removed.
if (_workspaceRegistration == null)
{
return;
}
if (e.Language != _languageService.RoslynLanguageName ||
e.Option != NavigationBarOptions.ShowNavigationBar)
{
return;
}
AddOrRemoveDropdown();
}
private void AddOrRemoveDropdown()
{
if (!(_codeWindow is IVsDropdownBarManager dropdownManager))
{
return;
}
if (ErrorHandler.Failed(_codeWindow.GetBuffer(out var buffer)))
{
return;
}
var textBuffer = _languageService.EditorAdaptersFactoryService.GetDataBuffer(buffer);
var document = textBuffer?.AsTextContainer()?.GetRelatedDocuments().FirstOrDefault();
// TODO - Remove the TS check once they move the liveshare navbar to LSP. Then we can also switch to LSP
// for the local navbar implementation.
// https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1163360
if (textBuffer?.IsInLspEditorContext() == true && document!.Project!.Language != InternalLanguageNames.TypeScript)
{
// Remove the existing dropdown bar if it is ours.
if (IsOurDropdownBar(dropdownManager, out var _))
{
RemoveDropdownBar(dropdownManager);
}
return;
}
var enabled = _optionService?.GetOption(NavigationBarOptions.ShowNavigationBar, _languageService.RoslynLanguageName);
if (enabled == true)
{
if (IsOurDropdownBar(dropdownManager, out var existingDropdownBar))
{
// The dropdown bar is already one of ours, do nothing.
return;
}
if (existingDropdownBar != null)
{
// Not ours, so remove the old one so that we can add ours.
RemoveDropdownBar(dropdownManager);
}
else
{
Contract.ThrowIfFalse(_navigationBarController == null, "We shouldn't have a controller manager if there isn't a dropdown");
Contract.ThrowIfFalse(_dropdownBarClient == null, "We shouldn't have a dropdown client if there isn't a dropdown");
}
AdddropdownBar(dropdownManager);
}
else
{
RemoveDropdownBar(dropdownManager);
}
bool IsOurDropdownBar(IVsDropdownBarManager dropdownBarManager, out IVsDropdownBar? existingDropdownBar)
{
existingDropdownBar = GetDropdownBar(dropdownBarManager);
if (existingDropdownBar != null)
{
if (_dropdownBarClient != null &&
_dropdownBarClient == GetDropdownBarClient(existingDropdownBar))
{
return true;
}
}
return false;
}
}
private static IVsDropdownBar GetDropdownBar(IVsDropdownBarManager dropdownManager)
{
ErrorHandler.ThrowOnFailure(dropdownManager.GetDropdownBar(out var existingDropdownBar));
return existingDropdownBar;
}
private static IVsDropdownBarClient GetDropdownBarClient(IVsDropdownBar dropdownBar)
{
ErrorHandler.ThrowOnFailure(dropdownBar.GetClient(out var dropdownBarClient));
return dropdownBarClient;
}
private void AdddropdownBar(IVsDropdownBarManager dropdownManager)
{
if (ErrorHandler.Failed(_codeWindow.GetBuffer(out var buffer)))
{
return;
}
var navigationBarClient = new NavigationBarClient(dropdownManager, _codeWindow, _languageService.SystemServiceProvider, _languageService.Workspace);
var textBuffer = _languageService.EditorAdaptersFactoryService.GetDataBuffer(buffer);
var controllerFactoryService = _languageService.Package.ComponentModel.GetService<INavigationBarControllerFactoryService>();
var newController = controllerFactoryService.CreateController(navigationBarClient, textBuffer);
var hr = dropdownManager.AddDropdownBar(cCombos: 3, pClient: navigationBarClient);
if (ErrorHandler.Failed(hr))
{
newController.Dispose();
ErrorHandler.ThrowOnFailure(hr);
}
_navigationBarController = newController;
_dropdownBarClient = navigationBarClient;
return;
}
private void RemoveDropdownBar(IVsDropdownBarManager dropdownManager)
{
if (ErrorHandler.Succeeded(dropdownManager.RemoveDropdownBar()))
{
if (_navigationBarController != null)
{
_navigationBarController.Dispose();
_navigationBarController = null;
}
_dropdownBarClient = null;
}
}
public int AddAdornments()
{
int hr;
if (ErrorHandler.Failed(hr = _codeWindow.GetPrimaryView(out var primaryView)))
{
Debug.Fail("GetPrimaryView failed in IVsCodeWindowManager.AddAdornments");
return hr;
}
SetupView(primaryView);
if (ErrorHandler.Succeeded(_codeWindow.GetSecondaryView(out var secondaryView)))
{
SetupView(secondaryView);
}
ErrorHandler.ThrowOnFailure(_codeWindow.GetBuffer(out var buffer));
var textContainer = _languageService.EditorAdaptersFactoryService.GetDataBuffer(buffer)?.AsTextContainer();
_workspaceRegistration = CodeAnalysis.Workspace.GetWorkspaceRegistration(textContainer);
_workspaceRegistration.WorkspaceChanged += OnWorkspaceRegistrationChanged;
UpdateOptionChangedSource(_workspaceRegistration.Workspace);
AddOrRemoveDropdown();
return VSConstants.S_OK;
}
public int OnCloseView(IVsTextView view)
{
return VSConstants.S_OK;
}
public int OnNewView(IVsTextView view)
{
SetupView(view);
return VSConstants.S_OK;
}
public int RemoveAdornments()
{
_sink.Unadvise();
if (_optionService != null)
{
_optionService.OptionChanged -= OnOptionChanged;
_optionService = null;
}
if (_workspaceRegistration != null)
{
_workspaceRegistration.WorkspaceChanged -= OnWorkspaceRegistrationChanged;
_workspaceRegistration = null;
}
if (_codeWindow is IVsDropdownBarManager dropdownManager)
{
RemoveDropdownBar(dropdownManager);
}
return VSConstants.S_OK;
}
}
}
}
| 1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/VisualStudio/Core/Def/Implementation/Options/LanguageSettingsPersister.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using System.Runtime.InteropServices;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Completion;
using Microsoft.CodeAnalysis.Editor.Options;
using Microsoft.CodeAnalysis.Editor.Shared.Utilities;
using Microsoft.CodeAnalysis.Formatting;
using Microsoft.CodeAnalysis.Options;
using Microsoft.VisualStudio.LanguageServices.Setup;
using Microsoft.VisualStudio.TextManager.Interop;
using Roslyn.Utilities;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.Options
{
/// <summary>
/// An <see cref="IOptionPersister"/> that syncs core language settings against the settings that exist for all languages
/// in Visual Studio and whose backing store is provided by the shell. This includes things like default tab size, tabs vs. spaces, etc.
/// </summary>
internal sealed class LanguageSettingsPersister : ForegroundThreadAffinitizedObject, IVsTextManagerEvents4, IOptionPersister
{
private readonly IVsTextManager4 _textManager;
private readonly IGlobalOptionService _optionService;
#pragma warning disable IDE0052 // Remove unread private members - https://github.com/dotnet/roslyn/issues/46167
private readonly ComEventSink _textManagerEvents2Sink;
#pragma warning restore IDE0052 // Remove unread private members
/// <summary>
/// The mapping between language names and Visual Studio language service GUIDs.
/// </summary>
/// <remarks>
/// This is a map between string and <see cref="Tuple{Guid}"/> rather than just to <see cref="Guid"/>
/// to avoid a bunch of JIT during startup. Generics of value types like <see cref="Guid"/> will have to JIT
/// but the ngen image will exist for the basic map between two reference types, since those are reused.</remarks>
private readonly IBidirectionalMap<string, Tuple<Guid>> _languageMap;
/// <remarks>
/// We make sure this code is from the UI by asking for all <see cref="IOptionPersister"/> in <see cref="RoslynPackage.InitializeAsync"/>
/// </remarks>
public LanguageSettingsPersister(
IThreadingContext threadingContext,
IVsTextManager4 textManager,
IGlobalOptionService optionService)
: base(threadingContext, assertIsForeground: true)
{
_textManager = textManager;
_optionService = optionService;
// TODO: make this configurable
_languageMap = BidirectionalMap<string, Tuple<Guid>>.Empty.Add(LanguageNames.CSharp, Tuple.Create(Guids.CSharpLanguageServiceId))
.Add(LanguageNames.VisualBasic, Tuple.Create(Guids.VisualBasicLanguageServiceId))
.Add("TypeScript", Tuple.Create(new Guid("4a0dddb5-7a95-4fbf-97cc-616d07737a77")))
.Add("F#", Tuple.Create(new Guid("BC6DD5A5-D4D6-4dab-A00D-A51242DBAF1B")))
.Add("Xaml", Tuple.Create(new Guid("CD53C9A1-6BC2-412B-BE36-CC715ED8DD41")));
foreach (var languageGuid in _languageMap.Values)
{
var languagePreferences = new LANGPREFERENCES3[1];
languagePreferences[0].guidLang = languageGuid.Item1;
// The function can potentially fail if that language service isn't installed
if (ErrorHandler.Succeeded(_textManager.GetUserPreferences4(pViewPrefs: null, pLangPrefs: languagePreferences, pColorPrefs: null)))
{
RefreshLanguageSettings(languagePreferences);
}
}
_textManagerEvents2Sink = ComEventSink.Advise<IVsTextManagerEvents4>(_textManager, this);
}
private readonly IOption[] _supportedOptions = new IOption[]
{
FormattingOptions.UseTabs,
FormattingOptions.TabSize,
FormattingOptions.SmartIndent,
FormattingOptions.IndentationSize,
CompletionOptions.HideAdvancedMembers,
CompletionOptions.TriggerOnTyping,
SignatureHelpOptions.ShowSignatureHelp,
NavigationBarOptions.ShowNavigationBar,
BraceCompletionOptions.Enable,
};
int IVsTextManagerEvents4.OnUserPreferencesChanged4(
VIEWPREFERENCES3[] viewPrefs,
LANGPREFERENCES3[] langPrefs,
FONTCOLORPREFERENCES2[] colorPrefs)
{
if (langPrefs != null)
{
RefreshLanguageSettings(langPrefs);
}
return VSConstants.S_OK;
}
private void RefreshLanguageSettings(LANGPREFERENCES3[] langPrefs)
{
this.AssertIsForeground();
if (_languageMap.TryGetKey(Tuple.Create(langPrefs[0].guidLang), out var languageName))
{
foreach (var option in _supportedOptions)
{
var keyWithLanguage = new OptionKey(option, languageName);
var newValue = GetValueForOption(option, langPrefs[0]);
_optionService.RefreshOption(keyWithLanguage, newValue);
}
}
}
private static object GetValueForOption(IOption option, LANGPREFERENCES3 languagePreference)
{
if (option == FormattingOptions.UseTabs)
{
return languagePreference.fInsertTabs != 0;
}
else if (option == FormattingOptions.TabSize)
{
return Convert.ToInt32(languagePreference.uTabSize);
}
else if (option == FormattingOptions.IndentationSize)
{
return Convert.ToInt32(languagePreference.uIndentSize);
}
else if (option == FormattingOptions.SmartIndent)
{
switch (languagePreference.IndentStyle)
{
case vsIndentStyle.vsIndentStyleNone:
return FormattingOptions.IndentStyle.None;
case vsIndentStyle.vsIndentStyleDefault:
return FormattingOptions.IndentStyle.Block;
default:
return FormattingOptions.IndentStyle.Smart;
}
}
else if (option == CompletionOptions.HideAdvancedMembers)
{
return languagePreference.fHideAdvancedAutoListMembers != 0;
}
else if (option == CompletionOptions.TriggerOnTyping)
{
return languagePreference.fAutoListMembers != 0;
}
else if (option == SignatureHelpOptions.ShowSignatureHelp)
{
return languagePreference.fAutoListParams != 0;
}
else if (option == NavigationBarOptions.ShowNavigationBar)
{
return languagePreference.fDropdownBar != 0;
}
else if (option == BraceCompletionOptions.Enable)
{
return languagePreference.fBraceCompletion != 0;
}
else
{
throw new ArgumentException("Unexpected option.", nameof(option));
}
}
private static void SetValueForOption(IOption option, ref LANGPREFERENCES3 languagePreference, object value)
{
if (option == FormattingOptions.UseTabs)
{
languagePreference.fInsertTabs = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == FormattingOptions.TabSize)
{
languagePreference.uTabSize = Convert.ToUInt32(value);
}
else if (option == FormattingOptions.IndentationSize)
{
languagePreference.uIndentSize = Convert.ToUInt32(value);
}
else if (option == FormattingOptions.SmartIndent)
{
switch ((FormattingOptions.IndentStyle)value)
{
case FormattingOptions.IndentStyle.None:
languagePreference.IndentStyle = vsIndentStyle.vsIndentStyleNone;
break;
case FormattingOptions.IndentStyle.Block:
languagePreference.IndentStyle = vsIndentStyle.vsIndentStyleDefault;
break;
default:
languagePreference.IndentStyle = vsIndentStyle.vsIndentStyleSmart;
break;
}
}
else if (option == CompletionOptions.HideAdvancedMembers)
{
languagePreference.fHideAdvancedAutoListMembers = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == CompletionOptions.TriggerOnTyping)
{
languagePreference.fAutoListMembers = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == SignatureHelpOptions.ShowSignatureHelp)
{
languagePreference.fAutoListParams = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == NavigationBarOptions.ShowNavigationBar)
{
languagePreference.fDropdownBar = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == BraceCompletionOptions.Enable)
{
languagePreference.fBraceCompletion = Convert.ToUInt32((bool)value ? 1 : 0);
}
else
{
throw new ArgumentException("Unexpected option.", nameof(option));
}
}
public bool TryFetch(OptionKey optionKey, out object value)
{
// This particular serializer is a bit strange, since we have to initially read things out on the UI thread.
// Therefore, we refresh the values in the constructor, meaning that this should never get called for our values.
Contract.ThrowIfTrue(_supportedOptions.Contains(optionKey.Option) && _languageMap.ContainsKey(optionKey.Language));
value = null;
return false;
}
public bool TryPersist(OptionKey optionKey, object value)
{
if (!_supportedOptions.Contains(optionKey.Option))
{
return false;
}
if (!_languageMap.TryGetValue(optionKey.Language, out var languageServiceGuid))
{
return false;
}
var languagePreferences = new LANGPREFERENCES3[1];
languagePreferences[0].guidLang = languageServiceGuid.Item1;
Marshal.ThrowExceptionForHR(_textManager.GetUserPreferences4(null, languagePreferences, null));
SetValueForOption(optionKey.Option, ref languagePreferences[0], value);
_ = SetUserPreferencesMaybeAsync(languagePreferences);
// Even if we didn't call back, say we completed the persist
return true;
}
private async Task SetUserPreferencesMaybeAsync(LANGPREFERENCES3[] languagePreferences)
{
await ThreadingContext.JoinableTaskFactory.SwitchToMainThreadAsync();
Marshal.ThrowExceptionForHR(_textManager.SetUserPreferences4(pViewPrefs: null, pLangPrefs: languagePreferences, pColorPrefs: null));
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using System.Runtime.InteropServices;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Completion;
using Microsoft.CodeAnalysis.Editor.Options;
using Microsoft.CodeAnalysis.Editor.Shared.Utilities;
using Microsoft.CodeAnalysis.Formatting;
using Microsoft.CodeAnalysis.Options;
using Microsoft.VisualStudio.LanguageServices.Setup;
using Microsoft.VisualStudio.TextManager.Interop;
using Roslyn.Utilities;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.Options
{
/// <summary>
/// An <see cref="IOptionPersister"/> that syncs core language settings against the settings that exist for all languages
/// in Visual Studio and whose backing store is provided by the shell. This includes things like default tab size, tabs vs. spaces, etc.
/// </summary>
internal sealed class LanguageSettingsPersister : ForegroundThreadAffinitizedObject, IVsTextManagerEvents4, IOptionPersister
{
private readonly IVsTextManager4 _textManager;
private readonly IGlobalOptionService _optionService;
#pragma warning disable IDE0052 // Remove unread private members - https://github.com/dotnet/roslyn/issues/46167
private readonly ComEventSink _textManagerEvents2Sink;
#pragma warning restore IDE0052 // Remove unread private members
/// <summary>
/// The mapping between language names and Visual Studio language service GUIDs.
/// </summary>
/// <remarks>
/// This is a map between string and <see cref="Tuple{Guid}"/> rather than just to <see cref="Guid"/>
/// to avoid a bunch of JIT during startup. Generics of value types like <see cref="Guid"/> will have to JIT
/// but the ngen image will exist for the basic map between two reference types, since those are reused.</remarks>
private readonly IBidirectionalMap<string, Tuple<Guid>> _languageMap;
/// <remarks>
/// We make sure this code is from the UI by asking for all <see cref="IOptionPersister"/> in <see cref="RoslynPackage.InitializeAsync"/>
/// </remarks>
public LanguageSettingsPersister(
IThreadingContext threadingContext,
IVsTextManager4 textManager,
IGlobalOptionService optionService)
: base(threadingContext, assertIsForeground: true)
{
_textManager = textManager;
_optionService = optionService;
// TODO: make this configurable
_languageMap = BidirectionalMap<string, Tuple<Guid>>.Empty.Add(LanguageNames.CSharp, Tuple.Create(Guids.CSharpLanguageServiceId))
.Add(LanguageNames.VisualBasic, Tuple.Create(Guids.VisualBasicLanguageServiceId))
.Add(InternalLanguageNames.TypeScript, Tuple.Create(new Guid("4a0dddb5-7a95-4fbf-97cc-616d07737a77")))
.Add("F#", Tuple.Create(new Guid("BC6DD5A5-D4D6-4dab-A00D-A51242DBAF1B")))
.Add("Xaml", Tuple.Create(new Guid("CD53C9A1-6BC2-412B-BE36-CC715ED8DD41")));
foreach (var languageGuid in _languageMap.Values)
{
var languagePreferences = new LANGPREFERENCES3[1];
languagePreferences[0].guidLang = languageGuid.Item1;
// The function can potentially fail if that language service isn't installed
if (ErrorHandler.Succeeded(_textManager.GetUserPreferences4(pViewPrefs: null, pLangPrefs: languagePreferences, pColorPrefs: null)))
{
RefreshLanguageSettings(languagePreferences);
}
}
_textManagerEvents2Sink = ComEventSink.Advise<IVsTextManagerEvents4>(_textManager, this);
}
private readonly IOption[] _supportedOptions = new IOption[]
{
FormattingOptions.UseTabs,
FormattingOptions.TabSize,
FormattingOptions.SmartIndent,
FormattingOptions.IndentationSize,
CompletionOptions.HideAdvancedMembers,
CompletionOptions.TriggerOnTyping,
SignatureHelpOptions.ShowSignatureHelp,
NavigationBarOptions.ShowNavigationBar,
BraceCompletionOptions.Enable,
};
int IVsTextManagerEvents4.OnUserPreferencesChanged4(
VIEWPREFERENCES3[] viewPrefs,
LANGPREFERENCES3[] langPrefs,
FONTCOLORPREFERENCES2[] colorPrefs)
{
if (langPrefs != null)
{
RefreshLanguageSettings(langPrefs);
}
return VSConstants.S_OK;
}
private void RefreshLanguageSettings(LANGPREFERENCES3[] langPrefs)
{
this.AssertIsForeground();
if (_languageMap.TryGetKey(Tuple.Create(langPrefs[0].guidLang), out var languageName))
{
foreach (var option in _supportedOptions)
{
var keyWithLanguage = new OptionKey(option, languageName);
var newValue = GetValueForOption(option, langPrefs[0]);
_optionService.RefreshOption(keyWithLanguage, newValue);
}
}
}
private static object GetValueForOption(IOption option, LANGPREFERENCES3 languagePreference)
{
if (option == FormattingOptions.UseTabs)
{
return languagePreference.fInsertTabs != 0;
}
else if (option == FormattingOptions.TabSize)
{
return Convert.ToInt32(languagePreference.uTabSize);
}
else if (option == FormattingOptions.IndentationSize)
{
return Convert.ToInt32(languagePreference.uIndentSize);
}
else if (option == FormattingOptions.SmartIndent)
{
switch (languagePreference.IndentStyle)
{
case vsIndentStyle.vsIndentStyleNone:
return FormattingOptions.IndentStyle.None;
case vsIndentStyle.vsIndentStyleDefault:
return FormattingOptions.IndentStyle.Block;
default:
return FormattingOptions.IndentStyle.Smart;
}
}
else if (option == CompletionOptions.HideAdvancedMembers)
{
return languagePreference.fHideAdvancedAutoListMembers != 0;
}
else if (option == CompletionOptions.TriggerOnTyping)
{
return languagePreference.fAutoListMembers != 0;
}
else if (option == SignatureHelpOptions.ShowSignatureHelp)
{
return languagePreference.fAutoListParams != 0;
}
else if (option == NavigationBarOptions.ShowNavigationBar)
{
return languagePreference.fDropdownBar != 0;
}
else if (option == BraceCompletionOptions.Enable)
{
return languagePreference.fBraceCompletion != 0;
}
else
{
throw new ArgumentException("Unexpected option.", nameof(option));
}
}
private static void SetValueForOption(IOption option, ref LANGPREFERENCES3 languagePreference, object value)
{
if (option == FormattingOptions.UseTabs)
{
languagePreference.fInsertTabs = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == FormattingOptions.TabSize)
{
languagePreference.uTabSize = Convert.ToUInt32(value);
}
else if (option == FormattingOptions.IndentationSize)
{
languagePreference.uIndentSize = Convert.ToUInt32(value);
}
else if (option == FormattingOptions.SmartIndent)
{
switch ((FormattingOptions.IndentStyle)value)
{
case FormattingOptions.IndentStyle.None:
languagePreference.IndentStyle = vsIndentStyle.vsIndentStyleNone;
break;
case FormattingOptions.IndentStyle.Block:
languagePreference.IndentStyle = vsIndentStyle.vsIndentStyleDefault;
break;
default:
languagePreference.IndentStyle = vsIndentStyle.vsIndentStyleSmart;
break;
}
}
else if (option == CompletionOptions.HideAdvancedMembers)
{
languagePreference.fHideAdvancedAutoListMembers = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == CompletionOptions.TriggerOnTyping)
{
languagePreference.fAutoListMembers = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == SignatureHelpOptions.ShowSignatureHelp)
{
languagePreference.fAutoListParams = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == NavigationBarOptions.ShowNavigationBar)
{
languagePreference.fDropdownBar = Convert.ToUInt32((bool)value ? 1 : 0);
}
else if (option == BraceCompletionOptions.Enable)
{
languagePreference.fBraceCompletion = Convert.ToUInt32((bool)value ? 1 : 0);
}
else
{
throw new ArgumentException("Unexpected option.", nameof(option));
}
}
public bool TryFetch(OptionKey optionKey, out object value)
{
// This particular serializer is a bit strange, since we have to initially read things out on the UI thread.
// Therefore, we refresh the values in the constructor, meaning that this should never get called for our values.
Contract.ThrowIfTrue(_supportedOptions.Contains(optionKey.Option) && _languageMap.ContainsKey(optionKey.Language));
value = null;
return false;
}
public bool TryPersist(OptionKey optionKey, object value)
{
if (!_supportedOptions.Contains(optionKey.Option))
{
return false;
}
if (!_languageMap.TryGetValue(optionKey.Language, out var languageServiceGuid))
{
return false;
}
var languagePreferences = new LANGPREFERENCES3[1];
languagePreferences[0].guidLang = languageServiceGuid.Item1;
Marshal.ThrowExceptionForHR(_textManager.GetUserPreferences4(null, languagePreferences, null));
SetValueForOption(optionKey.Option, ref languagePreferences[0], value);
_ = SetUserPreferencesMaybeAsync(languagePreferences);
// Even if we didn't call back, say we completed the persist
return true;
}
private async Task SetUserPreferencesMaybeAsync(LANGPREFERENCES3[] languagePreferences)
{
await ThreadingContext.JoinableTaskFactory.SwitchToMainThreadAsync();
Marshal.ThrowExceptionForHR(_textManager.SetUserPreferences4(pViewPrefs: null, pLangPrefs: languagePreferences, pColorPrefs: null));
}
}
}
| 1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Analyzers/CSharp/CodeFixes/SimplifyLinqExpression/CSharpSimplifyLinqExpressionCodeFixProvider.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Composition;
using System.Diagnostics.CodeAnalysis;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysis.CSharp.LanguageServices;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.LanguageServices;
using Microsoft.CodeAnalysis.SimplifyLinqExpression;
namespace Microsoft.CodeAnalysis.CSharp.SimplifyLinqExpression
{
[ExportCodeFixProvider(LanguageNames.CSharp, Name = PredefinedCodeFixProviderNames.SimplifyLinqExpression), Shared]
internal sealed class CSharpSimplifyLinqExpressionCodeFixProvider : AbstractSimplifyLinqExpressionCodeFixProvider<InvocationExpressionSyntax, SimpleNameSyntax, ExpressionSyntax>
{
[ImportingConstructor]
[SuppressMessage("RoslynDiagnosticsReliability", "RS0033:Importing constructor should be [Obsolete]", Justification = "Used in test code: https://github.com/dotnet/roslyn/issues/42814")]
public CSharpSimplifyLinqExpressionCodeFixProvider()
{
}
protected override ISyntaxFacts SyntaxFacts => CSharpSyntaxFacts.Instance;
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Composition;
using System.Diagnostics.CodeAnalysis;
using Microsoft.CodeAnalysis.CodeFixes;
using Microsoft.CodeAnalysis.CSharp.LanguageServices;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.LanguageServices;
using Microsoft.CodeAnalysis.SimplifyLinqExpression;
namespace Microsoft.CodeAnalysis.CSharp.SimplifyLinqExpression
{
[ExportCodeFixProvider(LanguageNames.CSharp, Name = PredefinedCodeFixProviderNames.SimplifyLinqExpression), Shared]
internal sealed class CSharpSimplifyLinqExpressionCodeFixProvider : AbstractSimplifyLinqExpressionCodeFixProvider<InvocationExpressionSyntax, SimpleNameSyntax, ExpressionSyntax>
{
[ImportingConstructor]
[SuppressMessage("RoslynDiagnosticsReliability", "RS0033:Importing constructor should be [Obsolete]", Justification = "Used in test code: https://github.com/dotnet/roslyn/issues/42814")]
public CSharpSimplifyLinqExpressionCodeFixProvider()
{
}
protected override ISyntaxFacts SyntaxFacts => CSharpSyntaxFacts.Instance;
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Workspaces/SharedUtilitiesAndExtensions/Workspace/Core/LanguageServices/TypeInferenceService/AbstractTypeInferenceService.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Linq;
using System.Threading;
namespace Microsoft.CodeAnalysis.LanguageServices.TypeInferenceService
{
internal abstract partial class AbstractTypeInferenceService : ITypeInferenceService
{
protected abstract AbstractTypeInferrer CreateTypeInferrer(SemanticModel semanticModel, CancellationToken cancellationToken);
private static ImmutableArray<ITypeSymbol> InferTypeBasedOnNameIfEmpty(
SemanticModel semanticModel, ImmutableArray<ITypeSymbol> result, string nameOpt)
{
if (result.IsEmpty && nameOpt != null)
{
return InferTypeBasedOnName(semanticModel, nameOpt);
}
return result;
}
private static ImmutableArray<TypeInferenceInfo> InferTypeBasedOnNameIfEmpty(
SemanticModel semanticModel, ImmutableArray<TypeInferenceInfo> result, string nameOpt)
{
if (result.IsEmpty && nameOpt != null)
{
var types = InferTypeBasedOnName(semanticModel, nameOpt);
return types.SelectAsArray(t => new TypeInferenceInfo(t));
}
return result;
}
private static readonly ImmutableArray<string> s_booleanPrefixes =
ImmutableArray.Create("Is", "Has", "Contains", "Supports");
private static ImmutableArray<ITypeSymbol> InferTypeBasedOnName(
SemanticModel semanticModel, string name)
{
var matchesBoolean = MatchesBoolean(name);
return matchesBoolean
? ImmutableArray.Create<ITypeSymbol>(semanticModel.Compilation.GetSpecialType(SpecialType.System_Boolean))
: ImmutableArray<ITypeSymbol>.Empty;
}
private static bool MatchesBoolean(string name)
{
foreach (var prefix in s_booleanPrefixes)
{
if (Matches(name, prefix))
{
return true;
}
}
return false;
}
private static bool Matches(string name, string prefix)
{
if (name.StartsWith(prefix))
{
if (name.Length == prefix.Length)
{
return true;
}
var nextChar = name[prefix.Length];
return !char.IsLower(nextChar);
}
return false;
}
public ImmutableArray<ITypeSymbol> InferTypes(
SemanticModel semanticModel, int position,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken)
.InferTypes(position)
.Select(t => t.InferredType)
.ToImmutableArray();
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
public ImmutableArray<ITypeSymbol> InferTypes(
SemanticModel semanticModel, SyntaxNode expression,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken)
.InferTypes(expression)
.Select(info => info.InferredType)
.ToImmutableArray();
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
public ImmutableArray<TypeInferenceInfo> GetTypeInferenceInfo(
SemanticModel semanticModel, int position,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken).InferTypes(position);
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
public ImmutableArray<TypeInferenceInfo> GetTypeInferenceInfo(
SemanticModel semanticModel, SyntaxNode expression,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken).InferTypes(expression);
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Linq;
using System.Threading;
namespace Microsoft.CodeAnalysis.LanguageServices.TypeInferenceService
{
internal abstract partial class AbstractTypeInferenceService : ITypeInferenceService
{
protected abstract AbstractTypeInferrer CreateTypeInferrer(SemanticModel semanticModel, CancellationToken cancellationToken);
private static ImmutableArray<ITypeSymbol> InferTypeBasedOnNameIfEmpty(
SemanticModel semanticModel, ImmutableArray<ITypeSymbol> result, string nameOpt)
{
if (result.IsEmpty && nameOpt != null)
{
return InferTypeBasedOnName(semanticModel, nameOpt);
}
return result;
}
private static ImmutableArray<TypeInferenceInfo> InferTypeBasedOnNameIfEmpty(
SemanticModel semanticModel, ImmutableArray<TypeInferenceInfo> result, string nameOpt)
{
if (result.IsEmpty && nameOpt != null)
{
var types = InferTypeBasedOnName(semanticModel, nameOpt);
return types.SelectAsArray(t => new TypeInferenceInfo(t));
}
return result;
}
private static readonly ImmutableArray<string> s_booleanPrefixes =
ImmutableArray.Create("Is", "Has", "Contains", "Supports");
private static ImmutableArray<ITypeSymbol> InferTypeBasedOnName(
SemanticModel semanticModel, string name)
{
var matchesBoolean = MatchesBoolean(name);
return matchesBoolean
? ImmutableArray.Create<ITypeSymbol>(semanticModel.Compilation.GetSpecialType(SpecialType.System_Boolean))
: ImmutableArray<ITypeSymbol>.Empty;
}
private static bool MatchesBoolean(string name)
{
foreach (var prefix in s_booleanPrefixes)
{
if (Matches(name, prefix))
{
return true;
}
}
return false;
}
private static bool Matches(string name, string prefix)
{
if (name.StartsWith(prefix))
{
if (name.Length == prefix.Length)
{
return true;
}
var nextChar = name[prefix.Length];
return !char.IsLower(nextChar);
}
return false;
}
public ImmutableArray<ITypeSymbol> InferTypes(
SemanticModel semanticModel, int position,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken)
.InferTypes(position)
.Select(t => t.InferredType)
.ToImmutableArray();
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
public ImmutableArray<ITypeSymbol> InferTypes(
SemanticModel semanticModel, SyntaxNode expression,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken)
.InferTypes(expression)
.Select(info => info.InferredType)
.ToImmutableArray();
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
public ImmutableArray<TypeInferenceInfo> GetTypeInferenceInfo(
SemanticModel semanticModel, int position,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken).InferTypes(position);
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
public ImmutableArray<TypeInferenceInfo> GetTypeInferenceInfo(
SemanticModel semanticModel, SyntaxNode expression,
string nameOpt, CancellationToken cancellationToken)
{
var result = CreateTypeInferrer(semanticModel, cancellationToken).InferTypes(expression);
return InferTypeBasedOnNameIfEmpty(semanticModel, result, nameOpt);
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/VisualStudio/IntegrationTest/TestUtilities/Input/ButtonBaseExtensions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Reflection;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Automation.Peers;
using System.Windows.Automation.Provider;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Input;
using Microsoft.VisualStudio.Threading;
namespace Microsoft.VisualStudio.IntegrationTest.Utilities.Input
{
public static class ButtonBaseExtensions
{
private static readonly MethodInfo s_executeCoreMethod;
static ButtonBaseExtensions()
{
var methodInfo = typeof(RoutedCommand).GetMethod("ExecuteCore", BindingFlags.Instance | BindingFlags.NonPublic, null, new[] { typeof(object), typeof(IInputElement), typeof(bool) }, null);
s_executeCoreMethod = methodInfo;
//s_executeCore = (Action<RoutedCommand, object, IInputElement, bool>)Delegate.CreateDelegate(typeof(Action<RoutedCommand, object, IInputElement, bool>), firstArgument: null, methodInfo);
}
public static async Task<bool> SimulateClickAsync(this ButtonBase button, JoinableTaskFactory joinableTaskFactory)
{
await joinableTaskFactory.SwitchToMainThreadAsync();
if (!button.IsEnabled || !button.IsVisible)
{
return false;
}
if (button is RadioButton radioButton)
{
ISelectionItemProvider peer = new RadioButtonAutomationPeer(radioButton);
peer.Select();
}
else if (button is Button button2)
{
IInvokeProvider peer = new ButtonAutomationPeer(button2);
peer.Invoke();
}
else
{
button.RaiseEvent(new RoutedEventArgs(ButtonBase.ClickEvent));
ExecuteCommandSource(button, true);
}
// Wait for changes to propagate
await Task.Yield();
return true;
}
private static void ExecuteCommandSource(ICommandSource commandSource, bool userInitiated)
{
var command = commandSource.Command;
if (command is null)
{
return;
}
var commandParameter = commandSource.CommandParameter;
var commandTarget = commandSource.CommandTarget;
if (command is RoutedCommand routedCommand)
{
if (commandTarget is null)
{
commandTarget = commandSource as IInputElement;
}
if (routedCommand.CanExecute(commandParameter, commandTarget))
{
s_executeCoreMethod.Invoke(routedCommand, new[] { commandParameter, commandTarget, userInitiated });
//s_executeCore(routedCommand, commandParameter, commandTarget, userInitiated);
}
}
else if (command.CanExecute(commandParameter))
{
command.Execute(commandParameter);
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Reflection;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Automation.Peers;
using System.Windows.Automation.Provider;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;
using System.Windows.Input;
using Microsoft.VisualStudio.Threading;
namespace Microsoft.VisualStudio.IntegrationTest.Utilities.Input
{
public static class ButtonBaseExtensions
{
private static readonly MethodInfo s_executeCoreMethod;
static ButtonBaseExtensions()
{
var methodInfo = typeof(RoutedCommand).GetMethod("ExecuteCore", BindingFlags.Instance | BindingFlags.NonPublic, null, new[] { typeof(object), typeof(IInputElement), typeof(bool) }, null);
s_executeCoreMethod = methodInfo;
//s_executeCore = (Action<RoutedCommand, object, IInputElement, bool>)Delegate.CreateDelegate(typeof(Action<RoutedCommand, object, IInputElement, bool>), firstArgument: null, methodInfo);
}
public static async Task<bool> SimulateClickAsync(this ButtonBase button, JoinableTaskFactory joinableTaskFactory)
{
await joinableTaskFactory.SwitchToMainThreadAsync();
if (!button.IsEnabled || !button.IsVisible)
{
return false;
}
if (button is RadioButton radioButton)
{
ISelectionItemProvider peer = new RadioButtonAutomationPeer(radioButton);
peer.Select();
}
else if (button is Button button2)
{
IInvokeProvider peer = new ButtonAutomationPeer(button2);
peer.Invoke();
}
else
{
button.RaiseEvent(new RoutedEventArgs(ButtonBase.ClickEvent));
ExecuteCommandSource(button, true);
}
// Wait for changes to propagate
await Task.Yield();
return true;
}
private static void ExecuteCommandSource(ICommandSource commandSource, bool userInitiated)
{
var command = commandSource.Command;
if (command is null)
{
return;
}
var commandParameter = commandSource.CommandParameter;
var commandTarget = commandSource.CommandTarget;
if (command is RoutedCommand routedCommand)
{
if (commandTarget is null)
{
commandTarget = commandSource as IInputElement;
}
if (routedCommand.CanExecute(commandParameter, commandTarget))
{
s_executeCoreMethod.Invoke(routedCommand, new[] { commandParameter, commandTarget, userInitiated });
//s_executeCore(routedCommand, commandParameter, commandTarget, userInitiated);
}
}
else if (command.CanExecute(commandParameter))
{
command.Execute(commandParameter);
}
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Workspaces/Core/Portable/Shared/Extensions/ITypeParameterSymbolExtensions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Linq;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Shared.Extensions
{
internal static class ITypeParameterSymbolExtensions
{
public static INamedTypeSymbol? GetNamedTypeSymbolConstraint(this ITypeParameterSymbol typeParameter)
=> typeParameter.ConstraintTypes.Select(GetNamedTypeSymbol).WhereNotNull().FirstOrDefault();
private static INamedTypeSymbol? GetNamedTypeSymbol(ITypeSymbol type)
{
return type is INamedTypeSymbol
? (INamedTypeSymbol)type
: type is ITypeParameterSymbol
? GetNamedTypeSymbolConstraint((ITypeParameterSymbol)type)
: null;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Linq;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.Shared.Extensions
{
internal static class ITypeParameterSymbolExtensions
{
public static INamedTypeSymbol? GetNamedTypeSymbolConstraint(this ITypeParameterSymbol typeParameter)
=> typeParameter.ConstraintTypes.Select(GetNamedTypeSymbol).WhereNotNull().FirstOrDefault();
private static INamedTypeSymbol? GetNamedTypeSymbol(ITypeSymbol type)
{
return type is INamedTypeSymbol
? (INamedTypeSymbol)type
: type is ITypeParameterSymbol
? GetNamedTypeSymbolConstraint((ITypeParameterSymbol)type)
: null;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/VisualStudio/Core/Def/Interactive/ScriptingOleCommandTarget.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using Microsoft.CodeAnalysis.Editor;
using Microsoft.CodeAnalysis.Editor.Shared.Extensions;
using Microsoft.VisualStudio.ComponentModelHost;
using Microsoft.VisualStudio.InteractiveWindow.Commands;
using Microsoft.VisualStudio.LanguageServices.Implementation;
using Microsoft.VisualStudio.Text;
using Microsoft.VisualStudio.Text.Editor;
namespace Microsoft.VisualStudio.LanguageServices.Interactive
{
/// <summary>
/// This command target routes commands in interactive window, .csx files and also interactive
/// commands in .cs files.
/// </summary>
internal sealed class ScriptingOleCommandTarget : AbstractOleCommandTarget
{
internal ScriptingOleCommandTarget(
IWpfTextView wpfTextView,
IComponentModel componentModel)
: base(wpfTextView, componentModel)
{
}
protected override ITextBuffer? GetSubjectBufferContainingCaret()
{
var result = WpfTextView.GetBufferContainingCaret(contentType: ContentTypeNames.RoslynContentType);
if (result == null)
{
result = WpfTextView.GetBufferContainingCaret(contentType: PredefinedInteractiveCommandsContentTypes.InteractiveCommandContentTypeName);
}
return result;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using Microsoft.CodeAnalysis.Editor;
using Microsoft.CodeAnalysis.Editor.Shared.Extensions;
using Microsoft.VisualStudio.ComponentModelHost;
using Microsoft.VisualStudio.InteractiveWindow.Commands;
using Microsoft.VisualStudio.LanguageServices.Implementation;
using Microsoft.VisualStudio.Text;
using Microsoft.VisualStudio.Text.Editor;
namespace Microsoft.VisualStudio.LanguageServices.Interactive
{
/// <summary>
/// This command target routes commands in interactive window, .csx files and also interactive
/// commands in .cs files.
/// </summary>
internal sealed class ScriptingOleCommandTarget : AbstractOleCommandTarget
{
internal ScriptingOleCommandTarget(
IWpfTextView wpfTextView,
IComponentModel componentModel)
: base(wpfTextView, componentModel)
{
}
protected override ITextBuffer? GetSubjectBufferContainingCaret()
{
var result = WpfTextView.GetBufferContainingCaret(contentType: ContentTypeNames.RoslynContentType);
if (result == null)
{
result = WpfTextView.GetBufferContainingCaret(contentType: PredefinedInteractiveCommandsContentTypes.InteractiveCommandContentTypeName);
}
return result;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Features/Core/Portable/LanguageServices/ProjectInfoService/IProjectInfoService.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.Host;
namespace Microsoft.CodeAnalysis.LanguageServices.ProjectInfoService
{
internal interface IProjectInfoService : IWorkspaceService
{
bool GeneratedTypesMustBePublic(Project project);
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.CodeAnalysis.Host;
namespace Microsoft.CodeAnalysis.LanguageServices.ProjectInfoService
{
internal interface IProjectInfoService : IWorkspaceService
{
bool GeneratedTypesMustBePublic(Project project);
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/Core/CodeAnalysisTest/MetadataReferences/FusionAssemblyIdentityTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Globalization;
using System.IO;
using System.Reflection;
using Xunit;
using Roslyn.Test.Utilities;
namespace Microsoft.CodeAnalysis.UnitTests.MetadataReferences
{
public class FusionAssemblyIdentityTests
{
/// <summary>
/// Converts <see cref="FusionAssemblyIdentity.IAssemblyName"/> to <see cref="AssemblyName"/> with possibly
/// missing name components.
/// </summary>
/// <returns>
/// An <see cref="AssemblyName"/> whose fields are be null if not present in <paramref name="nameObject"/>.
/// </returns>
internal static AssemblyName ToAssemblyName(FusionAssemblyIdentity.IAssemblyName nameObject)
{
var result = new AssemblyName();
result.Name = FusionAssemblyIdentity.GetName(nameObject);
result.Version = FusionAssemblyIdentity.GetVersion(nameObject);
var cultureName = FusionAssemblyIdentity.GetCulture(nameObject);
result.CultureInfo = (cultureName != null) ? new CultureInfo(cultureName) : null;
byte[] publicKey = FusionAssemblyIdentity.GetPublicKey(nameObject);
if (publicKey != null && publicKey.Length != 0)
{
result.SetPublicKey(publicKey);
}
else
{
result.SetPublicKeyToken(FusionAssemblyIdentity.GetPublicKeyToken(nameObject));
}
result.Flags = FusionAssemblyIdentity.GetFlags(nameObject);
result.ContentType = FusionAssemblyIdentity.GetContentType(nameObject);
return result;
}
private void RoundTrip(AssemblyName name, bool testFullName = true)
{
AssemblyName rtName;
FusionAssemblyIdentity.IAssemblyName obj;
if (testFullName)
{
string fullName = name.FullName;
obj = FusionAssemblyIdentity.ToAssemblyNameObject(fullName);
rtName = ToAssemblyName(obj);
Assert.Equal(name.Name, rtName.Name);
Assert.Equal(name.Version, rtName.Version);
Assert.Equal(name.CultureInfo, rtName.CultureInfo);
Assert.Equal(name.GetPublicKeyToken(), rtName.GetPublicKeyToken());
Assert.Equal(name.Flags, rtName.Flags);
Assert.Equal(name.ContentType, rtName.ContentType);
string displayName = FusionAssemblyIdentity.GetDisplayName(obj, FusionAssemblyIdentity.ASM_DISPLAYF.FULL);
Assert.Equal(fullName, displayName);
}
obj = FusionAssemblyIdentity.ToAssemblyNameObject(name);
rtName = ToAssemblyName(obj);
Assert.Equal(name.Name, rtName.Name);
Assert.Equal(name.Version, rtName.Version);
Assert.Equal(name.CultureInfo, rtName.CultureInfo);
Assert.Equal(name.GetPublicKeyToken(), rtName.GetPublicKeyToken());
Assert.Equal(name.Flags, rtName.Flags);
Assert.Equal(name.ContentType, rtName.ContentType);
}
[ConditionalFact(typeof(WindowsDesktopOnly), Reason = ConditionalSkipReason.TestExecutionNeedsFusion)]
public void FusionAssemblyNameRoundTrip()
{
RoundTrip(new AssemblyName("goo"));
RoundTrip(new AssemblyName { Name = "~!@#$%^&*()_+={}:\"<>?[];',./" });
RoundTrip(new AssemblyName("\\,"));
RoundTrip(new AssemblyName("\\\""));
RoundTrip(new AssemblyIdentity("goo").ToAssemblyName());
// 0xffff version is not included in AssemblyName.FullName for some reason:
var name = new AssemblyIdentity("goo", version: new Version(0xffff, 0xffff, 0xffff, 0xffff)).ToAssemblyName();
RoundTrip(name, testFullName: false);
var obj = FusionAssemblyIdentity.ToAssemblyNameObject(name);
var display = FusionAssemblyIdentity.GetDisplayName(obj, FusionAssemblyIdentity.ASM_DISPLAYF.FULL);
Assert.Equal("goo, Version=65535.65535.65535.65535, Culture=neutral, PublicKeyToken=null", display);
RoundTrip(new AssemblyIdentity("goo", version: new Version(1, 2, 3, 4)).ToAssemblyName());
RoundTrip(new AssemblyName("goo") { Version = new Version(1, 2, 3, 4) });
RoundTrip(new AssemblyIdentity("goo", cultureName: CultureInfo.CurrentCulture.Name).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", cultureName: "").ToAssemblyName());
RoundTrip(new AssemblyName("goo") { CultureInfo = CultureInfo.InvariantCulture });
RoundTrip(new AssemblyIdentity("goo", version: new Version(1, 2, 3, 4), cultureName: "en-US").ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", publicKeyOrToken: new byte[] { 1, 2, 3, 4, 5, 6, 7, 8 }.AsImmutableOrNull()).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", version: new Version(1, 2, 3, 4), cultureName: CultureInfo.CurrentCulture.Name, publicKeyOrToken: new byte[] { 1, 2, 3, 4, 5, 6, 7, 8 }.AsImmutableOrNull()).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", isRetargetable: true).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", contentType: AssemblyContentType.WindowsRuntime).ToAssemblyName());
}
[ConditionalFact(typeof(WindowsDesktopOnly), Reason = ConditionalSkipReason.TestExecutionNeedsFusion)]
public void FusionGetBestMatch()
{
var goo = FusionAssemblyIdentity.ToAssemblyNameObject("goo");
var goo1 = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=1.0.0.0, Culture=neutral");
var goo2 = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=2.0.0.0, Culture=neutral");
var goo3 = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=3.0.0.0, Culture=neutral");
var goo3_enUS = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=3.0.0.0, Culture=en-US");
var goo3_deDE = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=3.0.0.0, Culture=de-DE");
var m = FusionAssemblyIdentity.GetBestMatch(new[] { goo2, goo1, goo3 }, null);
Assert.Equal(goo3, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo3, goo2, goo1 }, null);
Assert.Equal(goo3, m);
// only simple name is used
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo2, goo3 }, null);
Assert.Equal(goo3, m);
// the first match if preferred cultures not specified
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3_deDE, goo3_enUS, goo2 }, null);
Assert.Equal(goo3_deDE, m);
// the first match if preferred cultures not specified
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3_deDE, goo3_enUS, goo2 }, null);
Assert.Equal(goo3_deDE, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3, goo3_deDE, goo3_enUS, goo2 }, "en-US");
Assert.Equal(goo3_enUS, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3_deDE, goo3, goo3_enUS, goo2 }, "cz-CZ");
Assert.Equal(goo3, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo3_deDE, goo2 }, "en-US");
Assert.Equal(goo3_deDE, m);
// neutral culture wins over specific non-matching one:
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo3_deDE, goo3, goo2 }, "en-US");
Assert.Equal(goo3, m);
}
[ConditionalFact(typeof(WindowsDesktopOnly), Reason = ConditionalSkipReason.TestExecutionNeedsFusion)]
public void FusionToAssemblyName()
{
var nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib");
var name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Null(name.Version);
Assert.Null(name.CultureInfo);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0");
name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Equal(new Version(2, 0, 0, 0), name.Version);
Assert.Null(name.CultureInfo);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=neutral");
name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Equal(new Version(2, 0, 0, 0), name.Version);
Assert.Equal(name.CultureInfo, CultureInfo.InvariantCulture);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=en-US");
name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Equal(new Version(2, 0, 0, 0), name.Version);
Assert.NotNull(name.CultureInfo);
Assert.Equal("en-US", name.CultureInfo.Name);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("Windows, Version=255.255.255.255, ContentType=WindowsRuntime");
name = ToAssemblyName(nameObject);
Assert.Equal("Windows", name.Name);
Assert.Equal(new Version(255, 255, 255, 255), name.Version);
Assert.Null(name.CultureInfo);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.WindowsRuntime, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=nonsense");
Assert.NotNull(nameObject);
Assert.Throws<CultureNotFoundException>(() => ToAssemblyName(nameObject));
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=null");
Assert.NotNull(nameObject);
Assert.Throws<CultureNotFoundException>(() => ToAssemblyName(nameObject));
Assert.Throws<CultureNotFoundException>(() => new AssemblyName("mscorlib, Version=2.0.0.0, Culture=nonsense"));
Assert.Throws<CultureNotFoundException>(() => new AssemblyName("mscorlib, Version=2.0.0.0, Culture=null"));
Assert.Throws<ArgumentException>(() => FusionAssemblyIdentity.ToAssemblyNameObject(new AssemblyName { Name = "x\0x" }));
// invalid characters are ok in the name, the FullName can't be built though:
foreach (char c in AssemblyIdentityTests.ClrInvalidCharacters)
{
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject(new AssemblyName { Name = c.ToString() });
name = ToAssemblyName(nameObject);
Assert.Equal(c.ToString(), name.Name);
Assert.Throws<FileLoadException>(() => name.FullName);
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Globalization;
using System.IO;
using System.Reflection;
using Xunit;
using Roslyn.Test.Utilities;
namespace Microsoft.CodeAnalysis.UnitTests.MetadataReferences
{
public class FusionAssemblyIdentityTests
{
/// <summary>
/// Converts <see cref="FusionAssemblyIdentity.IAssemblyName"/> to <see cref="AssemblyName"/> with possibly
/// missing name components.
/// </summary>
/// <returns>
/// An <see cref="AssemblyName"/> whose fields are be null if not present in <paramref name="nameObject"/>.
/// </returns>
internal static AssemblyName ToAssemblyName(FusionAssemblyIdentity.IAssemblyName nameObject)
{
var result = new AssemblyName();
result.Name = FusionAssemblyIdentity.GetName(nameObject);
result.Version = FusionAssemblyIdentity.GetVersion(nameObject);
var cultureName = FusionAssemblyIdentity.GetCulture(nameObject);
result.CultureInfo = (cultureName != null) ? new CultureInfo(cultureName) : null;
byte[] publicKey = FusionAssemblyIdentity.GetPublicKey(nameObject);
if (publicKey != null && publicKey.Length != 0)
{
result.SetPublicKey(publicKey);
}
else
{
result.SetPublicKeyToken(FusionAssemblyIdentity.GetPublicKeyToken(nameObject));
}
result.Flags = FusionAssemblyIdentity.GetFlags(nameObject);
result.ContentType = FusionAssemblyIdentity.GetContentType(nameObject);
return result;
}
private void RoundTrip(AssemblyName name, bool testFullName = true)
{
AssemblyName rtName;
FusionAssemblyIdentity.IAssemblyName obj;
if (testFullName)
{
string fullName = name.FullName;
obj = FusionAssemblyIdentity.ToAssemblyNameObject(fullName);
rtName = ToAssemblyName(obj);
Assert.Equal(name.Name, rtName.Name);
Assert.Equal(name.Version, rtName.Version);
Assert.Equal(name.CultureInfo, rtName.CultureInfo);
Assert.Equal(name.GetPublicKeyToken(), rtName.GetPublicKeyToken());
Assert.Equal(name.Flags, rtName.Flags);
Assert.Equal(name.ContentType, rtName.ContentType);
string displayName = FusionAssemblyIdentity.GetDisplayName(obj, FusionAssemblyIdentity.ASM_DISPLAYF.FULL);
Assert.Equal(fullName, displayName);
}
obj = FusionAssemblyIdentity.ToAssemblyNameObject(name);
rtName = ToAssemblyName(obj);
Assert.Equal(name.Name, rtName.Name);
Assert.Equal(name.Version, rtName.Version);
Assert.Equal(name.CultureInfo, rtName.CultureInfo);
Assert.Equal(name.GetPublicKeyToken(), rtName.GetPublicKeyToken());
Assert.Equal(name.Flags, rtName.Flags);
Assert.Equal(name.ContentType, rtName.ContentType);
}
[ConditionalFact(typeof(WindowsDesktopOnly), Reason = ConditionalSkipReason.TestExecutionNeedsFusion)]
public void FusionAssemblyNameRoundTrip()
{
RoundTrip(new AssemblyName("goo"));
RoundTrip(new AssemblyName { Name = "~!@#$%^&*()_+={}:\"<>?[];',./" });
RoundTrip(new AssemblyName("\\,"));
RoundTrip(new AssemblyName("\\\""));
RoundTrip(new AssemblyIdentity("goo").ToAssemblyName());
// 0xffff version is not included in AssemblyName.FullName for some reason:
var name = new AssemblyIdentity("goo", version: new Version(0xffff, 0xffff, 0xffff, 0xffff)).ToAssemblyName();
RoundTrip(name, testFullName: false);
var obj = FusionAssemblyIdentity.ToAssemblyNameObject(name);
var display = FusionAssemblyIdentity.GetDisplayName(obj, FusionAssemblyIdentity.ASM_DISPLAYF.FULL);
Assert.Equal("goo, Version=65535.65535.65535.65535, Culture=neutral, PublicKeyToken=null", display);
RoundTrip(new AssemblyIdentity("goo", version: new Version(1, 2, 3, 4)).ToAssemblyName());
RoundTrip(new AssemblyName("goo") { Version = new Version(1, 2, 3, 4) });
RoundTrip(new AssemblyIdentity("goo", cultureName: CultureInfo.CurrentCulture.Name).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", cultureName: "").ToAssemblyName());
RoundTrip(new AssemblyName("goo") { CultureInfo = CultureInfo.InvariantCulture });
RoundTrip(new AssemblyIdentity("goo", version: new Version(1, 2, 3, 4), cultureName: "en-US").ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", publicKeyOrToken: new byte[] { 1, 2, 3, 4, 5, 6, 7, 8 }.AsImmutableOrNull()).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", version: new Version(1, 2, 3, 4), cultureName: CultureInfo.CurrentCulture.Name, publicKeyOrToken: new byte[] { 1, 2, 3, 4, 5, 6, 7, 8 }.AsImmutableOrNull()).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", isRetargetable: true).ToAssemblyName());
RoundTrip(new AssemblyIdentity("goo", contentType: AssemblyContentType.WindowsRuntime).ToAssemblyName());
}
[ConditionalFact(typeof(WindowsDesktopOnly), Reason = ConditionalSkipReason.TestExecutionNeedsFusion)]
public void FusionGetBestMatch()
{
var goo = FusionAssemblyIdentity.ToAssemblyNameObject("goo");
var goo1 = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=1.0.0.0, Culture=neutral");
var goo2 = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=2.0.0.0, Culture=neutral");
var goo3 = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=3.0.0.0, Culture=neutral");
var goo3_enUS = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=3.0.0.0, Culture=en-US");
var goo3_deDE = FusionAssemblyIdentity.ToAssemblyNameObject("goo, Version=3.0.0.0, Culture=de-DE");
var m = FusionAssemblyIdentity.GetBestMatch(new[] { goo2, goo1, goo3 }, null);
Assert.Equal(goo3, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo3, goo2, goo1 }, null);
Assert.Equal(goo3, m);
// only simple name is used
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo2, goo3 }, null);
Assert.Equal(goo3, m);
// the first match if preferred cultures not specified
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3_deDE, goo3_enUS, goo2 }, null);
Assert.Equal(goo3_deDE, m);
// the first match if preferred cultures not specified
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3_deDE, goo3_enUS, goo2 }, null);
Assert.Equal(goo3_deDE, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3, goo3_deDE, goo3_enUS, goo2 }, "en-US");
Assert.Equal(goo3_enUS, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo1, goo3_deDE, goo3, goo3_enUS, goo2 }, "cz-CZ");
Assert.Equal(goo3, m);
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo3_deDE, goo2 }, "en-US");
Assert.Equal(goo3_deDE, m);
// neutral culture wins over specific non-matching one:
m = FusionAssemblyIdentity.GetBestMatch(new[] { goo3_deDE, goo3, goo2 }, "en-US");
Assert.Equal(goo3, m);
}
[ConditionalFact(typeof(WindowsDesktopOnly), Reason = ConditionalSkipReason.TestExecutionNeedsFusion)]
public void FusionToAssemblyName()
{
var nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib");
var name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Null(name.Version);
Assert.Null(name.CultureInfo);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0");
name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Equal(new Version(2, 0, 0, 0), name.Version);
Assert.Null(name.CultureInfo);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=neutral");
name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Equal(new Version(2, 0, 0, 0), name.Version);
Assert.Equal(name.CultureInfo, CultureInfo.InvariantCulture);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=en-US");
name = ToAssemblyName(nameObject);
Assert.Equal("mscorlib", name.Name);
Assert.Equal(new Version(2, 0, 0, 0), name.Version);
Assert.NotNull(name.CultureInfo);
Assert.Equal("en-US", name.CultureInfo.Name);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.Default, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("Windows, Version=255.255.255.255, ContentType=WindowsRuntime");
name = ToAssemblyName(nameObject);
Assert.Equal("Windows", name.Name);
Assert.Equal(new Version(255, 255, 255, 255), name.Version);
Assert.Null(name.CultureInfo);
Assert.Null(name.GetPublicKey());
Assert.Null(name.GetPublicKeyToken());
Assert.Equal(AssemblyContentType.WindowsRuntime, name.ContentType);
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=nonsense");
Assert.NotNull(nameObject);
Assert.Throws<CultureNotFoundException>(() => ToAssemblyName(nameObject));
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject("mscorlib, Version=2.0.0.0, Culture=null");
Assert.NotNull(nameObject);
Assert.Throws<CultureNotFoundException>(() => ToAssemblyName(nameObject));
Assert.Throws<CultureNotFoundException>(() => new AssemblyName("mscorlib, Version=2.0.0.0, Culture=nonsense"));
Assert.Throws<CultureNotFoundException>(() => new AssemblyName("mscorlib, Version=2.0.0.0, Culture=null"));
Assert.Throws<ArgumentException>(() => FusionAssemblyIdentity.ToAssemblyNameObject(new AssemblyName { Name = "x\0x" }));
// invalid characters are ok in the name, the FullName can't be built though:
foreach (char c in AssemblyIdentityTests.ClrInvalidCharacters)
{
nameObject = FusionAssemblyIdentity.ToAssemblyNameObject(new AssemblyName { Name = c.ToString() });
name = ToAssemblyName(nameObject);
Assert.Equal(c.ToString(), name.Name);
Assert.Throws<FileLoadException>(() => name.FullName);
}
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Features/Core/Portable/ValueTracking/ValueTrackingProgressCollector.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
namespace Microsoft.CodeAnalysis.ValueTracking
{
internal class ValueTrackingProgressCollector : IProgress<ValueTrackedItem>
{
private readonly object _lock = new();
private readonly Stack<ValueTrackedItem> _items = new();
public event EventHandler<ValueTrackedItem>? OnNewItem;
internal ValueTrackedItem? Parent { get; set; }
public void Report(ValueTrackedItem item)
{
lock (_lock)
{
_items.Push(item);
}
OnNewItem?.Invoke(null, item);
}
public ImmutableArray<ValueTrackedItem> GetItems()
{
lock (_lock)
{
return _items.ToImmutableArray();
}
}
internal async Task<bool> TryReportAsync(Solution solution, Location location, ISymbol symbol, CancellationToken cancellationToken = default)
{
var item = await ValueTrackedItem.TryCreateAsync(solution, location, symbol, Parent, cancellationToken).ConfigureAwait(false);
if (item is not null)
{
Report(item);
return true;
}
return false;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading;
using System.Threading.Tasks;
namespace Microsoft.CodeAnalysis.ValueTracking
{
internal class ValueTrackingProgressCollector : IProgress<ValueTrackedItem>
{
private readonly object _lock = new();
private readonly Stack<ValueTrackedItem> _items = new();
public event EventHandler<ValueTrackedItem>? OnNewItem;
internal ValueTrackedItem? Parent { get; set; }
public void Report(ValueTrackedItem item)
{
lock (_lock)
{
_items.Push(item);
}
OnNewItem?.Invoke(null, item);
}
public ImmutableArray<ValueTrackedItem> GetItems()
{
lock (_lock)
{
return _items.ToImmutableArray();
}
}
internal async Task<bool> TryReportAsync(Solution solution, Location location, ISymbol symbol, CancellationToken cancellationToken = default)
{
var item = await ValueTrackedItem.TryCreateAsync(solution, location, symbol, Parent, cancellationToken).ConfigureAwait(false);
if (item is not null)
{
Report(item);
return true;
}
return false;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/EditorFeatures/CSharpTest/Debugging/Resources/ProximityExpressionsGetterTestFile.cs | using System.Collections.Generic;
using Roslyn.Compilers.CSharp;
using Roslyn.Services.CSharp.Utilities;
using Roslyn.Services.Internal.Extensions;
namespace Roslyn.Services.CSharp.Debugging
{
internal partial class ProximityExpressionsGetter
{
private static string ConvertToString(ExpressionSyntax expression)
{
// TODO(cyrusn): Should we strip out comments?
return expression.GetFullText();
}
private static void CollectExpressionTerms(int position, ExpressionSyntax expression, List<string> terms)
{
// Check here rather than at all the call sites...
if (expression == null)
{
return;
}
// Collect terms from this expression, which returns flags indicating the validity
// of this expression as a whole.
var expressionType = ExpressionType.Invalid;
CollectExpressionTerms(position, expression, terms, ref expressionType);
if ((expressionType & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
// If this expression identified itself as a valid term, add it to the
// term table
terms.Add(ConvertToString(expression));
}
}
private static void CollectExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// Check here rather than at all the call sites...
if (expression == null)
{
return;
}
switch (expression.Kind)
{
case SyntaxKind.ThisExpression:
case SyntaxKind.BaseExpression:
// an op term is ok if it's a "this" or "base" op it allows us to see
// "this.goo" in the autos window note: it's not a VALIDTERM since we don't
// want "this" showing up in the auto's window twice.
expressionType = ExpressionType.ValidExpression;
return;
case SyntaxKind.IdentifierName:
// Name nodes are always valid terms
expressionType = ExpressionType.ValidTerm;
return;
case SyntaxKind.CharacterLiteralExpression:
case SyntaxKind.FalseLiteralExpression:
case SyntaxKind.NullLiteralExpression:
case SyntaxKind.NumericLiteralExpression:
case SyntaxKind.StringLiteralExpression:
case SyntaxKind.TrueLiteralExpression:
// Constants can make up a valid term, but we don't consider them valid
// terms themselves (since we don't want them to show up in the autos window
// on their own).
expressionType = ExpressionType.ValidExpression;
return;
case SyntaxKind.CastExpression:
// For a cast, just add the nested expression. Note: this is technically
// unsafe as the cast *may* have side effects. However, in practice this is
// extremely rare, so we allow for this since it's ok in the common case.
CollectExpressionTerms(position, ((CastExpressionSyntax)expression).Expression, terms, ref expressionType);
return;
case SyntaxKind.MemberAccessExpression:
case SyntaxKind.PointerMemberAccessExpression:
CollectMemberAccessExpressionTerms(position, expression, terms, ref expressionType);
return;
case SyntaxKind.ObjectCreationExpression:
CollectObjectCreationExpressionTerms(position, expression, terms, ref expressionType);
return;
case SyntaxKind.ArrayCreationExpression:
CollectArrayCreationExpressionTerms(position, expression, terms, ref expressionType);
return;
case SyntaxKind.InvocationExpression:
CollectInvocationExpressionTerms(position, expression, terms, ref expressionType);
return;
}
// +, -, ++, --, !, etc.
//
// This is a valid expression if it doesn't have obvious side effects (i.e. ++, --)
if (expression is PrefixUnaryExpressionSyntax)
{
CollectPrefixUnaryExpressionTerms(position, expression, terms, ref expressionType);
return;
}
if (expression is PostfixUnaryExpressionSyntax)
{
CollectPostfixUnaryExpressionTerms(position, expression, terms, ref expressionType);
return;
}
if (expression is BinaryExpressionSyntax)
{
CollectBinaryExpressionTerms(position, expression, terms, ref expressionType);
return;
}
expressionType = ExpressionType.Invalid;
}
private static void CollectMemberAccessExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
var flags = ExpressionType.Invalid;
// These operators always have a RHS of a name node, which we know would
// "claim" to be a valid term, but is not valid without the LHS present.
// So, we don't bother collecting anything from the RHS...
var memberAccess = (MemberAccessExpressionSyntax)expression;
CollectExpressionTerms(position, memberAccess.Expression, terms, ref flags);
// If the LHS says it's a valid term, then we add it ONLY if our PARENT
// is NOT another dot/arrow. This allows the expression 'a.b.c.d' to
// add both 'a.b.c.d' and 'a.b.c', but not 'a.b' and 'a'.
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm &&
!expression.IsParentKind(SyntaxKind.MemberAccessExpression) &&
!expression.IsParentKind(SyntaxKind.PointerMemberAccessExpression))
{
terms.Add(ConvertToString(memberAccess.Expression));
}
// And this expression itself is a valid term if the LHS is a valid
// expression, and its PARENT is not an invocation.
if ((flags & ExpressionType.ValidExpression) == ExpressionType.ValidExpression &&
!expression.IsParentKind(SyntaxKind.InvocationExpression))
{
expressionType = ExpressionType.ValidTerm;
}
else
{
expressionType = ExpressionType.ValidExpression;
}
}
private static void CollectObjectCreationExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// Object creation can *definitely* cause side effects. So we initially
// mark this as something invalid. We allow it as a valid expr if all
// the sub arguments are valid terms.
expressionType = ExpressionType.Invalid;
var objectionCreation = (ObjectCreationExpressionSyntax)expression;
if (objectionCreation.ArgumentListOpt != null)
{
var flags = ExpressionType.Invalid;
CollectArgumentTerms(position, objectionCreation.ArgumentListOpt, terms, ref flags);
// If all arguments are terms, then this is possibly a valid expr
// that can be used somewhere higher in the stack.
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
expressionType = ExpressionType.ValidExpression;
}
}
}
private static void CollectArrayCreationExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
var validTerm = true;
var arrayCreation = (ArrayCreationExpressionSyntax)expression;
if (arrayCreation.InitializerOpt != null)
{
var flags = ExpressionType.Invalid;
arrayCreation.InitializerOpt.Expressions.Do(e => CollectExpressionTerms(position, e, terms, ref flags));
validTerm &= (flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm;
}
if (validTerm)
{
expressionType = ExpressionType.ValidExpression;
}
else
{
expressionType = ExpressionType.Invalid;
}
}
private static void CollectInvocationExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// Invocations definitely have side effects. So we assume this
// is invalid initially
expressionType = ExpressionType.Invalid;
ExpressionType leftFlags = ExpressionType.Invalid, rightFlags = ExpressionType.Invalid;
var invocation = (InvocationExpressionSyntax)expression;
CollectExpressionTerms(position, invocation.Expression, terms, ref leftFlags);
CollectArgumentTerms(position, invocation.ArgumentList, terms, ref rightFlags);
if ((leftFlags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(invocation.Expression));
}
// We're valid if both children are...
expressionType = (leftFlags & rightFlags) & ExpressionType.ValidExpression;
}
private static void CollectPrefixUnaryExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
expressionType = ExpressionType.Invalid;
var flags = ExpressionType.Invalid;
var prefixUnaryExpression = (PrefixUnaryExpressionSyntax)expression;
// Ask our subexpression for terms
CollectExpressionTerms(position, prefixUnaryExpression.Operand, terms, ref flags);
// Is our expression a valid term?
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(prefixUnaryExpression.Operand));
}
if (expression.MatchesKind(SyntaxKind.LogicalNotExpression, SyntaxKind.BitwiseNotExpression, SyntaxKind.NegateExpression, SyntaxKind.PlusExpression))
{
// We're a valid expression if our subexpression is...
expressionType = flags & ExpressionType.ValidExpression;
}
}
private static void CollectPostfixUnaryExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// ++ and -- are the only postfix operators. Since they always have side
// effects, we never consider this an expression.
expressionType = ExpressionType.Invalid;
var flags = ExpressionType.Invalid;
var postfixUnaryExpression = (PostfixUnaryExpressionSyntax)expression;
// Ask our subexpression for terms
CollectExpressionTerms(position, postfixUnaryExpression.Operand, terms, ref flags);
// Is our expression a valid term?
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(postfixUnaryExpression.Operand));
}
}
private static void CollectBinaryExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
ExpressionType leftFlags = ExpressionType.Invalid, rightFlags = ExpressionType.Invalid;
var binaryExpression = (BinaryExpressionSyntax)expression;
CollectExpressionTerms(position, binaryExpression.Left, terms, ref leftFlags);
CollectExpressionTerms(position, binaryExpression.Right, terms, ref rightFlags);
if ((leftFlags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(binaryExpression.Left));
}
if ((rightFlags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(binaryExpression.Right));
}
// Many sorts of binops (like +=) will definitely have side effects. We only
// consider this valid if it's a simple expression like +, -, etc.
switch (binaryExpression.Kind)
{
case SyntaxKind.AddExpression:
case SyntaxKind.SubtractExpression:
case SyntaxKind.MultiplyExpression:
case SyntaxKind.DivideExpression:
case SyntaxKind.ModuloExpression:
case SyntaxKind.LeftShiftExpression:
case SyntaxKind.RightShiftExpression:
case SyntaxKind.LogicalOrExpression:
case SyntaxKind.LogicalAndExpression:
case SyntaxKind.BitwiseOrExpression:
case SyntaxKind.BitwiseAndExpression:
case SyntaxKind.ExclusiveOrExpression:
case SyntaxKind.EqualsExpression:
case SyntaxKind.NotEqualsExpression:
case SyntaxKind.LessThanExpression:
case SyntaxKind.LessThanOrEqualExpression:
case SyntaxKind.GreaterThanExpression:
case SyntaxKind.GreaterThanOrEqualExpression:
case SyntaxKind.IsExpression:
case SyntaxKind.AsExpression:
case SyntaxKind.CoalesceExpression:
// We're valid if both children are...
expressionType = (leftFlags & rightFlags) & ExpressionType.ValidExpression;
return;
default:
expressionType = ExpressionType.Invalid;
return;
}
}
private static void CollectArgumentTerms(int position, ArgumentListSyntax argumentList, IList<string> terms, ref ExpressionType expressionType)
{
var validExpr = true;
// Process the list of expressions. This is probably a list of
// arguments to a function call(or a list of array index expressions)
foreach (var arg in argumentList.Arguments)
{
var flags = ExpressionType.Invalid;
CollectExpressionTerms(position, arg.Expression, terms, ref flags);
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(arg.Expression));
}
validExpr &= (flags & ExpressionType.ValidExpression) == ExpressionType.ValidExpression;
}
// We're never a valid term, but we're a valid expression if all
// the list elements are...
expressionType = validExpr ? ExpressionType.ValidExpression : 0;
}
private static void CollectVariableTerms(int position, SeparatedSyntaxList<VariableDeclaratorSyntax> declarators, List<string> terms)
{
foreach (var declarator in declarators)
{
if (declarator.InitializerOpt != null)
{
CollectExpressionTerms(position, declarator.InitializerOpt.Value, terms);
}
}
}
}
}
| using System.Collections.Generic;
using Roslyn.Compilers.CSharp;
using Roslyn.Services.CSharp.Utilities;
using Roslyn.Services.Internal.Extensions;
namespace Roslyn.Services.CSharp.Debugging
{
internal partial class ProximityExpressionsGetter
{
private static string ConvertToString(ExpressionSyntax expression)
{
// TODO(cyrusn): Should we strip out comments?
return expression.GetFullText();
}
private static void CollectExpressionTerms(int position, ExpressionSyntax expression, List<string> terms)
{
// Check here rather than at all the call sites...
if (expression == null)
{
return;
}
// Collect terms from this expression, which returns flags indicating the validity
// of this expression as a whole.
var expressionType = ExpressionType.Invalid;
CollectExpressionTerms(position, expression, terms, ref expressionType);
if ((expressionType & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
// If this expression identified itself as a valid term, add it to the
// term table
terms.Add(ConvertToString(expression));
}
}
private static void CollectExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// Check here rather than at all the call sites...
if (expression == null)
{
return;
}
switch (expression.Kind)
{
case SyntaxKind.ThisExpression:
case SyntaxKind.BaseExpression:
// an op term is ok if it's a "this" or "base" op it allows us to see
// "this.goo" in the autos window note: it's not a VALIDTERM since we don't
// want "this" showing up in the auto's window twice.
expressionType = ExpressionType.ValidExpression;
return;
case SyntaxKind.IdentifierName:
// Name nodes are always valid terms
expressionType = ExpressionType.ValidTerm;
return;
case SyntaxKind.CharacterLiteralExpression:
case SyntaxKind.FalseLiteralExpression:
case SyntaxKind.NullLiteralExpression:
case SyntaxKind.NumericLiteralExpression:
case SyntaxKind.StringLiteralExpression:
case SyntaxKind.TrueLiteralExpression:
// Constants can make up a valid term, but we don't consider them valid
// terms themselves (since we don't want them to show up in the autos window
// on their own).
expressionType = ExpressionType.ValidExpression;
return;
case SyntaxKind.CastExpression:
// For a cast, just add the nested expression. Note: this is technically
// unsafe as the cast *may* have side effects. However, in practice this is
// extremely rare, so we allow for this since it's ok in the common case.
CollectExpressionTerms(position, ((CastExpressionSyntax)expression).Expression, terms, ref expressionType);
return;
case SyntaxKind.MemberAccessExpression:
case SyntaxKind.PointerMemberAccessExpression:
CollectMemberAccessExpressionTerms(position, expression, terms, ref expressionType);
return;
case SyntaxKind.ObjectCreationExpression:
CollectObjectCreationExpressionTerms(position, expression, terms, ref expressionType);
return;
case SyntaxKind.ArrayCreationExpression:
CollectArrayCreationExpressionTerms(position, expression, terms, ref expressionType);
return;
case SyntaxKind.InvocationExpression:
CollectInvocationExpressionTerms(position, expression, terms, ref expressionType);
return;
}
// +, -, ++, --, !, etc.
//
// This is a valid expression if it doesn't have obvious side effects (i.e. ++, --)
if (expression is PrefixUnaryExpressionSyntax)
{
CollectPrefixUnaryExpressionTerms(position, expression, terms, ref expressionType);
return;
}
if (expression is PostfixUnaryExpressionSyntax)
{
CollectPostfixUnaryExpressionTerms(position, expression, terms, ref expressionType);
return;
}
if (expression is BinaryExpressionSyntax)
{
CollectBinaryExpressionTerms(position, expression, terms, ref expressionType);
return;
}
expressionType = ExpressionType.Invalid;
}
private static void CollectMemberAccessExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
var flags = ExpressionType.Invalid;
// These operators always have a RHS of a name node, which we know would
// "claim" to be a valid term, but is not valid without the LHS present.
// So, we don't bother collecting anything from the RHS...
var memberAccess = (MemberAccessExpressionSyntax)expression;
CollectExpressionTerms(position, memberAccess.Expression, terms, ref flags);
// If the LHS says it's a valid term, then we add it ONLY if our PARENT
// is NOT another dot/arrow. This allows the expression 'a.b.c.d' to
// add both 'a.b.c.d' and 'a.b.c', but not 'a.b' and 'a'.
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm &&
!expression.IsParentKind(SyntaxKind.MemberAccessExpression) &&
!expression.IsParentKind(SyntaxKind.PointerMemberAccessExpression))
{
terms.Add(ConvertToString(memberAccess.Expression));
}
// And this expression itself is a valid term if the LHS is a valid
// expression, and its PARENT is not an invocation.
if ((flags & ExpressionType.ValidExpression) == ExpressionType.ValidExpression &&
!expression.IsParentKind(SyntaxKind.InvocationExpression))
{
expressionType = ExpressionType.ValidTerm;
}
else
{
expressionType = ExpressionType.ValidExpression;
}
}
private static void CollectObjectCreationExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// Object creation can *definitely* cause side effects. So we initially
// mark this as something invalid. We allow it as a valid expr if all
// the sub arguments are valid terms.
expressionType = ExpressionType.Invalid;
var objectionCreation = (ObjectCreationExpressionSyntax)expression;
if (objectionCreation.ArgumentListOpt != null)
{
var flags = ExpressionType.Invalid;
CollectArgumentTerms(position, objectionCreation.ArgumentListOpt, terms, ref flags);
// If all arguments are terms, then this is possibly a valid expr
// that can be used somewhere higher in the stack.
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
expressionType = ExpressionType.ValidExpression;
}
}
}
private static void CollectArrayCreationExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
var validTerm = true;
var arrayCreation = (ArrayCreationExpressionSyntax)expression;
if (arrayCreation.InitializerOpt != null)
{
var flags = ExpressionType.Invalid;
arrayCreation.InitializerOpt.Expressions.Do(e => CollectExpressionTerms(position, e, terms, ref flags));
validTerm &= (flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm;
}
if (validTerm)
{
expressionType = ExpressionType.ValidExpression;
}
else
{
expressionType = ExpressionType.Invalid;
}
}
private static void CollectInvocationExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// Invocations definitely have side effects. So we assume this
// is invalid initially
expressionType = ExpressionType.Invalid;
ExpressionType leftFlags = ExpressionType.Invalid, rightFlags = ExpressionType.Invalid;
var invocation = (InvocationExpressionSyntax)expression;
CollectExpressionTerms(position, invocation.Expression, terms, ref leftFlags);
CollectArgumentTerms(position, invocation.ArgumentList, terms, ref rightFlags);
if ((leftFlags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(invocation.Expression));
}
// We're valid if both children are...
expressionType = (leftFlags & rightFlags) & ExpressionType.ValidExpression;
}
private static void CollectPrefixUnaryExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
expressionType = ExpressionType.Invalid;
var flags = ExpressionType.Invalid;
var prefixUnaryExpression = (PrefixUnaryExpressionSyntax)expression;
// Ask our subexpression for terms
CollectExpressionTerms(position, prefixUnaryExpression.Operand, terms, ref flags);
// Is our expression a valid term?
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(prefixUnaryExpression.Operand));
}
if (expression.MatchesKind(SyntaxKind.LogicalNotExpression, SyntaxKind.BitwiseNotExpression, SyntaxKind.NegateExpression, SyntaxKind.PlusExpression))
{
// We're a valid expression if our subexpression is...
expressionType = flags & ExpressionType.ValidExpression;
}
}
private static void CollectPostfixUnaryExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
// ++ and -- are the only postfix operators. Since they always have side
// effects, we never consider this an expression.
expressionType = ExpressionType.Invalid;
var flags = ExpressionType.Invalid;
var postfixUnaryExpression = (PostfixUnaryExpressionSyntax)expression;
// Ask our subexpression for terms
CollectExpressionTerms(position, postfixUnaryExpression.Operand, terms, ref flags);
// Is our expression a valid term?
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(postfixUnaryExpression.Operand));
}
}
private static void CollectBinaryExpressionTerms(int position, ExpressionSyntax expression, IList<string> terms, ref ExpressionType expressionType)
{
ExpressionType leftFlags = ExpressionType.Invalid, rightFlags = ExpressionType.Invalid;
var binaryExpression = (BinaryExpressionSyntax)expression;
CollectExpressionTerms(position, binaryExpression.Left, terms, ref leftFlags);
CollectExpressionTerms(position, binaryExpression.Right, terms, ref rightFlags);
if ((leftFlags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(binaryExpression.Left));
}
if ((rightFlags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(binaryExpression.Right));
}
// Many sorts of binops (like +=) will definitely have side effects. We only
// consider this valid if it's a simple expression like +, -, etc.
switch (binaryExpression.Kind)
{
case SyntaxKind.AddExpression:
case SyntaxKind.SubtractExpression:
case SyntaxKind.MultiplyExpression:
case SyntaxKind.DivideExpression:
case SyntaxKind.ModuloExpression:
case SyntaxKind.LeftShiftExpression:
case SyntaxKind.RightShiftExpression:
case SyntaxKind.LogicalOrExpression:
case SyntaxKind.LogicalAndExpression:
case SyntaxKind.BitwiseOrExpression:
case SyntaxKind.BitwiseAndExpression:
case SyntaxKind.ExclusiveOrExpression:
case SyntaxKind.EqualsExpression:
case SyntaxKind.NotEqualsExpression:
case SyntaxKind.LessThanExpression:
case SyntaxKind.LessThanOrEqualExpression:
case SyntaxKind.GreaterThanExpression:
case SyntaxKind.GreaterThanOrEqualExpression:
case SyntaxKind.IsExpression:
case SyntaxKind.AsExpression:
case SyntaxKind.CoalesceExpression:
// We're valid if both children are...
expressionType = (leftFlags & rightFlags) & ExpressionType.ValidExpression;
return;
default:
expressionType = ExpressionType.Invalid;
return;
}
}
private static void CollectArgumentTerms(int position, ArgumentListSyntax argumentList, IList<string> terms, ref ExpressionType expressionType)
{
var validExpr = true;
// Process the list of expressions. This is probably a list of
// arguments to a function call(or a list of array index expressions)
foreach (var arg in argumentList.Arguments)
{
var flags = ExpressionType.Invalid;
CollectExpressionTerms(position, arg.Expression, terms, ref flags);
if ((flags & ExpressionType.ValidTerm) == ExpressionType.ValidTerm)
{
terms.Add(ConvertToString(arg.Expression));
}
validExpr &= (flags & ExpressionType.ValidExpression) == ExpressionType.ValidExpression;
}
// We're never a valid term, but we're a valid expression if all
// the list elements are...
expressionType = validExpr ? ExpressionType.ValidExpression : 0;
}
private static void CollectVariableTerms(int position, SeparatedSyntaxList<VariableDeclaratorSyntax> declarators, List<string> terms)
{
foreach (var declarator in declarators)
{
if (declarator.InitializerOpt != null)
{
CollectExpressionTerms(position, declarator.InitializerOpt.Value, terms);
}
}
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/CSharp/Portable/Symbols/Source/SourcePropertySymbolBase.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Emit;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.PooledObjects;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
internal abstract class SourcePropertySymbolBase : PropertySymbol, IAttributeTargetSymbol
{
protected const string DefaultIndexerName = "Item";
/// <summary>
/// Condensed flags storing useful information about the <see cref="SourcePropertySymbolBase"/>
/// so that we do not have to go back to source to compute this data.
/// </summary>
[Flags]
private enum Flags : byte
{
IsExpressionBodied = 1 << 0,
IsAutoProperty = 1 << 1,
IsExplicitInterfaceImplementation = 1 << 2,
HasInitializer = 1 << 3,
}
// TODO (tomat): consider splitting into multiple subclasses/rare data.
private readonly SourceMemberContainerTypeSymbol _containingType;
private readonly string _name;
private readonly SyntaxReference _syntaxRef;
protected readonly DeclarationModifiers _modifiers;
private ImmutableArray<CustomModifier> _lazyRefCustomModifiers;
#nullable enable
private readonly SourcePropertyAccessorSymbol? _getMethod;
private readonly SourcePropertyAccessorSymbol? _setMethod;
#nullable disable
private readonly TypeSymbol _explicitInterfaceType;
private ImmutableArray<PropertySymbol> _lazyExplicitInterfaceImplementations;
private readonly Flags _propertyFlags;
private readonly RefKind _refKind;
private SymbolCompletionState _state;
private ImmutableArray<ParameterSymbol> _lazyParameters;
private TypeWithAnnotations.Boxed _lazyType;
private string _lazySourceName;
private string _lazyDocComment;
private string _lazyExpandedDocComment;
private OverriddenOrHiddenMembersResult _lazyOverriddenOrHiddenMembers;
private SynthesizedSealedPropertyAccessor _lazySynthesizedSealedAccessor;
private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag;
// CONSIDER: if the parameters were computed lazily, ParameterCount could be overridden to fall back on the syntax (as in SourceMemberMethodSymbol).
public Location Location { get; }
#nullable enable
protected SourcePropertySymbolBase(
SourceMemberContainerTypeSymbol containingType,
CSharpSyntaxNode syntax,
bool hasGetAccessor,
bool hasSetAccessor,
bool isExplicitInterfaceImplementation,
TypeSymbol? explicitInterfaceType,
string? aliasQualifierOpt,
DeclarationModifiers modifiers,
bool hasInitializer,
bool isAutoProperty,
bool isExpressionBodied,
bool isInitOnly,
RefKind refKind,
string memberName,
SyntaxList<AttributeListSyntax> indexerNameAttributeLists,
Location location,
BindingDiagnosticBag diagnostics)
{
Debug.Assert(!isExpressionBodied || !isAutoProperty);
Debug.Assert(!isExpressionBodied || !hasInitializer);
_syntaxRef = syntax.GetReference();
Location = location;
_containingType = containingType;
_refKind = refKind;
_modifiers = modifiers;
_explicitInterfaceType = explicitInterfaceType;
if (isExplicitInterfaceImplementation)
{
_propertyFlags |= Flags.IsExplicitInterfaceImplementation;
}
else
{
_lazyExplicitInterfaceImplementations = ImmutableArray<PropertySymbol>.Empty;
}
bool isIndexer = IsIndexer;
isAutoProperty = isAutoProperty && !(containingType.IsInterface && !IsStatic) && !IsAbstract && !IsExtern && !isIndexer;
if (isAutoProperty)
{
_propertyFlags |= Flags.IsAutoProperty;
}
if (hasInitializer)
{
_propertyFlags |= Flags.HasInitializer;
}
if (isExpressionBodied)
{
_propertyFlags |= Flags.IsExpressionBodied;
}
if (isIndexer)
{
if (indexerNameAttributeLists.Count == 0 || isExplicitInterfaceImplementation)
{
_lazySourceName = memberName;
}
else
{
Debug.Assert(memberName == DefaultIndexerName);
}
_name = ExplicitInterfaceHelpers.GetMemberName(WellKnownMemberNames.Indexer, _explicitInterfaceType, aliasQualifierOpt);
}
else
{
_name = _lazySourceName = memberName;
}
if ((isAutoProperty && hasGetAccessor) || hasInitializer)
{
Debug.Assert(!IsIndexer);
string fieldName = GeneratedNames.MakeBackingFieldName(_name);
BackingField = new SynthesizedBackingFieldSymbol(this,
fieldName,
isReadOnly: (hasGetAccessor && !hasSetAccessor) || isInitOnly,
this.IsStatic,
hasInitializer);
}
if (hasGetAccessor)
{
_getMethod = CreateGetAccessorSymbol(isAutoPropertyAccessor: isAutoProperty, diagnostics);
}
if (hasSetAccessor)
{
_setMethod = CreateSetAccessorSymbol(isAutoPropertyAccessor: isAutoProperty, diagnostics);
}
}
private void EnsureSignatureGuarded(BindingDiagnosticBag diagnostics)
{
PropertySymbol? explicitlyImplementedProperty = null;
_lazyRefCustomModifiers = ImmutableArray<CustomModifier>.Empty;
TypeWithAnnotations type;
(type, _lazyParameters) = MakeParametersAndBindType(diagnostics);
_lazyType = new TypeWithAnnotations.Boxed(type);
// The runtime will not treat the accessors of this property as overrides or implementations
// of those of another property unless both the signatures and the custom modifiers match.
// Hence, in the case of overrides and *explicit* implementations, we need to copy the custom
// modifiers that are in the signatures of the overridden/implemented property accessors.
// (From source, we know that there can only be one overridden/implemented property, so there
// are no conflicts.) This is unnecessary for implicit implementations because, if the custom
// modifiers don't match, we'll insert bridge methods for the accessors (explicit implementations
// that delegate to the implicit implementations) with the correct custom modifiers
// (see SourceMemberContainerTypeSymbol.SynthesizeInterfaceMemberImplementation).
// Note: we're checking if the syntax indicates explicit implementation rather,
// than if explicitInterfaceType is null because we don't want to look for an
// overridden property if this is supposed to be an explicit implementation.
bool isExplicitInterfaceImplementation = IsExplicitInterfaceImplementation;
if (isExplicitInterfaceImplementation || this.IsOverride)
{
bool isOverride = false;
PropertySymbol? overriddenOrImplementedProperty;
if (!isExplicitInterfaceImplementation)
{
// If this property is an override, we may need to copy custom modifiers from
// the overridden property (so that the runtime will recognize it as an override).
// We check for this case here, while we can still modify the parameters and
// return type without losing the appearance of immutability.
isOverride = true;
overriddenOrImplementedProperty = this.OverriddenProperty;
}
else
{
CSharpSyntaxNode syntax = CSharpSyntaxNode;
string interfacePropertyName = IsIndexer ? WellKnownMemberNames.Indexer : ((PropertyDeclarationSyntax)syntax).Identifier.ValueText;
explicitlyImplementedProperty = this.FindExplicitlyImplementedProperty(_explicitInterfaceType, interfacePropertyName, GetExplicitInterfaceSpecifier(), diagnostics);
this.FindExplicitlyImplementedMemberVerification(explicitlyImplementedProperty, diagnostics);
overriddenOrImplementedProperty = explicitlyImplementedProperty;
}
if ((object)overriddenOrImplementedProperty != null)
{
_lazyRefCustomModifiers = _refKind != RefKind.None ? overriddenOrImplementedProperty.RefCustomModifiers : ImmutableArray<CustomModifier>.Empty;
TypeWithAnnotations overriddenPropertyType = overriddenOrImplementedProperty.TypeWithAnnotations;
// We do an extra check before copying the type to handle the case where the overriding
// property (incorrectly) has a different type than the overridden property. In such cases,
// we want to retain the original (incorrect) type to avoid hiding the type given in source.
if (type.Type.Equals(overriddenPropertyType.Type, TypeCompareKind.IgnoreCustomModifiersAndArraySizesAndLowerBounds | TypeCompareKind.IgnoreNullableModifiersForReferenceTypes | TypeCompareKind.IgnoreDynamic))
{
type = type.WithTypeAndModifiers(
CustomModifierUtils.CopyTypeCustomModifiers(overriddenPropertyType.Type, type.Type, this.ContainingAssembly),
overriddenPropertyType.CustomModifiers);
_lazyType = new TypeWithAnnotations.Boxed(type);
}
_lazyParameters = CustomModifierUtils.CopyParameterCustomModifiers(overriddenOrImplementedProperty.Parameters, _lazyParameters, alsoCopyParamsModifier: isOverride);
}
}
else if (_refKind == RefKind.RefReadOnly)
{
var modifierType = Binder.GetWellKnownType(DeclaringCompilation, WellKnownType.System_Runtime_InteropServices_InAttribute, diagnostics, TypeLocation);
_lazyRefCustomModifiers = ImmutableArray.Create(CSharpCustomModifier.CreateRequired(modifierType));
}
Debug.Assert(isExplicitInterfaceImplementation || _lazyExplicitInterfaceImplementations.IsEmpty);
_lazyExplicitInterfaceImplementations =
explicitlyImplementedProperty is null ?
ImmutableArray<PropertySymbol>.Empty :
ImmutableArray.Create(explicitlyImplementedProperty);
}
protected abstract Location TypeLocation { get; }
#nullable disable
internal sealed override ImmutableArray<string> NotNullMembers =>
GetDecodedWellKnownAttributeData()?.NotNullMembers ?? ImmutableArray<string>.Empty;
internal sealed override ImmutableArray<string> NotNullWhenTrueMembers =>
GetDecodedWellKnownAttributeData()?.NotNullWhenTrueMembers ?? ImmutableArray<string>.Empty;
internal sealed override ImmutableArray<string> NotNullWhenFalseMembers =>
GetDecodedWellKnownAttributeData()?.NotNullWhenFalseMembers ?? ImmutableArray<string>.Empty;
internal bool IsExpressionBodied
=> (_propertyFlags & Flags.IsExpressionBodied) != 0;
private void CheckInitializer(
bool isAutoProperty,
bool isInterface,
bool isStatic,
Location location,
BindingDiagnosticBag diagnostics)
{
if (isInterface && !isStatic)
{
diagnostics.Add(ErrorCode.ERR_InstancePropertyInitializerInInterface, location, this);
}
else if (!isAutoProperty)
{
diagnostics.Add(ErrorCode.ERR_InitializerOnNonAutoProperty, location, this);
}
}
public sealed override RefKind RefKind
{
get
{
return _refKind;
}
}
public sealed override TypeWithAnnotations TypeWithAnnotations
{
get
{
EnsureSignature();
return _lazyType.Value;
}
}
#nullable enable
private void EnsureSignature()
{
if (!_state.HasComplete(CompletionPart.FinishPropertyEnsureSignature))
{
// If this lock ever encloses a potential call to Debugger.NotifyOfCrossThreadDependency,
// then we should call DebuggerUtilities.CallBeforeAcquiringLock() (see method comment for more
// details).
lock (_syntaxRef)
{
if (_state.NotePartComplete(CompletionPart.StartPropertyEnsureSignature))
{
// By setting StartPropertyEnsureSignature, we've committed to doing the work and setting
// FinishPropertyEnsureSignature. So there is no cancellation supported between one and the other.
var diagnostics = BindingDiagnosticBag.GetInstance();
try
{
EnsureSignatureGuarded(diagnostics);
this.AddDeclarationDiagnostics(diagnostics);
}
finally
{
_state.NotePartComplete(CompletionPart.FinishPropertyEnsureSignature);
diagnostics.Free();
}
}
else
{
// Either (1) this thread is in the process of completing the method,
// or (2) some other thread has beat us to the punch and completed the method.
// We can distinguish the two cases here by checking for the FinishPropertyEnsureSignature
// part to be complete, which would only occur if another thread completed this
// method.
//
// The other case, in which this thread is in the process of completing the method,
// requires that we return here even though the work is not complete. That's because
// signature is processed by first populating the return type and parameters by binding
// the syntax from source. Those values are visible to the same thread for the purpose
// of computing which methods are implemented and overridden. But then those values
// may be rewritten (by the same thread) to copy down custom modifiers. In order to
// allow the same thread to see the return type and parameters from the syntax (though
// they do not yet take on their final values), we return here.
// Due to the fact that this method is potentially reentrant, we must use a
// reentrant lock to avoid deadlock and cannot assert that at this point the work
// has completed (_state.HasComplete(CompletionPart.FinishPropertyEnsureSignature)).
}
}
}
}
#nullable disable
internal bool HasPointerType
{
get
{
if (_lazyType != null)
{
var hasPointerType = _lazyType.Value.DefaultType.IsPointerOrFunctionPointer();
Debug.Assert(hasPointerType == HasPointerTypeSyntactically);
return hasPointerType;
}
return HasPointerTypeSyntactically;
}
}
protected abstract bool HasPointerTypeSyntactically { get; }
/// <remarks>
/// To facilitate lookup, all indexer symbols have the same name.
/// Check the MetadataName property to find the name that will be
/// emitted (based on IndexerNameAttribute, or the default "Item").
/// </remarks>
public override string Name
{
get
{
return _name;
}
}
#nullable enable
internal string SourceName
{
get
{
if (_lazySourceName is null)
{
Debug.Assert(IsIndexer);
var indexerNameAttributeLists = ((IndexerDeclarationSyntax)CSharpSyntaxNode).AttributeLists;
Debug.Assert(indexerNameAttributeLists.Count != 0);
Debug.Assert(!IsExplicitInterfaceImplementation);
string? sourceName = null;
// Evaluate the attributes immediately in case the IndexerNameAttribute has been applied.
// CONSIDER: none of the information from this early binding pass is cached. Everything will
// be re-bound when someone calls GetAttributes. If this gets to be a problem, we could
// always use the real attribute bag of this symbol and modify LoadAndValidateAttributes to
// handle partially filled bags.
CustomAttributesBag<CSharpAttributeData>? temp = null;
LoadAndValidateAttributes(OneOrMany.Create(indexerNameAttributeLists), ref temp, earlyDecodingOnly: true);
if (temp != null)
{
Debug.Assert(temp.IsEarlyDecodedWellKnownAttributeDataComputed);
var propertyData = (PropertyEarlyWellKnownAttributeData)temp.EarlyDecodedWellKnownAttributeData;
if (propertyData != null)
{
sourceName = propertyData.IndexerName;
}
}
sourceName = sourceName ?? DefaultIndexerName;
InterlockedOperations.Initialize(ref _lazySourceName, sourceName);
}
return _lazySourceName;
}
}
#nullable disable
public override string MetadataName
{
get
{
// Explicit implementation names may have spaces if the interface
// is generic (between the type arguments).
return SourceName.Replace(" ", "");
}
}
public override Symbol ContainingSymbol
{
get
{
return _containingType;
}
}
public override NamedTypeSymbol ContainingType
{
get
{
return _containingType;
}
}
internal override LexicalSortKey GetLexicalSortKey()
{
return new LexicalSortKey(Location, this.DeclaringCompilation);
}
public override ImmutableArray<Location> Locations
{
get
{
return ImmutableArray.Create(Location);
}
}
public override ImmutableArray<SyntaxReference> DeclaringSyntaxReferences
{
get
{
return ImmutableArray.Create(_syntaxRef);
}
}
public override bool IsAbstract
{
get { return (_modifiers & DeclarationModifiers.Abstract) != 0; }
}
public override bool IsExtern
{
get { return (_modifiers & DeclarationModifiers.Extern) != 0; }
}
public override bool IsStatic
{
get { return (_modifiers & DeclarationModifiers.Static) != 0; }
}
internal bool IsFixed
{
get { return false; }
}
/// <remarks>
/// Even though it is declared with an IndexerDeclarationSyntax, an explicit
/// interface implementation is not an indexer because it will not cause the
/// containing type to be emitted with a DefaultMemberAttribute (and even if
/// there is another indexer, the name of the explicit implementation won't
/// match). This is important for round-tripping.
/// </remarks>
public override bool IsIndexer
{
get { return (_modifiers & DeclarationModifiers.Indexer) != 0; }
}
public override bool IsOverride
{
get { return (_modifiers & DeclarationModifiers.Override) != 0; }
}
public override bool IsSealed
{
get { return (_modifiers & DeclarationModifiers.Sealed) != 0; }
}
public override bool IsVirtual
{
get { return (_modifiers & DeclarationModifiers.Virtual) != 0; }
}
internal bool IsNew
{
get { return (_modifiers & DeclarationModifiers.New) != 0; }
}
internal bool HasReadOnlyModifier => (_modifiers & DeclarationModifiers.ReadOnly) != 0;
#nullable enable
/// <summary>
/// The method is called at the end of <see cref="SourcePropertySymbolBase"/> constructor.
/// The implementation may depend only on information available from the <see cref="SourcePropertySymbolBase"/> type.
/// </summary>
protected abstract SourcePropertyAccessorSymbol CreateGetAccessorSymbol(
bool isAutoPropertyAccessor,
BindingDiagnosticBag diagnostics);
/// <summary>
/// The method is called at the end of <see cref="SourcePropertySymbolBase"/> constructor.
/// The implementation may depend only on information available from the <see cref="SourcePropertySymbolBase"/> type.
/// </summary>
protected abstract SourcePropertyAccessorSymbol CreateSetAccessorSymbol(
bool isAutoPropertyAccessor,
BindingDiagnosticBag diagnostics);
public sealed override MethodSymbol? GetMethod
{
get
{
return _getMethod;
}
}
public sealed override MethodSymbol? SetMethod
{
get
{
return _setMethod;
}
}
#nullable disable
internal override Microsoft.Cci.CallingConvention CallingConvention
{
get { return (IsStatic ? 0 : Microsoft.Cci.CallingConvention.HasThis); }
}
public sealed override ImmutableArray<ParameterSymbol> Parameters
{
get
{
EnsureSignature();
return _lazyParameters;
}
}
internal override bool IsExplicitInterfaceImplementation
=> (_propertyFlags & Flags.IsExplicitInterfaceImplementation) != 0;
public sealed override ImmutableArray<PropertySymbol> ExplicitInterfaceImplementations
{
get
{
if (IsExplicitInterfaceImplementation)
{
EnsureSignature();
}
else
{
Debug.Assert(_lazyExplicitInterfaceImplementations.IsEmpty);
}
return _lazyExplicitInterfaceImplementations;
}
}
public sealed override ImmutableArray<CustomModifier> RefCustomModifiers
{
get
{
EnsureSignature();
return _lazyRefCustomModifiers;
}
}
public override Accessibility DeclaredAccessibility
{
get
{
return ModifierUtils.EffectiveAccessibility(_modifiers);
}
}
public bool HasSkipLocalsInitAttribute
{
get
{
var data = this.GetDecodedWellKnownAttributeData();
return data?.HasSkipLocalsInitAttribute == true;
}
}
internal bool IsAutoPropertyWithGetAccessor
=> IsAutoProperty && _getMethod is object;
protected bool IsAutoProperty
=> (_propertyFlags & Flags.IsAutoProperty) != 0;
/// <summary>
/// Backing field for automatically implemented property, or
/// for a property with an initializer.
/// </summary>
internal SynthesizedBackingFieldSymbol BackingField { get; }
internal override bool MustCallMethodsDirectly
{
get { return false; }
}
internal SyntaxReference SyntaxReference
{
get
{
return _syntaxRef;
}
}
internal CSharpSyntaxNode CSharpSyntaxNode
{
get
{
return (CSharpSyntaxNode)_syntaxRef.GetSyntax();
}
}
internal SyntaxTree SyntaxTree
{
get
{
return _syntaxRef.SyntaxTree;
}
}
internal override void AfterAddingTypeMembersChecks(ConversionsBase conversions, BindingDiagnosticBag diagnostics)
{
#nullable enable
bool isExplicitInterfaceImplementation = IsExplicitInterfaceImplementation;
this.CheckAccessibility(Location, diagnostics, isExplicitInterfaceImplementation);
this.CheckModifiers(isExplicitInterfaceImplementation, Location, IsIndexer, diagnostics);
bool hasInitializer = (_propertyFlags & Flags.HasInitializer) != 0;
if (hasInitializer)
{
CheckInitializer(IsAutoProperty, ContainingType.IsInterface, IsStatic, Location, diagnostics);
}
if (IsAutoPropertyWithGetAccessor)
{
Debug.Assert(GetMethod is object);
if (!IsStatic && SetMethod is { IsInitOnly: false })
{
if (ContainingType.IsReadOnly)
{
diagnostics.Add(ErrorCode.ERR_AutoPropsInRoStruct, Location);
}
else if (HasReadOnlyModifier)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyWithSetterCantBeReadOnly, Location, this);
}
}
//issue a diagnostic if the compiler generated attribute ctor is not found.
Binder.ReportUseSiteDiagnosticForSynthesizedAttribute(DeclaringCompilation,
WellKnownMember.System_Runtime_CompilerServices_CompilerGeneratedAttribute__ctor, diagnostics, location: Location);
if (this.RefKind != RefKind.None)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyCannotBeRefReturning, Location, this);
}
// get-only auto property should not override settable properties
if (SetMethod is null && !this.IsReadOnly)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyMustOverrideSet, Location, this);
}
}
if (!IsExpressionBodied)
{
bool hasGetAccessor = GetMethod is object;
bool hasSetAccessor = SetMethod is object;
if (hasGetAccessor && hasSetAccessor)
{
Debug.Assert(_getMethod is object);
Debug.Assert(_setMethod is object);
if (_refKind != RefKind.None)
{
diagnostics.Add(ErrorCode.ERR_RefPropertyCannotHaveSetAccessor, _setMethod.Locations[0], _setMethod);
}
else if ((_getMethod.LocalAccessibility != Accessibility.NotApplicable) &&
(_setMethod.LocalAccessibility != Accessibility.NotApplicable))
{
// Check accessibility is set on at most one accessor.
diagnostics.Add(ErrorCode.ERR_DuplicatePropertyAccessMods, Location, this);
}
else if (_getMethod.LocalDeclaredReadOnly && _setMethod.LocalDeclaredReadOnly)
{
diagnostics.Add(ErrorCode.ERR_DuplicatePropertyReadOnlyMods, Location, this);
}
else if (this.IsAbstract)
{
// Check abstract property accessors are not private.
CheckAbstractPropertyAccessorNotPrivate(_getMethod, diagnostics);
CheckAbstractPropertyAccessorNotPrivate(_setMethod, diagnostics);
}
}
else
{
if (!hasGetAccessor && !hasSetAccessor)
{
diagnostics.Add(ErrorCode.ERR_PropertyWithNoAccessors, Location, this);
}
else if (RefKind != RefKind.None)
{
if (!hasGetAccessor)
{
diagnostics.Add(ErrorCode.ERR_RefPropertyMustHaveGetAccessor, Location, this);
}
}
else if (!hasGetAccessor && IsAutoProperty)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyMustHaveGetAccessor, _setMethod!.Locations[0], _setMethod);
}
if (!this.IsOverride)
{
var accessor = _getMethod ?? _setMethod;
if (accessor is object)
{
// Check accessibility is not set on the one accessor.
if (accessor.LocalAccessibility != Accessibility.NotApplicable)
{
diagnostics.Add(ErrorCode.ERR_AccessModMissingAccessor, Location, this);
}
// Check that 'readonly' is not set on the one accessor.
if (accessor.LocalDeclaredReadOnly)
{
diagnostics.Add(ErrorCode.ERR_ReadOnlyModMissingAccessor, Location, this);
}
}
}
}
// Check accessor accessibility is more restrictive than property accessibility.
CheckAccessibilityMoreRestrictive(_getMethod, diagnostics);
CheckAccessibilityMoreRestrictive(_setMethod, diagnostics);
}
PropertySymbol? explicitlyImplementedProperty = ExplicitInterfaceImplementations.FirstOrDefault();
if (explicitlyImplementedProperty is object)
{
CheckExplicitImplementationAccessor(GetMethod, explicitlyImplementedProperty.GetMethod, explicitlyImplementedProperty, diagnostics);
CheckExplicitImplementationAccessor(SetMethod, explicitlyImplementedProperty.SetMethod, explicitlyImplementedProperty, diagnostics);
}
#nullable disable
Location location = TypeLocation;
var compilation = DeclaringCompilation;
Debug.Assert(location != null);
// Check constraints on return type and parameters. Note: Dev10 uses the
// property name location for any such errors. We'll do the same for return
// type errors but for parameter errors, we'll use the parameter location.
if ((object)_explicitInterfaceType != null)
{
var explicitInterfaceSpecifier = GetExplicitInterfaceSpecifier();
Debug.Assert(explicitInterfaceSpecifier != null);
_explicitInterfaceType.CheckAllConstraints(compilation, conversions, new SourceLocation(explicitInterfaceSpecifier.Name), diagnostics);
// Note: we delayed nullable-related checks that could pull on NonNullTypes
if (explicitlyImplementedProperty is object)
{
TypeSymbol.CheckNullableReferenceTypeMismatchOnImplementingMember(this.ContainingType, this, explicitlyImplementedProperty, isExplicit: true, diagnostics);
}
}
if (_refKind == RefKind.RefReadOnly)
{
compilation.EnsureIsReadOnlyAttributeExists(diagnostics, location, modifyCompilation: true);
}
ParameterHelpers.EnsureIsReadOnlyAttributeExists(compilation, Parameters, diagnostics, modifyCompilation: true);
if (Type.ContainsNativeInteger())
{
compilation.EnsureNativeIntegerAttributeExists(diagnostics, location, modifyCompilation: true);
}
ParameterHelpers.EnsureNativeIntegerAttributeExists(compilation, Parameters, diagnostics, modifyCompilation: true);
if (compilation.ShouldEmitNullableAttributes(this) &&
this.TypeWithAnnotations.NeedsNullableAttribute())
{
compilation.EnsureNullableAttributeExists(diagnostics, location, modifyCompilation: true);
}
ParameterHelpers.EnsureNullableAttributeExists(compilation, this, Parameters, diagnostics, modifyCompilation: true);
}
private void CheckAccessibility(Location location, BindingDiagnosticBag diagnostics, bool isExplicitInterfaceImplementation)
{
var info = ModifierUtils.CheckAccessibility(_modifiers, this, isExplicitInterfaceImplementation);
if (info != null)
{
diagnostics.Add(new CSDiagnostic(info, location));
}
}
private void CheckModifiers(bool isExplicitInterfaceImplementation, Location location, bool isIndexer, BindingDiagnosticBag diagnostics)
{
Debug.Assert(!IsStatic || (!IsVirtual && !IsOverride)); // Otherwise 'virtual' and 'override' should have been reported and cleared earlier.
bool isExplicitInterfaceImplementationInInterface = isExplicitInterfaceImplementation && ContainingType.IsInterface;
if (this.DeclaredAccessibility == Accessibility.Private && (IsVirtual || (IsAbstract && !isExplicitInterfaceImplementationInInterface) || IsOverride))
{
diagnostics.Add(ErrorCode.ERR_VirtualPrivate, location, this);
}
else if (IsStatic && IsAbstract && !ContainingType.IsInterface)
{
// A static member '{0}' cannot be marked as 'abstract'
diagnostics.Add(ErrorCode.ERR_StaticNotVirtual, location, ModifierUtils.ConvertSingleModifierToSyntaxText(DeclarationModifiers.Abstract));
}
else if (IsStatic && HasReadOnlyModifier)
{
// Static member '{0}' cannot be marked 'readonly'.
diagnostics.Add(ErrorCode.ERR_StaticMemberCantBeReadOnly, location, this);
}
else if (IsOverride && (IsNew || IsVirtual))
{
// A member '{0}' marked as override cannot be marked as new or virtual
diagnostics.Add(ErrorCode.ERR_OverrideNotNew, location, this);
}
else if (IsSealed && !IsOverride && !(IsAbstract && isExplicitInterfaceImplementationInInterface))
{
// '{0}' cannot be sealed because it is not an override
diagnostics.Add(ErrorCode.ERR_SealedNonOverride, location, this);
}
else if (IsAbstract && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.AbstractKeyword));
}
else if (IsVirtual && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.VirtualKeyword));
}
else if (IsAbstract && IsExtern)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndExtern, location, this);
}
else if (IsAbstract && IsSealed && !isExplicitInterfaceImplementationInInterface)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndSealed, location, this);
}
else if (IsAbstract && IsVirtual)
{
diagnostics.Add(ErrorCode.ERR_AbstractNotVirtual, location, this.Kind.Localize(), this);
}
else if (ContainingType.IsSealed && this.DeclaredAccessibility.HasProtected() && !this.IsOverride)
{
diagnostics.Add(AccessCheck.GetProtectedMemberInSealedTypeError(ContainingType), location, this);
}
else if (ContainingType.IsStatic && !IsStatic)
{
ErrorCode errorCode = isIndexer ? ErrorCode.ERR_IndexerInStaticClass : ErrorCode.ERR_InstanceMemberInStaticClass;
diagnostics.Add(errorCode, location, this);
}
}
private void CheckAccessibilityMoreRestrictive(SourcePropertyAccessorSymbol accessor, BindingDiagnosticBag diagnostics)
{
if (((object)accessor != null) &&
!IsAccessibilityMoreRestrictive(this.DeclaredAccessibility, accessor.LocalAccessibility))
{
diagnostics.Add(ErrorCode.ERR_InvalidPropertyAccessMod, accessor.Locations[0], accessor, this);
}
}
/// <summary>
/// Return true if the accessor accessibility is more restrictive
/// than the property accessibility, otherwise false.
/// </summary>
private static bool IsAccessibilityMoreRestrictive(Accessibility property, Accessibility accessor)
{
if (accessor == Accessibility.NotApplicable)
{
return true;
}
return (accessor < property) &&
((accessor != Accessibility.Protected) || (property != Accessibility.Internal));
}
private static void CheckAbstractPropertyAccessorNotPrivate(SourcePropertyAccessorSymbol accessor, BindingDiagnosticBag diagnostics)
{
if (accessor.LocalAccessibility == Accessibility.Private)
{
diagnostics.Add(ErrorCode.ERR_PrivateAbstractAccessor, accessor.Locations[0], accessor);
}
}
public override string GetDocumentationCommentXml(CultureInfo preferredCulture = null, bool expandIncludes = false, CancellationToken cancellationToken = default(CancellationToken))
{
ref var lazyDocComment = ref expandIncludes ? ref _lazyExpandedDocComment : ref _lazyDocComment;
return SourceDocumentationCommentUtils.GetAndCacheDocumentationComment(this, expandIncludes, ref lazyDocComment);
}
// Separate these checks out of FindExplicitlyImplementedProperty because they depend on the accessor symbols,
// which depend on the explicitly implemented property
private void CheckExplicitImplementationAccessor(MethodSymbol thisAccessor, MethodSymbol otherAccessor, PropertySymbol explicitlyImplementedProperty, BindingDiagnosticBag diagnostics)
{
var thisHasAccessor = (object)thisAccessor != null;
var otherHasAccessor = otherAccessor.IsImplementable();
if (otherHasAccessor && !thisHasAccessor)
{
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyMissingAccessor, this.Location, this, otherAccessor);
}
else if (!otherHasAccessor && thisHasAccessor)
{
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyAddingAccessor, thisAccessor.Locations[0], thisAccessor, explicitlyImplementedProperty);
}
else if (TypeSymbol.HaveInitOnlyMismatch(thisAccessor, otherAccessor))
{
Debug.Assert(thisAccessor.MethodKind == MethodKind.PropertySet);
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyMismatchInitOnly, thisAccessor.Locations[0], thisAccessor, otherAccessor);
}
}
internal override OverriddenOrHiddenMembersResult OverriddenOrHiddenMembers
{
get
{
if (_lazyOverriddenOrHiddenMembers == null)
{
Interlocked.CompareExchange(ref _lazyOverriddenOrHiddenMembers, this.MakeOverriddenOrHiddenMembers(), null);
}
return _lazyOverriddenOrHiddenMembers;
}
}
/// <summary>
/// If this property is sealed, then we have to emit both accessors - regardless of whether
/// they are present in the source - so that they can be marked final. (i.e. sealed).
/// </summary>
internal SynthesizedSealedPropertyAccessor SynthesizedSealedAccessorOpt
{
get
{
bool hasGetter = GetMethod is object;
bool hasSetter = SetMethod is object;
if (!this.IsSealed || (hasGetter && hasSetter))
{
return null;
}
// This has to be cached because the CCI layer depends on reference equality.
// However, there's no point in having more than one field, since we don't
// expect to have to synthesize more than one accessor.
if ((object)_lazySynthesizedSealedAccessor == null)
{
Interlocked.CompareExchange(ref _lazySynthesizedSealedAccessor, MakeSynthesizedSealedAccessor(), null);
}
return _lazySynthesizedSealedAccessor;
}
}
/// <remarks>
/// Only non-null for sealed properties without both accessors.
/// </remarks>
private SynthesizedSealedPropertyAccessor MakeSynthesizedSealedAccessor()
{
Debug.Assert(this.IsSealed && (GetMethod is null || SetMethod is null));
if (GetMethod is object)
{
// need to synthesize setter
MethodSymbol overriddenAccessor = this.GetOwnOrInheritedSetMethod();
return (object)overriddenAccessor == null ? null : new SynthesizedSealedPropertyAccessor(this, overriddenAccessor);
}
else if (SetMethod is object)
{
// need to synthesize getter
MethodSymbol overriddenAccessor = this.GetOwnOrInheritedGetMethod();
return (object)overriddenAccessor == null ? null : new SynthesizedSealedPropertyAccessor(this, overriddenAccessor);
}
else
{
// Arguably, it would be more correct to return an array containing two
// synthesized accessors, but we're already in an error case, so we'll
// minimize the cascading error behavior by suppressing synthesis.
return null;
}
}
#region Attributes
public abstract SyntaxList<AttributeListSyntax> AttributeDeclarationSyntaxList { get; }
public abstract IAttributeTargetSymbol AttributesOwner { get; }
IAttributeTargetSymbol IAttributeTargetSymbol.AttributesOwner => AttributesOwner;
AttributeLocation IAttributeTargetSymbol.DefaultAttributeLocation => AttributeLocation.Property;
AttributeLocation IAttributeTargetSymbol.AllowedAttributeLocations
=> IsAutoPropertyWithGetAccessor
? AttributeLocation.Property | AttributeLocation.Field
: AttributeLocation.Property;
/// <summary>
/// Returns a bag of custom attributes applied on the property and data decoded from well-known attributes. Returns null if there are no attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
private CustomAttributesBag<CSharpAttributeData> GetAttributesBag()
{
var bag = _lazyCustomAttributesBag;
if (bag != null && bag.IsSealed)
{
return bag;
}
// The property is responsible for completion of the backing field
_ = BackingField?.GetAttributes();
if (LoadAndValidateAttributes(OneOrMany.Create(AttributeDeclarationSyntaxList), ref _lazyCustomAttributesBag))
{
var completed = _state.NotePartComplete(CompletionPart.Attributes);
Debug.Assert(completed);
}
Debug.Assert(_lazyCustomAttributesBag.IsSealed);
return _lazyCustomAttributesBag;
}
/// <summary>
/// Gets the attributes applied on this symbol.
/// Returns an empty array if there are no attributes.
/// </summary>
/// <remarks>
/// NOTE: This method should always be kept as a sealed override.
/// If you want to override attribute binding logic for a sub-class, then override <see cref="GetAttributesBag"/> method.
/// </remarks>
public sealed override ImmutableArray<CSharpAttributeData> GetAttributes()
{
return this.GetAttributesBag().Attributes;
}
/// <summary>
/// Returns data decoded from well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
private PropertyWellKnownAttributeData GetDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (PropertyWellKnownAttributeData)attributesBag.DecodedWellKnownAttributeData;
}
/// <summary>
/// Returns data decoded from special early bound well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
internal PropertyEarlyWellKnownAttributeData GetEarlyDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (PropertyEarlyWellKnownAttributeData)attributesBag.EarlyDecodedWellKnownAttributeData;
}
internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<SynthesizedAttributeData> attributes)
{
base.AddSynthesizedAttributes(moduleBuilder, ref attributes);
var compilation = this.DeclaringCompilation;
var type = this.TypeWithAnnotations;
if (type.Type.ContainsDynamic())
{
AddSynthesizedAttribute(ref attributes,
compilation.SynthesizeDynamicAttribute(type.Type, type.CustomModifiers.Length + RefCustomModifiers.Length, _refKind));
}
if (type.Type.ContainsNativeInteger())
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNativeIntegerAttribute(this, type.Type));
}
if (type.Type.ContainsTupleNames())
{
AddSynthesizedAttribute(ref attributes,
compilation.SynthesizeTupleNamesAttribute(type.Type));
}
if (compilation.ShouldEmitNullableAttributes(this))
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNullableAttributeIfNecessary(this, ContainingType.GetNullableContextValue(), type));
}
if (this.ReturnsByRefReadonly)
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeIsReadOnlyAttribute(this));
}
}
internal sealed override bool IsDirectlyExcludedFromCodeCoverage =>
GetDecodedWellKnownAttributeData()?.HasExcludeFromCodeCoverageAttribute == true;
internal override bool HasSpecialName
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasSpecialNameAttribute;
}
}
internal override CSharpAttributeData EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments)
{
CSharpAttributeData boundAttribute;
ObsoleteAttributeData obsoleteData;
if (EarlyDecodeDeprecatedOrExperimentalOrObsoleteAttribute(ref arguments, out boundAttribute, out obsoleteData))
{
if (obsoleteData != null)
{
arguments.GetOrCreateData<PropertyEarlyWellKnownAttributeData>().ObsoleteAttributeData = obsoleteData;
}
return boundAttribute;
}
if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.IndexerNameAttribute))
{
bool hasAnyDiagnostics;
boundAttribute = arguments.Binder.GetAttribute(arguments.AttributeSyntax, arguments.AttributeType, out hasAnyDiagnostics);
if (!boundAttribute.HasErrors)
{
string indexerName = boundAttribute.CommonConstructorArguments[0].DecodeValue<string>(SpecialType.System_String);
if (indexerName != null)
{
arguments.GetOrCreateData<PropertyEarlyWellKnownAttributeData>().IndexerName = indexerName;
}
if (!hasAnyDiagnostics)
{
return boundAttribute;
}
}
return null;
}
return base.EarlyDecodeWellKnownAttribute(ref arguments);
}
/// <summary>
/// Returns data decoded from Obsolete attribute or null if there is no Obsolete attribute.
/// This property returns ObsoleteAttributeData.Uninitialized if attribute arguments haven't been decoded yet.
/// </summary>
internal override ObsoleteAttributeData ObsoleteAttributeData
{
get
{
if (!_containingType.AnyMemberHasAttributes)
{
return null;
}
var lazyCustomAttributesBag = _lazyCustomAttributesBag;
if (lazyCustomAttributesBag != null && lazyCustomAttributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
return ((PropertyEarlyWellKnownAttributeData)lazyCustomAttributesBag.EarlyDecodedWellKnownAttributeData)?.ObsoleteAttributeData;
}
return ObsoleteAttributeData.Uninitialized;
}
}
internal override void DecodeWellKnownAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments)
{
Debug.Assert(arguments.AttributeSyntaxOpt != null);
var diagnostics = (BindingDiagnosticBag)arguments.Diagnostics;
Debug.Assert(diagnostics.DiagnosticBag is object);
var attribute = arguments.Attribute;
Debug.Assert(!attribute.HasErrors);
Debug.Assert(arguments.SymbolPart == AttributeLocation.None);
if (attribute.IsTargetAttribute(this, AttributeDescription.IndexerNameAttribute))
{
//NOTE: decoding was done by EarlyDecodeWellKnownAttribute.
ValidateIndexerNameAttribute(attribute, arguments.AttributeSyntaxOpt, diagnostics);
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.SpecialNameAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasSpecialNameAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.ExcludeFromCodeCoverageAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasExcludeFromCodeCoverageAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.SkipLocalsInitAttribute))
{
CSharpAttributeData.DecodeSkipLocalsInitAttribute<PropertyWellKnownAttributeData>(DeclaringCompilation, ref arguments);
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.DynamicAttribute))
{
// DynamicAttribute should not be set explicitly.
diagnostics.Add(ErrorCode.ERR_ExplicitDynamicAttr, arguments.AttributeSyntaxOpt.Location);
}
else if (ReportExplicitUseOfReservedAttributes(in arguments,
ReservedAttributes.DynamicAttribute | ReservedAttributes.IsReadOnlyAttribute | ReservedAttributes.IsUnmanagedAttribute | ReservedAttributes.IsByRefLikeAttribute | ReservedAttributes.TupleElementNamesAttribute | ReservedAttributes.NullableAttribute | ReservedAttributes.NativeIntegerAttribute))
{
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.DisallowNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasDisallowNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.AllowNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasAllowNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.MaybeNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasMaybeNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.NotNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasNotNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.MemberNotNullAttribute))
{
MessageID.IDS_FeatureMemberNotNull.CheckFeatureAvailability(diagnostics, arguments.AttributeSyntaxOpt);
CSharpAttributeData.DecodeMemberNotNullAttribute<PropertyWellKnownAttributeData>(ContainingType, ref arguments);
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.MemberNotNullWhenAttribute))
{
MessageID.IDS_FeatureMemberNotNull.CheckFeatureAvailability(diagnostics, arguments.AttributeSyntaxOpt);
CSharpAttributeData.DecodeMemberNotNullWhenAttribute<PropertyWellKnownAttributeData>(ContainingType, ref arguments);
}
}
internal bool HasDisallowNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasDisallowNullAttribute;
}
}
internal bool HasAllowNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasAllowNullAttribute;
}
}
internal bool HasMaybeNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasMaybeNullAttribute;
}
}
internal bool HasNotNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasNotNullAttribute;
}
}
internal SourceAttributeData DisallowNullAttributeIfExists
=> FindAttribute(AttributeDescription.DisallowNullAttribute);
internal SourceAttributeData AllowNullAttributeIfExists
=> FindAttribute(AttributeDescription.AllowNullAttribute);
internal SourceAttributeData MaybeNullAttributeIfExists
=> FindAttribute(AttributeDescription.MaybeNullAttribute);
internal SourceAttributeData NotNullAttributeIfExists
=> FindAttribute(AttributeDescription.NotNullAttribute);
internal ImmutableArray<SourceAttributeData> MemberNotNullAttributeIfExists
=> FindAttributes(AttributeDescription.MemberNotNullAttribute);
internal ImmutableArray<SourceAttributeData> MemberNotNullWhenAttributeIfExists
=> FindAttributes(AttributeDescription.MemberNotNullWhenAttribute);
private SourceAttributeData FindAttribute(AttributeDescription attributeDescription)
=> (SourceAttributeData)GetAttributes().First(a => a.IsTargetAttribute(this, attributeDescription));
private ImmutableArray<SourceAttributeData> FindAttributes(AttributeDescription attributeDescription)
=> GetAttributes().Where(a => a.IsTargetAttribute(this, attributeDescription)).Cast<SourceAttributeData>().ToImmutableArray();
internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
{
Debug.Assert(!boundAttributes.IsDefault);
Debug.Assert(!allAttributeSyntaxNodes.IsDefault);
Debug.Assert(boundAttributes.Length == allAttributeSyntaxNodes.Length);
Debug.Assert(_lazyCustomAttributesBag != null);
Debug.Assert(_lazyCustomAttributesBag.IsDecodedWellKnownAttributeDataComputed);
Debug.Assert(symbolPart == AttributeLocation.None);
base.PostDecodeWellKnownAttributes(boundAttributes, allAttributeSyntaxNodes, diagnostics, symbolPart, decodedData);
}
private void ValidateIndexerNameAttribute(CSharpAttributeData attribute, AttributeSyntax node, BindingDiagnosticBag diagnostics)
{
if (!this.IsIndexer || this.IsExplicitInterfaceImplementation)
{
diagnostics.Add(ErrorCode.ERR_BadIndexerNameAttr, node.Name.Location, node.GetErrorDisplayName());
}
else
{
string indexerName = attribute.CommonConstructorArguments[0].DecodeValue<string>(SpecialType.System_String);
if (indexerName == null || !SyntaxFacts.IsValidIdentifier(indexerName))
{
diagnostics.Add(ErrorCode.ERR_BadArgumentToAttribute, node.ArgumentList.Arguments[0].Location, node.GetErrorDisplayName());
}
}
}
#endregion
#region Completion
internal sealed override bool RequiresCompletion
{
get { return true; }
}
internal sealed override bool HasComplete(CompletionPart part)
{
return _state.HasComplete(part);
}
internal override void ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken)
{
while (true)
{
cancellationToken.ThrowIfCancellationRequested();
var incompletePart = _state.NextIncompletePart;
switch (incompletePart)
{
case CompletionPart.Attributes:
GetAttributes();
break;
case CompletionPart.StartPropertyEnsureSignature:
case CompletionPart.FinishPropertyEnsureSignature:
EnsureSignature();
Debug.Assert(_state.HasComplete(CompletionPart.FinishPropertyEnsureSignature));
break;
case CompletionPart.StartPropertyParameters:
case CompletionPart.FinishPropertyParameters:
{
if (_state.NotePartComplete(CompletionPart.StartPropertyParameters))
{
var parameters = this.Parameters;
if (parameters.Length > 0)
{
var diagnostics = BindingDiagnosticBag.GetInstance();
var conversions = new TypeConversions(this.ContainingAssembly.CorLibrary);
foreach (var parameter in this.Parameters)
{
parameter.ForceComplete(locationOpt, cancellationToken);
parameter.Type.CheckAllConstraints(DeclaringCompilation, conversions, parameter.Locations[0], diagnostics);
}
this.AddDeclarationDiagnostics(diagnostics);
diagnostics.Free();
}
DeclaringCompilation.SymbolDeclaredEvent(this);
var completedOnThisThread = _state.NotePartComplete(CompletionPart.FinishPropertyParameters);
Debug.Assert(completedOnThisThread);
}
else
{
// StartPropertyParameters was completed by another thread. Wait for it to finish the parameters.
_state.SpinWaitComplete(CompletionPart.FinishPropertyParameters, cancellationToken);
}
}
break;
case CompletionPart.StartPropertyType:
case CompletionPart.FinishPropertyType:
{
if (_state.NotePartComplete(CompletionPart.StartPropertyType))
{
var diagnostics = BindingDiagnosticBag.GetInstance();
var conversions = new TypeConversions(this.ContainingAssembly.CorLibrary);
this.Type.CheckAllConstraints(DeclaringCompilation, conversions, Location, diagnostics);
ValidatePropertyType(diagnostics);
this.AddDeclarationDiagnostics(diagnostics);
var completedOnThisThread = _state.NotePartComplete(CompletionPart.FinishPropertyType);
Debug.Assert(completedOnThisThread);
diagnostics.Free();
}
else
{
// StartPropertyType was completed by another thread. Wait for it to finish the type.
_state.SpinWaitComplete(CompletionPart.FinishPropertyType, cancellationToken);
}
}
break;
case CompletionPart.None:
return;
default:
// any other values are completion parts intended for other kinds of symbols
_state.NotePartComplete(CompletionPart.All & ~CompletionPart.PropertySymbolAll);
break;
}
_state.SpinWaitComplete(incompletePart, cancellationToken);
}
}
protected virtual void ValidatePropertyType(BindingDiagnosticBag diagnostics)
{
var type = this.Type;
if (type.IsRestrictedType(ignoreSpanLikeTypes: true))
{
diagnostics.Add(ErrorCode.ERR_FieldCantBeRefAny, TypeLocation, type);
}
else if (this.IsAutoPropertyWithGetAccessor && type.IsRefLikeType && (this.IsStatic || !this.ContainingType.IsRefLikeType))
{
diagnostics.Add(ErrorCode.ERR_FieldAutoPropCantBeByRefLike, TypeLocation, type);
}
}
#endregion
#nullable enable
protected abstract (TypeWithAnnotations Type, ImmutableArray<ParameterSymbol> Parameters) MakeParametersAndBindType(BindingDiagnosticBag diagnostics);
protected static ExplicitInterfaceSpecifierSyntax? GetExplicitInterfaceSpecifier(SyntaxNode syntax)
=> (syntax as BasePropertyDeclarationSyntax)?.ExplicitInterfaceSpecifier;
internal ExplicitInterfaceSpecifierSyntax? GetExplicitInterfaceSpecifier()
=> GetExplicitInterfaceSpecifier(CSharpSyntaxNode);
#nullable disable
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Threading;
using Microsoft.CodeAnalysis.CSharp.Emit;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.PooledObjects;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
internal abstract class SourcePropertySymbolBase : PropertySymbol, IAttributeTargetSymbol
{
protected const string DefaultIndexerName = "Item";
/// <summary>
/// Condensed flags storing useful information about the <see cref="SourcePropertySymbolBase"/>
/// so that we do not have to go back to source to compute this data.
/// </summary>
[Flags]
private enum Flags : byte
{
IsExpressionBodied = 1 << 0,
IsAutoProperty = 1 << 1,
IsExplicitInterfaceImplementation = 1 << 2,
HasInitializer = 1 << 3,
}
// TODO (tomat): consider splitting into multiple subclasses/rare data.
private readonly SourceMemberContainerTypeSymbol _containingType;
private readonly string _name;
private readonly SyntaxReference _syntaxRef;
protected readonly DeclarationModifiers _modifiers;
private ImmutableArray<CustomModifier> _lazyRefCustomModifiers;
#nullable enable
private readonly SourcePropertyAccessorSymbol? _getMethod;
private readonly SourcePropertyAccessorSymbol? _setMethod;
#nullable disable
private readonly TypeSymbol _explicitInterfaceType;
private ImmutableArray<PropertySymbol> _lazyExplicitInterfaceImplementations;
private readonly Flags _propertyFlags;
private readonly RefKind _refKind;
private SymbolCompletionState _state;
private ImmutableArray<ParameterSymbol> _lazyParameters;
private TypeWithAnnotations.Boxed _lazyType;
private string _lazySourceName;
private string _lazyDocComment;
private string _lazyExpandedDocComment;
private OverriddenOrHiddenMembersResult _lazyOverriddenOrHiddenMembers;
private SynthesizedSealedPropertyAccessor _lazySynthesizedSealedAccessor;
private CustomAttributesBag<CSharpAttributeData> _lazyCustomAttributesBag;
// CONSIDER: if the parameters were computed lazily, ParameterCount could be overridden to fall back on the syntax (as in SourceMemberMethodSymbol).
public Location Location { get; }
#nullable enable
protected SourcePropertySymbolBase(
SourceMemberContainerTypeSymbol containingType,
CSharpSyntaxNode syntax,
bool hasGetAccessor,
bool hasSetAccessor,
bool isExplicitInterfaceImplementation,
TypeSymbol? explicitInterfaceType,
string? aliasQualifierOpt,
DeclarationModifiers modifiers,
bool hasInitializer,
bool isAutoProperty,
bool isExpressionBodied,
bool isInitOnly,
RefKind refKind,
string memberName,
SyntaxList<AttributeListSyntax> indexerNameAttributeLists,
Location location,
BindingDiagnosticBag diagnostics)
{
Debug.Assert(!isExpressionBodied || !isAutoProperty);
Debug.Assert(!isExpressionBodied || !hasInitializer);
_syntaxRef = syntax.GetReference();
Location = location;
_containingType = containingType;
_refKind = refKind;
_modifiers = modifiers;
_explicitInterfaceType = explicitInterfaceType;
if (isExplicitInterfaceImplementation)
{
_propertyFlags |= Flags.IsExplicitInterfaceImplementation;
}
else
{
_lazyExplicitInterfaceImplementations = ImmutableArray<PropertySymbol>.Empty;
}
bool isIndexer = IsIndexer;
isAutoProperty = isAutoProperty && !(containingType.IsInterface && !IsStatic) && !IsAbstract && !IsExtern && !isIndexer;
if (isAutoProperty)
{
_propertyFlags |= Flags.IsAutoProperty;
}
if (hasInitializer)
{
_propertyFlags |= Flags.HasInitializer;
}
if (isExpressionBodied)
{
_propertyFlags |= Flags.IsExpressionBodied;
}
if (isIndexer)
{
if (indexerNameAttributeLists.Count == 0 || isExplicitInterfaceImplementation)
{
_lazySourceName = memberName;
}
else
{
Debug.Assert(memberName == DefaultIndexerName);
}
_name = ExplicitInterfaceHelpers.GetMemberName(WellKnownMemberNames.Indexer, _explicitInterfaceType, aliasQualifierOpt);
}
else
{
_name = _lazySourceName = memberName;
}
if ((isAutoProperty && hasGetAccessor) || hasInitializer)
{
Debug.Assert(!IsIndexer);
string fieldName = GeneratedNames.MakeBackingFieldName(_name);
BackingField = new SynthesizedBackingFieldSymbol(this,
fieldName,
isReadOnly: (hasGetAccessor && !hasSetAccessor) || isInitOnly,
this.IsStatic,
hasInitializer);
}
if (hasGetAccessor)
{
_getMethod = CreateGetAccessorSymbol(isAutoPropertyAccessor: isAutoProperty, diagnostics);
}
if (hasSetAccessor)
{
_setMethod = CreateSetAccessorSymbol(isAutoPropertyAccessor: isAutoProperty, diagnostics);
}
}
private void EnsureSignatureGuarded(BindingDiagnosticBag diagnostics)
{
PropertySymbol? explicitlyImplementedProperty = null;
_lazyRefCustomModifiers = ImmutableArray<CustomModifier>.Empty;
TypeWithAnnotations type;
(type, _lazyParameters) = MakeParametersAndBindType(diagnostics);
_lazyType = new TypeWithAnnotations.Boxed(type);
// The runtime will not treat the accessors of this property as overrides or implementations
// of those of another property unless both the signatures and the custom modifiers match.
// Hence, in the case of overrides and *explicit* implementations, we need to copy the custom
// modifiers that are in the signatures of the overridden/implemented property accessors.
// (From source, we know that there can only be one overridden/implemented property, so there
// are no conflicts.) This is unnecessary for implicit implementations because, if the custom
// modifiers don't match, we'll insert bridge methods for the accessors (explicit implementations
// that delegate to the implicit implementations) with the correct custom modifiers
// (see SourceMemberContainerTypeSymbol.SynthesizeInterfaceMemberImplementation).
// Note: we're checking if the syntax indicates explicit implementation rather,
// than if explicitInterfaceType is null because we don't want to look for an
// overridden property if this is supposed to be an explicit implementation.
bool isExplicitInterfaceImplementation = IsExplicitInterfaceImplementation;
if (isExplicitInterfaceImplementation || this.IsOverride)
{
bool isOverride = false;
PropertySymbol? overriddenOrImplementedProperty;
if (!isExplicitInterfaceImplementation)
{
// If this property is an override, we may need to copy custom modifiers from
// the overridden property (so that the runtime will recognize it as an override).
// We check for this case here, while we can still modify the parameters and
// return type without losing the appearance of immutability.
isOverride = true;
overriddenOrImplementedProperty = this.OverriddenProperty;
}
else
{
CSharpSyntaxNode syntax = CSharpSyntaxNode;
string interfacePropertyName = IsIndexer ? WellKnownMemberNames.Indexer : ((PropertyDeclarationSyntax)syntax).Identifier.ValueText;
explicitlyImplementedProperty = this.FindExplicitlyImplementedProperty(_explicitInterfaceType, interfacePropertyName, GetExplicitInterfaceSpecifier(), diagnostics);
this.FindExplicitlyImplementedMemberVerification(explicitlyImplementedProperty, diagnostics);
overriddenOrImplementedProperty = explicitlyImplementedProperty;
}
if ((object)overriddenOrImplementedProperty != null)
{
_lazyRefCustomModifiers = _refKind != RefKind.None ? overriddenOrImplementedProperty.RefCustomModifiers : ImmutableArray<CustomModifier>.Empty;
TypeWithAnnotations overriddenPropertyType = overriddenOrImplementedProperty.TypeWithAnnotations;
// We do an extra check before copying the type to handle the case where the overriding
// property (incorrectly) has a different type than the overridden property. In such cases,
// we want to retain the original (incorrect) type to avoid hiding the type given in source.
if (type.Type.Equals(overriddenPropertyType.Type, TypeCompareKind.IgnoreCustomModifiersAndArraySizesAndLowerBounds | TypeCompareKind.IgnoreNullableModifiersForReferenceTypes | TypeCompareKind.IgnoreDynamic))
{
type = type.WithTypeAndModifiers(
CustomModifierUtils.CopyTypeCustomModifiers(overriddenPropertyType.Type, type.Type, this.ContainingAssembly),
overriddenPropertyType.CustomModifiers);
_lazyType = new TypeWithAnnotations.Boxed(type);
}
_lazyParameters = CustomModifierUtils.CopyParameterCustomModifiers(overriddenOrImplementedProperty.Parameters, _lazyParameters, alsoCopyParamsModifier: isOverride);
}
}
else if (_refKind == RefKind.RefReadOnly)
{
var modifierType = Binder.GetWellKnownType(DeclaringCompilation, WellKnownType.System_Runtime_InteropServices_InAttribute, diagnostics, TypeLocation);
_lazyRefCustomModifiers = ImmutableArray.Create(CSharpCustomModifier.CreateRequired(modifierType));
}
Debug.Assert(isExplicitInterfaceImplementation || _lazyExplicitInterfaceImplementations.IsEmpty);
_lazyExplicitInterfaceImplementations =
explicitlyImplementedProperty is null ?
ImmutableArray<PropertySymbol>.Empty :
ImmutableArray.Create(explicitlyImplementedProperty);
}
protected abstract Location TypeLocation { get; }
#nullable disable
internal sealed override ImmutableArray<string> NotNullMembers =>
GetDecodedWellKnownAttributeData()?.NotNullMembers ?? ImmutableArray<string>.Empty;
internal sealed override ImmutableArray<string> NotNullWhenTrueMembers =>
GetDecodedWellKnownAttributeData()?.NotNullWhenTrueMembers ?? ImmutableArray<string>.Empty;
internal sealed override ImmutableArray<string> NotNullWhenFalseMembers =>
GetDecodedWellKnownAttributeData()?.NotNullWhenFalseMembers ?? ImmutableArray<string>.Empty;
internal bool IsExpressionBodied
=> (_propertyFlags & Flags.IsExpressionBodied) != 0;
private void CheckInitializer(
bool isAutoProperty,
bool isInterface,
bool isStatic,
Location location,
BindingDiagnosticBag diagnostics)
{
if (isInterface && !isStatic)
{
diagnostics.Add(ErrorCode.ERR_InstancePropertyInitializerInInterface, location, this);
}
else if (!isAutoProperty)
{
diagnostics.Add(ErrorCode.ERR_InitializerOnNonAutoProperty, location, this);
}
}
public sealed override RefKind RefKind
{
get
{
return _refKind;
}
}
public sealed override TypeWithAnnotations TypeWithAnnotations
{
get
{
EnsureSignature();
return _lazyType.Value;
}
}
#nullable enable
private void EnsureSignature()
{
if (!_state.HasComplete(CompletionPart.FinishPropertyEnsureSignature))
{
// If this lock ever encloses a potential call to Debugger.NotifyOfCrossThreadDependency,
// then we should call DebuggerUtilities.CallBeforeAcquiringLock() (see method comment for more
// details).
lock (_syntaxRef)
{
if (_state.NotePartComplete(CompletionPart.StartPropertyEnsureSignature))
{
// By setting StartPropertyEnsureSignature, we've committed to doing the work and setting
// FinishPropertyEnsureSignature. So there is no cancellation supported between one and the other.
var diagnostics = BindingDiagnosticBag.GetInstance();
try
{
EnsureSignatureGuarded(diagnostics);
this.AddDeclarationDiagnostics(diagnostics);
}
finally
{
_state.NotePartComplete(CompletionPart.FinishPropertyEnsureSignature);
diagnostics.Free();
}
}
else
{
// Either (1) this thread is in the process of completing the method,
// or (2) some other thread has beat us to the punch and completed the method.
// We can distinguish the two cases here by checking for the FinishPropertyEnsureSignature
// part to be complete, which would only occur if another thread completed this
// method.
//
// The other case, in which this thread is in the process of completing the method,
// requires that we return here even though the work is not complete. That's because
// signature is processed by first populating the return type and parameters by binding
// the syntax from source. Those values are visible to the same thread for the purpose
// of computing which methods are implemented and overridden. But then those values
// may be rewritten (by the same thread) to copy down custom modifiers. In order to
// allow the same thread to see the return type and parameters from the syntax (though
// they do not yet take on their final values), we return here.
// Due to the fact that this method is potentially reentrant, we must use a
// reentrant lock to avoid deadlock and cannot assert that at this point the work
// has completed (_state.HasComplete(CompletionPart.FinishPropertyEnsureSignature)).
}
}
}
}
#nullable disable
internal bool HasPointerType
{
get
{
if (_lazyType != null)
{
var hasPointerType = _lazyType.Value.DefaultType.IsPointerOrFunctionPointer();
Debug.Assert(hasPointerType == HasPointerTypeSyntactically);
return hasPointerType;
}
return HasPointerTypeSyntactically;
}
}
protected abstract bool HasPointerTypeSyntactically { get; }
/// <remarks>
/// To facilitate lookup, all indexer symbols have the same name.
/// Check the MetadataName property to find the name that will be
/// emitted (based on IndexerNameAttribute, or the default "Item").
/// </remarks>
public override string Name
{
get
{
return _name;
}
}
#nullable enable
internal string SourceName
{
get
{
if (_lazySourceName is null)
{
Debug.Assert(IsIndexer);
var indexerNameAttributeLists = ((IndexerDeclarationSyntax)CSharpSyntaxNode).AttributeLists;
Debug.Assert(indexerNameAttributeLists.Count != 0);
Debug.Assert(!IsExplicitInterfaceImplementation);
string? sourceName = null;
// Evaluate the attributes immediately in case the IndexerNameAttribute has been applied.
// CONSIDER: none of the information from this early binding pass is cached. Everything will
// be re-bound when someone calls GetAttributes. If this gets to be a problem, we could
// always use the real attribute bag of this symbol and modify LoadAndValidateAttributes to
// handle partially filled bags.
CustomAttributesBag<CSharpAttributeData>? temp = null;
LoadAndValidateAttributes(OneOrMany.Create(indexerNameAttributeLists), ref temp, earlyDecodingOnly: true);
if (temp != null)
{
Debug.Assert(temp.IsEarlyDecodedWellKnownAttributeDataComputed);
var propertyData = (PropertyEarlyWellKnownAttributeData)temp.EarlyDecodedWellKnownAttributeData;
if (propertyData != null)
{
sourceName = propertyData.IndexerName;
}
}
sourceName = sourceName ?? DefaultIndexerName;
InterlockedOperations.Initialize(ref _lazySourceName, sourceName);
}
return _lazySourceName;
}
}
#nullable disable
public override string MetadataName
{
get
{
// Explicit implementation names may have spaces if the interface
// is generic (between the type arguments).
return SourceName.Replace(" ", "");
}
}
public override Symbol ContainingSymbol
{
get
{
return _containingType;
}
}
public override NamedTypeSymbol ContainingType
{
get
{
return _containingType;
}
}
internal override LexicalSortKey GetLexicalSortKey()
{
return new LexicalSortKey(Location, this.DeclaringCompilation);
}
public override ImmutableArray<Location> Locations
{
get
{
return ImmutableArray.Create(Location);
}
}
public override ImmutableArray<SyntaxReference> DeclaringSyntaxReferences
{
get
{
return ImmutableArray.Create(_syntaxRef);
}
}
public override bool IsAbstract
{
get { return (_modifiers & DeclarationModifiers.Abstract) != 0; }
}
public override bool IsExtern
{
get { return (_modifiers & DeclarationModifiers.Extern) != 0; }
}
public override bool IsStatic
{
get { return (_modifiers & DeclarationModifiers.Static) != 0; }
}
internal bool IsFixed
{
get { return false; }
}
/// <remarks>
/// Even though it is declared with an IndexerDeclarationSyntax, an explicit
/// interface implementation is not an indexer because it will not cause the
/// containing type to be emitted with a DefaultMemberAttribute (and even if
/// there is another indexer, the name of the explicit implementation won't
/// match). This is important for round-tripping.
/// </remarks>
public override bool IsIndexer
{
get { return (_modifiers & DeclarationModifiers.Indexer) != 0; }
}
public override bool IsOverride
{
get { return (_modifiers & DeclarationModifiers.Override) != 0; }
}
public override bool IsSealed
{
get { return (_modifiers & DeclarationModifiers.Sealed) != 0; }
}
public override bool IsVirtual
{
get { return (_modifiers & DeclarationModifiers.Virtual) != 0; }
}
internal bool IsNew
{
get { return (_modifiers & DeclarationModifiers.New) != 0; }
}
internal bool HasReadOnlyModifier => (_modifiers & DeclarationModifiers.ReadOnly) != 0;
#nullable enable
/// <summary>
/// The method is called at the end of <see cref="SourcePropertySymbolBase"/> constructor.
/// The implementation may depend only on information available from the <see cref="SourcePropertySymbolBase"/> type.
/// </summary>
protected abstract SourcePropertyAccessorSymbol CreateGetAccessorSymbol(
bool isAutoPropertyAccessor,
BindingDiagnosticBag diagnostics);
/// <summary>
/// The method is called at the end of <see cref="SourcePropertySymbolBase"/> constructor.
/// The implementation may depend only on information available from the <see cref="SourcePropertySymbolBase"/> type.
/// </summary>
protected abstract SourcePropertyAccessorSymbol CreateSetAccessorSymbol(
bool isAutoPropertyAccessor,
BindingDiagnosticBag diagnostics);
public sealed override MethodSymbol? GetMethod
{
get
{
return _getMethod;
}
}
public sealed override MethodSymbol? SetMethod
{
get
{
return _setMethod;
}
}
#nullable disable
internal override Microsoft.Cci.CallingConvention CallingConvention
{
get { return (IsStatic ? 0 : Microsoft.Cci.CallingConvention.HasThis); }
}
public sealed override ImmutableArray<ParameterSymbol> Parameters
{
get
{
EnsureSignature();
return _lazyParameters;
}
}
internal override bool IsExplicitInterfaceImplementation
=> (_propertyFlags & Flags.IsExplicitInterfaceImplementation) != 0;
public sealed override ImmutableArray<PropertySymbol> ExplicitInterfaceImplementations
{
get
{
if (IsExplicitInterfaceImplementation)
{
EnsureSignature();
}
else
{
Debug.Assert(_lazyExplicitInterfaceImplementations.IsEmpty);
}
return _lazyExplicitInterfaceImplementations;
}
}
public sealed override ImmutableArray<CustomModifier> RefCustomModifiers
{
get
{
EnsureSignature();
return _lazyRefCustomModifiers;
}
}
public override Accessibility DeclaredAccessibility
{
get
{
return ModifierUtils.EffectiveAccessibility(_modifiers);
}
}
public bool HasSkipLocalsInitAttribute
{
get
{
var data = this.GetDecodedWellKnownAttributeData();
return data?.HasSkipLocalsInitAttribute == true;
}
}
internal bool IsAutoPropertyWithGetAccessor
=> IsAutoProperty && _getMethod is object;
protected bool IsAutoProperty
=> (_propertyFlags & Flags.IsAutoProperty) != 0;
/// <summary>
/// Backing field for automatically implemented property, or
/// for a property with an initializer.
/// </summary>
internal SynthesizedBackingFieldSymbol BackingField { get; }
internal override bool MustCallMethodsDirectly
{
get { return false; }
}
internal SyntaxReference SyntaxReference
{
get
{
return _syntaxRef;
}
}
internal CSharpSyntaxNode CSharpSyntaxNode
{
get
{
return (CSharpSyntaxNode)_syntaxRef.GetSyntax();
}
}
internal SyntaxTree SyntaxTree
{
get
{
return _syntaxRef.SyntaxTree;
}
}
internal override void AfterAddingTypeMembersChecks(ConversionsBase conversions, BindingDiagnosticBag diagnostics)
{
#nullable enable
bool isExplicitInterfaceImplementation = IsExplicitInterfaceImplementation;
this.CheckAccessibility(Location, diagnostics, isExplicitInterfaceImplementation);
this.CheckModifiers(isExplicitInterfaceImplementation, Location, IsIndexer, diagnostics);
bool hasInitializer = (_propertyFlags & Flags.HasInitializer) != 0;
if (hasInitializer)
{
CheckInitializer(IsAutoProperty, ContainingType.IsInterface, IsStatic, Location, diagnostics);
}
if (IsAutoPropertyWithGetAccessor)
{
Debug.Assert(GetMethod is object);
if (!IsStatic && SetMethod is { IsInitOnly: false })
{
if (ContainingType.IsReadOnly)
{
diagnostics.Add(ErrorCode.ERR_AutoPropsInRoStruct, Location);
}
else if (HasReadOnlyModifier)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyWithSetterCantBeReadOnly, Location, this);
}
}
//issue a diagnostic if the compiler generated attribute ctor is not found.
Binder.ReportUseSiteDiagnosticForSynthesizedAttribute(DeclaringCompilation,
WellKnownMember.System_Runtime_CompilerServices_CompilerGeneratedAttribute__ctor, diagnostics, location: Location);
if (this.RefKind != RefKind.None)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyCannotBeRefReturning, Location, this);
}
// get-only auto property should not override settable properties
if (SetMethod is null && !this.IsReadOnly)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyMustOverrideSet, Location, this);
}
}
if (!IsExpressionBodied)
{
bool hasGetAccessor = GetMethod is object;
bool hasSetAccessor = SetMethod is object;
if (hasGetAccessor && hasSetAccessor)
{
Debug.Assert(_getMethod is object);
Debug.Assert(_setMethod is object);
if (_refKind != RefKind.None)
{
diagnostics.Add(ErrorCode.ERR_RefPropertyCannotHaveSetAccessor, _setMethod.Locations[0], _setMethod);
}
else if ((_getMethod.LocalAccessibility != Accessibility.NotApplicable) &&
(_setMethod.LocalAccessibility != Accessibility.NotApplicable))
{
// Check accessibility is set on at most one accessor.
diagnostics.Add(ErrorCode.ERR_DuplicatePropertyAccessMods, Location, this);
}
else if (_getMethod.LocalDeclaredReadOnly && _setMethod.LocalDeclaredReadOnly)
{
diagnostics.Add(ErrorCode.ERR_DuplicatePropertyReadOnlyMods, Location, this);
}
else if (this.IsAbstract)
{
// Check abstract property accessors are not private.
CheckAbstractPropertyAccessorNotPrivate(_getMethod, diagnostics);
CheckAbstractPropertyAccessorNotPrivate(_setMethod, diagnostics);
}
}
else
{
if (!hasGetAccessor && !hasSetAccessor)
{
diagnostics.Add(ErrorCode.ERR_PropertyWithNoAccessors, Location, this);
}
else if (RefKind != RefKind.None)
{
if (!hasGetAccessor)
{
diagnostics.Add(ErrorCode.ERR_RefPropertyMustHaveGetAccessor, Location, this);
}
}
else if (!hasGetAccessor && IsAutoProperty)
{
diagnostics.Add(ErrorCode.ERR_AutoPropertyMustHaveGetAccessor, _setMethod!.Locations[0], _setMethod);
}
if (!this.IsOverride)
{
var accessor = _getMethod ?? _setMethod;
if (accessor is object)
{
// Check accessibility is not set on the one accessor.
if (accessor.LocalAccessibility != Accessibility.NotApplicable)
{
diagnostics.Add(ErrorCode.ERR_AccessModMissingAccessor, Location, this);
}
// Check that 'readonly' is not set on the one accessor.
if (accessor.LocalDeclaredReadOnly)
{
diagnostics.Add(ErrorCode.ERR_ReadOnlyModMissingAccessor, Location, this);
}
}
}
}
// Check accessor accessibility is more restrictive than property accessibility.
CheckAccessibilityMoreRestrictive(_getMethod, diagnostics);
CheckAccessibilityMoreRestrictive(_setMethod, diagnostics);
}
PropertySymbol? explicitlyImplementedProperty = ExplicitInterfaceImplementations.FirstOrDefault();
if (explicitlyImplementedProperty is object)
{
CheckExplicitImplementationAccessor(GetMethod, explicitlyImplementedProperty.GetMethod, explicitlyImplementedProperty, diagnostics);
CheckExplicitImplementationAccessor(SetMethod, explicitlyImplementedProperty.SetMethod, explicitlyImplementedProperty, diagnostics);
}
#nullable disable
Location location = TypeLocation;
var compilation = DeclaringCompilation;
Debug.Assert(location != null);
// Check constraints on return type and parameters. Note: Dev10 uses the
// property name location for any such errors. We'll do the same for return
// type errors but for parameter errors, we'll use the parameter location.
if ((object)_explicitInterfaceType != null)
{
var explicitInterfaceSpecifier = GetExplicitInterfaceSpecifier();
Debug.Assert(explicitInterfaceSpecifier != null);
_explicitInterfaceType.CheckAllConstraints(compilation, conversions, new SourceLocation(explicitInterfaceSpecifier.Name), diagnostics);
// Note: we delayed nullable-related checks that could pull on NonNullTypes
if (explicitlyImplementedProperty is object)
{
TypeSymbol.CheckNullableReferenceTypeMismatchOnImplementingMember(this.ContainingType, this, explicitlyImplementedProperty, isExplicit: true, diagnostics);
}
}
if (_refKind == RefKind.RefReadOnly)
{
compilation.EnsureIsReadOnlyAttributeExists(diagnostics, location, modifyCompilation: true);
}
ParameterHelpers.EnsureIsReadOnlyAttributeExists(compilation, Parameters, diagnostics, modifyCompilation: true);
if (Type.ContainsNativeInteger())
{
compilation.EnsureNativeIntegerAttributeExists(diagnostics, location, modifyCompilation: true);
}
ParameterHelpers.EnsureNativeIntegerAttributeExists(compilation, Parameters, diagnostics, modifyCompilation: true);
if (compilation.ShouldEmitNullableAttributes(this) &&
this.TypeWithAnnotations.NeedsNullableAttribute())
{
compilation.EnsureNullableAttributeExists(diagnostics, location, modifyCompilation: true);
}
ParameterHelpers.EnsureNullableAttributeExists(compilation, this, Parameters, diagnostics, modifyCompilation: true);
}
private void CheckAccessibility(Location location, BindingDiagnosticBag diagnostics, bool isExplicitInterfaceImplementation)
{
var info = ModifierUtils.CheckAccessibility(_modifiers, this, isExplicitInterfaceImplementation);
if (info != null)
{
diagnostics.Add(new CSDiagnostic(info, location));
}
}
private void CheckModifiers(bool isExplicitInterfaceImplementation, Location location, bool isIndexer, BindingDiagnosticBag diagnostics)
{
Debug.Assert(!IsStatic || (!IsVirtual && !IsOverride)); // Otherwise 'virtual' and 'override' should have been reported and cleared earlier.
bool isExplicitInterfaceImplementationInInterface = isExplicitInterfaceImplementation && ContainingType.IsInterface;
if (this.DeclaredAccessibility == Accessibility.Private && (IsVirtual || (IsAbstract && !isExplicitInterfaceImplementationInInterface) || IsOverride))
{
diagnostics.Add(ErrorCode.ERR_VirtualPrivate, location, this);
}
else if (IsStatic && IsAbstract && !ContainingType.IsInterface)
{
// A static member '{0}' cannot be marked as 'abstract'
diagnostics.Add(ErrorCode.ERR_StaticNotVirtual, location, ModifierUtils.ConvertSingleModifierToSyntaxText(DeclarationModifiers.Abstract));
}
else if (IsStatic && HasReadOnlyModifier)
{
// Static member '{0}' cannot be marked 'readonly'.
diagnostics.Add(ErrorCode.ERR_StaticMemberCantBeReadOnly, location, this);
}
else if (IsOverride && (IsNew || IsVirtual))
{
// A member '{0}' marked as override cannot be marked as new or virtual
diagnostics.Add(ErrorCode.ERR_OverrideNotNew, location, this);
}
else if (IsSealed && !IsOverride && !(IsAbstract && isExplicitInterfaceImplementationInInterface))
{
// '{0}' cannot be sealed because it is not an override
diagnostics.Add(ErrorCode.ERR_SealedNonOverride, location, this);
}
else if (IsAbstract && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.AbstractKeyword));
}
else if (IsVirtual && ContainingType.TypeKind == TypeKind.Struct)
{
// The modifier '{0}' is not valid for this item
diagnostics.Add(ErrorCode.ERR_BadMemberFlag, location, SyntaxFacts.GetText(SyntaxKind.VirtualKeyword));
}
else if (IsAbstract && IsExtern)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndExtern, location, this);
}
else if (IsAbstract && IsSealed && !isExplicitInterfaceImplementationInInterface)
{
diagnostics.Add(ErrorCode.ERR_AbstractAndSealed, location, this);
}
else if (IsAbstract && IsVirtual)
{
diagnostics.Add(ErrorCode.ERR_AbstractNotVirtual, location, this.Kind.Localize(), this);
}
else if (ContainingType.IsSealed && this.DeclaredAccessibility.HasProtected() && !this.IsOverride)
{
diagnostics.Add(AccessCheck.GetProtectedMemberInSealedTypeError(ContainingType), location, this);
}
else if (ContainingType.IsStatic && !IsStatic)
{
ErrorCode errorCode = isIndexer ? ErrorCode.ERR_IndexerInStaticClass : ErrorCode.ERR_InstanceMemberInStaticClass;
diagnostics.Add(errorCode, location, this);
}
}
private void CheckAccessibilityMoreRestrictive(SourcePropertyAccessorSymbol accessor, BindingDiagnosticBag diagnostics)
{
if (((object)accessor != null) &&
!IsAccessibilityMoreRestrictive(this.DeclaredAccessibility, accessor.LocalAccessibility))
{
diagnostics.Add(ErrorCode.ERR_InvalidPropertyAccessMod, accessor.Locations[0], accessor, this);
}
}
/// <summary>
/// Return true if the accessor accessibility is more restrictive
/// than the property accessibility, otherwise false.
/// </summary>
private static bool IsAccessibilityMoreRestrictive(Accessibility property, Accessibility accessor)
{
if (accessor == Accessibility.NotApplicable)
{
return true;
}
return (accessor < property) &&
((accessor != Accessibility.Protected) || (property != Accessibility.Internal));
}
private static void CheckAbstractPropertyAccessorNotPrivate(SourcePropertyAccessorSymbol accessor, BindingDiagnosticBag diagnostics)
{
if (accessor.LocalAccessibility == Accessibility.Private)
{
diagnostics.Add(ErrorCode.ERR_PrivateAbstractAccessor, accessor.Locations[0], accessor);
}
}
public override string GetDocumentationCommentXml(CultureInfo preferredCulture = null, bool expandIncludes = false, CancellationToken cancellationToken = default(CancellationToken))
{
ref var lazyDocComment = ref expandIncludes ? ref _lazyExpandedDocComment : ref _lazyDocComment;
return SourceDocumentationCommentUtils.GetAndCacheDocumentationComment(this, expandIncludes, ref lazyDocComment);
}
// Separate these checks out of FindExplicitlyImplementedProperty because they depend on the accessor symbols,
// which depend on the explicitly implemented property
private void CheckExplicitImplementationAccessor(MethodSymbol thisAccessor, MethodSymbol otherAccessor, PropertySymbol explicitlyImplementedProperty, BindingDiagnosticBag diagnostics)
{
var thisHasAccessor = (object)thisAccessor != null;
var otherHasAccessor = otherAccessor.IsImplementable();
if (otherHasAccessor && !thisHasAccessor)
{
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyMissingAccessor, this.Location, this, otherAccessor);
}
else if (!otherHasAccessor && thisHasAccessor)
{
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyAddingAccessor, thisAccessor.Locations[0], thisAccessor, explicitlyImplementedProperty);
}
else if (TypeSymbol.HaveInitOnlyMismatch(thisAccessor, otherAccessor))
{
Debug.Assert(thisAccessor.MethodKind == MethodKind.PropertySet);
diagnostics.Add(ErrorCode.ERR_ExplicitPropertyMismatchInitOnly, thisAccessor.Locations[0], thisAccessor, otherAccessor);
}
}
internal override OverriddenOrHiddenMembersResult OverriddenOrHiddenMembers
{
get
{
if (_lazyOverriddenOrHiddenMembers == null)
{
Interlocked.CompareExchange(ref _lazyOverriddenOrHiddenMembers, this.MakeOverriddenOrHiddenMembers(), null);
}
return _lazyOverriddenOrHiddenMembers;
}
}
/// <summary>
/// If this property is sealed, then we have to emit both accessors - regardless of whether
/// they are present in the source - so that they can be marked final. (i.e. sealed).
/// </summary>
internal SynthesizedSealedPropertyAccessor SynthesizedSealedAccessorOpt
{
get
{
bool hasGetter = GetMethod is object;
bool hasSetter = SetMethod is object;
if (!this.IsSealed || (hasGetter && hasSetter))
{
return null;
}
// This has to be cached because the CCI layer depends on reference equality.
// However, there's no point in having more than one field, since we don't
// expect to have to synthesize more than one accessor.
if ((object)_lazySynthesizedSealedAccessor == null)
{
Interlocked.CompareExchange(ref _lazySynthesizedSealedAccessor, MakeSynthesizedSealedAccessor(), null);
}
return _lazySynthesizedSealedAccessor;
}
}
/// <remarks>
/// Only non-null for sealed properties without both accessors.
/// </remarks>
private SynthesizedSealedPropertyAccessor MakeSynthesizedSealedAccessor()
{
Debug.Assert(this.IsSealed && (GetMethod is null || SetMethod is null));
if (GetMethod is object)
{
// need to synthesize setter
MethodSymbol overriddenAccessor = this.GetOwnOrInheritedSetMethod();
return (object)overriddenAccessor == null ? null : new SynthesizedSealedPropertyAccessor(this, overriddenAccessor);
}
else if (SetMethod is object)
{
// need to synthesize getter
MethodSymbol overriddenAccessor = this.GetOwnOrInheritedGetMethod();
return (object)overriddenAccessor == null ? null : new SynthesizedSealedPropertyAccessor(this, overriddenAccessor);
}
else
{
// Arguably, it would be more correct to return an array containing two
// synthesized accessors, but we're already in an error case, so we'll
// minimize the cascading error behavior by suppressing synthesis.
return null;
}
}
#region Attributes
public abstract SyntaxList<AttributeListSyntax> AttributeDeclarationSyntaxList { get; }
public abstract IAttributeTargetSymbol AttributesOwner { get; }
IAttributeTargetSymbol IAttributeTargetSymbol.AttributesOwner => AttributesOwner;
AttributeLocation IAttributeTargetSymbol.DefaultAttributeLocation => AttributeLocation.Property;
AttributeLocation IAttributeTargetSymbol.AllowedAttributeLocations
=> IsAutoPropertyWithGetAccessor
? AttributeLocation.Property | AttributeLocation.Field
: AttributeLocation.Property;
/// <summary>
/// Returns a bag of custom attributes applied on the property and data decoded from well-known attributes. Returns null if there are no attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
private CustomAttributesBag<CSharpAttributeData> GetAttributesBag()
{
var bag = _lazyCustomAttributesBag;
if (bag != null && bag.IsSealed)
{
return bag;
}
// The property is responsible for completion of the backing field
_ = BackingField?.GetAttributes();
if (LoadAndValidateAttributes(OneOrMany.Create(AttributeDeclarationSyntaxList), ref _lazyCustomAttributesBag))
{
var completed = _state.NotePartComplete(CompletionPart.Attributes);
Debug.Assert(completed);
}
Debug.Assert(_lazyCustomAttributesBag.IsSealed);
return _lazyCustomAttributesBag;
}
/// <summary>
/// Gets the attributes applied on this symbol.
/// Returns an empty array if there are no attributes.
/// </summary>
/// <remarks>
/// NOTE: This method should always be kept as a sealed override.
/// If you want to override attribute binding logic for a sub-class, then override <see cref="GetAttributesBag"/> method.
/// </remarks>
public sealed override ImmutableArray<CSharpAttributeData> GetAttributes()
{
return this.GetAttributesBag().Attributes;
}
/// <summary>
/// Returns data decoded from well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
private PropertyWellKnownAttributeData GetDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (PropertyWellKnownAttributeData)attributesBag.DecodedWellKnownAttributeData;
}
/// <summary>
/// Returns data decoded from special early bound well-known attributes applied to the symbol or null if there are no applied attributes.
/// </summary>
/// <remarks>
/// Forces binding and decoding of attributes.
/// </remarks>
internal PropertyEarlyWellKnownAttributeData GetEarlyDecodedWellKnownAttributeData()
{
var attributesBag = _lazyCustomAttributesBag;
if (attributesBag == null || !attributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
attributesBag = this.GetAttributesBag();
}
return (PropertyEarlyWellKnownAttributeData)attributesBag.EarlyDecodedWellKnownAttributeData;
}
internal override void AddSynthesizedAttributes(PEModuleBuilder moduleBuilder, ref ArrayBuilder<SynthesizedAttributeData> attributes)
{
base.AddSynthesizedAttributes(moduleBuilder, ref attributes);
var compilation = this.DeclaringCompilation;
var type = this.TypeWithAnnotations;
if (type.Type.ContainsDynamic())
{
AddSynthesizedAttribute(ref attributes,
compilation.SynthesizeDynamicAttribute(type.Type, type.CustomModifiers.Length + RefCustomModifiers.Length, _refKind));
}
if (type.Type.ContainsNativeInteger())
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNativeIntegerAttribute(this, type.Type));
}
if (type.Type.ContainsTupleNames())
{
AddSynthesizedAttribute(ref attributes,
compilation.SynthesizeTupleNamesAttribute(type.Type));
}
if (compilation.ShouldEmitNullableAttributes(this))
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNullableAttributeIfNecessary(this, ContainingType.GetNullableContextValue(), type));
}
if (this.ReturnsByRefReadonly)
{
AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeIsReadOnlyAttribute(this));
}
}
internal sealed override bool IsDirectlyExcludedFromCodeCoverage =>
GetDecodedWellKnownAttributeData()?.HasExcludeFromCodeCoverageAttribute == true;
internal override bool HasSpecialName
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasSpecialNameAttribute;
}
}
internal override CSharpAttributeData EarlyDecodeWellKnownAttribute(ref EarlyDecodeWellKnownAttributeArguments<EarlyWellKnownAttributeBinder, NamedTypeSymbol, AttributeSyntax, AttributeLocation> arguments)
{
CSharpAttributeData boundAttribute;
ObsoleteAttributeData obsoleteData;
if (EarlyDecodeDeprecatedOrExperimentalOrObsoleteAttribute(ref arguments, out boundAttribute, out obsoleteData))
{
if (obsoleteData != null)
{
arguments.GetOrCreateData<PropertyEarlyWellKnownAttributeData>().ObsoleteAttributeData = obsoleteData;
}
return boundAttribute;
}
if (CSharpAttributeData.IsTargetEarlyAttribute(arguments.AttributeType, arguments.AttributeSyntax, AttributeDescription.IndexerNameAttribute))
{
bool hasAnyDiagnostics;
boundAttribute = arguments.Binder.GetAttribute(arguments.AttributeSyntax, arguments.AttributeType, out hasAnyDiagnostics);
if (!boundAttribute.HasErrors)
{
string indexerName = boundAttribute.CommonConstructorArguments[0].DecodeValue<string>(SpecialType.System_String);
if (indexerName != null)
{
arguments.GetOrCreateData<PropertyEarlyWellKnownAttributeData>().IndexerName = indexerName;
}
if (!hasAnyDiagnostics)
{
return boundAttribute;
}
}
return null;
}
return base.EarlyDecodeWellKnownAttribute(ref arguments);
}
/// <summary>
/// Returns data decoded from Obsolete attribute or null if there is no Obsolete attribute.
/// This property returns ObsoleteAttributeData.Uninitialized if attribute arguments haven't been decoded yet.
/// </summary>
internal override ObsoleteAttributeData ObsoleteAttributeData
{
get
{
if (!_containingType.AnyMemberHasAttributes)
{
return null;
}
var lazyCustomAttributesBag = _lazyCustomAttributesBag;
if (lazyCustomAttributesBag != null && lazyCustomAttributesBag.IsEarlyDecodedWellKnownAttributeDataComputed)
{
return ((PropertyEarlyWellKnownAttributeData)lazyCustomAttributesBag.EarlyDecodedWellKnownAttributeData)?.ObsoleteAttributeData;
}
return ObsoleteAttributeData.Uninitialized;
}
}
internal override void DecodeWellKnownAttribute(ref DecodeWellKnownAttributeArguments<AttributeSyntax, CSharpAttributeData, AttributeLocation> arguments)
{
Debug.Assert(arguments.AttributeSyntaxOpt != null);
var diagnostics = (BindingDiagnosticBag)arguments.Diagnostics;
Debug.Assert(diagnostics.DiagnosticBag is object);
var attribute = arguments.Attribute;
Debug.Assert(!attribute.HasErrors);
Debug.Assert(arguments.SymbolPart == AttributeLocation.None);
if (attribute.IsTargetAttribute(this, AttributeDescription.IndexerNameAttribute))
{
//NOTE: decoding was done by EarlyDecodeWellKnownAttribute.
ValidateIndexerNameAttribute(attribute, arguments.AttributeSyntaxOpt, diagnostics);
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.SpecialNameAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasSpecialNameAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.ExcludeFromCodeCoverageAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasExcludeFromCodeCoverageAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.SkipLocalsInitAttribute))
{
CSharpAttributeData.DecodeSkipLocalsInitAttribute<PropertyWellKnownAttributeData>(DeclaringCompilation, ref arguments);
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.DynamicAttribute))
{
// DynamicAttribute should not be set explicitly.
diagnostics.Add(ErrorCode.ERR_ExplicitDynamicAttr, arguments.AttributeSyntaxOpt.Location);
}
else if (ReportExplicitUseOfReservedAttributes(in arguments,
ReservedAttributes.DynamicAttribute | ReservedAttributes.IsReadOnlyAttribute | ReservedAttributes.IsUnmanagedAttribute | ReservedAttributes.IsByRefLikeAttribute | ReservedAttributes.TupleElementNamesAttribute | ReservedAttributes.NullableAttribute | ReservedAttributes.NativeIntegerAttribute))
{
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.DisallowNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasDisallowNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.AllowNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasAllowNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.MaybeNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasMaybeNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.NotNullAttribute))
{
arguments.GetOrCreateData<PropertyWellKnownAttributeData>().HasNotNullAttribute = true;
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.MemberNotNullAttribute))
{
MessageID.IDS_FeatureMemberNotNull.CheckFeatureAvailability(diagnostics, arguments.AttributeSyntaxOpt);
CSharpAttributeData.DecodeMemberNotNullAttribute<PropertyWellKnownAttributeData>(ContainingType, ref arguments);
}
else if (attribute.IsTargetAttribute(this, AttributeDescription.MemberNotNullWhenAttribute))
{
MessageID.IDS_FeatureMemberNotNull.CheckFeatureAvailability(diagnostics, arguments.AttributeSyntaxOpt);
CSharpAttributeData.DecodeMemberNotNullWhenAttribute<PropertyWellKnownAttributeData>(ContainingType, ref arguments);
}
}
internal bool HasDisallowNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasDisallowNullAttribute;
}
}
internal bool HasAllowNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasAllowNullAttribute;
}
}
internal bool HasMaybeNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasMaybeNullAttribute;
}
}
internal bool HasNotNull
{
get
{
var data = GetDecodedWellKnownAttributeData();
return data != null && data.HasNotNullAttribute;
}
}
internal SourceAttributeData DisallowNullAttributeIfExists
=> FindAttribute(AttributeDescription.DisallowNullAttribute);
internal SourceAttributeData AllowNullAttributeIfExists
=> FindAttribute(AttributeDescription.AllowNullAttribute);
internal SourceAttributeData MaybeNullAttributeIfExists
=> FindAttribute(AttributeDescription.MaybeNullAttribute);
internal SourceAttributeData NotNullAttributeIfExists
=> FindAttribute(AttributeDescription.NotNullAttribute);
internal ImmutableArray<SourceAttributeData> MemberNotNullAttributeIfExists
=> FindAttributes(AttributeDescription.MemberNotNullAttribute);
internal ImmutableArray<SourceAttributeData> MemberNotNullWhenAttributeIfExists
=> FindAttributes(AttributeDescription.MemberNotNullWhenAttribute);
private SourceAttributeData FindAttribute(AttributeDescription attributeDescription)
=> (SourceAttributeData)GetAttributes().First(a => a.IsTargetAttribute(this, attributeDescription));
private ImmutableArray<SourceAttributeData> FindAttributes(AttributeDescription attributeDescription)
=> GetAttributes().Where(a => a.IsTargetAttribute(this, attributeDescription)).Cast<SourceAttributeData>().ToImmutableArray();
internal override void PostDecodeWellKnownAttributes(ImmutableArray<CSharpAttributeData> boundAttributes, ImmutableArray<AttributeSyntax> allAttributeSyntaxNodes, BindingDiagnosticBag diagnostics, AttributeLocation symbolPart, WellKnownAttributeData decodedData)
{
Debug.Assert(!boundAttributes.IsDefault);
Debug.Assert(!allAttributeSyntaxNodes.IsDefault);
Debug.Assert(boundAttributes.Length == allAttributeSyntaxNodes.Length);
Debug.Assert(_lazyCustomAttributesBag != null);
Debug.Assert(_lazyCustomAttributesBag.IsDecodedWellKnownAttributeDataComputed);
Debug.Assert(symbolPart == AttributeLocation.None);
base.PostDecodeWellKnownAttributes(boundAttributes, allAttributeSyntaxNodes, diagnostics, symbolPart, decodedData);
}
private void ValidateIndexerNameAttribute(CSharpAttributeData attribute, AttributeSyntax node, BindingDiagnosticBag diagnostics)
{
if (!this.IsIndexer || this.IsExplicitInterfaceImplementation)
{
diagnostics.Add(ErrorCode.ERR_BadIndexerNameAttr, node.Name.Location, node.GetErrorDisplayName());
}
else
{
string indexerName = attribute.CommonConstructorArguments[0].DecodeValue<string>(SpecialType.System_String);
if (indexerName == null || !SyntaxFacts.IsValidIdentifier(indexerName))
{
diagnostics.Add(ErrorCode.ERR_BadArgumentToAttribute, node.ArgumentList.Arguments[0].Location, node.GetErrorDisplayName());
}
}
}
#endregion
#region Completion
internal sealed override bool RequiresCompletion
{
get { return true; }
}
internal sealed override bool HasComplete(CompletionPart part)
{
return _state.HasComplete(part);
}
internal override void ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken)
{
while (true)
{
cancellationToken.ThrowIfCancellationRequested();
var incompletePart = _state.NextIncompletePart;
switch (incompletePart)
{
case CompletionPart.Attributes:
GetAttributes();
break;
case CompletionPart.StartPropertyEnsureSignature:
case CompletionPart.FinishPropertyEnsureSignature:
EnsureSignature();
Debug.Assert(_state.HasComplete(CompletionPart.FinishPropertyEnsureSignature));
break;
case CompletionPart.StartPropertyParameters:
case CompletionPart.FinishPropertyParameters:
{
if (_state.NotePartComplete(CompletionPart.StartPropertyParameters))
{
var parameters = this.Parameters;
if (parameters.Length > 0)
{
var diagnostics = BindingDiagnosticBag.GetInstance();
var conversions = new TypeConversions(this.ContainingAssembly.CorLibrary);
foreach (var parameter in this.Parameters)
{
parameter.ForceComplete(locationOpt, cancellationToken);
parameter.Type.CheckAllConstraints(DeclaringCompilation, conversions, parameter.Locations[0], diagnostics);
}
this.AddDeclarationDiagnostics(diagnostics);
diagnostics.Free();
}
DeclaringCompilation.SymbolDeclaredEvent(this);
var completedOnThisThread = _state.NotePartComplete(CompletionPart.FinishPropertyParameters);
Debug.Assert(completedOnThisThread);
}
else
{
// StartPropertyParameters was completed by another thread. Wait for it to finish the parameters.
_state.SpinWaitComplete(CompletionPart.FinishPropertyParameters, cancellationToken);
}
}
break;
case CompletionPart.StartPropertyType:
case CompletionPart.FinishPropertyType:
{
if (_state.NotePartComplete(CompletionPart.StartPropertyType))
{
var diagnostics = BindingDiagnosticBag.GetInstance();
var conversions = new TypeConversions(this.ContainingAssembly.CorLibrary);
this.Type.CheckAllConstraints(DeclaringCompilation, conversions, Location, diagnostics);
ValidatePropertyType(diagnostics);
this.AddDeclarationDiagnostics(diagnostics);
var completedOnThisThread = _state.NotePartComplete(CompletionPart.FinishPropertyType);
Debug.Assert(completedOnThisThread);
diagnostics.Free();
}
else
{
// StartPropertyType was completed by another thread. Wait for it to finish the type.
_state.SpinWaitComplete(CompletionPart.FinishPropertyType, cancellationToken);
}
}
break;
case CompletionPart.None:
return;
default:
// any other values are completion parts intended for other kinds of symbols
_state.NotePartComplete(CompletionPart.All & ~CompletionPart.PropertySymbolAll);
break;
}
_state.SpinWaitComplete(incompletePart, cancellationToken);
}
}
protected virtual void ValidatePropertyType(BindingDiagnosticBag diagnostics)
{
var type = this.Type;
if (type.IsRestrictedType(ignoreSpanLikeTypes: true))
{
diagnostics.Add(ErrorCode.ERR_FieldCantBeRefAny, TypeLocation, type);
}
else if (this.IsAutoPropertyWithGetAccessor && type.IsRefLikeType && (this.IsStatic || !this.ContainingType.IsRefLikeType))
{
diagnostics.Add(ErrorCode.ERR_FieldAutoPropCantBeByRefLike, TypeLocation, type);
}
}
#endregion
#nullable enable
protected abstract (TypeWithAnnotations Type, ImmutableArray<ParameterSymbol> Parameters) MakeParametersAndBindType(BindingDiagnosticBag diagnostics);
protected static ExplicitInterfaceSpecifierSyntax? GetExplicitInterfaceSpecifier(SyntaxNode syntax)
=> (syntax as BasePropertyDeclarationSyntax)?.ExplicitInterfaceSpecifier;
internal ExplicitInterfaceSpecifierSyntax? GetExplicitInterfaceSpecifier()
=> GetExplicitInterfaceSpecifier(CSharpSyntaxNode);
#nullable disable
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/CSharp/Portable/Compilation/CSharpCompilationExtensions.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Linq;
namespace Microsoft.CodeAnalysis.CSharp
{
internal static class CSharpCompilationExtensions
{
internal static bool IsFeatureEnabled(this CSharpCompilation compilation, MessageID feature)
{
return ((CSharpParseOptions?)compilation.SyntaxTrees.FirstOrDefault()?.Options)?.IsFeatureEnabled(feature) == true;
}
internal static bool IsFeatureEnabled(this SyntaxNode? syntax, MessageID feature)
{
return ((CSharpParseOptions?)syntax?.SyntaxTree.Options)?.IsFeatureEnabled(feature) == true;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Linq;
namespace Microsoft.CodeAnalysis.CSharp
{
internal static class CSharpCompilationExtensions
{
internal static bool IsFeatureEnabled(this CSharpCompilation compilation, MessageID feature)
{
return ((CSharpParseOptions?)compilation.SyntaxTrees.FirstOrDefault()?.Options)?.IsFeatureEnabled(feature) == true;
}
internal static bool IsFeatureEnabled(this SyntaxNode? syntax, MessageID feature)
{
return ((CSharpParseOptions?)syntax?.SyntaxTree.Options)?.IsFeatureEnabled(feature) == true;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/Core/Portable/Syntax/InternalSyntax/SeparatedSyntaxListBuilder.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
namespace Microsoft.CodeAnalysis.Syntax.InternalSyntax
{
// The null-suppression uses in this type are covered under the following issue to
// better design this type around a null _builder
// https://github.com/dotnet/roslyn/issues/40858
internal struct SeparatedSyntaxListBuilder<TNode> where TNode : GreenNode
{
private readonly SyntaxListBuilder? _builder;
public SeparatedSyntaxListBuilder(int size)
: this(new SyntaxListBuilder(size))
{
}
public static SeparatedSyntaxListBuilder<TNode> Create()
{
return new SeparatedSyntaxListBuilder<TNode>(8);
}
internal SeparatedSyntaxListBuilder(SyntaxListBuilder builder)
{
_builder = builder;
}
public bool IsNull
{
get
{
return _builder == null;
}
}
public int Count
{
get
{
return _builder!.Count;
}
}
public GreenNode? this[int index]
{
get
{
return _builder![index];
}
set
{
_builder![index] = value;
}
}
public void Clear()
{
_builder!.Clear();
}
public void RemoveLast()
{
_builder!.RemoveLast();
}
public SeparatedSyntaxListBuilder<TNode> Add(TNode node)
{
_builder!.Add(node);
return this;
}
public void AddSeparator(GreenNode separatorToken)
{
_builder!.Add(separatorToken);
}
public void AddRange(TNode[] items, int offset, int length)
{
_builder!.AddRange(items, offset, length);
}
public void AddRange(in SeparatedSyntaxList<TNode> nodes)
{
_builder!.AddRange(nodes.GetWithSeparators());
}
public void AddRange(in SeparatedSyntaxList<TNode> nodes, int count)
{
var list = nodes.GetWithSeparators();
_builder!.AddRange(list, this.Count, Math.Min(count * 2, list.Count));
}
public bool Any(int kind)
{
return _builder!.Any(kind);
}
public SeparatedSyntaxList<TNode> ToList()
{
return _builder == null
? default(SeparatedSyntaxList<TNode>)
: new SeparatedSyntaxList<TNode>(new SyntaxList<GreenNode>(_builder.ToListNode()));
}
/// <summary>
/// WARN WARN WARN: This should be used with extreme caution - the underlying builder does
/// not give any indication that it is from a separated syntax list but the constraints
/// (node, token, node, token, ...) should still be maintained.
/// </summary>
/// <remarks>
/// In order to avoid creating a separate pool of SeparatedSyntaxListBuilders, we expose
/// our underlying SyntaxListBuilder to SyntaxListPool.
/// </remarks>
internal SyntaxListBuilder? UnderlyingBuilder
{
get { return _builder; }
}
public static implicit operator SeparatedSyntaxList<TNode>(in SeparatedSyntaxListBuilder<TNode> builder)
{
return builder.ToList();
}
public static implicit operator SyntaxListBuilder?(in SeparatedSyntaxListBuilder<TNode> builder)
{
return builder._builder;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
namespace Microsoft.CodeAnalysis.Syntax.InternalSyntax
{
// The null-suppression uses in this type are covered under the following issue to
// better design this type around a null _builder
// https://github.com/dotnet/roslyn/issues/40858
internal struct SeparatedSyntaxListBuilder<TNode> where TNode : GreenNode
{
private readonly SyntaxListBuilder? _builder;
public SeparatedSyntaxListBuilder(int size)
: this(new SyntaxListBuilder(size))
{
}
public static SeparatedSyntaxListBuilder<TNode> Create()
{
return new SeparatedSyntaxListBuilder<TNode>(8);
}
internal SeparatedSyntaxListBuilder(SyntaxListBuilder builder)
{
_builder = builder;
}
public bool IsNull
{
get
{
return _builder == null;
}
}
public int Count
{
get
{
return _builder!.Count;
}
}
public GreenNode? this[int index]
{
get
{
return _builder![index];
}
set
{
_builder![index] = value;
}
}
public void Clear()
{
_builder!.Clear();
}
public void RemoveLast()
{
_builder!.RemoveLast();
}
public SeparatedSyntaxListBuilder<TNode> Add(TNode node)
{
_builder!.Add(node);
return this;
}
public void AddSeparator(GreenNode separatorToken)
{
_builder!.Add(separatorToken);
}
public void AddRange(TNode[] items, int offset, int length)
{
_builder!.AddRange(items, offset, length);
}
public void AddRange(in SeparatedSyntaxList<TNode> nodes)
{
_builder!.AddRange(nodes.GetWithSeparators());
}
public void AddRange(in SeparatedSyntaxList<TNode> nodes, int count)
{
var list = nodes.GetWithSeparators();
_builder!.AddRange(list, this.Count, Math.Min(count * 2, list.Count));
}
public bool Any(int kind)
{
return _builder!.Any(kind);
}
public SeparatedSyntaxList<TNode> ToList()
{
return _builder == null
? default(SeparatedSyntaxList<TNode>)
: new SeparatedSyntaxList<TNode>(new SyntaxList<GreenNode>(_builder.ToListNode()));
}
/// <summary>
/// WARN WARN WARN: This should be used with extreme caution - the underlying builder does
/// not give any indication that it is from a separated syntax list but the constraints
/// (node, token, node, token, ...) should still be maintained.
/// </summary>
/// <remarks>
/// In order to avoid creating a separate pool of SeparatedSyntaxListBuilders, we expose
/// our underlying SyntaxListBuilder to SyntaxListPool.
/// </remarks>
internal SyntaxListBuilder? UnderlyingBuilder
{
get { return _builder; }
}
public static implicit operator SeparatedSyntaxList<TNode>(in SeparatedSyntaxListBuilder<TNode> builder)
{
return builder.ToList();
}
public static implicit operator SyntaxListBuilder?(in SeparatedSyntaxListBuilder<TNode> builder)
{
return builder._builder;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/CSharp/Test/Semantic/Semantics/DeconstructionTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Test.Utilities;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.CSharp.UnitTests.Semantics
{
[CompilerTrait(CompilerFeature.Tuples)]
public class DeconstructionTests : CompilingTestBase
{
private static readonly MetadataReference[] s_valueTupleRefs = new[] { SystemRuntimeFacadeRef, ValueTupleRef };
const string commonSource =
@"public class Pair<T1, T2>
{
T1 item1;
T2 item2;
public Pair(T1 item1, T2 item2)
{
this.item1 = item1;
this.item2 = item2;
}
public void Deconstruct(out T1 item1, out T2 item2)
{
System.Console.WriteLine($""Deconstructing {ToString()}"");
item1 = this.item1;
item2 = this.item2;
}
public override string ToString() { return $""({item1.ToString()}, {item2.ToString()})""; }
}
public static class Pair
{
public static Pair<T1, T2> Create<T1, T2>(T1 item1, T2 item2) { return new Pair<T1, T2>(item1, item2); }
}
public class Integer
{
public int state;
public override string ToString() { return state.ToString(); }
public Integer(int i) { state = i; }
public static implicit operator LongInteger(Integer i) { System.Console.WriteLine($""Converting {i}""); return new LongInteger(i.state); }
}
public class LongInteger
{
long state;
public LongInteger(long l) { state = l; }
public override string ToString() { return state.ToString(); }
}";
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodMissing()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'C' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'C' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "new C()").WithArguments("C", "Deconstruct").WithLocation(8, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWrongParams()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a) // too few arguments
{
a = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1501: No overload for method 'Deconstruct' takes 2 arguments
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgCount, "new C()").WithArguments("Deconstruct", "2").WithLocation(8, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWrongParams2()
{
string source = @"
class C
{
static void Main()
{
long x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a, out int b, out int c) // too many arguments
{
a = b = c = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.Int64 y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.Int64 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS7036: There is no argument given that corresponds to the required formal parameter 'c' of 'C.Deconstruct(out int, out int, out int)'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoCorrespondingArgument, "new C()").WithArguments("c", "C.Deconstruct(out int, out int, out int)").WithLocation(7, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignmentWithLeftHandSideErrors()
{
string source = @"
class C
{
static void Main()
{
long x = 1;
string y = ""hello"";
/*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
}
public void Deconstruct() { }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x.f, y.g) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (? f, ? g), IsInvalid) (Syntax: '(x.f, y.g)')
NaturalType: (? f, ? g)
Elements(2):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x.f')
Children(1):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'y.g')
Children(1):
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'long' does not contain a definition for 'f' and no extension method 'f' accepting a first argument of type 'long' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "f").WithArguments("long", "f").WithLocation(8, 22),
// CS1061: 'string' does not contain a definition for 'g' and no extension method 'g' accepting a first argument of type 'string' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "g").WithArguments("string", "g").WithLocation(8, 27),
// CS1501: No overload for method 'Deconstruct' takes 2 arguments
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgCount, "new C()").WithArguments("Deconstruct", "2").WithLocation(8, 32),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 32)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWithInParam()
{
string source = @"
class C
{
static void Main()
{
int x;
int y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int x, int y) { x = 1; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1615: Argument 2 may not be passed with the 'out' keyword
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgExtraRef, "(x, y) = new C()").WithArguments("2", "out").WithLocation(8, 19),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWithRefParam()
{
string source = @"
class C
{
static void Main()
{
int x;
int y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(ref int x, out int y) { x = 1; y = 2; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1620: Argument 1 must be passed with the 'ref' keyword
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgRef, "(x, y) = new C()").WithArguments("1", "ref").WithLocation(8, 19),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructManually()
{
string source = @"
struct C
{
static void Main()
{
long x;
string y;
C c = new C();
c.Deconstruct(out x, out y); // error
/*<bind>*/(x, y) = c/*</bind>*/;
}
void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y) = c')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
ILocalReferenceOperation: c (OperationKind.LocalReference, Type: C) (Syntax: 'c')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1503: Argument 1: cannot convert from 'out long' to 'out int'
// c.Deconstruct(out x, out y); // error
Diagnostic(ErrorCode.ERR_BadArgType, "x").WithArguments("1", "out long", "out int").WithLocation(10, 27)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodHasOptionalParam()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out string b, int c = 42) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void BadDeconstructShadowsBaseDeconstruct()
{
string source = @"
class D
{
public void Deconstruct(out int a, out string b) { a = 2; b = ""world""; }
}
class C : D
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out string b, int c = 42) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(13, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodHasParams()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out string b, params int[] c) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodHasArglist()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a, out string b, __arglist) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS7036: There is no argument given that corresponds to the required formal parameter '__arglist' of 'C.Deconstruct(out int, out string, __arglist)'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoCorrespondingArgument, "new C()").WithArguments("__arglist", "C.Deconstruct(out int, out string, __arglist)").WithLocation(9, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructDelegate()
{
string source = @"
delegate void D1(out int x, out int y);
class C
{
public D1 Deconstruct; // not a Deconstruct operator
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
}
public static void DeconstructMethod(out int a, out int b) { a = 1; b = 2; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = ne ... uctMethod }')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C() { D ... uctMethod }')
Arguments(0)
Initializer:
IObjectOrCollectionInitializerOperation (OperationKind.ObjectOrCollectionInitializer, Type: C, IsInvalid) (Syntax: '{ Deconstru ... uctMethod }')
Initializers(1):
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: D1, IsInvalid) (Syntax: 'Deconstruct ... tructMethod')
Left:
IFieldReferenceOperation: D1 C.Deconstruct (OperationKind.FieldReference, Type: D1, IsInvalid) (Syntax: 'Deconstruct')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ImplicitReceiver) (OperationKind.InstanceReference, Type: C, IsInvalid, IsImplicit) (Syntax: 'Deconstruct')
Right:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: D1, IsInvalid, IsImplicit) (Syntax: 'DeconstructMethod')
Target:
IMethodReferenceOperation: void C.DeconstructMethod(out System.Int32 a, out System.Int32 b) (Static) (OperationKind.MethodReference, Type: null, IsInvalid) (Syntax: 'DeconstructMethod')
Instance Receiver:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C() { Deconstruct = DeconstructMethod }").WithArguments("C", "2").WithLocation(11, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructDelegate2()
{
string source = @"
delegate void D1(out int x, out int y);
class C
{
public D1 Deconstruct;
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
}
public static void DeconstructMethod(out int a, out int b) { a = 1; b = 2; }
public void Deconstruct(out int a, out int b) { a = 1; b = 2; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32 y), IsInvalid) (Syntax: '(x, y) = ne ... uctMethod }')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C() { D ... uctMethod }')
Arguments(0)
Initializer:
IObjectOrCollectionInitializerOperation (OperationKind.ObjectOrCollectionInitializer, Type: C, IsInvalid) (Syntax: '{ Deconstru ... uctMethod }')
Initializers(1):
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: ?, IsInvalid) (Syntax: 'Deconstruct ... tructMethod')
Left:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid, IsImplicit) (Syntax: 'Deconstruct')
Children(1):
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'Deconstruct')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ImplicitReceiver) (OperationKind.InstanceReference, Type: C, IsImplicit) (Syntax: 'C')
Right:
IOperation: (OperationKind.None, Type: null) (Syntax: 'DeconstructMethod')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C, IsImplicit) (Syntax: 'DeconstructMethod')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0102: The type 'C' already contains a definition for 'Deconstruct'
// public void Deconstruct(out int a, out int b) { a = 1; b = 2; }
Diagnostic(ErrorCode.ERR_DuplicateNameInClass, "Deconstruct").WithArguments("C", "Deconstruct").WithLocation(16, 17),
// CS1913: Member 'Deconstruct' cannot be initialized. It is not a field or property.
// /*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
Diagnostic(ErrorCode.ERR_MemberCannotBeInitialized, "Deconstruct").WithArguments("Deconstruct").WithLocation(11, 38),
// CS0649: Field 'C.Deconstruct' is never assigned to, and will always have its default value null
// public D1 Deconstruct;
Diagnostic(ErrorCode.WRN_UnassignedInternalField, "Deconstruct").WithArguments("C.Deconstruct", "null").WithLocation(6, 15)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructEvent()
{
string source = @"
delegate void D1(out int x, out int y);
class C
{
public event D1 Deconstruct; // not a Deconstruct operator
static void Main()
{
long x;
int y;
C c = new C();
c.Deconstruct += DeconstructMethod;
/*<bind>*/(x, y) = c/*</bind>*/;
}
public static void DeconstructMethod(out int a, out int b)
{
a = 1;
b = 2;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = c')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
ILocalReferenceOperation: c (OperationKind.LocalReference, Type: C, IsInvalid) (Syntax: 'c')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = c/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "c").WithArguments("C", "2").WithLocation(14, 28),
// CS0067: The event 'C.Deconstruct' is never used
// public event D1 Deconstruct; // not a Deconstruct operator
Diagnostic(ErrorCode.WRN_UnreferencedEvent, "Deconstruct").WithArguments("C.Deconstruct").WithLocation(6, 21)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ConversionErrors()
{
string source = @"
class C
{
static void Main()
{
byte x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Byte x, System.String y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (System.Byte x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Byte, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0266: Cannot implicitly convert type 'int' to 'byte'. An explicit conversion exists (are you missing a cast?)
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "x").WithArguments("int", "byte").WithLocation(8, 20),
// CS0029: Cannot implicitly convert type 'int' to 'string'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "y").WithArguments("int", "string").WithLocation(8, 23)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void ExpressionType()
{
string source = @"
class C
{
static void Main()
{
int x, y;
var type = ((x, y) = new C()).GetType();
System.Console.Write(type.ToString());
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
var comp = CreateCompilation(source, options: TestOptions.DebugExe);
comp.VerifyDiagnostics();
CompileAndVerify(comp, expectedOutput: "System.ValueTuple`2[System.Int32,System.Int32]");
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ExpressionType_IOperation()
{
string source = @"
class C
{
static void Main()
{
int x, y;
var type = (/*<bind>*/(x, y) = new C()/*</bind>*/).GetType();
System.Console.Write(type.ToString());
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void LambdaStillNotValidStatement()
{
string source = @"
class C
{
static void Main()
{
(a) => a;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (a) => a;
Diagnostic(ErrorCode.ERR_IllegalStatement, "(a) => a").WithLocation(6, 9)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void LambdaWithBodyStillNotValidStatement()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(a, b) => { }/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IAnonymousFunctionOperation (Symbol: lambda expression) (OperationKind.AnonymousFunction, Type: null, IsInvalid) (Syntax: '(a, b) => { }')
IBlockOperation (0 statements) (OperationKind.Block, Type: null, IsInvalid) (Syntax: '{ }')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// /*<bind>*/(a, b) => { }/*</bind>*/;
Diagnostic(ErrorCode.ERR_IllegalStatement, "(a, b) => { }").WithLocation(6, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<ParenthesizedLambdaExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void CastButNotCast()
{
// int and string must be types, so (int, string) must be type and ((int, string)) a cast, but then .String() cannot follow a cast...
string source = @"
class C
{
static void Main()
{
/*<bind>*/((int, string)).ToString()/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IInvocationOperation (virtual System.String (System.Int32, System.String).ToString()) (OperationKind.Invocation, Type: System.String, IsInvalid) (Syntax: '((int, stri ... .ToString()')
Instance Receiver:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.String), IsInvalid) (Syntax: '(int, string)')
NaturalType: (System.Int32, System.String)
Elements(2):
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'int')
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'string')
Arguments(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1525: Invalid expression term 'int'
// /*<bind>*/((int, string)).ToString()/*</bind>*/;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "int").WithArguments("int").WithLocation(6, 21),
// CS1525: Invalid expression term 'string'
// /*<bind>*/((int, string)).ToString()/*</bind>*/;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "string").WithArguments("string").WithLocation(6, 26)
};
VerifyOperationTreeAndDiagnosticsForTest<InvocationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningMethod2()
{
string source = @"
class C
{
static int i;
static void Main()
{
(M(), M()) = new C();
System.Console.Write(i);
}
static ref int M()
{
System.Console.Write(""M "");
return ref i;
}
void Deconstruct(out int i, out int j)
{
i = 42;
j = 43;
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "M M 43");
comp.VerifyDiagnostics(
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningMethod2_IOperation()
{
string source = @"
class C
{
static int i;
static void Main()
{
/*<bind>*/(M(), M()) = new C()/*</bind>*/;
System.Console.Write(i);
}
static ref int M()
{
System.Console.Write(""M "");
return ref i;
}
void Deconstruct(out int i, out int j)
{
i = 42;
j = 43;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32)) (Syntax: '(M(), M()) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(M(), M())')
NaturalType: (System.Int32, System.Int32)
Elements(2):
IInvocationOperation (ref System.Int32 C.M()) (OperationKind.Invocation, Type: System.Int32) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
IInvocationOperation (ref System.Int32 C.M()) (OperationKind.Invocation, Type: System.Int32) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void UninitializedRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = x/*</bind>*/;
}
}
static class D
{
public static void Deconstruct(this int input, out int output, out int output2) { output = input; output2 = input; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(x, x) = x')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0165: Use of unassigned local variable 'x'
// /*<bind>*/(x, x) = x/*</bind>*/;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x").WithArguments("x").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NullRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = null/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(x, x) = null')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/(x, x) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ErrorRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = undeclared/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(x, x) = undeclared')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'undeclared')
Children(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0103: The name 'undeclared' does not exist in the current context
// /*<bind>*/(x, x) = undeclared/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "undeclared").WithArguments("undeclared").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void VoidRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = M()/*</bind>*/;
}
static void M() { }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, x) = M()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
IInvocationOperation (void C.M()) (OperationKind.Invocation, Type: System.Void, IsInvalid) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'void' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'void' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x, x) = M()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "M()").WithArguments("void", "Deconstruct").WithLocation(7, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'void', with 2 out parameters and a void return type.
// /*<bind>*/(x, x) = M()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "M()").WithArguments("void", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssigningTupleWithNoConversion()
{
string source = @"
class C
{
static void Main()
{
byte x;
string y;
/*<bind>*/(x, y) = (1, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Byte x, System.String y), IsInvalid) (Syntax: '(x, y) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Byte x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Byte x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Byte) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Byte, System.String), IsInvalid, IsImplicit) (Syntax: '(1, 2)')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2, IsInvalid) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0029: Cannot implicitly convert type 'int' to 'string'
// /*<bind>*/(x, y) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "2").WithArguments("int", "string").WithLocation(9, 32)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NotAssignable()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(1, P) = (1, 2)/*</bind>*/;
}
static int P { get { return 1; } }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32 P), IsInvalid) (Syntax: '(1, P) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32 P), IsInvalid) (Syntax: '(1, P)')
NaturalType: (System.Int32, System.Int32 P)
Elements(2):
IInvalidOperation (OperationKind.Invalid, Type: System.Int32, IsInvalid, IsImplicit) (Syntax: '1')
Children(1):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1, IsInvalid) (Syntax: '1')
IInvalidOperation (OperationKind.Invalid, Type: System.Int32, IsInvalid, IsImplicit) (Syntax: 'P')
Children(1):
IPropertyReferenceOperation: System.Int32 C.P { get; } (Static) (OperationKind.PropertyReference, Type: System.Int32, IsInvalid) (Syntax: 'P')
Instance Receiver:
null
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0131: The left-hand side of an assignment must be a variable, property or indexer
// /*<bind>*/(1, P) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_AssgLvalueExpected, "1").WithLocation(6, 20),
// CS0200: Property or indexer 'C.P' cannot be assigned to -- it is read only
// /*<bind>*/(1, P) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_AssgReadonlyProp, "P").WithArguments("C.P").WithLocation(6, 23)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void TupleWithUseSiteError()
{
string source = @"
namespace System
{
public struct ValueTuple<T1, T2>
{
public T1 Item1;
public ValueTuple(T1 item1, T2 item2)
{
this.Item1 = item1;
}
}
}
class C
{
static void Main()
{
int x;
int y;
(x, y) = (1, 2);
System.Console.WriteLine($""{x} {y}"");
}
}
";
var comp = CreateCompilation(source, assemblyName: "comp", options: TestOptions.DebugExe);
comp.VerifyDiagnostics();
comp.VerifyEmitDiagnostics();
CompileAndVerify(comp, expectedOutput: "1 2");
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TupleWithUseSiteError_IOperation()
{
string source = @"
namespace System
{
struct ValueTuple<T1, T2>
{
public T1 Item1;
public ValueTuple(T1 item1, T2 item2)
{
this.Item1 = item1;
}
}
}
class C
{
static void Main()
{
int x;
int y;
/*<bind>*/(x, y) = (1, 2)/*</bind>*/;
System.Console.WriteLine($""{x} {y}"");
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignUsingAmbiguousDeconstruction()
{
string source = @"
class Base
{
public void Deconstruct(out int a, out int b) { a = 1; b = 2; }
public void Deconstruct(out long a, out long b) { a = 1; b = 2; }
}
class C : Base
{
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// file.cs(12,28): error CS0121: The call is ambiguous between the following methods or properties: 'Base.Deconstruct(out int, out int)' and 'Base.Deconstruct(out long, out long)'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_AmbigCall, "new C()").WithArguments("Base.Deconstruct(out int, out int)", "Base.Deconstruct(out long, out long)").WithLocation(12, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructIsDynamicField()
{
string source = @"
class C
{
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public dynamic Deconstruct = null;
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructIsField()
{
string source = @"
class C
{
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public object Deconstruct = null;
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1955: Non-invocable member 'C.Deconstruct' cannot be used like a method.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NonInvocableMemberCalled, "new C()").WithArguments("C.Deconstruct").WithLocation(7, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void CannotDeconstructRefTuple22()
{
string template = @"
using System;
class C
{
static void Main()
{
int VARIABLES; // int x1, x2, ...
(VARIABLES) = CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)));
}
public static Tuple<T1, T2, T3, T4, T5, T6, T7, TRest> CreateLongRef<T1, T2, T3, T4, T5, T6, T7, TRest>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, TRest rest) =>
new Tuple<T1, T2, T3, T4, T5, T6, T7, TRest>(item1, item2, item3, item4, item5, item6, item7, rest);
}
";
var tuple = String.Join(", ", Enumerable.Range(1, 22).Select(n => n.ToString()));
var variables = String.Join(", ", Enumerable.Range(1, 22).Select(n => $"x{n}"));
var source = template.Replace("VARIABLES", variables).Replace("TUPLE", tuple);
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (8,113): error CS1501: No overload for method 'Deconstruct' takes 22 arguments
// (x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19, x20, x21, x22) = CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)));
Diagnostic(ErrorCode.ERR_BadArgCount, "CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)))").WithArguments("Deconstruct", "22").WithLocation(8, 113),
// (8,113): error CS8129: No Deconstruct instance or extension method was found for type 'Tuple<int, int, int, int, int, int, int, Tuple<int, int, int, int, int, int, int, Tuple<int, int, int, int, int, int, int, Tuple<int>>>>', with 22 out parameters.
// (x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19, x20, x21, x22) = CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)));
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)))").WithArguments("System.Tuple<int, int, int, int, int, int, int, System.Tuple<int, int, int, int, int, int, int, System.Tuple<int, int, int, int, int, int, int, System.Tuple<int>>>>", "22").WithLocation(8, 113)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructUsingDynamicMethod()
{
string source = @"
class C
{
static void Main()
{
int x;
string y;
dynamic c = new C();
/*<bind>*/(x, y) = c/*</bind>*/;
}
public void Deconstruct(out int a, out string b) { a = 1; b = ""hello""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = c')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
ILocalReferenceOperation: c (OperationKind.LocalReference, Type: dynamic, IsInvalid) (Syntax: 'c')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8133: Cannot deconstruct dynamic objects.
// /*<bind>*/(x, y) = c/*</bind>*/;
Diagnostic(ErrorCode.ERR_CannotDeconstructDynamic, "c").WithLocation(10, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodInaccessible()
{
string source = @"
class C
{
static void Main()
{
int x;
string y;
/*<bind>*/(x, y) = new C1()/*</bind>*/;
}
}
class C1
{
protected void Deconstruct(out int a, out string b) { a = 1; b = ""hello""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C1()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C1..ctor()) (OperationKind.ObjectCreation, Type: C1, IsInvalid) (Syntax: 'new C1()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0122: 'C1.Deconstruct(out int, out string)' is inaccessible due to its protection level
// /*<bind>*/(x, y) = new C1()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadAccess, "new C1()").WithArguments("C1.Deconstruct(out int, out string)").WithLocation(9, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C1', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C1()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C1()").WithArguments("C1", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void DeconstructHasUseSiteError()
{
string libMissingSource = @"public class Missing { }";
string libSource = @"
public class C
{
public void Deconstruct(out Missing a, out Missing b) { a = new Missing(); b = new Missing(); }
}
";
string source = @"
class C1
{
static void Main()
{
object x, y;
(x, y) = new C();
}
}
";
var libMissingComp = CreateCompilation(new string[] { libMissingSource }, assemblyName: "libMissingComp").VerifyDiagnostics();
var libMissingRef = libMissingComp.EmitToImageReference();
var libComp = CreateCompilation(new string[] { libSource }, references: new[] { libMissingRef }, parseOptions: TestOptions.Regular).VerifyDiagnostics();
var libRef = libComp.EmitToImageReference();
var comp = CreateCompilation(new string[] { source }, references: new[] { libRef });
comp.VerifyDiagnostics(
// (7,18): error CS0012: The type 'Missing' is defined in an assembly that is not referenced. You must add a reference to assembly 'libMissingComp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'.
// (x, y) = new C();
Diagnostic(ErrorCode.ERR_NoTypeDef, "new C()").WithArguments("Missing", "libMissingComp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null").WithLocation(7, 18),
// (7,18): error CS8129: No Deconstruct instance or extension method was found for type 'C', with 2 out parameters.
// (x, y) = new C();
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 18)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void StaticDeconstruct()
{
string source = @"
class C
{
static void Main()
{
int x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public static void Deconstruct(out int a, out string b) { a = 1; b = ""hello""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0176: Member 'C.Deconstruct(out int, out string)' cannot be accessed with an instance reference; qualify it with a type name instead
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_ObjectProhibited, "new C()").WithArguments("C.Deconstruct(out int, out string)").WithLocation(9, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void AssignmentTypeIsValueTuple()
{
string source = @"
class C
{
public static void Main()
{
long x; string y;
var z1 = ((x, y) = new C()).ToString();
var z2 = ((x, y) = new C());
var z3 = (x, y) = new C();
System.Console.Write($""{z1} {z2.ToString()} {z3.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "(1, hello) (1, hello) (1, hello)");
comp.VerifyDiagnostics();
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignmentTypeIsValueTuple_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x; string y;
var z1 = ((x, y) = new C()).ToString();
var z2 = (/*<bind>*/(x, y) = new C()/*</bind>*/);
var z3 = (x, y) = new C();
System.Console.Write($""{z1} {z2.ToString()} {z3.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void NestedAssignmentTypeIsValueTuple()
{
string source = @"
class C
{
public static void Main()
{
long x1; string x2; int x3;
var y = ((x1, x2), x3) = (new C(), 3);
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "((1, hello), 3)");
comp.VerifyDiagnostics();
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NestedAssignmentTypeIsValueTuple_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x1; string x2; int x3;
var y = /*<bind>*/((x1, x2), x3) = (new C(), 3)/*</bind>*/;
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ((System.Int64 x1, System.String x2), System.Int32 x3)) (Syntax: '((x1, x2), ... new C(), 3)')
Left:
ITupleOperation (OperationKind.Tuple, Type: ((System.Int64 x1, System.String x2), System.Int32 x3)) (Syntax: '((x1, x2), x3)')
NaturalType: ((System.Int64 x1, System.String x2), System.Int32 x3)
Elements(2):
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x1, System.String x2)) (Syntax: '(x1, x2)')
NaturalType: (System.Int64 x1, System.String x2)
Elements(2):
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x1')
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.String) (Syntax: 'x2')
ILocalReferenceOperation: x3 (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x3')
Right:
ITupleOperation (OperationKind.Tuple, Type: (C, System.Int32)) (Syntax: '(new C(), 3)')
NaturalType: (C, System.Int32)
Elements(2):
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3) (Syntax: '3')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void AssignmentReturnsLongValueTuple()
{
string source = @"
class C
{
public static void Main()
{
long x;
var y = (x, x, x, x, x, x, x, x, x) = new C();
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int x1, out int x2, out int x3, out int x4, out int x5, out int x6, out int x7, out int x8, out int x9)
{
x1 = x2 = x3 = x4 = x5 = x6 = x7 = x8 = 1;
x9 = 9;
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "(1, 1, 1, 1, 1, 1, 1, 1, 9)");
comp.VerifyDiagnostics();
var tree = comp.Compilation.SyntaxTrees.First();
var model = comp.Compilation.GetSemanticModel(tree, ignoreAccessibility: false);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
var y = nodes.OfType<VariableDeclaratorSyntax>().Skip(1).First();
Assert.Equal("y = (x, x, x, x, x, x, x, x, x) = new C()", y.ToFullString());
Assert.Equal("(System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64) y",
model.GetDeclaredSymbol(y).ToTestDisplayString());
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignmentReturnsLongValueTuple_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x;
var /*<bind>*/y = (x, x, x, x, x, x, x, x, x) = new C()/*</bind>*/;
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int x1, out int x2, out int x3, out int x4, out int x5, out int x6, out int x7, out int x8, out int x9)
{
x1 = x2 = x3 = x4 = x5 = x6 = x7 = x8 = 1;
x9 = 9;
}
}
";
string expectedOperationTree = @"
IVariableDeclaratorOperation (Symbol: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64) y) (OperationKind.VariableDeclarator, Type: null) (Syntax: 'y = (x, x, ... ) = new C()')
Initializer:
IVariableInitializerOperation (OperationKind.VariableInitializer, Type: null) (Syntax: '= (x, x, x, ... ) = new C()')
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64)) (Syntax: '(x, x, x, x ... ) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64)) (Syntax: '(x, x, x, x ... x, x, x, x)')
NaturalType: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64)
Elements(9):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<VariableDeclaratorSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void DeconstructWithoutValueTupleLibrary()
{
string source = @"
class C
{
public static void Main()
{
long x;
var y = (x, x) = new C();
System.Console.Write(y.ToString());
}
public void Deconstruct(out int x1, out int x2)
{
x1 = x2 = 1;
}
}
";
var comp = CreateCompilationWithMscorlib40(source);
comp.VerifyDiagnostics(
// (7,17): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// var y = (x, x) = new C();
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(x, x)").WithArguments("System.ValueTuple`2").WithLocation(7, 17)
);
}
[Fact]
public void ChainedAssignment()
{
string source = @"
class C
{
public static void Main()
{
long x1, x2;
var y = (x1, x1) = (x2, x2) = new C();
System.Console.Write($""{y.ToString()} {x1} {x2}"");
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
var comp = CreateCompilation(source, options: TestOptions.DebugExe);
comp.VerifyDiagnostics();
CompileAndVerify(comp, expectedOutput: "(1, 1) 1 1");
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ChainedAssignment_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x1, x2;
var y = /*<bind>*/(x1, x1) = (x2, x2) = new C()/*</bind>*/;
System.Console.Write($""{y.ToString()} {x1} {x2}"");
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64, System.Int64)) (Syntax: '(x1, x1) = ... ) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64, System.Int64)) (Syntax: '(x1, x1)')
NaturalType: (System.Int64, System.Int64)
Elements(2):
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x1')
Right:
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64, System.Int64)) (Syntax: '(x2, x2) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64, System.Int64)) (Syntax: '(x2, x2)')
NaturalType: (System.Int64, System.Int64)
Elements(2):
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x2')
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x2')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NestedTypelessTupleAssignment2()
{
string source = @"
class C
{
static void Main()
{
int x, y, z; // int cannot be null
/*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
System.Console.WriteLine(""nothing"" + x + y + z);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, (System.Int32 y, System.Int32 z)), IsInvalid) (Syntax: '(x, (y, z)) ... ull, null))')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, (System.Int32 y, System.Int32 z))) (Syntax: '(x, (y, z))')
NaturalType: (System.Int32 x, (System.Int32 y, System.Int32 z))
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 y, System.Int32 z)) (Syntax: '(y, z)')
NaturalType: (System.Int32 y, System.Int32 z)
Elements(2):
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
ILocalReferenceOperation: z (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'z')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32, (System.Int32, System.Int32)), IsInvalid, IsImplicit) (Syntax: '(null, (null, null))')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: null, IsInvalid) (Syntax: '(null, (null, null))')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ITupleOperation (OperationKind.Tuple, Type: null, IsInvalid) (Syntax: '(null, null)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0037: Cannot convert null to 'int' because it is a non-nullable value type
// /*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
Diagnostic(ErrorCode.ERR_ValueCantBeNull, "null").WithArguments("int").WithLocation(8, 34),
// CS0037: Cannot convert null to 'int' because it is a non-nullable value type
// /*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
Diagnostic(ErrorCode.ERR_ValueCantBeNull, "null").WithArguments("int").WithLocation(8, 41),
// CS0037: Cannot convert null to 'int' because it is a non-nullable value type
// /*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
Diagnostic(ErrorCode.ERR_ValueCantBeNull, "null").WithArguments("int").WithLocation(8, 47)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TupleWithWrongCardinality()
{
string source = @"
class C
{
static void Main()
{
int x, y, z;
/*<bind>*/(x, y, z) = MakePair()/*</bind>*/;
}
public static (int, int) MakePair()
{
return (42, 42);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y, z) = MakePair()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y, System.Int32 z), IsInvalid) (Syntax: '(x, y, z)')
NaturalType: (System.Int32 x, System.Int32 y, System.Int32 z)
Elements(3):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
ILocalReferenceOperation: z (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'z')
Right:
IInvocationOperation ((System.Int32, System.Int32) C.MakePair()) (OperationKind.Invocation, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'MakePair()')
Instance Receiver:
null
Arguments(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '2' elements into '3' variables.
// /*<bind>*/(x, y, z) = MakePair()/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, "(x, y, z) = MakePair()").WithArguments("2", "3").WithLocation(8, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NestedTupleWithWrongCardinality()
{
string source = @"
class C
{
static void Main()
{
int x, y, z, w;
/*<bind>*/(x, (y, z, w)) = Pair.Create(42, (43, 44))/*</bind>*/;
}
}
" + commonSource;
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, (y, z, ... , (43, 44))')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, (System.Int32 y, System.Int32 z, System.Int32 w)), IsInvalid) (Syntax: '(x, (y, z, w))')
NaturalType: (System.Int32 x, (System.Int32 y, System.Int32 z, System.Int32 w))
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 y, System.Int32 z, System.Int32 w), IsInvalid) (Syntax: '(y, z, w)')
NaturalType: (System.Int32 y, System.Int32 z, System.Int32 w)
Elements(3):
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
ILocalReferenceOperation: z (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'z')
ILocalReferenceOperation: w (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'w')
Right:
IInvocationOperation (Pair<System.Int32, (System.Int32, System.Int32)> Pair.Create<System.Int32, (System.Int32, System.Int32)>(System.Int32 item1, (System.Int32, System.Int32) item2)) (OperationKind.Invocation, Type: Pair<System.Int32, (System.Int32, System.Int32)>, IsInvalid) (Syntax: 'Pair.Create ... , (43, 44))')
Instance Receiver:
null
Arguments(2):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item1) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: '42')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 42, IsInvalid) (Syntax: '42')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item2) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: '(43, 44)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(43, 44)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 43, IsInvalid) (Syntax: '43')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 44, IsInvalid) (Syntax: '44')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '2' elements into '3' variables.
// /*<bind>*/(x, (y, z, w)) = Pair.Create(42, (43, 44))/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, "(x, (y, z, w)) = Pair.Create(42, (43, 44))").WithArguments("2", "3").WithLocation(8, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructionTooFewElements()
{
string source = @"
class C
{
static void Main()
{
for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
}
}
" + commonSource;
string expectedOperationTree = @"
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: ?, IsInvalid) (Syntax: '(var(x, y)) ... reate(1, 2)')
Left:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x, y)')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'y')
Children(0)
Right:
IInvocationOperation (Pair<System.Int32, System.Int32> Pair.Create<System.Int32, System.Int32>(System.Int32 item1, System.Int32 item2)) (OperationKind.Invocation, Type: Pair<System.Int32, System.Int32>) (Syntax: 'Pair.Create(1, 2)')
Instance Receiver:
null
Arguments(2):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item1) (OperationKind.Argument, Type: null) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item2) (OperationKind.Argument, Type: null) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0103: The name 'var' does not exist in the current context
// for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(6, 25),
// CS0103: The name 'x' does not exist in the current context
// for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "x").WithArguments("x").WithLocation(6, 29),
// CS0103: The name 'y' does not exist in the current context
// for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "y").WithArguments("y").WithLocation(6, 32)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void DeconstructionDeclarationInCSharp6()
{
string source = @"
class C
{
static void Main()
{
var (x1, x2) = Pair.Create(1, 2);
(int x3, int x4) = Pair.Create(1, 2);
foreach ((int x5, var (x6, x7)) in new[] { Pair.Create(1, Pair.Create(2, 3)) }) { }
for ((int x8, var (x9, x10)) = Pair.Create(1, Pair.Create(2, 3)); ; ) { }
}
}
" + commonSource;
var comp = CreateCompilation(source, parseOptions: TestOptions.Regular6);
comp.VerifyDiagnostics(
// (6,13): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// var (x1, x2) = Pair.Create(1, 2);
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(x1, x2)").WithArguments("tuples", "7.0").WithLocation(6, 13),
// (7,9): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// (int x3, int x4) = Pair.Create(1, 2);
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(int x3, int x4)").WithArguments("tuples", "7.0").WithLocation(7, 9),
// (8,18): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// foreach ((int x5, var (x6, x7)) in new[] { Pair.Create(1, Pair.Create(2, 3)) }) { }
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(int x5, var (x6, x7))").WithArguments("tuples", "7.0").WithLocation(8, 18),
// (9,14): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// for ((int x8, var (x9, x10)) = Pair.Create(1, Pair.Create(2, 3)); ; ) { }
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(int x8, var (x9, x10))").WithArguments("tuples", "7.0").WithLocation(9, 14)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclareLocalTwice()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x1) = (1, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'var (x1, x1) = (1, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'var (x1, x1)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(x1, x1)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0128: A local variable or function named 'x1' is already defined in this scope
// /*<bind>*/var (x1, x1) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x1").WithArguments("x1").WithLocation(6, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclareLocalTwice2()
{
string source = @"
class C
{
static void Main()
{
string x1 = null;
/*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
System.Console.WriteLine(x1);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0128: A local variable or function named 'x1' is already defined in this scope
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x1").WithArguments("x1").WithLocation(7, 24)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void VarMethodMissing()
{
string source = @"
class C
{
static void Main()
{
int x1 = 1;
int x2 = 1;
/*<bind>*/var(x1, x2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x1, x2)')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0103: The name 'var' does not exist in the current context
// /*<bind>*/var(x1, x2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(8, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<InvocationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void UseBeforeDeclared()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
}
static (int, int) M(int a) { return (1, 2); }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(int x1, int x2) = M(x1)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IInvocationOperation ((System.Int32, System.Int32) C.M(System.Int32 a)) (OperationKind.Invocation, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'M(x1)')
Instance Receiver:
null
Arguments(1):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: a) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0165: Use of unassigned local variable 'x1'
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x1").WithArguments("x1").WithLocation(6, 40)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclareWithVoidType()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
}
static void M(int a) { }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(int x1, int x2) = M(x1)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IInvocationOperation (void C.M(System.Int32 a)) (OperationKind.Invocation, Type: System.Void, IsInvalid) (Syntax: 'M(x1)')
Instance Receiver:
null
Arguments(1):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: a) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'void' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'void' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "M(x1)").WithArguments("void", "Deconstruct").WithLocation(6, 38),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'void', with 2 out parameters and a void return type.
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "M(x1)").WithArguments("void", "2").WithLocation(6, 38),
// CS0165: Use of unassigned local variable 'x1'
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x1").WithArguments("x1").WithLocation(6, 40)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void UseBeforeDeclared2()
{
string source = @"
class C
{
static void Main()
{
System.Console.WriteLine(x1);
/*<bind>*/(int x1, int x2) = (1, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, in ... 2) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x1' before it is declared
// System.Console.WriteLine(x1);
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 34)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NullAssignmentInDeclaration()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(int x1, int x2) = null/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(int x1, int x2) = null')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/(int x1, int x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(6, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NullAssignmentInVarDeclaration()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = null/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: 'var (x1, x2) = null')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/var (x1, x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(6, 34),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// /*<bind>*/var (x1, x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 24),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/var (x1, x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypelessDeclaration()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (1, null)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: 'var (x1, x2) = (1, null)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(1, null)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// /*<bind>*/var (x1, x2) = (1, null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 24),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/var (x1, x2) = (1, null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithMultipleAmbiguousVars()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, (byte x2, var x3), var x4) = (null, (2, null), null)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(string x1, ... ull), null)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, (System.Byte x2, var x3), var x4), IsInvalid) (Syntax: '(string x1, ... 3), var x4)')
NaturalType: (System.String x1, (System.Byte x2, var x3), var x4)
Elements(3):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String) (Syntax: 'x1')
ITupleOperation (OperationKind.Tuple, Type: (System.Byte x2, var x3), IsInvalid) (Syntax: '(byte x2, var x3)')
NaturalType: (System.Byte x2, var x3)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Byte) (Syntax: 'byte x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Byte) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x3')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x4')
ILocalReferenceOperation: x4 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x4')
Right:
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(null, (2, null), null)')
NaturalType: null
Elements(3):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(2, null)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x3'.
// /*<bind>*/(string x1, (byte x2, var x3), var x4) = (null, (2, null), null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x3").WithArguments("x3").WithLocation(6, 45),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x4'.
// /*<bind>*/(string x1, (byte x2, var x3), var x4) = (null, (2, null), null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x4").WithArguments("x4").WithLocation(6, 54)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyLeftNestings()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/((string x1, byte x2, var x3), int x4) = (null, 4)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '((string x1 ... = (null, 4)')
Left:
ITupleOperation (OperationKind.Tuple, Type: ((System.String x1, System.Byte x2, var x3), System.Int32 x4), IsInvalid) (Syntax: '((string x1 ... 3), int x4)')
NaturalType: ((System.String x1, System.Byte x2, var x3), System.Int32 x4)
Elements(2):
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, System.Byte x2, var x3), IsInvalid) (Syntax: '(string x1, ... x2, var x3)')
NaturalType: (System.String x1, System.Byte x2, var x3)
Elements(3):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Byte) (Syntax: 'byte x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Byte) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x3')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x4')
ILocalReferenceOperation: x4 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x4')
Right:
ITupleOperation (OperationKind.Tuple, Type: null, IsInvalid) (Syntax: '(null, 4)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 4) (Syntax: '4')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/((string x1, byte x2, var x3), int x4) = (null, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(6, 61),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x3'.
// /*<bind>*/((string x1, byte x2, var x3), int x4) = (null, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x3").WithArguments("x3").WithLocation(6, 45)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyRightNestings()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, var x2) = (null, (null, 2))/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(string x1, ... (null, 2))')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, var x2), IsInvalid) (Syntax: '(string x1, var x2)')
NaturalType: (System.String x1, var x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(null, (null, 2))')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(null, 2)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/(string x1, var x2) = (null, (null, 2))/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 35)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyLeftVariables()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, var x2, int x3) = (null, ""hello"")/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(string x1, ... l, ""hello"")')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, System.String x2, System.Int32 x3), IsInvalid) (Syntax: '(string x1, ... x2, int x3)')
NaturalType: (System.String x1, System.String x2, System.Int32 x3)
Elements(3):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'var x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'int x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x3')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.String, System.String), IsInvalid) (Syntax: '(null, ""hello"")')
NaturalType: null
Elements(2):
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.String, Constant: null, IsInvalid, IsImplicit) (Syntax: 'null')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.String, Constant: ""hello"", IsInvalid) (Syntax: '""hello""')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '2' elements into '3' variables.
// /*<bind>*/(string x1, var x2, int x3) = (null, "hello")/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, @"(string x1, var x2, int x3) = (null, ""hello"")").WithArguments("2", "3").WithLocation(6, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyRightElements()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, var y1) = (null, ""hello"", 3)/*</bind>*/;
(string x2, var y2) = (null, ""hello"", null);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(string x1, ... ""hello"", 3)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, System.String y1), IsInvalid) (Syntax: '(string x1, var y1)')
NaturalType: (System.String x1, System.String y1)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'var y1')
ILocalReferenceOperation: y1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'y1')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.String, System.String, System.Int32), IsInvalid) (Syntax: '(null, ""hello"", 3)')
NaturalType: null
Elements(3):
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.String, Constant: null, IsInvalid, IsImplicit) (Syntax: 'null')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.String, Constant: ""hello"", IsInvalid) (Syntax: '""hello""')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3, IsInvalid) (Syntax: '3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '3' elements into '2' variables.
// /*<bind>*/(string x1, var y1) = (null, "hello", 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, @"(string x1, var y1) = (null, ""hello"", 3)").WithArguments("3", "2").WithLocation(6, 19),
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// (string x2, var y2) = (null, "hello", null);
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(7, 47),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'y2'.
// (string x2, var y2) = (null, "hello", null);
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "y2").WithArguments("y2").WithLocation(7, 25)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationVarFormWithActualVarType()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
}
}
class var { }
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (var, var), IsInvalid, IsImplicit) (Syntax: '(1, 2)')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1, IsInvalid) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2, IsInvalid) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8136: Deconstruction 'var (...)' form disallows a specific type for 'var'.
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "(x1, x2)").WithLocation(6, 23),
// CS0029: Cannot implicitly convert type 'int' to 'var'
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "1").WithArguments("int", "var").WithLocation(6, 35),
// CS0029: Cannot implicitly convert type 'int' to 'var'
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "2").WithArguments("int", "var").WithLocation(6, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationVarFormWithAliasedVarType()
{
string source = @"
using var = D;
class C
{
static void Main()
{
/*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
}
}
class D
{
public override string ToString() { return ""var""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (D x3, D x4), IsInvalid) (Syntax: 'var (x3, x4) = (3, 4)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (D x3, D x4), IsInvalid) (Syntax: 'var (x3, x4)')
ITupleOperation (OperationKind.Tuple, Type: (D x3, D x4), IsInvalid) (Syntax: '(x3, x4)')
NaturalType: (D x3, D x4)
Elements(2):
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: D, IsInvalid) (Syntax: 'x3')
ILocalReferenceOperation: x4 (IsDeclaration: True) (OperationKind.LocalReference, Type: D, IsInvalid) (Syntax: 'x4')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (D, D), IsInvalid, IsImplicit) (Syntax: '(3, 4)')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(3, 4)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3, IsInvalid) (Syntax: '3')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 4, IsInvalid) (Syntax: '4')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8136: Deconstruction 'var (...)' form disallows a specific type for 'var'.
// /*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "(x3, x4)").WithLocation(7, 23),
// CS0029: Cannot implicitly convert type 'int' to 'D'
// /*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "3").WithArguments("int", "D").WithLocation(7, 35),
// CS0029: Cannot implicitly convert type 'int' to 'D'
// /*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "4").WithArguments("int", "D").WithLocation(7, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithWrongCardinality()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(var (x1, x ... = (1, 2, 3)')
Left:
ITupleOperation (OperationKind.Tuple, Type: ((var x1, var x2), System.Int32 x3), IsInvalid) (Syntax: '(var (x1, x2), var x3)')
NaturalType: ((var x1, var x2), System.Int32 x3)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'var x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x3')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32, System.Int32), IsInvalid) (Syntax: '(1, 2, 3)')
NaturalType: (System.Int32, System.Int32, System.Int32)
Elements(3):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1, IsInvalid) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2, IsInvalid) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3, IsInvalid) (Syntax: '3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '3' elements into '2' variables.
// /*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, "(var (x1, x2), var x3) = (1, 2, 3)").WithArguments("3", "2").WithLocation(6, 19),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// /*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 25),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 29)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithCircularity1()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, var x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, x1)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x1, var x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, var x2)) (Syntax: '(x1, x2)')
NaturalType: (System.Int32 x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32, var), IsInvalid, IsImplicit) (Syntax: '(1, x1)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, var x1), IsInvalid) (Syntax: '(1, x1)')
NaturalType: (System.Int32, var x1)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x1' before it is declared
// /*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithCircularity2()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (var x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2) = (x2, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, System.Int32 x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, System.Int32 x2)) (Syntax: '(x1, x2)')
NaturalType: (var x1, System.Int32 x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (var, System.Int32), IsInvalid, IsImplicit) (Syntax: '(x2, 2)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (var x2, System.Int32), IsInvalid) (Syntax: '(x2, 2)')
NaturalType: (var x2, System.Int32)
Elements(2):
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x2' before it is declared
// /*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x2").WithArguments("x2").WithLocation(6, 35)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningVarInvocation()
{
string source = @"
class C
{
static int i;
static void Main()
{
int x = 0, y = 0;
/*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
System.Console.WriteLine(i);
}
static ref int var(int a, int b) { return ref i; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: 'var (x, y) = 42')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x, var y), IsInvalid) (Syntax: 'var (x, y)')
ITupleOperation (OperationKind.Tuple, Type: (var x, var y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (var x, var y)
Elements(2):
ILocalReferenceOperation: x (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'y')
Right:
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 42, IsInvalid) (Syntax: '42')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0128: A local variable or function named 'x' is already defined in this scope
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(9, 24),
// CS0128: A local variable or function named 'y' is already defined in this scope
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(9, 27),
// CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "42").WithArguments("int", "Deconstruct").WithLocation(9, 32),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'int', with 2 out parameters and a void return type.
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "42").WithArguments("int", "2").WithLocation(9, 32),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x'.
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x").WithArguments("x").WithLocation(9, 24),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'y'.
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "y").WithArguments("y").WithLocation(9, 27),
// CS0219: The variable 'x' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "x").WithArguments("x").WithLocation(8, 13),
// CS0219: The variable 'y' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "y").WithArguments("y").WithLocation(8, 20)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact(Skip = "https://github.com/dotnet/roslyn/issues/12468"), CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12468, "https://github.com/dotnet/roslyn/issues/12468")]
public void RefReturningVarInvocation2()
{
string source = @"
class C
{
static int i = 0;
static void Main()
{
int x = 0, y = 0;
@var(x, y) = 42; // parsed as invocation
System.Console.Write(i + "" "");
(var(x, y)) = 43; // parsed as invocation
System.Console.Write(i + "" "");
(var(x, y) = 44); // parsed as invocation
System.Console.Write(i);
}
static ref int var(int a, int b) { return ref i; }
}
";
// The correct expectation is for the code to compile and execute
//var comp = CompileAndVerify(source, expectedOutput: "42 43 44");
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (11,9): error CS8134: Deconstruction must contain at least two variables.
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_DeconstructTooFewElements, "(var(x, y)) = 43").WithLocation(11, 9),
// (13,20): error CS1026: ) expected
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_CloseParenExpected, "=").WithLocation(13, 20),
// (13,24): error CS1002: ; expected
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_SemicolonExpected, ")").WithLocation(13, 24),
// (13,24): error CS1513: } expected
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_RbraceExpected, ")").WithLocation(13, 24),
// (9,14): error CS0128: A local variable named 'x' is already defined in this scope
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(9, 14),
// (9,9): error CS0246: The type or namespace name 'var' could not be found (are you missing a using directive or an assembly reference?)
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "@var").WithArguments("var").WithLocation(9, 9),
// (9,14): error CS8136: Deconstruction `var (...)` form disallows a specific type for 'var'.
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "x").WithLocation(9, 14),
// (9,17): error CS0128: A local variable named 'y' is already defined in this scope
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(9, 17),
// (9,9): error CS0246: The type or namespace name 'var' could not be found (are you missing a using directive or an assembly reference?)
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "@var").WithArguments("var").WithLocation(9, 9),
// (9,17): error CS8136: Deconstruction `var (...)` form disallows a specific type for 'var'.
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "y").WithLocation(9, 17),
// (9,22): error CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "42").WithArguments("int", "Deconstruct").WithLocation(9, 22),
// (9,22): error CS8129: No Deconstruct instance or extension method was found for type 'int', with 2 out parameters.
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "42").WithArguments("int", "2").WithLocation(9, 22),
// (11,14): error CS0128: A local variable named 'x' is already defined in this scope
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(11, 14),
// (11,17): error CS0128: A local variable named 'y' is already defined in this scope
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(11, 17),
// (11,23): error CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "43").WithArguments("int", "Deconstruct").WithLocation(11, 23),
// (11,23): error CS8129: No Deconstruct instance or extension method was found for type 'int', with 1 out parameters.
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "43").WithArguments("int", "1").WithLocation(11, 23),
// (13,14): error CS0128: A local variable named 'x' is already defined in this scope
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(13, 14),
// (13,17): error CS0128: A local variable named 'y' is already defined in this scope
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(13, 17),
// (13,22): error CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "44").WithArguments("int", "Deconstruct").WithLocation(13, 22),
// (13,22): error CS8129: No Deconstruct instance or extension method was found for type 'int', with 1 out parameters.
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "44").WithArguments("int", "1").WithLocation(13, 22),
// (8,13): warning CS0219: The variable 'x' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "x").WithArguments("x").WithLocation(8, 13),
// (8,20): warning CS0219: The variable 'y' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "y").WithArguments("y").WithLocation(8, 20)
);
}
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningInvocation()
{
string source = @"
class C
{
static int i;
static void Main()
{
int x = 0, y = 0;
M(x, y) = 42;
System.Console.WriteLine(i);
}
static ref int M(int a, int b) { return ref i; }
}
";
var comp = CompileAndVerify(source, expectedOutput: "42");
comp.VerifyDiagnostics();
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithTypeInsideVarForm()
{
string source = @"
class C
{
static void Main()
{
var(int x1, x2) = (1, 2);
var(var x3, x4) = (1, 2);
/*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
}
}
";
string expectedOperationTree = @"
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: ?, IsInvalid) (Syntax: 'var(x5, var ... (1, (2, 3))')
Left:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x5, var(x6, x7))')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x5')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x6, x7)')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x6')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x7')
Children(0)
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, (System.Int32, System.Int32))) (Syntax: '(1, (2, 3))')
NaturalType: (System.Int32, (System.Int32, System.Int32))
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(2, 3)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3) (Syntax: '3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1525: Invalid expression term 'int'
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "int").WithArguments("int").WithLocation(6, 13),
// CS1003: Syntax error, ',' expected
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_SyntaxError, "x1").WithArguments(",", "").WithLocation(6, 17),
// CS1003: Syntax error, ',' expected
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_SyntaxError, "x3").WithArguments(",", "").WithLocation(7, 17),
// CS8199: The syntax 'var (...)' as an lvalue is reserved.
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_VarInvocationLvalueReserved, "var(int x1, x2)").WithLocation(6, 9),
// CS0103: The name 'var' does not exist in the current context
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(6, 9),
// CS0103: The name 'x1' does not exist in the current context
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 17),
// CS0103: The name 'x2' does not exist in the current context
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x2").WithArguments("x2").WithLocation(6, 21),
// CS8199: The syntax 'var (...)' as an lvalue is reserved.
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_VarInvocationLvalueReserved, "var(var x3, x4)").WithLocation(7, 9),
// CS0103: The name 'var' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 9),
// CS0103: The name 'var' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 13),
// CS0103: The name 'x3' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x3").WithArguments("x3").WithLocation(7, 17),
// CS0103: The name 'x4' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x4").WithArguments("x4").WithLocation(7, 21),
// CS8199: The syntax 'var (...)' as an lvalue is reserved.
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_VarInvocationLvalueReserved, "var(x5, var(x6, x7))").WithLocation(8, 19),
// CS0103: The name 'var' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(8, 19),
// CS0103: The name 'x5' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x5").WithArguments("x5").WithLocation(8, 23),
// CS0103: The name 'var' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(8, 27),
// CS0103: The name 'x6' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x6").WithArguments("x6").WithLocation(8, 31),
// CS0103: The name 'x7' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x7").WithArguments("x7").WithLocation(8, 35)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForWithCircularity1()
{
string source = @"
class C
{
static void Main()
{
for (/*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/; ;) { }
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, var x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, x1)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x1, var x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, var x2)) (Syntax: '(x1, x2)')
NaturalType: (System.Int32 x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32, var), IsInvalid, IsImplicit) (Syntax: '(1, x1)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, var x1), IsInvalid) (Syntax: '(1, x1)')
NaturalType: (System.Int32, var x1)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x1' before it is declared
// for (/*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 43)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForWithCircularity2()
{
string source = @"
class C
{
static void Main()
{
for (/*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/; ;) { }
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (var x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2) = (x2, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, System.Int32 x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, System.Int32 x2)) (Syntax: '(x1, x2)')
NaturalType: (var x1, System.Int32 x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (var, System.Int32), IsInvalid, IsImplicit) (Syntax: '(x2, 2)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (var x2, System.Int32), IsInvalid) (Syntax: '(x2, 2)')
NaturalType: (var x2, System.Int32)
Elements(2):
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x2' before it is declared
// for (/*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x2").WithArguments("x2").WithLocation(6, 40)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachNameConflict()
{
string source = @"
class C
{
static void Main()
{
int x1 = 1;
/*<bind>*/foreach ((int x1, int x2) in M()) { }/*</bind>*/
System.Console.Write(x1);
}
static (int, int)[] M() { return new[] { (1, 2) }; }
}
";
string expectedOperationTree = @"
IForEachLoopOperation (LoopKind.ForEach, Continue Label Id: 0, Exit Label Id: 1) (OperationKind.Loop, Type: null, IsInvalid) (Syntax: 'foreach ((i ... in M()) { }')
Locals: Local_1: System.Int32 x1
Local_2: System.Int32 x2
LoopControlVariable:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Collection:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.Collections.IEnumerable, IsImplicit) (Syntax: 'M()')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
IInvocationOperation ((System.Int32, System.Int32)[] C.M()) (OperationKind.Invocation, Type: (System.Int32, System.Int32)[]) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
Body:
IBlockOperation (0 statements) (OperationKind.Block, Type: null) (Syntax: '{ }')
NextVariables(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0136: A local or parameter named 'x1' cannot be declared in this scope because that name is used in an enclosing local scope to define a local or parameter
// /*<bind>*/foreach ((int x1, int x2) in M()) { }/*</bind>*/
Diagnostic(ErrorCode.ERR_LocalIllegallyOverrides, "x1").WithArguments("x1").WithLocation(7, 33)
};
VerifyOperationTreeAndDiagnosticsForTest<ForEachVariableStatementSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachNameConflict2()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/foreach ((int x1, int x2) in M(out int x1)) { }/*</bind>*/
}
static (int, int)[] M(out int a) { a = 1; return new[] { (1, 2) }; }
}
";
string expectedOperationTree = @"
IForEachLoopOperation (LoopKind.ForEach, Continue Label Id: 0, Exit Label Id: 1) (OperationKind.Loop, Type: null, IsInvalid) (Syntax: 'foreach ((i ... nt x1)) { }')
Locals: Local_1: System.Int32 x1
Local_2: System.Int32 x2
LoopControlVariable:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Collection:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.Collections.IEnumerable, IsImplicit) (Syntax: 'M(out int x1)')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
IInvocationOperation ((System.Int32, System.Int32)[] C.M(out System.Int32 a)) (OperationKind.Invocation, Type: (System.Int32, System.Int32)[]) (Syntax: 'M(out int x1)')
Instance Receiver:
null
Arguments(1):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: a) (OperationKind.Argument, Type: null) (Syntax: 'out int x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Body:
IBlockOperation (0 statements) (OperationKind.Block, Type: null) (Syntax: '{ }')
NextVariables(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0136: A local or parameter named 'x1' cannot be declared in this scope because that name is used in an enclosing local scope to define a local or parameter
// /*<bind>*/foreach ((int x1, int x2) in M(out int x1)) { }/*</bind>*/
Diagnostic(ErrorCode.ERR_LocalIllegallyOverrides, "x1").WithArguments("x1").WithLocation(6, 33)
};
VerifyOperationTreeAndDiagnosticsForTest<ForEachVariableStatementSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void ForEachNameConflict3()
{
string source = @"
class C
{
static void Main()
{
foreach ((int x1, int x2) in M())
{
int x1 = 1;
System.Console.Write(x1);
}
}
static (int, int)[] M() { return new[] { (1, 2) }; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (8,17): error CS0136: A local or parameter named 'x1' cannot be declared in this scope because that name is used in an enclosing local scope to define a local or parameter
// int x1 = 1;
Diagnostic(ErrorCode.ERR_LocalIllegallyOverrides, "x1").WithArguments("x1").WithLocation(8, 17)
);
}
[Fact]
public void ForEachUseBeforeDeclared()
{
string source = @"
class C
{
static void Main()
{
foreach ((int x1, int x2) in M(x1)) { }
}
static (int, int)[] M(int a) { return new[] { (1, 2) }; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,40): error CS0103: The name 'x1' does not exist in the current context
// foreach ((int x1, int x2) in M(x1))
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 40)
);
}
[Fact]
public void ForEachUseOutsideScope()
{
string source = @"
class C
{
static void Main()
{
foreach ((int x1, int x2) in M()) { }
System.Console.Write(x1);
}
static (int, int)[] M() { return new[] { (1, 2) }; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (7,30): error CS0103: The name 'x1' does not exist in the current context
// System.Console.Write(x1);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(7, 30)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachNoIEnumerable()
{
string source = @"
class C
{
static void Main()
{
foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
{
System.Console.WriteLine(x1 + "" "" + x2);
}
}
}
";
string expectedOperationTree = @"
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1579: foreach statement cannot operate on variables of type 'int' because 'int' does not contain a public definition for 'GetEnumerator'
// foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
Diagnostic(ErrorCode.ERR_ForEachMissingMember, "1").WithArguments("int", "GetEnumerator").WithLocation(6, 55),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 33),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 37)
};
VerifyOperationTreeAndDiagnosticsForTest<DeclarationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachIterationVariablesAreReadonly()
{
string source = @"
class C
{
static void Main()
{
foreach (/*<bind>*/(int x1, var (x2, x3))/*</bind>*/ in new[] { (1, (1, 1)) })
{
x1 = 1;
x2 = 2;
x3 = 3;
}
}
}
";
string expectedOperationTree = @"
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, (System.Int32 x2, System.Int32 x3))) (Syntax: '(int x1, var (x2, x3))')
NaturalType: (System.Int32 x1, (System.Int32 x2, System.Int32 x3))
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x2, System.Int32 x3)) (Syntax: 'var (x2, x3)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x2, System.Int32 x3)) (Syntax: '(x2, x3)')
NaturalType: (System.Int32 x2, System.Int32 x3)
Elements(2):
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1656: Cannot assign to 'x1' because it is a 'foreach iteration variable'
// x1 = 1;
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "x1").WithArguments("x1", "foreach iteration variable").WithLocation(8, 13),
// CS1656: Cannot assign to 'x2' because it is a 'foreach iteration variable'
// x2 = 2;
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "x2").WithArguments("x2", "foreach iteration variable").WithLocation(9, 13),
// CS1656: Cannot assign to 'x3' because it is a 'foreach iteration variable'
// x3 = 3;
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "x3").WithArguments("x3", "foreach iteration variable").WithLocation(10, 13)
};
VerifyOperationTreeAndDiagnosticsForTest<TupleExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void ForEachScoping()
{
string source = @"
class C
{
static void Main()
{
foreach (var (x1, x2) in M(x1)) { }
}
static (int, int) M(int i) { return (1, 2); }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,36): error CS0103: The name 'x1' does not exist in the current context
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 36),
// (6,34): error CS1579: foreach statement cannot operate on variables of type '(int, int)' because '(int, int)' does not contain a public instance or extension definition for 'GetEnumerator'
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_ForEachMissingMember, "M(x1)").WithArguments("(int, int)", "GetEnumerator").WithLocation(6, 34),
// (6,23): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 23),
// (6,27): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 27)
);
}
[Fact]
public void AssignmentDataFlow()
{
string source = @"
class C
{
static void Main()
{
int x, y;
(x, y) = new C(); // x and y are assigned here, so no complaints on usage of un-initialized locals on the line below
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out int b)
{
a = 1;
b = 2;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics();
}
[Fact]
public void GetTypeInfoForTupleLiteral()
{
var source = @"
class C
{
static void Main()
{
var x1 = (1, 2);
var (x2, x3) = (1, 2);
System.Console.Write($""{x1} {x2} {x3}"");
}
}
";
Action<ModuleSymbol> validator = module =>
{
var sourceModule = (SourceModuleSymbol)module;
var compilation = sourceModule.DeclaringCompilation;
var tree = compilation.SyntaxTrees.First();
var model = compilation.GetSemanticModel(tree);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
var literal1 = nodes.OfType<TupleExpressionSyntax>().First();
Assert.Equal("(int, int)", model.GetTypeInfo(literal1).Type.ToDisplayString());
var literal2 = nodes.OfType<TupleExpressionSyntax>().Skip(1).First();
Assert.Equal("(int, int)", model.GetTypeInfo(literal2).Type.ToDisplayString());
};
var verifier = CompileAndVerify(source, sourceSymbolValidator: validator);
verifier.VerifyDiagnostics();
}
[Fact]
public void DeclarationWithCircularity3()
{
string source = @"
class C
{
static void Main()
{
var (x1, x2) = (M(out x2), M(out x1));
}
static T M<T>(out T x) { x = default(T); return x; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,31): error CS0841: Cannot use local variable 'x2' before it is declared
// var (x1, x2) = (M(out x2), M(out x1));
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x2").WithArguments("x2").WithLocation(6, 31),
// (6,42): error CS0841: Cannot use local variable 'x1' before it is declared
// var (x1, x2) = (M(out x2), M(out x1));
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 42)
);
}
[Fact, WorkItem(13081, "https://github.com/dotnet/roslyn/issues/13081")]
public void GettingDiagnosticsWhenValueTupleIsMissing()
{
var source = @"
class C1
{
static void Test(int arg1, (byte, byte) arg2)
{
foreach ((int, int) e in new (int, int)[10])
{
}
}
}
";
var comp = CreateCompilationWithMscorlib40(source);
comp.VerifyDiagnostics(
// (4,32): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// static void Test(int arg1, (byte, byte) arg2)
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(byte, byte)").WithArguments("System.ValueTuple`2").WithLocation(4, 32),
// (6,38): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// foreach ((int, int) e in new (int, int)[10])
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(int, int)").WithArguments("System.ValueTuple`2").WithLocation(6, 38),
// (6,18): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// foreach ((int, int) e in new (int, int)[10])
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(int, int)").WithArguments("System.ValueTuple`2").WithLocation(6, 18)
);
// no crash
}
[Fact]
public void DeconstructionMayBeEmbedded()
{
var source = @"
class C1
{
void M()
{
if (true)
var (x, y) = (1, 2);
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// this is no longer considered a declaration statement,
// but rather is an assignment expression. So no error.
);
}
[Fact]
public void AssignmentExpressionCanBeUsedInEmbeddedStatement()
{
var source = @"
class C1
{
void M()
{
int x, y;
if (true)
(x, y) = (1, 2);
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics();
}
[Fact]
public void DeconstructObsoleteWarning()
{
var source = @"
class C
{
void M()
{
(int y1, int y2) = new C();
}
[System.Obsolete()]
void Deconstruct(out int x1, out int x2) { x1 = 1; x2 = 2; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,27): warning CS0612: 'C.Deconstruct(out int, out int)' is obsolete
// (int y1, int y2) = new C();
Diagnostic(ErrorCode.WRN_DeprecatedSymbol, "new C()").WithArguments("C.Deconstruct(out int, out int)").WithLocation(6, 27)
);
}
[Fact]
public void DeconstructObsoleteError()
{
var source = @"
class C
{
void M()
{
(int y1, int y2) = new C();
}
[System.Obsolete(""Deprecated"", error: true)]
void Deconstruct(out int x1, out int x2) { x1 = 1; x2 = 2; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,27): error CS0619: 'C.Deconstruct(out int, out int)' is obsolete: 'Deprecated'
// (int y1, int y2) = new C();
Diagnostic(ErrorCode.ERR_DeprecatedSymbolStr, "new C()").WithArguments("C.Deconstruct(out int, out int)", "Deprecated").WithLocation(6, 27)
);
}
[Fact]
public void DeconstructionLocalsDeclaredNotUsed()
{
// Check that there are no *use sites* within this code for local variables.
// They are not declared. So they should not be returned
// by SemanticModel.GetSymbolInfo. Similarly, check that all designation syntax
// forms declare deconstruction locals.
string source = @"
class Program
{
static void Main()
{
var (x1, y1) = (1, 2);
(var x2, var y2) = (1, 2);
}
static void M((int, int) t)
{
var (x3, y3) = t;
(var x4, var y4) = t;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics();
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree, ignoreAccessibility: false);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
foreach (var node in nodes)
{
var si = model.GetSymbolInfo(node);
var symbol = si.Symbol;
if ((object)symbol != null)
{
if (node is DeclarationExpressionSyntax)
{
Assert.Equal(SymbolKind.Local, symbol.Kind);
Assert.Equal(LocalDeclarationKind.DeconstructionVariable, symbol.GetSymbol<LocalSymbol>().DeclarationKind);
}
else
{
Assert.NotEqual(SymbolKind.Local, symbol.Kind);
}
}
symbol = model.GetDeclaredSymbol(node);
if ((object)symbol != null)
{
if (node is SingleVariableDesignationSyntax)
{
Assert.Equal(SymbolKind.Local, symbol.Kind);
Assert.Equal(LocalDeclarationKind.DeconstructionVariable, symbol.GetSymbol<LocalSymbol>().DeclarationKind);
}
else
{
Assert.NotEqual(SymbolKind.Local, symbol.Kind);
}
}
}
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact, WorkItem(14287, "https://github.com/dotnet/roslyn/issues/14287")]
public void TupleDeconstructionStatementWithTypesCannotBeConst()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/const (int x, int y) = (1, 2);/*</bind>*/
}
}
";
string expectedOperationTree = @"
IVariableDeclarationGroupOperation (1 declarations) (OperationKind.VariableDeclarationGroup, Type: null, IsInvalid) (Syntax: 'const (int ... ) = (1, 2);')
IVariableDeclarationOperation (1 declarators) (OperationKind.VariableDeclaration, Type: null, IsInvalid) (Syntax: '(int x, int y) = (1, 2)')
Declarators:
IVariableDeclaratorOperation (Symbol: (System.Int32 x, System.Int32 y) ) (OperationKind.VariableDeclarator, Type: null, IsInvalid) (Syntax: '= (1, 2)')
Initializer:
IVariableInitializerOperation (OperationKind.VariableInitializer, Type: null, IsInvalid) (Syntax: '= (1, 2)')
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32 x, System.Int32 y), IsImplicit) (Syntax: '(1, 2)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1001: Identifier expected
// const /*<bind>*/(int x, int y) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_IdentifierExpected, "=").WithLocation(6, 40),
// CS0283: The type '(int x, int y)' cannot be declared const
// const /*<bind>*/(int x, int y) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadConstType, "(int x, int y)").WithArguments("(int x, int y)").WithLocation(6, 25)
};
VerifyOperationTreeAndDiagnosticsForTest<LocalDeclarationStatementSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact, WorkItem(14287, "https://github.com/dotnet/roslyn/issues/14287")]
public void TupleDeconstructionStatementWithoutTypesCannotBeConst()
{
string source = @"
class C
{
static void Main()
{
const var (x, y) = (1, 2);
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,9): error CS0106: The modifier 'const' is not valid for this item
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_BadMemberFlag, "const").WithArguments("const").WithLocation(6, 9),
// (6,19): error CS1001: Identifier expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_IdentifierExpected, "(").WithLocation(6, 19),
// (6,21): error CS1001: Identifier expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_IdentifierExpected, ",").WithLocation(6, 21),
// (6,24): error CS1001: Identifier expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_IdentifierExpected, ")").WithLocation(6, 24),
// (6,26): error CS1002: ; expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_SemicolonExpected, "=").WithLocation(6, 26),
// (6,26): error CS1525: Invalid expression term '='
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "=").WithArguments("=").WithLocation(6, 26),
// (6,19): error CS8112: '(x, y)' is a local function and must therefore always have a body.
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_LocalFunctionMissingBody, "").WithArguments("(x, y)").WithLocation(6, 19),
// (6,20): error CS0246: The type or namespace name 'x' could not be found (are you missing a using directive or an assembly reference?)
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "x").WithArguments("x").WithLocation(6, 20),
// (6,23): error CS0246: The type or namespace name 'y' could not be found (are you missing a using directive or an assembly reference?)
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "y").WithArguments("y").WithLocation(6, 23),
// (6,15): error CS0825: The contextual keyword 'var' may only appear within a local variable declaration or in script code
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_TypeVarNotFound, "var").WithLocation(6, 15)
);
}
[Fact, WorkItem(15934, "https://github.com/dotnet/roslyn/issues/15934")]
public void PointerTypeInDeconstruction()
{
string source = @"
unsafe class C
{
static void Main(C c)
{
(int* x1, int y1) = c;
(var* x2, int y2) = c;
(int*[] x3, int y3) = c;
(var*[] x4, int y4) = c;
}
public void Deconstruct(out dynamic x, out dynamic y)
{
x = y = null;
}
}
";
var comp = CreateCompilationWithMscorlib40AndSystemCore(source,
references: new[] { ValueTupleRef, SystemRuntimeFacadeRef },
options: TestOptions.UnsafeDebugDll,
parseOptions: TestOptions.RegularPreview);
// The precise diagnostics here are not important, and may be sensitive to parser
// adjustments. This is a test that we don't crash. The errors here are likely to
// change as we adjust the parser and semantic analysis of error cases.
comp.VerifyDiagnostics(
// (6,10): error CS1525: Invalid expression term 'int'
// (int* x1, int y1) = c;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "int").WithArguments("int").WithLocation(6, 10),
// (6,15): error CS0103: The name 'x1' does not exist in the current context
// (int* x1, int y1) = c;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 15),
// (6,19): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (int* x1, int y1) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y1").WithArguments("dynamic", "int").WithLocation(6, 19),
// (7,10): error CS0103: The name 'var' does not exist in the current context
// (var* x2, int y2) = c;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 10),
// (7,15): error CS0103: The name 'x2' does not exist in the current context
// (var* x2, int y2) = c;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x2").WithArguments("x2").WithLocation(7, 15),
// (7,19): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (var* x2, int y2) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y2").WithArguments("dynamic", "int").WithLocation(7, 19),
// (8,10): error CS0266: Cannot implicitly convert type 'dynamic' to 'int*[]'. An explicit conversion exists (are you missing a cast?)
// (int*[] x3, int y3) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int*[] x3").WithArguments("dynamic", "int*[]").WithLocation(8, 10),
// (8,21): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (int*[] x3, int y3) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y3").WithArguments("dynamic", "int").WithLocation(8, 21),
// (9,10): error CS0825: The contextual keyword 'var' may only appear within a local variable declaration or in script code
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_TypeVarNotFound, "var").WithLocation(9, 10),
// (9,10): error CS0208: Cannot take the address of, get the size of, or declare a pointer to a managed type ('var')
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_ManagedAddr, "var*").WithArguments("var").WithLocation(9, 10),
// (9,10): error CS0266: Cannot implicitly convert type 'dynamic' to 'var*[]'. An explicit conversion exists (are you missing a cast?)
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "var*[] x4").WithArguments("dynamic", "var*[]").WithLocation(9, 10),
// (9,21): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y4").WithArguments("dynamic", "int").WithLocation(9, 21)
);
}
[Fact]
public void DeclarationInsideNameof()
{
string source = @"
class Program
{
static void Main()
{
string s = nameof((int x1, var x2) = (1, 2)).ToString();
string s1 = x1, s2 = x2;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,28): error CS8185: A declaration is not allowed in this context.
// string s = nameof((int x1, var x2) = (1, 2)).ToString();
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int x1").WithLocation(6, 28),
// (6,27): error CS8081: Expression does not have a name.
// string s = nameof((int x1, var x2) = (1, 2)).ToString();
Diagnostic(ErrorCode.ERR_ExpressionHasNoName, "(int x1, var x2) = (1, 2)").WithLocation(6, 27),
// (7,21): error CS0029: Cannot implicitly convert type 'int' to 'string'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "x1").WithArguments("int", "string").WithLocation(7, 21),
// (7,30): error CS0029: Cannot implicitly convert type 'int' to 'string'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "x2").WithArguments("int", "string").WithLocation(7, 30),
// (7,21): error CS0165: Use of unassigned local variable 'x1'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x1").WithArguments("x1").WithLocation(7, 21),
// (7,30): error CS0165: Use of unassigned local variable 'x2'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x2").WithArguments("x2").WithLocation(7, 30)
);
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(2, designations.Count());
var refs = tree.GetCompilationUnitRoot().DescendantNodes().OfType<IdentifierNameSyntax>();
var x1 = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("x1", x1.Name);
Assert.Equal("System.Int32", ((ILocalSymbol)x1).Type.ToTestDisplayString());
Assert.Same(x1, model.GetSymbolInfo(refs.Where(r => r.Identifier.ValueText == "x1").Single()).Symbol);
var x2 = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("x2", x2.Name);
Assert.Equal("System.Int32", ((ILocalSymbol)x2).Type.ToTestDisplayString());
Assert.Same(x2, model.GetSymbolInfo(refs.Where(r => r.Identifier.ValueText == "x2").Single()).Symbol);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_01()
{
string source1 = @"
class C
{
static void Main()
{
(var (a,b), var c, int d);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)"),
// (6,21): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c"),
// (6,28): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(6, 28),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (a,b), var c, int d)").WithLocation(6, 9),
// (6,28): error CS0165: Use of unassigned local variable 'd'
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_UseDefViolation, "int d").WithArguments("d").WithLocation(6, 28)
);
StandAlone_01_VerifySemanticModel(comp1, LocalDeclarationKind.DeclarationExpressionVariable);
string source2 = @"
class C
{
static void Main()
{
(var (a,b), var c, int d) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_01_VerifySemanticModel(comp2, LocalDeclarationKind.DeconstructionVariable);
}
private static void StandAlone_01_VerifySemanticModel(CSharpCompilation comp, LocalDeclarationKind localDeclarationKind)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var a", a.ToTestDisplayString());
Assert.Equal(localDeclarationKind, a.GetSymbol<LocalSymbol>().DeclarationKind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var b", b.ToTestDisplayString());
Assert.Equal(localDeclarationKind, b.GetSymbol<LocalSymbol>().DeclarationKind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var c", c.ToTestDisplayString());
Assert.Equal(localDeclarationKind, c.GetSymbol<LocalSymbol>().DeclarationKind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 d", d.ToTestDisplayString());
Assert.Equal(localDeclarationKind, d.GetSymbol<LocalSymbol>().DeclarationKind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("((var a, var b), var c, System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_02()
{
string source1 = @"
(var (a,b), var c, int d);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,7): error CS7019: Type of 'a' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "a").WithArguments("a"),
// (2,9): error CS7019: Type of 'b' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "b").WithArguments("b"),
// (2,17): error CS7019: Type of 'c' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "c").WithArguments("c"),
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)"),
// (2,13): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c"),
// (2,20): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(2, 20),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (a,b), var c, int d)").WithLocation(2, 1)
);
StandAlone_02_VerifySemanticModel(comp1);
string source2 = @"
(var (a,b), var c, int d) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_02_VerifySemanticModel(comp2);
}
private static void StandAlone_02_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var Script.a", a.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, a.Kind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var Script.b", b.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, b.Kind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var Script.c", c.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, c.Kind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 Script.d", d.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, d.Kind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var Script.c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 Script.d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("((var a, var b), var c, System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_03()
{
string source1 = @"
class C
{
static void Main()
{
(var (_, _), var _, int _);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)"),
// (6,22): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _"),
// (6,29): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(6, 29),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (_, _), var _, int _)").WithLocation(6, 9)
);
StandAlone_03_VerifySemanticModel(comp1);
string source2 = @"
class C
{
static void Main()
{
(var (_, _), var _, int _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_03_VerifySemanticModel(comp2);
}
private static void StandAlone_03_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
int count = 0;
foreach (var designation in tree.GetCompilationUnitRoot().DescendantNodes().OfType<DiscardDesignationSyntax>())
{
Assert.Null(model.GetDeclaredSymbol(designation));
count++;
}
Assert.Equal(4, count);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (_, _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var, var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int _", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("((var, var), var, System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_04()
{
string source1 = @"
(var (_, _), var _, int _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)"),
// (2,14): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _"),
// (2,21): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(2, 21),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (_, _), var _, int _)").WithLocation(2, 1)
);
StandAlone_03_VerifySemanticModel(comp1);
string source2 = @"
(var (_, _), var _, int _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_03_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_05()
{
string source1 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (a,b), var c);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_05_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (a,b), var c) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_05_VerifySemanticModel(comp2);
}
private static void StandAlone_05_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(System.Int32 a, System.Int32 b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[0].Type).ToTestDisplayString());
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[1].Type).ToTestDisplayString());
}
[Fact]
[WorkItem(23651, "https://github.com/dotnet/roslyn/issues/23651")]
public void StandAlone_05_WithDuplicateNames()
{
string source1 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (a, a), var c);
}
}
";
var comp1 = CreateCompilation(source1);
var tree = comp1.SyntaxTrees.Single();
var model = comp1.GetSemanticModel(tree);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
var aa = nodes.OfType<DeclarationExpressionSyntax>().ElementAt(0);
Assert.Equal("var (a, a)", aa.ToString());
var aaType = model.GetTypeInfo(aa).Type.GetSymbol();
Assert.True(aaType.TupleElementNames.IsDefault);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_06()
{
string source1 = @"
using var = System.Int32;
(var (a,b), var c);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_06_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
(var (a,b), var c) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_06_VerifySemanticModel(comp2);
}
private static void StandAlone_06_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(System.Int32 a, System.Int32 b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[0].Type).ToTestDisplayString());
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 Script.c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[1].Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_07()
{
string source1 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (_, _), var _);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_07_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (_, _), var _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_07_VerifySemanticModel(comp2);
}
private static void StandAlone_07_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var (_, _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(System.Int32, System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[0].Type).ToTestDisplayString());
Assert.Equal("var _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[1].Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_08()
{
string source1 = @"
using var = System.Int32;
(var (_, _), var _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_07_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
(var (_, _), var _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_07_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_09()
{
string source1 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (a,b), al c);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_09_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (a,b), al c) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_09_VerifySemanticModel(comp2);
}
private static void StandAlone_09_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declaration = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Single();
Assert.Equal("al c", declaration.ToString());
var typeInfo = model.GetTypeInfo(declaration);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration).IsIdentity);
Assert.Equal("System.Int32 c", model.GetSymbolInfo(declaration).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declaration.Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration.Type).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declaration.Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("al=System.Int32", model.GetAliasInfo(declaration.Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_10()
{
string source1 = @"
using al = System.Int32;
(al (a,b), al c);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_10_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
(al (a,b), al c) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_10_VerifySemanticModel(comp2);
}
private static void StandAlone_10_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declaration = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Single();
Assert.Equal("al c", declaration.ToString());
var typeInfo = model.GetTypeInfo(declaration);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration).IsIdentity);
Assert.Equal("System.Int32 Script.c", model.GetSymbolInfo(declaration).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declaration.Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration.Type).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declaration.Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("al=System.Int32", model.GetAliasInfo(declaration.Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_11()
{
string source1 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (_, _), al _);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_11_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (_, _), al _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_11_VerifySemanticModel(comp2);
}
private static void StandAlone_11_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declaration = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Single();
Assert.Equal("al _", declaration.ToString());
var typeInfo = model.GetTypeInfo(declaration);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declaration);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declaration.Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration.Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declaration.Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("al=System.Int32", model.GetAliasInfo(declaration.Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_12()
{
string source1 = @"
using al = System.Int32;
(al (_, _), al _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_11_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
(al (_, _), al _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_11_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_13()
{
string source1 = @"
class C
{
static void Main()
{
var (a, b);
var (c, d)
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (7,19): error CS1002: ; expected
// var (c, d)
Diagnostic(ErrorCode.ERR_SemicolonExpected, "").WithLocation(7, 19),
// (6,9): error CS0103: The name 'var' does not exist in the current context
// var (a, b);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(6, 9),
// (6,14): error CS0103: The name 'a' does not exist in the current context
// var (a, b);
Diagnostic(ErrorCode.ERR_NameNotInContext, "a").WithArguments("a").WithLocation(6, 14),
// (6,17): error CS0103: The name 'b' does not exist in the current context
// var (a, b);
Diagnostic(ErrorCode.ERR_NameNotInContext, "b").WithArguments("b").WithLocation(6, 17),
// (7,9): error CS0103: The name 'var' does not exist in the current context
// var (c, d)
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 9),
// (7,14): error CS0103: The name 'c' does not exist in the current context
// var (c, d)
Diagnostic(ErrorCode.ERR_NameNotInContext, "c").WithArguments("c").WithLocation(7, 14),
// (7,17): error CS0103: The name 'd' does not exist in the current context
// var (c, d)
Diagnostic(ErrorCode.ERR_NameNotInContext, "d").WithArguments("d").WithLocation(7, 17)
);
var tree = comp1.SyntaxTrees.First();
Assert.False(tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_14()
{
string source1 = @"
class C
{
static void Main()
{
((var (a,b), var c), int d);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,11): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)").WithLocation(6, 11),
// (6,22): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c").WithLocation(6, 22),
// (6,30): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(6, 30),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (a,b), var c), int d)").WithLocation(6, 9),
// (6,30): error CS0165: Use of unassigned local variable 'd'
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_UseDefViolation, "int d").WithArguments("d").WithLocation(6, 30)
);
StandAlone_14_VerifySemanticModel(comp1, LocalDeclarationKind.DeclarationExpressionVariable);
string source2 = @"
class C
{
static void Main()
{
((var (a,b), var c), int d) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_14_VerifySemanticModel(comp2, LocalDeclarationKind.DeconstructionVariable);
}
private static void StandAlone_14_VerifySemanticModel(CSharpCompilation comp, LocalDeclarationKind localDeclarationKind)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var a", a.ToTestDisplayString());
Assert.Equal(localDeclarationKind, a.GetSymbol<LocalSymbol>().DeclarationKind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var b", b.ToTestDisplayString());
Assert.Equal(localDeclarationKind, b.GetSymbol<LocalSymbol>().DeclarationKind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var c", c.ToTestDisplayString());
Assert.Equal(localDeclarationKind, c.GetSymbol<LocalSymbol>().DeclarationKind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 d", d.ToTestDisplayString());
Assert.Equal(localDeclarationKind, d.GetSymbol<LocalSymbol>().DeclarationKind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuples = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().ToArray();
Assert.Equal(2, tuples.Length);
Assert.Equal("((var (a,b), var c), int d)", tuples[0].ToString());
typeInfo = model.GetTypeInfo(tuples[0]);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[0]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("(var (a,b), var c)", tuples[1].ToString());
typeInfo = model.GetTypeInfo(tuples[1]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_15()
{
string source1 = @"
((var (a,b), var c), int d);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,8): error CS7019: Type of 'a' cannot be inferred since its initializer directly or indirectly refers to the definition.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "a").WithArguments("a").WithLocation(2, 8),
// (2,10): error CS7019: Type of 'b' cannot be inferred since its initializer directly or indirectly refers to the definition.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "b").WithArguments("b").WithLocation(2, 10),
// (2,18): error CS7019: Type of 'c' cannot be inferred since its initializer directly or indirectly refers to the definition.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "c").WithArguments("c").WithLocation(2, 18),
// (2,3): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)").WithLocation(2, 3),
// (2,14): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c").WithLocation(2, 14),
// (2,22): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(2, 22),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (a,b), var c), int d)").WithLocation(2, 1)
);
StandAlone_15_VerifySemanticModel(comp1);
string source2 = @"
((var (a,b), var c), int d) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_15_VerifySemanticModel(comp2);
}
private static void StandAlone_15_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var Script.a", a.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, a.Kind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var Script.b", b.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, b.Kind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var Script.c", c.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, c.Kind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 Script.d", d.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, d.Kind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var Script.c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 Script.d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuples = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().ToArray();
Assert.Equal(2, tuples.Length);
Assert.Equal("((var (a,b), var c), int d)", tuples[0].ToString());
typeInfo = model.GetTypeInfo(tuples[0]);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[0]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("(var (a,b), var c)", tuples[1].ToString());
typeInfo = model.GetTypeInfo(tuples[1]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_16()
{
string source1 = @"
class C
{
static void Main()
{
((var (_, _), var _), int _);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,11): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)").WithLocation(6, 11),
// (6,23): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _").WithLocation(6, 23),
// (6,31): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(6, 31),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (_, _), var _), int _)").WithLocation(6, 9)
);
StandAlone_16_VerifySemanticModel(comp1);
string source2 = @"
class C
{
static void Main()
{
((var (_, _), var _), int _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_16_VerifySemanticModel(comp2);
}
private static void StandAlone_16_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
int count = 0;
foreach (var designation in tree.GetCompilationUnitRoot().DescendantNodes().OfType<DiscardDesignationSyntax>())
{
Assert.Null(model.GetDeclaredSymbol(designation));
count++;
}
Assert.Equal(4, count);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (_, _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var, var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int _", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuples = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().ToArray();
Assert.Equal(2, tuples.Length);
Assert.Equal("((var (_, _), var _), int _)", tuples[0].ToString());
typeInfo = model.GetTypeInfo(tuples[0]);
Assert.Equal("(((var, var), var), System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[0]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("(var (_, _), var _)", tuples[1].ToString());
typeInfo = model.GetTypeInfo(tuples[1]);
Assert.Equal("((var, var), var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_17()
{
string source1 = @"
((var (_, _), var _), int _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,3): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)").WithLocation(2, 3),
// (2,15): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _").WithLocation(2, 15),
// (2,23): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(2, 23),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (_, _), var _), int _)").WithLocation(2, 1)
);
StandAlone_16_VerifySemanticModel(comp1);
string source2 = @"
((var (_, _), var _), int _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_16_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_18()
{
string source1 = @"
class C
{
static void Main()
{
(var ((a,b), c), int d);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((a,b), c)").WithLocation(6, 10),
// (6,26): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(6, 26),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((a,b), c), int d)").WithLocation(6, 9),
// (6,26): error CS0165: Use of unassigned local variable 'd'
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_UseDefViolation, "int d").WithArguments("d").WithLocation(6, 26)
);
StandAlone_18_VerifySemanticModel(comp1, LocalDeclarationKind.DeclarationExpressionVariable);
string source2 = @"
class C
{
static void Main()
{
(var ((a,b), c), int d) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_18_VerifySemanticModel(comp2, LocalDeclarationKind.DeconstructionVariable);
}
private static void StandAlone_18_VerifySemanticModel(CSharpCompilation comp, LocalDeclarationKind localDeclarationKind)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var a", a.ToTestDisplayString());
Assert.Equal(localDeclarationKind, a.GetSymbol<LocalSymbol>().DeclarationKind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var b", b.ToTestDisplayString());
Assert.Equal(localDeclarationKind, b.GetSymbol<LocalSymbol>().DeclarationKind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var c", c.ToTestDisplayString());
Assert.Equal(localDeclarationKind, c.GetSymbol<LocalSymbol>().DeclarationKind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 d", d.ToTestDisplayString());
Assert.Equal(localDeclarationKind, d.GetSymbol<LocalSymbol>().DeclarationKind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var ((a,b), c)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("int d", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 d", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[1].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_19()
{
string source1 = @"
(var ((a,b), c), int d);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,8): error CS7019: Type of 'a' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "a").WithArguments("a").WithLocation(2, 8),
// (2,10): error CS7019: Type of 'b' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "b").WithArguments("b").WithLocation(2, 10),
// (2,14): error CS7019: Type of 'c' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "c").WithArguments("c").WithLocation(2, 14),
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((a,b), c)").WithLocation(2, 2),
// (2,18): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(2, 18),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((a,b), c), int d)").WithLocation(2, 1)
);
StandAlone_19_VerifySemanticModel(comp1);
string source2 = @"
(var ((a,b), c), int d) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_19_VerifySemanticModel(comp2);
}
private static void StandAlone_19_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var Script.a", a.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, a.Kind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var Script.b", b.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, b.Kind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var Script.c", c.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, c.Kind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 Script.d", d.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, d.Kind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var ((a,b), c)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("int d", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 Script.d", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[1].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_20()
{
string source1 = @"
class C
{
static void Main()
{
(var ((_, _), _), int _);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((_, _), _)").WithLocation(6, 10),
// (6,27): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(6, 27),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((_, _), _), int _)").WithLocation(6, 9)
);
StandAlone_20_VerifySemanticModel(comp1);
string source2 = @"
class C
{
static void Main()
{
(var ((_, _), _), int _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_20_VerifySemanticModel(comp2);
}
private static void StandAlone_20_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
int count = 0;
foreach (var designation in tree.GetCompilationUnitRoot().DescendantNodes().OfType<DiscardDesignationSyntax>())
{
Assert.Null(model.GetDeclaredSymbol(designation));
count++;
}
Assert.Equal(4, count);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var ((_, _), _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("((var, var), var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("int _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[1].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("(((var, var), var), System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_21()
{
string source1 = @"
(var ((_, _), _), int _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((_, _), _)").WithLocation(2, 2),
// (2,19): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(2, 19),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((_, _), _), int _)").WithLocation(2, 1)
);
StandAlone_20_VerifySemanticModel(comp1);
string source2 = @"
(var ((_, _), _), int _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_20_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DiscardVoid_01()
{
var source = @"class C
{
static void Main()
{
(_, _) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,22): error CS8210: A tuple may not contain a value of type 'void'.
// (_, _) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 22)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_01()
{
var source = @"class C
{
static void Main()
{
(int x, void y) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,17): error CS1547: Keyword 'void' cannot be used in this context
// (int x, void y) = (1, Main());
Diagnostic(ErrorCode.ERR_NoVoidHere, "void").WithLocation(5, 17),
// (5,31): error CS8210: A tuple may not contain a value of type 'void'.
// (int x, void y) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 31)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_02()
{
var source = @"class C
{
static void Main()
{
var (x, y) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,26): error CS8210: A tuple may not contain a value of type 'void'.
// var (x, y) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 26)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_03()
{
var source = @"class C
{
static void Main()
{
(int x, void y) = (1, 2);
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,17): error CS1547: Keyword 'void' cannot be used in this context
// (int x, void y) = (1, 2);
Diagnostic(ErrorCode.ERR_NoVoidHere, "void").WithLocation(5, 17),
// (5,31): error CS0029: Cannot implicitly convert type 'int' to 'void'
// (int x, void y) = (1, 2);
Diagnostic(ErrorCode.ERR_NoImplicitConv, "2").WithArguments("int", "void").WithLocation(5, 31)
);
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var two = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "2").Single();
var type = model.GetTypeInfo(two);
Assert.Equal(SpecialType.System_Int32, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Int32, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(two).Kind);
var symbols = model.GetSymbolInfo(two);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)two.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_04()
{
var source = @"class C
{
static void Main()
{
(int x, int y) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,30): error CS8210: A tuple may not contain a value of type 'void'.
// (int x, int y) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 30)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DiscardDeclarationExpression_IOperation()
{
string source = @"
class C
{
void M()
{
/*<bind>*/var (_, _) = (0, 0)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32)) (Syntax: 'var (_, _) = (0, 0)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32, System.Int32)) (Syntax: 'var (_, _)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(_, _)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: '_')
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: '_')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(0, 0)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DiscardDeclarationAssignment_IOperation()
{
string source = @"
class C
{
void M()
{
int x;
/*<bind>*/(x, _) = (0, 0)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32)) (Syntax: '(x, _) = (0, 0)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32)) (Syntax: '(x, _)')
NaturalType: (System.Int32 x, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: '_')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(0, 0)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DiscardOutVarDeclaration_IOperation()
{
string source = @"
class C
{
void M()
{
M2(out /*<bind>*/var _/*</bind>*/);
}
void M2(out int x)
{
x = 0;
}
}
";
string expectedOperationTree = @"
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: 'var _')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<DeclarationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_1()
{
var text = @"
class C
{
static void Main()
{
foreach ((var i, i))
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,18): error CS8186: A foreach loop must declare its iteration variables.
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_MustDeclareForeachIteration, "(var i, i)").WithLocation(6, 18),
// (6,23): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'i'.
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "i").WithArguments("i").WithLocation(6, 23),
// (6,26): error CS0841: Cannot use local variable 'i' before it is declared
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "i").WithArguments("i").WithLocation(6, 26),
// (6,28): error CS1515: 'in' expected
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_InExpected, ")").WithLocation(6, 28),
// (6,28): error CS1525: Invalid expression term ')'
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ")").WithArguments(")").WithLocation(6, 28),
// (6,29): error CS1525: Invalid expression term '}'
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "").WithArguments("}").WithLocation(6, 29),
// (6,29): error CS1002: ; expected
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_SemicolonExpected, "").WithLocation(6, 29)
);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_2()
{
var text = @"
class C
{
static void Main()
{
(var i, i) = ;
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,14): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'i'.
// (var i, i) = ;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "i").WithArguments("i").WithLocation(6, 14),
// (6,17): error CS0841: Cannot use local variable 'i' before it is declared
// (var i, i) = ;
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "i").WithArguments("i").WithLocation(6, 17),
// (6,22): error CS1525: Invalid expression term ';'
// (var i, i) = ;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ";").WithArguments(";").WithLocation(6, 22)
);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_3()
{
var text = @"
class C
{
static void Main()
{
foreach ((int i, i))
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,18): error CS8186: A foreach loop must declare its iteration variables.
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_MustDeclareForeachIteration, "(int i, i)").WithLocation(6, 18),
// (6,26): error CS1656: Cannot assign to 'i' because it is a 'foreach iteration variable'
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "i").WithArguments("i", "foreach iteration variable").WithLocation(6, 26),
// (6,28): error CS1515: 'in' expected
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_InExpected, ")").WithLocation(6, 28),
// (6,28): error CS1525: Invalid expression term ')'
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ")").WithArguments(")").WithLocation(6, 28),
// (6,29): error CS1525: Invalid expression term '}'
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "").WithArguments("}").WithLocation(6, 29),
// (6,29): error CS1002: ; expected
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_SemicolonExpected, "").WithLocation(6, 29)
);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_4()
{
var text = @"
class C
{
static void Main()
{
(int i, i) = ;
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,22): error CS1525: Invalid expression term ';'
// (int i, i) = ;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ";").WithArguments(";").WithLocation(6, 22)
);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Linq;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Test.Utilities;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.CSharp.UnitTests.Semantics
{
[CompilerTrait(CompilerFeature.Tuples)]
public class DeconstructionTests : CompilingTestBase
{
private static readonly MetadataReference[] s_valueTupleRefs = new[] { SystemRuntimeFacadeRef, ValueTupleRef };
const string commonSource =
@"public class Pair<T1, T2>
{
T1 item1;
T2 item2;
public Pair(T1 item1, T2 item2)
{
this.item1 = item1;
this.item2 = item2;
}
public void Deconstruct(out T1 item1, out T2 item2)
{
System.Console.WriteLine($""Deconstructing {ToString()}"");
item1 = this.item1;
item2 = this.item2;
}
public override string ToString() { return $""({item1.ToString()}, {item2.ToString()})""; }
}
public static class Pair
{
public static Pair<T1, T2> Create<T1, T2>(T1 item1, T2 item2) { return new Pair<T1, T2>(item1, item2); }
}
public class Integer
{
public int state;
public override string ToString() { return state.ToString(); }
public Integer(int i) { state = i; }
public static implicit operator LongInteger(Integer i) { System.Console.WriteLine($""Converting {i}""); return new LongInteger(i.state); }
}
public class LongInteger
{
long state;
public LongInteger(long l) { state = l; }
public override string ToString() { return state.ToString(); }
}";
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodMissing()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'C' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'C' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "new C()").WithArguments("C", "Deconstruct").WithLocation(8, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWrongParams()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a) // too few arguments
{
a = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1501: No overload for method 'Deconstruct' takes 2 arguments
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgCount, "new C()").WithArguments("Deconstruct", "2").WithLocation(8, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWrongParams2()
{
string source = @"
class C
{
static void Main()
{
long x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a, out int b, out int c) // too many arguments
{
a = b = c = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.Int64 y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.Int64 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS7036: There is no argument given that corresponds to the required formal parameter 'c' of 'C.Deconstruct(out int, out int, out int)'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoCorrespondingArgument, "new C()").WithArguments("c", "C.Deconstruct(out int, out int, out int)").WithLocation(7, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignmentWithLeftHandSideErrors()
{
string source = @"
class C
{
static void Main()
{
long x = 1;
string y = ""hello"";
/*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
}
public void Deconstruct() { }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x.f, y.g) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (? f, ? g), IsInvalid) (Syntax: '(x.f, y.g)')
NaturalType: (? f, ? g)
Elements(2):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x.f')
Children(1):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'y.g')
Children(1):
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'long' does not contain a definition for 'f' and no extension method 'f' accepting a first argument of type 'long' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "f").WithArguments("long", "f").WithLocation(8, 22),
// CS1061: 'string' does not contain a definition for 'g' and no extension method 'g' accepting a first argument of type 'string' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "g").WithArguments("string", "g").WithLocation(8, 27),
// CS1501: No overload for method 'Deconstruct' takes 2 arguments
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgCount, "new C()").WithArguments("Deconstruct", "2").WithLocation(8, 32),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x.f, y.g) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 32)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWithInParam()
{
string source = @"
class C
{
static void Main()
{
int x;
int y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int x, int y) { x = 1; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1615: Argument 2 may not be passed with the 'out' keyword
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgExtraRef, "(x, y) = new C()").WithArguments("2", "out").WithLocation(8, 19),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructWithRefParam()
{
string source = @"
class C
{
static void Main()
{
int x;
int y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(ref int x, out int y) { x = 1; y = 2; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1620: Argument 1 must be passed with the 'ref' keyword
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadArgRef, "(x, y) = new C()").WithArguments("1", "ref").WithLocation(8, 19),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(8, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructManually()
{
string source = @"
struct C
{
static void Main()
{
long x;
string y;
C c = new C();
c.Deconstruct(out x, out y); // error
/*<bind>*/(x, y) = c/*</bind>*/;
}
void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y) = c')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
ILocalReferenceOperation: c (OperationKind.LocalReference, Type: C) (Syntax: 'c')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1503: Argument 1: cannot convert from 'out long' to 'out int'
// c.Deconstruct(out x, out y); // error
Diagnostic(ErrorCode.ERR_BadArgType, "x").WithArguments("1", "out long", "out int").WithLocation(10, 27)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodHasOptionalParam()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out string b, int c = 42) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void BadDeconstructShadowsBaseDeconstruct()
{
string source = @"
class D
{
public void Deconstruct(out int a, out string b) { a = 2; b = ""world""; }
}
class C : D
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out string b, int c = 42) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(13, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodHasParams()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out string b, params int[] c) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodHasArglist()
{
string source = @"
class C
{
static void Main()
{
long x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a, out string b, __arglist) // not a Deconstruct operator
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS7036: There is no argument given that corresponds to the required formal parameter '__arglist' of 'C.Deconstruct(out int, out string, __arglist)'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoCorrespondingArgument, "new C()").WithArguments("__arglist", "C.Deconstruct(out int, out string, __arglist)").WithLocation(9, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructDelegate()
{
string source = @"
delegate void D1(out int x, out int y);
class C
{
public D1 Deconstruct; // not a Deconstruct operator
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
}
public static void DeconstructMethod(out int a, out int b) { a = 1; b = 2; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = ne ... uctMethod }')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C() { D ... uctMethod }')
Arguments(0)
Initializer:
IObjectOrCollectionInitializerOperation (OperationKind.ObjectOrCollectionInitializer, Type: C, IsInvalid) (Syntax: '{ Deconstru ... uctMethod }')
Initializers(1):
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: D1, IsInvalid) (Syntax: 'Deconstruct ... tructMethod')
Left:
IFieldReferenceOperation: D1 C.Deconstruct (OperationKind.FieldReference, Type: D1, IsInvalid) (Syntax: 'Deconstruct')
Instance Receiver:
IInstanceReferenceOperation (ReferenceKind: ImplicitReceiver) (OperationKind.InstanceReference, Type: C, IsInvalid, IsImplicit) (Syntax: 'Deconstruct')
Right:
IDelegateCreationOperation (OperationKind.DelegateCreation, Type: D1, IsInvalid, IsImplicit) (Syntax: 'DeconstructMethod')
Target:
IMethodReferenceOperation: void C.DeconstructMethod(out System.Int32 a, out System.Int32 b) (Static) (OperationKind.MethodReference, Type: null, IsInvalid) (Syntax: 'DeconstructMethod')
Instance Receiver:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C() { Deconstruct = DeconstructMethod }").WithArguments("C", "2").WithLocation(11, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructDelegate2()
{
string source = @"
delegate void D1(out int x, out int y);
class C
{
public D1 Deconstruct;
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
}
public static void DeconstructMethod(out int a, out int b) { a = 1; b = 2; }
public void Deconstruct(out int a, out int b) { a = 1; b = 2; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32 y), IsInvalid) (Syntax: '(x, y) = ne ... uctMethod }')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C() { D ... uctMethod }')
Arguments(0)
Initializer:
IObjectOrCollectionInitializerOperation (OperationKind.ObjectOrCollectionInitializer, Type: C, IsInvalid) (Syntax: '{ Deconstru ... uctMethod }')
Initializers(1):
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: ?, IsInvalid) (Syntax: 'Deconstruct ... tructMethod')
Left:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid, IsImplicit) (Syntax: 'Deconstruct')
Children(1):
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'Deconstruct')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ImplicitReceiver) (OperationKind.InstanceReference, Type: C, IsImplicit) (Syntax: 'C')
Right:
IOperation: (OperationKind.None, Type: null) (Syntax: 'DeconstructMethod')
Children(1):
IInstanceReferenceOperation (ReferenceKind: ContainingTypeInstance) (OperationKind.InstanceReference, Type: C, IsImplicit) (Syntax: 'DeconstructMethod')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0102: The type 'C' already contains a definition for 'Deconstruct'
// public void Deconstruct(out int a, out int b) { a = 1; b = 2; }
Diagnostic(ErrorCode.ERR_DuplicateNameInClass, "Deconstruct").WithArguments("C", "Deconstruct").WithLocation(16, 17),
// CS1913: Member 'Deconstruct' cannot be initialized. It is not a field or property.
// /*<bind>*/(x, y) = new C() { Deconstruct = DeconstructMethod }/*</bind>*/;
Diagnostic(ErrorCode.ERR_MemberCannotBeInitialized, "Deconstruct").WithArguments("Deconstruct").WithLocation(11, 38),
// CS0649: Field 'C.Deconstruct' is never assigned to, and will always have its default value null
// public D1 Deconstruct;
Diagnostic(ErrorCode.WRN_UnassignedInternalField, "Deconstruct").WithArguments("C.Deconstruct", "null").WithLocation(6, 15)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructEvent()
{
string source = @"
delegate void D1(out int x, out int y);
class C
{
public event D1 Deconstruct; // not a Deconstruct operator
static void Main()
{
long x;
int y;
C c = new C();
c.Deconstruct += DeconstructMethod;
/*<bind>*/(x, y) = c/*</bind>*/;
}
public static void DeconstructMethod(out int a, out int b)
{
a = 1;
b = 2;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = c')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
ILocalReferenceOperation: c (OperationKind.LocalReference, Type: C, IsInvalid) (Syntax: 'c')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = c/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "c").WithArguments("C", "2").WithLocation(14, 28),
// CS0067: The event 'C.Deconstruct' is never used
// public event D1 Deconstruct; // not a Deconstruct operator
Diagnostic(ErrorCode.WRN_UnreferencedEvent, "Deconstruct").WithArguments("C.Deconstruct").WithLocation(6, 21)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ConversionErrors()
{
string source = @"
class C
{
static void Main()
{
byte x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Byte x, System.String y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (System.Byte x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Byte, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0266: Cannot implicitly convert type 'int' to 'byte'. An explicit conversion exists (are you missing a cast?)
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "x").WithArguments("int", "byte").WithLocation(8, 20),
// CS0029: Cannot implicitly convert type 'int' to 'string'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "y").WithArguments("int", "string").WithLocation(8, 23)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void ExpressionType()
{
string source = @"
class C
{
static void Main()
{
int x, y;
var type = ((x, y) = new C()).GetType();
System.Console.Write(type.ToString());
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
var comp = CreateCompilation(source, options: TestOptions.DebugExe);
comp.VerifyDiagnostics();
CompileAndVerify(comp, expectedOutput: "System.ValueTuple`2[System.Int32,System.Int32]");
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ExpressionType_IOperation()
{
string source = @"
class C
{
static void Main()
{
int x, y;
var type = (/*<bind>*/(x, y) = new C()/*</bind>*/).GetType();
System.Console.Write(type.ToString());
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void LambdaStillNotValidStatement()
{
string source = @"
class C
{
static void Main()
{
(a) => a;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (a) => a;
Diagnostic(ErrorCode.ERR_IllegalStatement, "(a) => a").WithLocation(6, 9)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void LambdaWithBodyStillNotValidStatement()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(a, b) => { }/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IAnonymousFunctionOperation (Symbol: lambda expression) (OperationKind.AnonymousFunction, Type: null, IsInvalid) (Syntax: '(a, b) => { }')
IBlockOperation (0 statements) (OperationKind.Block, Type: null, IsInvalid) (Syntax: '{ }')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// /*<bind>*/(a, b) => { }/*</bind>*/;
Diagnostic(ErrorCode.ERR_IllegalStatement, "(a, b) => { }").WithLocation(6, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<ParenthesizedLambdaExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void CastButNotCast()
{
// int and string must be types, so (int, string) must be type and ((int, string)) a cast, but then .String() cannot follow a cast...
string source = @"
class C
{
static void Main()
{
/*<bind>*/((int, string)).ToString()/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IInvocationOperation (virtual System.String (System.Int32, System.String).ToString()) (OperationKind.Invocation, Type: System.String, IsInvalid) (Syntax: '((int, stri ... .ToString()')
Instance Receiver:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.String), IsInvalid) (Syntax: '(int, string)')
NaturalType: (System.Int32, System.String)
Elements(2):
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'int')
IOperation: (OperationKind.None, Type: null, IsInvalid) (Syntax: 'string')
Arguments(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1525: Invalid expression term 'int'
// /*<bind>*/((int, string)).ToString()/*</bind>*/;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "int").WithArguments("int").WithLocation(6, 21),
// CS1525: Invalid expression term 'string'
// /*<bind>*/((int, string)).ToString()/*</bind>*/;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "string").WithArguments("string").WithLocation(6, 26)
};
VerifyOperationTreeAndDiagnosticsForTest<InvocationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningMethod2()
{
string source = @"
class C
{
static int i;
static void Main()
{
(M(), M()) = new C();
System.Console.Write(i);
}
static ref int M()
{
System.Console.Write(""M "");
return ref i;
}
void Deconstruct(out int i, out int j)
{
i = 42;
j = 43;
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "M M 43");
comp.VerifyDiagnostics(
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningMethod2_IOperation()
{
string source = @"
class C
{
static int i;
static void Main()
{
/*<bind>*/(M(), M()) = new C()/*</bind>*/;
System.Console.Write(i);
}
static ref int M()
{
System.Console.Write(""M "");
return ref i;
}
void Deconstruct(out int i, out int j)
{
i = 42;
j = 43;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32)) (Syntax: '(M(), M()) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(M(), M())')
NaturalType: (System.Int32, System.Int32)
Elements(2):
IInvocationOperation (ref System.Int32 C.M()) (OperationKind.Invocation, Type: System.Int32) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
IInvocationOperation (ref System.Int32 C.M()) (OperationKind.Invocation, Type: System.Int32) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void UninitializedRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = x/*</bind>*/;
}
}
static class D
{
public static void Deconstruct(this int input, out int output, out int output2) { output = input; output2 = input; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(x, x) = x')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0165: Use of unassigned local variable 'x'
// /*<bind>*/(x, x) = x/*</bind>*/;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x").WithArguments("x").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NullRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = null/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(x, x) = null')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/(x, x) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ErrorRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = undeclared/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(x, x) = undeclared')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'undeclared')
Children(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0103: The name 'undeclared' does not exist in the current context
// /*<bind>*/(x, x) = undeclared/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "undeclared").WithArguments("undeclared").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void VoidRight()
{
string source = @"
class C
{
static void Main()
{
int x;
/*<bind>*/(x, x) = M()/*</bind>*/;
}
static void M() { }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, x) = M()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(x, x)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
Right:
IInvocationOperation (void C.M()) (OperationKind.Invocation, Type: System.Void, IsInvalid) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'void' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'void' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(x, x) = M()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "M()").WithArguments("void", "Deconstruct").WithLocation(7, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'void', with 2 out parameters and a void return type.
// /*<bind>*/(x, x) = M()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "M()").WithArguments("void", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssigningTupleWithNoConversion()
{
string source = @"
class C
{
static void Main()
{
byte x;
string y;
/*<bind>*/(x, y) = (1, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Byte x, System.String y), IsInvalid) (Syntax: '(x, y) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Byte x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Byte x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Byte) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Byte, System.String), IsInvalid, IsImplicit) (Syntax: '(1, 2)')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2, IsInvalid) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0029: Cannot implicitly convert type 'int' to 'string'
// /*<bind>*/(x, y) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "2").WithArguments("int", "string").WithLocation(9, 32)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NotAssignable()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(1, P) = (1, 2)/*</bind>*/;
}
static int P { get { return 1; } }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32 P), IsInvalid) (Syntax: '(1, P) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32 P), IsInvalid) (Syntax: '(1, P)')
NaturalType: (System.Int32, System.Int32 P)
Elements(2):
IInvalidOperation (OperationKind.Invalid, Type: System.Int32, IsInvalid, IsImplicit) (Syntax: '1')
Children(1):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1, IsInvalid) (Syntax: '1')
IInvalidOperation (OperationKind.Invalid, Type: System.Int32, IsInvalid, IsImplicit) (Syntax: 'P')
Children(1):
IPropertyReferenceOperation: System.Int32 C.P { get; } (Static) (OperationKind.PropertyReference, Type: System.Int32, IsInvalid) (Syntax: 'P')
Instance Receiver:
null
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0131: The left-hand side of an assignment must be a variable, property or indexer
// /*<bind>*/(1, P) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_AssgLvalueExpected, "1").WithLocation(6, 20),
// CS0200: Property or indexer 'C.P' cannot be assigned to -- it is read only
// /*<bind>*/(1, P) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_AssgReadonlyProp, "P").WithArguments("C.P").WithLocation(6, 23)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void TupleWithUseSiteError()
{
string source = @"
namespace System
{
public struct ValueTuple<T1, T2>
{
public T1 Item1;
public ValueTuple(T1 item1, T2 item2)
{
this.Item1 = item1;
}
}
}
class C
{
static void Main()
{
int x;
int y;
(x, y) = (1, 2);
System.Console.WriteLine($""{x} {y}"");
}
}
";
var comp = CreateCompilation(source, assemblyName: "comp", options: TestOptions.DebugExe);
comp.VerifyDiagnostics();
comp.VerifyEmitDiagnostics();
CompileAndVerify(comp, expectedOutput: "1 2");
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TupleWithUseSiteError_IOperation()
{
string source = @"
namespace System
{
struct ValueTuple<T1, T2>
{
public T1 Item1;
public ValueTuple(T1 item1, T2 item2)
{
this.Item1 = item1;
}
}
}
class C
{
static void Main()
{
int x;
int y;
/*<bind>*/(x, y) = (1, 2)/*</bind>*/;
System.Console.WriteLine($""{x} {y}"");
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignUsingAmbiguousDeconstruction()
{
string source = @"
class Base
{
public void Deconstruct(out int a, out int b) { a = 1; b = 2; }
public void Deconstruct(out long a, out long b) { a = 1; b = 2; }
}
class C : Base
{
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
System.Console.WriteLine(x + "" "" + y);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// file.cs(12,28): error CS0121: The call is ambiguous between the following methods or properties: 'Base.Deconstruct(out int, out int)' and 'Base.Deconstruct(out long, out long)'
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_AmbigCall, "new C()").WithArguments("Base.Deconstruct(out int, out int)", "Base.Deconstruct(out long, out long)").WithLocation(12, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructIsDynamicField()
{
string source = @"
class C
{
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public dynamic Deconstruct = null;
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructIsField()
{
string source = @"
class C
{
static void Main()
{
int x, y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public object Deconstruct = null;
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.Int32 y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1955: Non-invocable member 'C.Deconstruct' cannot be used like a method.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_NonInvocableMemberCalled, "new C()").WithArguments("C.Deconstruct").WithLocation(7, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void CannotDeconstructRefTuple22()
{
string template = @"
using System;
class C
{
static void Main()
{
int VARIABLES; // int x1, x2, ...
(VARIABLES) = CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)));
}
public static Tuple<T1, T2, T3, T4, T5, T6, T7, TRest> CreateLongRef<T1, T2, T3, T4, T5, T6, T7, TRest>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, TRest rest) =>
new Tuple<T1, T2, T3, T4, T5, T6, T7, TRest>(item1, item2, item3, item4, item5, item6, item7, rest);
}
";
var tuple = String.Join(", ", Enumerable.Range(1, 22).Select(n => n.ToString()));
var variables = String.Join(", ", Enumerable.Range(1, 22).Select(n => $"x{n}"));
var source = template.Replace("VARIABLES", variables).Replace("TUPLE", tuple);
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (8,113): error CS1501: No overload for method 'Deconstruct' takes 22 arguments
// (x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19, x20, x21, x22) = CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)));
Diagnostic(ErrorCode.ERR_BadArgCount, "CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)))").WithArguments("Deconstruct", "22").WithLocation(8, 113),
// (8,113): error CS8129: No Deconstruct instance or extension method was found for type 'Tuple<int, int, int, int, int, int, int, Tuple<int, int, int, int, int, int, int, Tuple<int, int, int, int, int, int, int, Tuple<int>>>>', with 22 out parameters.
// (x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19, x20, x21, x22) = CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)));
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "CreateLongRef(1, 2, 3, 4, 5, 6, 7, CreateLongRef(8, 9, 10, 11, 12, 13, 14, Tuple.Create(15, 16, 17, 18, 19, 20, 21, 22)))").WithArguments("System.Tuple<int, int, int, int, int, int, int, System.Tuple<int, int, int, int, int, int, int, System.Tuple<int, int, int, int, int, int, int, System.Tuple<int>>>>", "22").WithLocation(8, 113)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructUsingDynamicMethod()
{
string source = @"
class C
{
static void Main()
{
int x;
string y;
dynamic c = new C();
/*<bind>*/(x, y) = c/*</bind>*/;
}
public void Deconstruct(out int a, out string b) { a = 1; b = ""hello""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = c')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
ILocalReferenceOperation: c (OperationKind.LocalReference, Type: dynamic, IsInvalid) (Syntax: 'c')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8133: Cannot deconstruct dynamic objects.
// /*<bind>*/(x, y) = c/*</bind>*/;
Diagnostic(ErrorCode.ERR_CannotDeconstructDynamic, "c").WithLocation(10, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructMethodInaccessible()
{
string source = @"
class C
{
static void Main()
{
int x;
string y;
/*<bind>*/(x, y) = new C1()/*</bind>*/;
}
}
class C1
{
protected void Deconstruct(out int a, out string b) { a = 1; b = ""hello""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C1()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C1..ctor()) (OperationKind.ObjectCreation, Type: C1, IsInvalid) (Syntax: 'new C1()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0122: 'C1.Deconstruct(out int, out string)' is inaccessible due to its protection level
// /*<bind>*/(x, y) = new C1()/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadAccess, "new C1()").WithArguments("C1.Deconstruct(out int, out string)").WithLocation(9, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C1', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C1()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C1()").WithArguments("C1", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void DeconstructHasUseSiteError()
{
string libMissingSource = @"public class Missing { }";
string libSource = @"
public class C
{
public void Deconstruct(out Missing a, out Missing b) { a = new Missing(); b = new Missing(); }
}
";
string source = @"
class C1
{
static void Main()
{
object x, y;
(x, y) = new C();
}
}
";
var libMissingComp = CreateCompilation(new string[] { libMissingSource }, assemblyName: "libMissingComp").VerifyDiagnostics();
var libMissingRef = libMissingComp.EmitToImageReference();
var libComp = CreateCompilation(new string[] { libSource }, references: new[] { libMissingRef }, parseOptions: TestOptions.Regular).VerifyDiagnostics();
var libRef = libComp.EmitToImageReference();
var comp = CreateCompilation(new string[] { source }, references: new[] { libRef });
comp.VerifyDiagnostics(
// (7,18): error CS0012: The type 'Missing' is defined in an assembly that is not referenced. You must add a reference to assembly 'libMissingComp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'.
// (x, y) = new C();
Diagnostic(ErrorCode.ERR_NoTypeDef, "new C()").WithArguments("Missing", "libMissingComp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null").WithLocation(7, 18),
// (7,18): error CS8129: No Deconstruct instance or extension method was found for type 'C', with 2 out parameters.
// (x, y) = new C();
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(7, 18)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void StaticDeconstruct()
{
string source = @"
class C
{
static void Main()
{
int x;
string y;
/*<bind>*/(x, y) = new C()/*</bind>*/;
}
public static void Deconstruct(out int a, out string b) { a = 1; b = ""hello""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int32 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C, IsInvalid) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0176: Member 'C.Deconstruct(out int, out string)' cannot be accessed with an instance reference; qualify it with a type name instead
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_ObjectProhibited, "new C()").WithArguments("C.Deconstruct(out int, out string)").WithLocation(9, 28),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'C', with 2 out parameters and a void return type.
// /*<bind>*/(x, y) = new C()/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "new C()").WithArguments("C", "2").WithLocation(9, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void AssignmentTypeIsValueTuple()
{
string source = @"
class C
{
public static void Main()
{
long x; string y;
var z1 = ((x, y) = new C()).ToString();
var z2 = ((x, y) = new C());
var z3 = (x, y) = new C();
System.Console.Write($""{z1} {z2.ToString()} {z3.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "(1, hello) (1, hello) (1, hello)");
comp.VerifyDiagnostics();
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignmentTypeIsValueTuple_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x; string y;
var z1 = ((x, y) = new C()).ToString();
var z2 = (/*<bind>*/(x, y) = new C()/*</bind>*/);
var z3 = (x, y) = new C();
System.Console.Write($""{z1} {z2.ToString()} {z3.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x, System.String y)) (Syntax: '(x, y)')
NaturalType: (System.Int64 x, System.String y)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.String) (Syntax: 'y')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void NestedAssignmentTypeIsValueTuple()
{
string source = @"
class C
{
public static void Main()
{
long x1; string x2; int x3;
var y = ((x1, x2), x3) = (new C(), 3);
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "((1, hello), 3)");
comp.VerifyDiagnostics();
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NestedAssignmentTypeIsValueTuple_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x1; string x2; int x3;
var y = /*<bind>*/((x1, x2), x3) = (new C(), 3)/*</bind>*/;
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int a, out string b)
{
a = 1;
b = ""hello"";
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ((System.Int64 x1, System.String x2), System.Int32 x3)) (Syntax: '((x1, x2), ... new C(), 3)')
Left:
ITupleOperation (OperationKind.Tuple, Type: ((System.Int64 x1, System.String x2), System.Int32 x3)) (Syntax: '((x1, x2), x3)')
NaturalType: ((System.Int64 x1, System.String x2), System.Int32 x3)
Elements(2):
ITupleOperation (OperationKind.Tuple, Type: (System.Int64 x1, System.String x2)) (Syntax: '(x1, x2)')
NaturalType: (System.Int64 x1, System.String x2)
Elements(2):
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x1')
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.String) (Syntax: 'x2')
ILocalReferenceOperation: x3 (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x3')
Right:
ITupleOperation (OperationKind.Tuple, Type: (C, System.Int32)) (Syntax: '(new C(), 3)')
NaturalType: (C, System.Int32)
Elements(2):
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3) (Syntax: '3')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void AssignmentReturnsLongValueTuple()
{
string source = @"
class C
{
public static void Main()
{
long x;
var y = (x, x, x, x, x, x, x, x, x) = new C();
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int x1, out int x2, out int x3, out int x4, out int x5, out int x6, out int x7, out int x8, out int x9)
{
x1 = x2 = x3 = x4 = x5 = x6 = x7 = x8 = 1;
x9 = 9;
}
}
";
var comp = CompileAndVerify(source, expectedOutput: "(1, 1, 1, 1, 1, 1, 1, 1, 9)");
comp.VerifyDiagnostics();
var tree = comp.Compilation.SyntaxTrees.First();
var model = comp.Compilation.GetSemanticModel(tree, ignoreAccessibility: false);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
var y = nodes.OfType<VariableDeclaratorSyntax>().Skip(1).First();
Assert.Equal("y = (x, x, x, x, x, x, x, x, x) = new C()", y.ToFullString());
Assert.Equal("(System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64) y",
model.GetDeclaredSymbol(y).ToTestDisplayString());
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void AssignmentReturnsLongValueTuple_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x;
var /*<bind>*/y = (x, x, x, x, x, x, x, x, x) = new C()/*</bind>*/;
System.Console.Write($""{y.ToString()}"");
}
public void Deconstruct(out int x1, out int x2, out int x3, out int x4, out int x5, out int x6, out int x7, out int x8, out int x9)
{
x1 = x2 = x3 = x4 = x5 = x6 = x7 = x8 = 1;
x9 = 9;
}
}
";
string expectedOperationTree = @"
IVariableDeclaratorOperation (Symbol: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64) y) (OperationKind.VariableDeclarator, Type: null) (Syntax: 'y = (x, x, ... ) = new C()')
Initializer:
IVariableInitializerOperation (OperationKind.VariableInitializer, Type: null) (Syntax: '= (x, x, x, ... ) = new C()')
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64)) (Syntax: '(x, x, x, x ... ) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64)) (Syntax: '(x, x, x, x ... x, x, x, x)')
NaturalType: (System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64, System.Int64)
Elements(9):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<VariableDeclaratorSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void DeconstructWithoutValueTupleLibrary()
{
string source = @"
class C
{
public static void Main()
{
long x;
var y = (x, x) = new C();
System.Console.Write(y.ToString());
}
public void Deconstruct(out int x1, out int x2)
{
x1 = x2 = 1;
}
}
";
var comp = CreateCompilationWithMscorlib40(source);
comp.VerifyDiagnostics(
// (7,17): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// var y = (x, x) = new C();
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(x, x)").WithArguments("System.ValueTuple`2").WithLocation(7, 17)
);
}
[Fact]
public void ChainedAssignment()
{
string source = @"
class C
{
public static void Main()
{
long x1, x2;
var y = (x1, x1) = (x2, x2) = new C();
System.Console.Write($""{y.ToString()} {x1} {x2}"");
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
var comp = CreateCompilation(source, options: TestOptions.DebugExe);
comp.VerifyDiagnostics();
CompileAndVerify(comp, expectedOutput: "(1, 1) 1 1");
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ChainedAssignment_IOperation()
{
string source = @"
class C
{
public static void Main()
{
long x1, x2;
var y = /*<bind>*/(x1, x1) = (x2, x2) = new C()/*</bind>*/;
System.Console.Write($""{y.ToString()} {x1} {x2}"");
}
public void Deconstruct(out int a, out int b)
{
a = b = 1;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64, System.Int64)) (Syntax: '(x1, x1) = ... ) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64, System.Int64)) (Syntax: '(x1, x1)')
NaturalType: (System.Int64, System.Int64)
Elements(2):
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x1')
Right:
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int64, System.Int64)) (Syntax: '(x2, x2) = new C()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int64, System.Int64)) (Syntax: '(x2, x2)')
NaturalType: (System.Int64, System.Int64)
Elements(2):
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x2')
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.Int64) (Syntax: 'x2')
Right:
IObjectCreationOperation (Constructor: C..ctor()) (OperationKind.ObjectCreation, Type: C) (Syntax: 'new C()')
Arguments(0)
Initializer:
null
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NestedTypelessTupleAssignment2()
{
string source = @"
class C
{
static void Main()
{
int x, y, z; // int cannot be null
/*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
System.Console.WriteLine(""nothing"" + x + y + z);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, (System.Int32 y, System.Int32 z)), IsInvalid) (Syntax: '(x, (y, z)) ... ull, null))')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, (System.Int32 y, System.Int32 z))) (Syntax: '(x, (y, z))')
NaturalType: (System.Int32 x, (System.Int32 y, System.Int32 z))
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 y, System.Int32 z)) (Syntax: '(y, z)')
NaturalType: (System.Int32 y, System.Int32 z)
Elements(2):
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'y')
ILocalReferenceOperation: z (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'z')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32, (System.Int32, System.Int32)), IsInvalid, IsImplicit) (Syntax: '(null, (null, null))')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: null, IsInvalid) (Syntax: '(null, (null, null))')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ITupleOperation (OperationKind.Tuple, Type: null, IsInvalid) (Syntax: '(null, null)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0037: Cannot convert null to 'int' because it is a non-nullable value type
// /*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
Diagnostic(ErrorCode.ERR_ValueCantBeNull, "null").WithArguments("int").WithLocation(8, 34),
// CS0037: Cannot convert null to 'int' because it is a non-nullable value type
// /*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
Diagnostic(ErrorCode.ERR_ValueCantBeNull, "null").WithArguments("int").WithLocation(8, 41),
// CS0037: Cannot convert null to 'int' because it is a non-nullable value type
// /*<bind>*/(x, (y, z)) = (null, (null, null))/*</bind>*/;
Diagnostic(ErrorCode.ERR_ValueCantBeNull, "null").WithArguments("int").WithLocation(8, 47)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TupleWithWrongCardinality()
{
string source = @"
class C
{
static void Main()
{
int x, y, z;
/*<bind>*/(x, y, z) = MakePair()/*</bind>*/;
}
public static (int, int) MakePair()
{
return (42, 42);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, y, z) = MakePair()')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32 y, System.Int32 z), IsInvalid) (Syntax: '(x, y, z)')
NaturalType: (System.Int32 x, System.Int32 y, System.Int32 z)
Elements(3):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
ILocalReferenceOperation: z (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'z')
Right:
IInvocationOperation ((System.Int32, System.Int32) C.MakePair()) (OperationKind.Invocation, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'MakePair()')
Instance Receiver:
null
Arguments(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '2' elements into '3' variables.
// /*<bind>*/(x, y, z) = MakePair()/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, "(x, y, z) = MakePair()").WithArguments("2", "3").WithLocation(8, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NestedTupleWithWrongCardinality()
{
string source = @"
class C
{
static void Main()
{
int x, y, z, w;
/*<bind>*/(x, (y, z, w)) = Pair.Create(42, (43, 44))/*</bind>*/;
}
}
" + commonSource;
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(x, (y, z, ... , (43, 44))')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, (System.Int32 y, System.Int32 z, System.Int32 w)), IsInvalid) (Syntax: '(x, (y, z, w))')
NaturalType: (System.Int32 x, (System.Int32 y, System.Int32 z, System.Int32 w))
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 y, System.Int32 z, System.Int32 w), IsInvalid) (Syntax: '(y, z, w)')
NaturalType: (System.Int32 y, System.Int32 z, System.Int32 w)
Elements(3):
ILocalReferenceOperation: y (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'y')
ILocalReferenceOperation: z (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'z')
ILocalReferenceOperation: w (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'w')
Right:
IInvocationOperation (Pair<System.Int32, (System.Int32, System.Int32)> Pair.Create<System.Int32, (System.Int32, System.Int32)>(System.Int32 item1, (System.Int32, System.Int32) item2)) (OperationKind.Invocation, Type: Pair<System.Int32, (System.Int32, System.Int32)>, IsInvalid) (Syntax: 'Pair.Create ... , (43, 44))')
Instance Receiver:
null
Arguments(2):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item1) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: '42')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 42, IsInvalid) (Syntax: '42')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item2) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: '(43, 44)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(43, 44)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 43, IsInvalid) (Syntax: '43')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 44, IsInvalid) (Syntax: '44')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '2' elements into '3' variables.
// /*<bind>*/(x, (y, z, w)) = Pair.Create(42, (43, 44))/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, "(x, (y, z, w)) = Pair.Create(42, (43, 44))").WithArguments("2", "3").WithLocation(8, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeconstructionTooFewElements()
{
string source = @"
class C
{
static void Main()
{
for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
}
}
" + commonSource;
string expectedOperationTree = @"
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: ?, IsInvalid) (Syntax: '(var(x, y)) ... reate(1, 2)')
Left:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x, y)')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'y')
Children(0)
Right:
IInvocationOperation (Pair<System.Int32, System.Int32> Pair.Create<System.Int32, System.Int32>(System.Int32 item1, System.Int32 item2)) (OperationKind.Invocation, Type: Pair<System.Int32, System.Int32>) (Syntax: 'Pair.Create(1, 2)')
Instance Receiver:
null
Arguments(2):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item1) (OperationKind.Argument, Type: null) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: item2) (OperationKind.Argument, Type: null) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0103: The name 'var' does not exist in the current context
// for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(6, 25),
// CS0103: The name 'x' does not exist in the current context
// for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "x").WithArguments("x").WithLocation(6, 29),
// CS0103: The name 'y' does not exist in the current context
// for (/*<bind>*/(var(x, y)) = Pair.Create(1, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "y").WithArguments("y").WithLocation(6, 32)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void DeconstructionDeclarationInCSharp6()
{
string source = @"
class C
{
static void Main()
{
var (x1, x2) = Pair.Create(1, 2);
(int x3, int x4) = Pair.Create(1, 2);
foreach ((int x5, var (x6, x7)) in new[] { Pair.Create(1, Pair.Create(2, 3)) }) { }
for ((int x8, var (x9, x10)) = Pair.Create(1, Pair.Create(2, 3)); ; ) { }
}
}
" + commonSource;
var comp = CreateCompilation(source, parseOptions: TestOptions.Regular6);
comp.VerifyDiagnostics(
// (6,13): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// var (x1, x2) = Pair.Create(1, 2);
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(x1, x2)").WithArguments("tuples", "7.0").WithLocation(6, 13),
// (7,9): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// (int x3, int x4) = Pair.Create(1, 2);
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(int x3, int x4)").WithArguments("tuples", "7.0").WithLocation(7, 9),
// (8,18): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// foreach ((int x5, var (x6, x7)) in new[] { Pair.Create(1, Pair.Create(2, 3)) }) { }
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(int x5, var (x6, x7))").WithArguments("tuples", "7.0").WithLocation(8, 18),
// (9,14): error CS8059: Feature 'tuples' is not available in C# 6. Please use language version 7.0 or greater.
// for ((int x8, var (x9, x10)) = Pair.Create(1, Pair.Create(2, 3)); ; ) { }
Diagnostic(ErrorCode.ERR_FeatureNotAvailableInVersion6, "(int x8, var (x9, x10))").WithArguments("tuples", "7.0").WithLocation(9, 14)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclareLocalTwice()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x1) = (1, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'var (x1, x1) = (1, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'var (x1, x1)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(x1, x1)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0128: A local variable or function named 'x1' is already defined in this scope
// /*<bind>*/var (x1, x1) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x1").WithArguments("x1").WithLocation(6, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclareLocalTwice2()
{
string source = @"
class C
{
static void Main()
{
string x1 = null;
/*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
System.Console.WriteLine(x1);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0128: A local variable or function named 'x1' is already defined in this scope
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x1").WithArguments("x1").WithLocation(7, 24)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void VarMethodMissing()
{
string source = @"
class C
{
static void Main()
{
int x1 = 1;
int x2 = 1;
/*<bind>*/var(x1, x2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x1, x2)')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0103: The name 'var' does not exist in the current context
// /*<bind>*/var(x1, x2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(8, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<InvocationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void UseBeforeDeclared()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
}
static (int, int) M(int a) { return (1, 2); }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(int x1, int x2) = M(x1)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IInvocationOperation ((System.Int32, System.Int32) C.M(System.Int32 a)) (OperationKind.Invocation, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: 'M(x1)')
Instance Receiver:
null
Arguments(1):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: a) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0165: Use of unassigned local variable 'x1'
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x1").WithArguments("x1").WithLocation(6, 40)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclareWithVoidType()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
}
static void M(int a) { }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(int x1, int x2) = M(x1)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IInvocationOperation (void C.M(System.Int32 a)) (OperationKind.Invocation, Type: System.Void, IsInvalid) (Syntax: 'M(x1)')
Instance Receiver:
null
Arguments(1):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: a) (OperationKind.Argument, Type: null, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1061: 'void' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'void' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "M(x1)").WithArguments("void", "Deconstruct").WithLocation(6, 38),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'void', with 2 out parameters and a void return type.
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "M(x1)").WithArguments("void", "2").WithLocation(6, 38),
// CS0165: Use of unassigned local variable 'x1'
// /*<bind>*/(int x1, int x2) = M(x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x1").WithArguments("x1").WithLocation(6, 40)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void UseBeforeDeclared2()
{
string source = @"
class C
{
static void Main()
{
System.Console.WriteLine(x1);
/*<bind>*/(int x1, int x2) = (1, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, in ... 2) = (1, 2)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x1' before it is declared
// System.Console.WriteLine(x1);
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 34)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NullAssignmentInDeclaration()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(int x1, int x2) = null/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(int x1, int x2) = null')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2)) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/(int x1, int x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(6, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void NullAssignmentInVarDeclaration()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = null/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: 'var (x1, x2) = null')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/var (x1, x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(6, 34),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// /*<bind>*/var (x1, x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 24),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/var (x1, x2) = null/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypelessDeclaration()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (1, null)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: 'var (x1, x2) = (1, null)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(1, null)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// /*<bind>*/var (x1, x2) = (1, null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 24),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/var (x1, x2) = (1, null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 28)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithMultipleAmbiguousVars()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, (byte x2, var x3), var x4) = (null, (2, null), null)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(string x1, ... ull), null)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, (System.Byte x2, var x3), var x4), IsInvalid) (Syntax: '(string x1, ... 3), var x4)')
NaturalType: (System.String x1, (System.Byte x2, var x3), var x4)
Elements(3):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String) (Syntax: 'x1')
ITupleOperation (OperationKind.Tuple, Type: (System.Byte x2, var x3), IsInvalid) (Syntax: '(byte x2, var x3)')
NaturalType: (System.Byte x2, var x3)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Byte) (Syntax: 'byte x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Byte) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x3')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x4')
ILocalReferenceOperation: x4 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x4')
Right:
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(null, (2, null), null)')
NaturalType: null
Elements(3):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(2, null)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x3'.
// /*<bind>*/(string x1, (byte x2, var x3), var x4) = (null, (2, null), null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x3").WithArguments("x3").WithLocation(6, 45),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x4'.
// /*<bind>*/(string x1, (byte x2, var x3), var x4) = (null, (2, null), null)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x4").WithArguments("x4").WithLocation(6, 54)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyLeftNestings()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/((string x1, byte x2, var x3), int x4) = (null, 4)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '((string x1 ... = (null, 4)')
Left:
ITupleOperation (OperationKind.Tuple, Type: ((System.String x1, System.Byte x2, var x3), System.Int32 x4), IsInvalid) (Syntax: '((string x1 ... 3), int x4)')
NaturalType: ((System.String x1, System.Byte x2, var x3), System.Int32 x4)
Elements(2):
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, System.Byte x2, var x3), IsInvalid) (Syntax: '(string x1, ... x2, var x3)')
NaturalType: (System.String x1, System.Byte x2, var x3)
Elements(3):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Byte) (Syntax: 'byte x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Byte) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x3')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x4')
ILocalReferenceOperation: x4 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x4')
Right:
ITupleOperation (OperationKind.Tuple, Type: null, IsInvalid) (Syntax: '(null, 4)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 4) (Syntax: '4')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// /*<bind>*/((string x1, byte x2, var x3), int x4) = (null, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(6, 61),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x3'.
// /*<bind>*/((string x1, byte x2, var x3), int x4) = (null, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x3").WithArguments("x3").WithLocation(6, 45)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyRightNestings()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, var x2) = (null, (null, 2))/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: System.Void, IsInvalid) (Syntax: '(string x1, ... (null, 2))')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, var x2), IsInvalid) (Syntax: '(string x1, var x2)')
NaturalType: (System.String x1, var x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: var, IsInvalid) (Syntax: 'var x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(null, (null, 2))')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ITupleOperation (OperationKind.Tuple, Type: null) (Syntax: '(null, 2)')
NaturalType: null
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/(string x1, var x2) = (null, (null, 2))/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 35)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyLeftVariables()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, var x2, int x3) = (null, ""hello"")/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(string x1, ... l, ""hello"")')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, System.String x2, System.Int32 x3), IsInvalid) (Syntax: '(string x1, ... x2, int x3)')
NaturalType: (System.String x1, System.String x2, System.Int32 x3)
Elements(3):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'var x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'int x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x3')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.String, System.String), IsInvalid) (Syntax: '(null, ""hello"")')
NaturalType: null
Elements(2):
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.String, Constant: null, IsInvalid, IsImplicit) (Syntax: 'null')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.String, Constant: ""hello"", IsInvalid) (Syntax: '""hello""')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '2' elements into '3' variables.
// /*<bind>*/(string x1, var x2, int x3) = (null, "hello")/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, @"(string x1, var x2, int x3) = (null, ""hello"")").WithArguments("2", "3").WithLocation(6, 19)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void TypeMergingWithTooManyRightElements()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(string x1, var y1) = (null, ""hello"", 3)/*</bind>*/;
(string x2, var y2) = (null, ""hello"", null);
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(string x1, ... ""hello"", 3)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.String x1, System.String y1), IsInvalid) (Syntax: '(string x1, var y1)')
NaturalType: (System.String x1, System.String y1)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'string x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.String, IsInvalid) (Syntax: 'var y1')
ILocalReferenceOperation: y1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.String, IsInvalid) (Syntax: 'y1')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.String, System.String, System.Int32), IsInvalid) (Syntax: '(null, ""hello"", 3)')
NaturalType: null
Elements(3):
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.String, Constant: null, IsInvalid, IsImplicit) (Syntax: 'null')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
ILiteralOperation (OperationKind.Literal, Type: null, Constant: null, IsInvalid) (Syntax: 'null')
ILiteralOperation (OperationKind.Literal, Type: System.String, Constant: ""hello"", IsInvalid) (Syntax: '""hello""')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3, IsInvalid) (Syntax: '3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '3' elements into '2' variables.
// /*<bind>*/(string x1, var y1) = (null, "hello", 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, @"(string x1, var y1) = (null, ""hello"", 3)").WithArguments("3", "2").WithLocation(6, 19),
// CS8131: Deconstruct assignment requires an expression with a type on the right-hand-side.
// (string x2, var y2) = (null, "hello", null);
Diagnostic(ErrorCode.ERR_DeconstructRequiresExpression, "null").WithLocation(7, 47),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'y2'.
// (string x2, var y2) = (null, "hello", null);
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "y2").WithArguments("y2").WithLocation(7, 25)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationVarFormWithActualVarType()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
}
}
class var { }
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (var, var), IsInvalid, IsImplicit) (Syntax: '(1, 2)')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1, IsInvalid) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2, IsInvalid) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8136: Deconstruction 'var (...)' form disallows a specific type for 'var'.
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "(x1, x2)").WithLocation(6, 23),
// CS0029: Cannot implicitly convert type 'int' to 'var'
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "1").WithArguments("int", "var").WithLocation(6, 35),
// CS0029: Cannot implicitly convert type 'int' to 'var'
// /*<bind>*/var (x1, x2) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "2").WithArguments("int", "var").WithLocation(6, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationVarFormWithAliasedVarType()
{
string source = @"
using var = D;
class C
{
static void Main()
{
/*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
}
}
class D
{
public override string ToString() { return ""var""; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (D x3, D x4), IsInvalid) (Syntax: 'var (x3, x4) = (3, 4)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (D x3, D x4), IsInvalid) (Syntax: 'var (x3, x4)')
ITupleOperation (OperationKind.Tuple, Type: (D x3, D x4), IsInvalid) (Syntax: '(x3, x4)')
NaturalType: (D x3, D x4)
Elements(2):
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: D, IsInvalid) (Syntax: 'x3')
ILocalReferenceOperation: x4 (IsDeclaration: True) (OperationKind.LocalReference, Type: D, IsInvalid) (Syntax: 'x4')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (D, D), IsInvalid, IsImplicit) (Syntax: '(3, 4)')
Conversion: CommonConversion (Exists: False, IsIdentity: False, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32), IsInvalid) (Syntax: '(3, 4)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3, IsInvalid) (Syntax: '3')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 4, IsInvalid) (Syntax: '4')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8136: Deconstruction 'var (...)' form disallows a specific type for 'var'.
// /*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "(x3, x4)").WithLocation(7, 23),
// CS0029: Cannot implicitly convert type 'int' to 'D'
// /*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "3").WithArguments("int", "D").WithLocation(7, 35),
// CS0029: Cannot implicitly convert type 'int' to 'D'
// /*<bind>*/var (x3, x4) = (3, 4)/*</bind>*/;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "4").WithArguments("int", "D").WithLocation(7, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithWrongCardinality()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: '(var (x1, x ... = (1, 2, 3)')
Left:
ITupleOperation (OperationKind.Tuple, Type: ((var x1, var x2), System.Int32 x3), IsInvalid) (Syntax: '(var (x1, x2), var x3)')
NaturalType: ((var x1, var x2), System.Int32 x3)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'var x3')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x3')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32, System.Int32), IsInvalid) (Syntax: '(1, 2, 3)')
NaturalType: (System.Int32, System.Int32, System.Int32)
Elements(3):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1, IsInvalid) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2, IsInvalid) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3, IsInvalid) (Syntax: '3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS8132: Cannot deconstruct a tuple of '3' elements into '2' variables.
// /*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_DeconstructWrongCardinality, "(var (x1, x2), var x3) = (1, 2, 3)").WithArguments("3", "2").WithLocation(6, 19),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// /*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 25),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// /*<bind>*/(var (x1, x2), var x3) = (1, 2, 3)/*</bind>*/;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 29)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithCircularity1()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, var x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, x1)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x1, var x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, var x2)) (Syntax: '(x1, x2)')
NaturalType: (System.Int32 x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32, var), IsInvalid, IsImplicit) (Syntax: '(1, x1)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, var x1), IsInvalid) (Syntax: '(1, x1)')
NaturalType: (System.Int32, var x1)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x1' before it is declared
// /*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/;
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 38)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithCircularity2()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (var x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2) = (x2, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, System.Int32 x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, System.Int32 x2)) (Syntax: '(x1, x2)')
NaturalType: (var x1, System.Int32 x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (var, System.Int32), IsInvalid, IsImplicit) (Syntax: '(x2, 2)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (var x2, System.Int32), IsInvalid) (Syntax: '(x2, 2)')
NaturalType: (var x2, System.Int32)
Elements(2):
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x2' before it is declared
// /*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x2").WithArguments("x2").WithLocation(6, 35)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningVarInvocation()
{
string source = @"
class C
{
static int i;
static void Main()
{
int x = 0, y = 0;
/*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
System.Console.WriteLine(i);
}
static ref int var(int a, int b) { return ref i; }
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: ?, IsInvalid) (Syntax: 'var (x, y) = 42')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x, var y), IsInvalid) (Syntax: 'var (x, y)')
ITupleOperation (OperationKind.Tuple, Type: (var x, var y), IsInvalid) (Syntax: '(x, y)')
NaturalType: (var x, var y)
Elements(2):
ILocalReferenceOperation: x (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x')
ILocalReferenceOperation: y (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'y')
Right:
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 42, IsInvalid) (Syntax: '42')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0128: A local variable or function named 'x' is already defined in this scope
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(9, 24),
// CS0128: A local variable or function named 'y' is already defined in this scope
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(9, 27),
// CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "42").WithArguments("int", "Deconstruct").WithLocation(9, 32),
// CS8129: No suitable Deconstruct instance or extension method was found for type 'int', with 2 out parameters and a void return type.
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "42").WithArguments("int", "2").WithLocation(9, 32),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x'.
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x").WithArguments("x").WithLocation(9, 24),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'y'.
// /*<bind>*/var (x, y) = 42/*</bind>*/; // parsed as deconstruction
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "y").WithArguments("y").WithLocation(9, 27),
// CS0219: The variable 'x' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "x").WithArguments("x").WithLocation(8, 13),
// CS0219: The variable 'y' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "y").WithArguments("y").WithLocation(8, 20)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact(Skip = "https://github.com/dotnet/roslyn/issues/12468"), CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12468, "https://github.com/dotnet/roslyn/issues/12468")]
public void RefReturningVarInvocation2()
{
string source = @"
class C
{
static int i = 0;
static void Main()
{
int x = 0, y = 0;
@var(x, y) = 42; // parsed as invocation
System.Console.Write(i + "" "");
(var(x, y)) = 43; // parsed as invocation
System.Console.Write(i + "" "");
(var(x, y) = 44); // parsed as invocation
System.Console.Write(i);
}
static ref int var(int a, int b) { return ref i; }
}
";
// The correct expectation is for the code to compile and execute
//var comp = CompileAndVerify(source, expectedOutput: "42 43 44");
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (11,9): error CS8134: Deconstruction must contain at least two variables.
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_DeconstructTooFewElements, "(var(x, y)) = 43").WithLocation(11, 9),
// (13,20): error CS1026: ) expected
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_CloseParenExpected, "=").WithLocation(13, 20),
// (13,24): error CS1002: ; expected
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_SemicolonExpected, ")").WithLocation(13, 24),
// (13,24): error CS1513: } expected
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_RbraceExpected, ")").WithLocation(13, 24),
// (9,14): error CS0128: A local variable named 'x' is already defined in this scope
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(9, 14),
// (9,9): error CS0246: The type or namespace name 'var' could not be found (are you missing a using directive or an assembly reference?)
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "@var").WithArguments("var").WithLocation(9, 9),
// (9,14): error CS8136: Deconstruction `var (...)` form disallows a specific type for 'var'.
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "x").WithLocation(9, 14),
// (9,17): error CS0128: A local variable named 'y' is already defined in this scope
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(9, 17),
// (9,9): error CS0246: The type or namespace name 'var' could not be found (are you missing a using directive or an assembly reference?)
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "@var").WithArguments("var").WithLocation(9, 9),
// (9,17): error CS8136: Deconstruction `var (...)` form disallows a specific type for 'var'.
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_DeconstructionVarFormDisallowsSpecificType, "y").WithLocation(9, 17),
// (9,22): error CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "42").WithArguments("int", "Deconstruct").WithLocation(9, 22),
// (9,22): error CS8129: No Deconstruct instance or extension method was found for type 'int', with 2 out parameters.
// @var(x, y) = 42; // parsed as invocation
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "42").WithArguments("int", "2").WithLocation(9, 22),
// (11,14): error CS0128: A local variable named 'x' is already defined in this scope
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(11, 14),
// (11,17): error CS0128: A local variable named 'y' is already defined in this scope
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(11, 17),
// (11,23): error CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "43").WithArguments("int", "Deconstruct").WithLocation(11, 23),
// (11,23): error CS8129: No Deconstruct instance or extension method was found for type 'int', with 1 out parameters.
// (var(x, y)) = 43; // parsed as invocation
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "43").WithArguments("int", "1").WithLocation(11, 23),
// (13,14): error CS0128: A local variable named 'x' is already defined in this scope
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "x").WithArguments("x").WithLocation(13, 14),
// (13,17): error CS0128: A local variable named 'y' is already defined in this scope
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_LocalDuplicate, "y").WithArguments("y").WithLocation(13, 17),
// (13,22): error CS1061: 'int' does not contain a definition for 'Deconstruct' and no extension method 'Deconstruct' accepting a first argument of type 'int' could be found (are you missing a using directive or an assembly reference?)
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_NoSuchMemberOrExtension, "44").WithArguments("int", "Deconstruct").WithLocation(13, 22),
// (13,22): error CS8129: No Deconstruct instance or extension method was found for type 'int', with 1 out parameters.
// (var(x, y) = 44); // parsed as invocation
Diagnostic(ErrorCode.ERR_MissingDeconstruct, "44").WithArguments("int", "1").WithLocation(13, 22),
// (8,13): warning CS0219: The variable 'x' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "x").WithArguments("x").WithLocation(8, 13),
// (8,20): warning CS0219: The variable 'y' is assigned but its value is never used
// int x = 0, y = 0;
Diagnostic(ErrorCode.WRN_UnreferencedVarAssg, "y").WithArguments("y").WithLocation(8, 20)
);
}
[Fact, CompilerTrait(CompilerFeature.RefLocalsReturns)]
[WorkItem(12283, "https://github.com/dotnet/roslyn/issues/12283")]
public void RefReturningInvocation()
{
string source = @"
class C
{
static int i;
static void Main()
{
int x = 0, y = 0;
M(x, y) = 42;
System.Console.WriteLine(i);
}
static ref int M(int a, int b) { return ref i; }
}
";
var comp = CompileAndVerify(source, expectedOutput: "42");
comp.VerifyDiagnostics();
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DeclarationWithTypeInsideVarForm()
{
string source = @"
class C
{
static void Main()
{
var(int x1, x2) = (1, 2);
var(var x3, x4) = (1, 2);
/*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
}
}
";
string expectedOperationTree = @"
ISimpleAssignmentOperation (OperationKind.SimpleAssignment, Type: ?, IsInvalid) (Syntax: 'var(x5, var ... (1, (2, 3))')
Left:
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x5, var(x6, x7))')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x5')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var(x6, x7)')
Children(3):
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'var')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x6')
Children(0)
IInvalidOperation (OperationKind.Invalid, Type: ?, IsInvalid) (Syntax: 'x7')
Children(0)
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, (System.Int32, System.Int32))) (Syntax: '(1, (2, 3))')
NaturalType: (System.Int32, (System.Int32, System.Int32))
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(2, 3)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 3) (Syntax: '3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1525: Invalid expression term 'int'
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "int").WithArguments("int").WithLocation(6, 13),
// CS1003: Syntax error, ',' expected
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_SyntaxError, "x1").WithArguments(",", "").WithLocation(6, 17),
// CS1003: Syntax error, ',' expected
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_SyntaxError, "x3").WithArguments(",", "").WithLocation(7, 17),
// CS8199: The syntax 'var (...)' as an lvalue is reserved.
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_VarInvocationLvalueReserved, "var(int x1, x2)").WithLocation(6, 9),
// CS0103: The name 'var' does not exist in the current context
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(6, 9),
// CS0103: The name 'x1' does not exist in the current context
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 17),
// CS0103: The name 'x2' does not exist in the current context
// var(int x1, x2) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x2").WithArguments("x2").WithLocation(6, 21),
// CS8199: The syntax 'var (...)' as an lvalue is reserved.
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_VarInvocationLvalueReserved, "var(var x3, x4)").WithLocation(7, 9),
// CS0103: The name 'var' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 9),
// CS0103: The name 'var' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 13),
// CS0103: The name 'x3' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x3").WithArguments("x3").WithLocation(7, 17),
// CS0103: The name 'x4' does not exist in the current context
// var(var x3, x4) = (1, 2);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x4").WithArguments("x4").WithLocation(7, 21),
// CS8199: The syntax 'var (...)' as an lvalue is reserved.
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_VarInvocationLvalueReserved, "var(x5, var(x6, x7))").WithLocation(8, 19),
// CS0103: The name 'var' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(8, 19),
// CS0103: The name 'x5' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x5").WithArguments("x5").WithLocation(8, 23),
// CS0103: The name 'var' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(8, 27),
// CS0103: The name 'x6' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x6").WithArguments("x6").WithLocation(8, 31),
// CS0103: The name 'x7' does not exist in the current context
// /*<bind>*/var(x5, var(x6, x7)) = (1, (2, 3))/*</bind>*/;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x7").WithArguments("x7").WithLocation(8, 35)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForWithCircularity1()
{
string source = @"
class C
{
static void Main()
{
for (/*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/; ;) { }
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x1, var x2), IsInvalid) (Syntax: 'var (x1, x2) = (1, x1)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x1, var x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, var x2)) (Syntax: '(x1, x2)')
NaturalType: (System.Int32 x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32, var), IsInvalid, IsImplicit) (Syntax: '(1, x1)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, var x1), IsInvalid) (Syntax: '(1, x1)')
NaturalType: (System.Int32, var x1)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILocalReferenceOperation: x1 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x1' before it is declared
// for (/*<bind>*/var (x1, x2) = (1, x1)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 43)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForWithCircularity2()
{
string source = @"
class C
{
static void Main()
{
for (/*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/; ;) { }
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (var x1, System.Int32 x2), IsInvalid) (Syntax: 'var (x1, x2) = (x2, 2)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, System.Int32 x2)) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, System.Int32 x2)) (Syntax: '(x1, x2)')
NaturalType: (var x1, System.Int32 x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Right:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (var, System.Int32), IsInvalid, IsImplicit) (Syntax: '(x2, 2)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (var x2, System.Int32), IsInvalid) (Syntax: '(x2, 2)')
NaturalType: (var x2, System.Int32)
Elements(2):
ILocalReferenceOperation: x2 (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0841: Cannot use local variable 'x2' before it is declared
// for (/*<bind>*/var (x1, x2) = (x2, 2)/*</bind>*/; ;) { }
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x2").WithArguments("x2").WithLocation(6, 40)
};
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachNameConflict()
{
string source = @"
class C
{
static void Main()
{
int x1 = 1;
/*<bind>*/foreach ((int x1, int x2) in M()) { }/*</bind>*/
System.Console.Write(x1);
}
static (int, int)[] M() { return new[] { (1, 2) }; }
}
";
string expectedOperationTree = @"
IForEachLoopOperation (LoopKind.ForEach, Continue Label Id: 0, Exit Label Id: 1) (OperationKind.Loop, Type: null, IsInvalid) (Syntax: 'foreach ((i ... in M()) { }')
Locals: Local_1: System.Int32 x1
Local_2: System.Int32 x2
LoopControlVariable:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Collection:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.Collections.IEnumerable, IsImplicit) (Syntax: 'M()')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
IInvocationOperation ((System.Int32, System.Int32)[] C.M()) (OperationKind.Invocation, Type: (System.Int32, System.Int32)[]) (Syntax: 'M()')
Instance Receiver:
null
Arguments(0)
Body:
IBlockOperation (0 statements) (OperationKind.Block, Type: null) (Syntax: '{ }')
NextVariables(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0136: A local or parameter named 'x1' cannot be declared in this scope because that name is used in an enclosing local scope to define a local or parameter
// /*<bind>*/foreach ((int x1, int x2) in M()) { }/*</bind>*/
Diagnostic(ErrorCode.ERR_LocalIllegallyOverrides, "x1").WithArguments("x1").WithLocation(7, 33)
};
VerifyOperationTreeAndDiagnosticsForTest<ForEachVariableStatementSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachNameConflict2()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/foreach ((int x1, int x2) in M(out int x1)) { }/*</bind>*/
}
static (int, int)[] M(out int a) { a = 1; return new[] { (1, 2) }; }
}
";
string expectedOperationTree = @"
IForEachLoopOperation (LoopKind.ForEach, Continue Label Id: 0, Exit Label Id: 1) (OperationKind.Loop, Type: null, IsInvalid) (Syntax: 'foreach ((i ... nt x1)) { }')
Locals: Local_1: System.Int32 x1
Local_2: System.Int32 x2
LoopControlVariable:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, System.Int32 x2), IsInvalid) (Syntax: '(int x1, int x2)')
NaturalType: (System.Int32 x1, System.Int32 x2)
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32, IsInvalid) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32, IsInvalid) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x2')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
Collection:
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: System.Collections.IEnumerable, IsImplicit) (Syntax: 'M(out int x1)')
Conversion: CommonConversion (Exists: True, IsIdentity: False, IsNumeric: False, IsReference: True, IsUserDefined: False) (MethodSymbol: null)
Operand:
IInvocationOperation ((System.Int32, System.Int32)[] C.M(out System.Int32 a)) (OperationKind.Invocation, Type: (System.Int32, System.Int32)[]) (Syntax: 'M(out int x1)')
Instance Receiver:
null
Arguments(1):
IArgumentOperation (ArgumentKind.Explicit, Matching Parameter: a) (OperationKind.Argument, Type: null) (Syntax: 'out int x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
InConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
OutConversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Body:
IBlockOperation (0 statements) (OperationKind.Block, Type: null) (Syntax: '{ }')
NextVariables(0)
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS0136: A local or parameter named 'x1' cannot be declared in this scope because that name is used in an enclosing local scope to define a local or parameter
// /*<bind>*/foreach ((int x1, int x2) in M(out int x1)) { }/*</bind>*/
Diagnostic(ErrorCode.ERR_LocalIllegallyOverrides, "x1").WithArguments("x1").WithLocation(6, 33)
};
VerifyOperationTreeAndDiagnosticsForTest<ForEachVariableStatementSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void ForEachNameConflict3()
{
string source = @"
class C
{
static void Main()
{
foreach ((int x1, int x2) in M())
{
int x1 = 1;
System.Console.Write(x1);
}
}
static (int, int)[] M() { return new[] { (1, 2) }; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (8,17): error CS0136: A local or parameter named 'x1' cannot be declared in this scope because that name is used in an enclosing local scope to define a local or parameter
// int x1 = 1;
Diagnostic(ErrorCode.ERR_LocalIllegallyOverrides, "x1").WithArguments("x1").WithLocation(8, 17)
);
}
[Fact]
public void ForEachUseBeforeDeclared()
{
string source = @"
class C
{
static void Main()
{
foreach ((int x1, int x2) in M(x1)) { }
}
static (int, int)[] M(int a) { return new[] { (1, 2) }; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,40): error CS0103: The name 'x1' does not exist in the current context
// foreach ((int x1, int x2) in M(x1))
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 40)
);
}
[Fact]
public void ForEachUseOutsideScope()
{
string source = @"
class C
{
static void Main()
{
foreach ((int x1, int x2) in M()) { }
System.Console.Write(x1);
}
static (int, int)[] M() { return new[] { (1, 2) }; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (7,30): error CS0103: The name 'x1' does not exist in the current context
// System.Console.Write(x1);
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(7, 30)
);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachNoIEnumerable()
{
string source = @"
class C
{
static void Main()
{
foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
{
System.Console.WriteLine(x1 + "" "" + x2);
}
}
}
";
string expectedOperationTree = @"
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (var x1, var x2), IsInvalid) (Syntax: 'var (x1, x2)')
ITupleOperation (OperationKind.Tuple, Type: (var x1, var x2), IsInvalid) (Syntax: '(x1, x2)')
NaturalType: (var x1, var x2)
Elements(2):
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x1')
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: var, IsInvalid) (Syntax: 'x2')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1579: foreach statement cannot operate on variables of type 'int' because 'int' does not contain a public definition for 'GetEnumerator'
// foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
Diagnostic(ErrorCode.ERR_ForEachMissingMember, "1").WithArguments("int", "GetEnumerator").WithLocation(6, 55),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 33),
// CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// foreach (/*<bind>*/var (x1, x2)/*</bind>*/ in 1)
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 37)
};
VerifyOperationTreeAndDiagnosticsForTest<DeclarationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void ForEachIterationVariablesAreReadonly()
{
string source = @"
class C
{
static void Main()
{
foreach (/*<bind>*/(int x1, var (x2, x3))/*</bind>*/ in new[] { (1, (1, 1)) })
{
x1 = 1;
x2 = 2;
x3 = 3;
}
}
}
";
string expectedOperationTree = @"
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x1, (System.Int32 x2, System.Int32 x3))) (Syntax: '(int x1, var (x2, x3))')
NaturalType: (System.Int32 x1, (System.Int32 x2, System.Int32 x3))
Elements(2):
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: System.Int32) (Syntax: 'int x1')
ILocalReferenceOperation: x1 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x1')
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32 x2, System.Int32 x3)) (Syntax: 'var (x2, x3)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x2, System.Int32 x3)) (Syntax: '(x2, x3)')
NaturalType: (System.Int32 x2, System.Int32 x3)
Elements(2):
ILocalReferenceOperation: x2 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x2')
ILocalReferenceOperation: x3 (IsDeclaration: True) (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x3')
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1656: Cannot assign to 'x1' because it is a 'foreach iteration variable'
// x1 = 1;
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "x1").WithArguments("x1", "foreach iteration variable").WithLocation(8, 13),
// CS1656: Cannot assign to 'x2' because it is a 'foreach iteration variable'
// x2 = 2;
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "x2").WithArguments("x2", "foreach iteration variable").WithLocation(9, 13),
// CS1656: Cannot assign to 'x3' because it is a 'foreach iteration variable'
// x3 = 3;
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "x3").WithArguments("x3", "foreach iteration variable").WithLocation(10, 13)
};
VerifyOperationTreeAndDiagnosticsForTest<TupleExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
public void ForEachScoping()
{
string source = @"
class C
{
static void Main()
{
foreach (var (x1, x2) in M(x1)) { }
}
static (int, int) M(int i) { return (1, 2); }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,36): error CS0103: The name 'x1' does not exist in the current context
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 36),
// (6,34): error CS1579: foreach statement cannot operate on variables of type '(int, int)' because '(int, int)' does not contain a public instance or extension definition for 'GetEnumerator'
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_ForEachMissingMember, "M(x1)").WithArguments("(int, int)", "GetEnumerator").WithLocation(6, 34),
// (6,23): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x1'.
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x1").WithArguments("x1").WithLocation(6, 23),
// (6,27): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'x2'.
// foreach (var (x1, x2) in M(x1)) { }
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "x2").WithArguments("x2").WithLocation(6, 27)
);
}
[Fact]
public void AssignmentDataFlow()
{
string source = @"
class C
{
static void Main()
{
int x, y;
(x, y) = new C(); // x and y are assigned here, so no complaints on usage of un-initialized locals on the line below
System.Console.WriteLine(x + "" "" + y);
}
public void Deconstruct(out int a, out int b)
{
a = 1;
b = 2;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics();
}
[Fact]
public void GetTypeInfoForTupleLiteral()
{
var source = @"
class C
{
static void Main()
{
var x1 = (1, 2);
var (x2, x3) = (1, 2);
System.Console.Write($""{x1} {x2} {x3}"");
}
}
";
Action<ModuleSymbol> validator = module =>
{
var sourceModule = (SourceModuleSymbol)module;
var compilation = sourceModule.DeclaringCompilation;
var tree = compilation.SyntaxTrees.First();
var model = compilation.GetSemanticModel(tree);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
var literal1 = nodes.OfType<TupleExpressionSyntax>().First();
Assert.Equal("(int, int)", model.GetTypeInfo(literal1).Type.ToDisplayString());
var literal2 = nodes.OfType<TupleExpressionSyntax>().Skip(1).First();
Assert.Equal("(int, int)", model.GetTypeInfo(literal2).Type.ToDisplayString());
};
var verifier = CompileAndVerify(source, sourceSymbolValidator: validator);
verifier.VerifyDiagnostics();
}
[Fact]
public void DeclarationWithCircularity3()
{
string source = @"
class C
{
static void Main()
{
var (x1, x2) = (M(out x2), M(out x1));
}
static T M<T>(out T x) { x = default(T); return x; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,31): error CS0841: Cannot use local variable 'x2' before it is declared
// var (x1, x2) = (M(out x2), M(out x1));
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x2").WithArguments("x2").WithLocation(6, 31),
// (6,42): error CS0841: Cannot use local variable 'x1' before it is declared
// var (x1, x2) = (M(out x2), M(out x1));
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "x1").WithArguments("x1").WithLocation(6, 42)
);
}
[Fact, WorkItem(13081, "https://github.com/dotnet/roslyn/issues/13081")]
public void GettingDiagnosticsWhenValueTupleIsMissing()
{
var source = @"
class C1
{
static void Test(int arg1, (byte, byte) arg2)
{
foreach ((int, int) e in new (int, int)[10])
{
}
}
}
";
var comp = CreateCompilationWithMscorlib40(source);
comp.VerifyDiagnostics(
// (4,32): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// static void Test(int arg1, (byte, byte) arg2)
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(byte, byte)").WithArguments("System.ValueTuple`2").WithLocation(4, 32),
// (6,38): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// foreach ((int, int) e in new (int, int)[10])
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(int, int)").WithArguments("System.ValueTuple`2").WithLocation(6, 38),
// (6,18): error CS8179: Predefined type 'System.ValueTuple`2' is not defined or imported
// foreach ((int, int) e in new (int, int)[10])
Diagnostic(ErrorCode.ERR_PredefinedValueTupleTypeNotFound, "(int, int)").WithArguments("System.ValueTuple`2").WithLocation(6, 18)
);
// no crash
}
[Fact]
public void DeconstructionMayBeEmbedded()
{
var source = @"
class C1
{
void M()
{
if (true)
var (x, y) = (1, 2);
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// this is no longer considered a declaration statement,
// but rather is an assignment expression. So no error.
);
}
[Fact]
public void AssignmentExpressionCanBeUsedInEmbeddedStatement()
{
var source = @"
class C1
{
void M()
{
int x, y;
if (true)
(x, y) = (1, 2);
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics();
}
[Fact]
public void DeconstructObsoleteWarning()
{
var source = @"
class C
{
void M()
{
(int y1, int y2) = new C();
}
[System.Obsolete()]
void Deconstruct(out int x1, out int x2) { x1 = 1; x2 = 2; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,27): warning CS0612: 'C.Deconstruct(out int, out int)' is obsolete
// (int y1, int y2) = new C();
Diagnostic(ErrorCode.WRN_DeprecatedSymbol, "new C()").WithArguments("C.Deconstruct(out int, out int)").WithLocation(6, 27)
);
}
[Fact]
public void DeconstructObsoleteError()
{
var source = @"
class C
{
void M()
{
(int y1, int y2) = new C();
}
[System.Obsolete(""Deprecated"", error: true)]
void Deconstruct(out int x1, out int x2) { x1 = 1; x2 = 2; }
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,27): error CS0619: 'C.Deconstruct(out int, out int)' is obsolete: 'Deprecated'
// (int y1, int y2) = new C();
Diagnostic(ErrorCode.ERR_DeprecatedSymbolStr, "new C()").WithArguments("C.Deconstruct(out int, out int)", "Deprecated").WithLocation(6, 27)
);
}
[Fact]
public void DeconstructionLocalsDeclaredNotUsed()
{
// Check that there are no *use sites* within this code for local variables.
// They are not declared. So they should not be returned
// by SemanticModel.GetSymbolInfo. Similarly, check that all designation syntax
// forms declare deconstruction locals.
string source = @"
class Program
{
static void Main()
{
var (x1, y1) = (1, 2);
(var x2, var y2) = (1, 2);
}
static void M((int, int) t)
{
var (x3, y3) = t;
(var x4, var y4) = t;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics();
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree, ignoreAccessibility: false);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
foreach (var node in nodes)
{
var si = model.GetSymbolInfo(node);
var symbol = si.Symbol;
if ((object)symbol != null)
{
if (node is DeclarationExpressionSyntax)
{
Assert.Equal(SymbolKind.Local, symbol.Kind);
Assert.Equal(LocalDeclarationKind.DeconstructionVariable, symbol.GetSymbol<LocalSymbol>().DeclarationKind);
}
else
{
Assert.NotEqual(SymbolKind.Local, symbol.Kind);
}
}
symbol = model.GetDeclaredSymbol(node);
if ((object)symbol != null)
{
if (node is SingleVariableDesignationSyntax)
{
Assert.Equal(SymbolKind.Local, symbol.Kind);
Assert.Equal(LocalDeclarationKind.DeconstructionVariable, symbol.GetSymbol<LocalSymbol>().DeclarationKind);
}
else
{
Assert.NotEqual(SymbolKind.Local, symbol.Kind);
}
}
}
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact, WorkItem(14287, "https://github.com/dotnet/roslyn/issues/14287")]
public void TupleDeconstructionStatementWithTypesCannotBeConst()
{
string source = @"
class C
{
static void Main()
{
/*<bind>*/const (int x, int y) = (1, 2);/*</bind>*/
}
}
";
string expectedOperationTree = @"
IVariableDeclarationGroupOperation (1 declarations) (OperationKind.VariableDeclarationGroup, Type: null, IsInvalid) (Syntax: 'const (int ... ) = (1, 2);')
IVariableDeclarationOperation (1 declarators) (OperationKind.VariableDeclaration, Type: null, IsInvalid) (Syntax: '(int x, int y) = (1, 2)')
Declarators:
IVariableDeclaratorOperation (Symbol: (System.Int32 x, System.Int32 y) ) (OperationKind.VariableDeclarator, Type: null, IsInvalid) (Syntax: '= (1, 2)')
Initializer:
IVariableInitializerOperation (OperationKind.VariableInitializer, Type: null, IsInvalid) (Syntax: '= (1, 2)')
IConversionOperation (TryCast: False, Unchecked) (OperationKind.Conversion, Type: (System.Int32 x, System.Int32 y), IsImplicit) (Syntax: '(1, 2)')
Conversion: CommonConversion (Exists: True, IsIdentity: True, IsNumeric: False, IsReference: False, IsUserDefined: False) (MethodSymbol: null)
Operand:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(1, 2)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 1) (Syntax: '1')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 2) (Syntax: '2')
Initializer:
null
";
var expectedDiagnostics = new DiagnosticDescription[] {
// CS1001: Identifier expected
// const /*<bind>*/(int x, int y) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_IdentifierExpected, "=").WithLocation(6, 40),
// CS0283: The type '(int x, int y)' cannot be declared const
// const /*<bind>*/(int x, int y) = (1, 2)/*</bind>*/;
Diagnostic(ErrorCode.ERR_BadConstType, "(int x, int y)").WithArguments("(int x, int y)").WithLocation(6, 25)
};
VerifyOperationTreeAndDiagnosticsForTest<LocalDeclarationStatementSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact, WorkItem(14287, "https://github.com/dotnet/roslyn/issues/14287")]
public void TupleDeconstructionStatementWithoutTypesCannotBeConst()
{
string source = @"
class C
{
static void Main()
{
const var (x, y) = (1, 2);
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,9): error CS0106: The modifier 'const' is not valid for this item
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_BadMemberFlag, "const").WithArguments("const").WithLocation(6, 9),
// (6,19): error CS1001: Identifier expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_IdentifierExpected, "(").WithLocation(6, 19),
// (6,21): error CS1001: Identifier expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_IdentifierExpected, ",").WithLocation(6, 21),
// (6,24): error CS1001: Identifier expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_IdentifierExpected, ")").WithLocation(6, 24),
// (6,26): error CS1002: ; expected
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_SemicolonExpected, "=").WithLocation(6, 26),
// (6,26): error CS1525: Invalid expression term '='
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "=").WithArguments("=").WithLocation(6, 26),
// (6,19): error CS8112: '(x, y)' is a local function and must therefore always have a body.
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_LocalFunctionMissingBody, "").WithArguments("(x, y)").WithLocation(6, 19),
// (6,20): error CS0246: The type or namespace name 'x' could not be found (are you missing a using directive or an assembly reference?)
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "x").WithArguments("x").WithLocation(6, 20),
// (6,23): error CS0246: The type or namespace name 'y' could not be found (are you missing a using directive or an assembly reference?)
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_SingleTypeNameNotFound, "y").WithArguments("y").WithLocation(6, 23),
// (6,15): error CS0825: The contextual keyword 'var' may only appear within a local variable declaration or in script code
// const var (x, y) = (1, 2);
Diagnostic(ErrorCode.ERR_TypeVarNotFound, "var").WithLocation(6, 15)
);
}
[Fact, WorkItem(15934, "https://github.com/dotnet/roslyn/issues/15934")]
public void PointerTypeInDeconstruction()
{
string source = @"
unsafe class C
{
static void Main(C c)
{
(int* x1, int y1) = c;
(var* x2, int y2) = c;
(int*[] x3, int y3) = c;
(var*[] x4, int y4) = c;
}
public void Deconstruct(out dynamic x, out dynamic y)
{
x = y = null;
}
}
";
var comp = CreateCompilationWithMscorlib40AndSystemCore(source,
references: new[] { ValueTupleRef, SystemRuntimeFacadeRef },
options: TestOptions.UnsafeDebugDll,
parseOptions: TestOptions.RegularPreview);
// The precise diagnostics here are not important, and may be sensitive to parser
// adjustments. This is a test that we don't crash. The errors here are likely to
// change as we adjust the parser and semantic analysis of error cases.
comp.VerifyDiagnostics(
// (6,10): error CS1525: Invalid expression term 'int'
// (int* x1, int y1) = c;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "int").WithArguments("int").WithLocation(6, 10),
// (6,15): error CS0103: The name 'x1' does not exist in the current context
// (int* x1, int y1) = c;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x1").WithArguments("x1").WithLocation(6, 15),
// (6,19): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (int* x1, int y1) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y1").WithArguments("dynamic", "int").WithLocation(6, 19),
// (7,10): error CS0103: The name 'var' does not exist in the current context
// (var* x2, int y2) = c;
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 10),
// (7,15): error CS0103: The name 'x2' does not exist in the current context
// (var* x2, int y2) = c;
Diagnostic(ErrorCode.ERR_NameNotInContext, "x2").WithArguments("x2").WithLocation(7, 15),
// (7,19): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (var* x2, int y2) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y2").WithArguments("dynamic", "int").WithLocation(7, 19),
// (8,10): error CS0266: Cannot implicitly convert type 'dynamic' to 'int*[]'. An explicit conversion exists (are you missing a cast?)
// (int*[] x3, int y3) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int*[] x3").WithArguments("dynamic", "int*[]").WithLocation(8, 10),
// (8,21): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (int*[] x3, int y3) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y3").WithArguments("dynamic", "int").WithLocation(8, 21),
// (9,10): error CS0825: The contextual keyword 'var' may only appear within a local variable declaration or in script code
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_TypeVarNotFound, "var").WithLocation(9, 10),
// (9,10): error CS0208: Cannot take the address of, get the size of, or declare a pointer to a managed type ('var')
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_ManagedAddr, "var*").WithArguments("var").WithLocation(9, 10),
// (9,10): error CS0266: Cannot implicitly convert type 'dynamic' to 'var*[]'. An explicit conversion exists (are you missing a cast?)
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "var*[] x4").WithArguments("dynamic", "var*[]").WithLocation(9, 10),
// (9,21): error CS0266: Cannot implicitly convert type 'dynamic' to 'int'. An explicit conversion exists (are you missing a cast?)
// (var*[] x4, int y4) = c;
Diagnostic(ErrorCode.ERR_NoImplicitConvCast, "int y4").WithArguments("dynamic", "int").WithLocation(9, 21)
);
}
[Fact]
public void DeclarationInsideNameof()
{
string source = @"
class Program
{
static void Main()
{
string s = nameof((int x1, var x2) = (1, 2)).ToString();
string s1 = x1, s2 = x2;
}
}
";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (6,28): error CS8185: A declaration is not allowed in this context.
// string s = nameof((int x1, var x2) = (1, 2)).ToString();
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int x1").WithLocation(6, 28),
// (6,27): error CS8081: Expression does not have a name.
// string s = nameof((int x1, var x2) = (1, 2)).ToString();
Diagnostic(ErrorCode.ERR_ExpressionHasNoName, "(int x1, var x2) = (1, 2)").WithLocation(6, 27),
// (7,21): error CS0029: Cannot implicitly convert type 'int' to 'string'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "x1").WithArguments("int", "string").WithLocation(7, 21),
// (7,30): error CS0029: Cannot implicitly convert type 'int' to 'string'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_NoImplicitConv, "x2").WithArguments("int", "string").WithLocation(7, 30),
// (7,21): error CS0165: Use of unassigned local variable 'x1'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x1").WithArguments("x1").WithLocation(7, 21),
// (7,30): error CS0165: Use of unassigned local variable 'x2'
// string s1 = x1, s2 = x2;
Diagnostic(ErrorCode.ERR_UseDefViolation, "x2").WithArguments("x2").WithLocation(7, 30)
);
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(2, designations.Count());
var refs = tree.GetCompilationUnitRoot().DescendantNodes().OfType<IdentifierNameSyntax>();
var x1 = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("x1", x1.Name);
Assert.Equal("System.Int32", ((ILocalSymbol)x1).Type.ToTestDisplayString());
Assert.Same(x1, model.GetSymbolInfo(refs.Where(r => r.Identifier.ValueText == "x1").Single()).Symbol);
var x2 = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("x2", x2.Name);
Assert.Equal("System.Int32", ((ILocalSymbol)x2).Type.ToTestDisplayString());
Assert.Same(x2, model.GetSymbolInfo(refs.Where(r => r.Identifier.ValueText == "x2").Single()).Symbol);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_01()
{
string source1 = @"
class C
{
static void Main()
{
(var (a,b), var c, int d);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)"),
// (6,21): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c"),
// (6,28): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(6, 28),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (a,b), var c, int d)").WithLocation(6, 9),
// (6,28): error CS0165: Use of unassigned local variable 'd'
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_UseDefViolation, "int d").WithArguments("d").WithLocation(6, 28)
);
StandAlone_01_VerifySemanticModel(comp1, LocalDeclarationKind.DeclarationExpressionVariable);
string source2 = @"
class C
{
static void Main()
{
(var (a,b), var c, int d) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_01_VerifySemanticModel(comp2, LocalDeclarationKind.DeconstructionVariable);
}
private static void StandAlone_01_VerifySemanticModel(CSharpCompilation comp, LocalDeclarationKind localDeclarationKind)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var a", a.ToTestDisplayString());
Assert.Equal(localDeclarationKind, a.GetSymbol<LocalSymbol>().DeclarationKind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var b", b.ToTestDisplayString());
Assert.Equal(localDeclarationKind, b.GetSymbol<LocalSymbol>().DeclarationKind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var c", c.ToTestDisplayString());
Assert.Equal(localDeclarationKind, c.GetSymbol<LocalSymbol>().DeclarationKind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 d", d.ToTestDisplayString());
Assert.Equal(localDeclarationKind, d.GetSymbol<LocalSymbol>().DeclarationKind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("((var a, var b), var c, System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_02()
{
string source1 = @"
(var (a,b), var c, int d);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,7): error CS7019: Type of 'a' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "a").WithArguments("a"),
// (2,9): error CS7019: Type of 'b' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "b").WithArguments("b"),
// (2,17): error CS7019: Type of 'c' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "c").WithArguments("c"),
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)"),
// (2,13): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c"),
// (2,20): error CS8185: A declaration is not allowed in this context.
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(2, 20),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (a,b), var c, int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (a,b), var c, int d)").WithLocation(2, 1)
);
StandAlone_02_VerifySemanticModel(comp1);
string source2 = @"
(var (a,b), var c, int d) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_02_VerifySemanticModel(comp2);
}
private static void StandAlone_02_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var Script.a", a.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, a.Kind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var Script.b", b.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, b.Kind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var Script.c", c.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, c.Kind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 Script.d", d.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, d.Kind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var Script.c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 Script.d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("((var a, var b), var c, System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_03()
{
string source1 = @"
class C
{
static void Main()
{
(var (_, _), var _, int _);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)"),
// (6,22): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _"),
// (6,29): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(6, 29),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (_, _), var _, int _)").WithLocation(6, 9)
);
StandAlone_03_VerifySemanticModel(comp1);
string source2 = @"
class C
{
static void Main()
{
(var (_, _), var _, int _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_03_VerifySemanticModel(comp2);
}
private static void StandAlone_03_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
int count = 0;
foreach (var designation in tree.GetCompilationUnitRoot().DescendantNodes().OfType<DiscardDesignationSyntax>())
{
Assert.Null(model.GetDeclaredSymbol(designation));
count++;
}
Assert.Equal(4, count);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (_, _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var, var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int _", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("((var, var), var, System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_04()
{
string source1 = @"
(var (_, _), var _, int _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)"),
// (2,14): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _"),
// (2,21): error CS8185: A declaration is not allowed in this context.
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(2, 21),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var (_, _), var _, int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (_, _), var _, int _)").WithLocation(2, 1)
);
StandAlone_03_VerifySemanticModel(comp1);
string source2 = @"
(var (_, _), var _, int _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_03_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_05()
{
string source1 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (a,b), var c);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_05_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (a,b), var c) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_05_VerifySemanticModel(comp2);
}
private static void StandAlone_05_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(System.Int32 a, System.Int32 b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[0].Type).ToTestDisplayString());
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[1].Type).ToTestDisplayString());
}
[Fact]
[WorkItem(23651, "https://github.com/dotnet/roslyn/issues/23651")]
public void StandAlone_05_WithDuplicateNames()
{
string source1 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (a, a), var c);
}
}
";
var comp1 = CreateCompilation(source1);
var tree = comp1.SyntaxTrees.Single();
var model = comp1.GetSemanticModel(tree);
var nodes = tree.GetCompilationUnitRoot().DescendantNodes();
var aa = nodes.OfType<DeclarationExpressionSyntax>().ElementAt(0);
Assert.Equal("var (a, a)", aa.ToString());
var aaType = model.GetTypeInfo(aa).Type.GetSymbol();
Assert.True(aaType.TupleElementNames.IsDefault);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_06()
{
string source1 = @"
using var = System.Int32;
(var (a,b), var c);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_06_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
(var (a,b), var c) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_06_VerifySemanticModel(comp2);
}
private static void StandAlone_06_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(System.Int32 a, System.Int32 b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[0].Type).ToTestDisplayString());
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 Script.c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[1].Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_07()
{
string source1 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (_, _), var _);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_07_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
class C
{
static void Main()
{
(var (_, _), var _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_07_VerifySemanticModel(comp2);
}
private static void StandAlone_07_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var (_, _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(System.Int32, System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[0].Type).ToTestDisplayString());
Assert.Equal("var _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("var=System.Int32", model.GetAliasInfo(declarations[1].Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_08()
{
string source1 = @"
using var = System.Int32;
(var (_, _), var _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_07_VerifySemanticModel(comp1);
string source2 = @"
using var = System.Int32;
(var (_, _), var _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_07_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_09()
{
string source1 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (a,b), al c);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_09_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (a,b), al c) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_09_VerifySemanticModel(comp2);
}
private static void StandAlone_09_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declaration = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Single();
Assert.Equal("al c", declaration.ToString());
var typeInfo = model.GetTypeInfo(declaration);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration).IsIdentity);
Assert.Equal("System.Int32 c", model.GetSymbolInfo(declaration).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declaration.Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration.Type).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declaration.Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("al=System.Int32", model.GetAliasInfo(declaration.Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_10()
{
string source1 = @"
using al = System.Int32;
(al (a,b), al c);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_10_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
(al (a,b), al c) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_10_VerifySemanticModel(comp2);
}
private static void StandAlone_10_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declaration = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Single();
Assert.Equal("al c", declaration.ToString());
var typeInfo = model.GetTypeInfo(declaration);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration).IsIdentity);
Assert.Equal("System.Int32 Script.c", model.GetSymbolInfo(declaration).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declaration.Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration.Type).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declaration.Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("al=System.Int32", model.GetAliasInfo(declaration.Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_11()
{
string source1 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (_, _), al _);
}
}
";
var comp1 = CreateCompilation(source1);
StandAlone_11_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
class C
{
static void Main()
{
(al (_, _), al _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_11_VerifySemanticModel(comp2);
}
private static void StandAlone_11_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var declaration = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Single();
Assert.Equal("al _", declaration.ToString());
var typeInfo = model.GetTypeInfo(declaration);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declaration);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declaration.Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declaration.Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declaration.Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Equal("al=System.Int32", model.GetAliasInfo(declaration.Type).ToTestDisplayString());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_12()
{
string source1 = @"
using al = System.Int32;
(al (_, _), al _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
StandAlone_11_VerifySemanticModel(comp1);
string source2 = @"
using al = System.Int32;
(al (_, _), al _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_11_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_13()
{
string source1 = @"
class C
{
static void Main()
{
var (a, b);
var (c, d)
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (7,19): error CS1002: ; expected
// var (c, d)
Diagnostic(ErrorCode.ERR_SemicolonExpected, "").WithLocation(7, 19),
// (6,9): error CS0103: The name 'var' does not exist in the current context
// var (a, b);
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(6, 9),
// (6,14): error CS0103: The name 'a' does not exist in the current context
// var (a, b);
Diagnostic(ErrorCode.ERR_NameNotInContext, "a").WithArguments("a").WithLocation(6, 14),
// (6,17): error CS0103: The name 'b' does not exist in the current context
// var (a, b);
Diagnostic(ErrorCode.ERR_NameNotInContext, "b").WithArguments("b").WithLocation(6, 17),
// (7,9): error CS0103: The name 'var' does not exist in the current context
// var (c, d)
Diagnostic(ErrorCode.ERR_NameNotInContext, "var").WithArguments("var").WithLocation(7, 9),
// (7,14): error CS0103: The name 'c' does not exist in the current context
// var (c, d)
Diagnostic(ErrorCode.ERR_NameNotInContext, "c").WithArguments("c").WithLocation(7, 14),
// (7,17): error CS0103: The name 'd' does not exist in the current context
// var (c, d)
Diagnostic(ErrorCode.ERR_NameNotInContext, "d").WithArguments("d").WithLocation(7, 17)
);
var tree = comp1.SyntaxTrees.First();
Assert.False(tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any());
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_14()
{
string source1 = @"
class C
{
static void Main()
{
((var (a,b), var c), int d);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,11): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)").WithLocation(6, 11),
// (6,22): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c").WithLocation(6, 22),
// (6,30): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(6, 30),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (a,b), var c), int d)").WithLocation(6, 9),
// (6,30): error CS0165: Use of unassigned local variable 'd'
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_UseDefViolation, "int d").WithArguments("d").WithLocation(6, 30)
);
StandAlone_14_VerifySemanticModel(comp1, LocalDeclarationKind.DeclarationExpressionVariable);
string source2 = @"
class C
{
static void Main()
{
((var (a,b), var c), int d) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_14_VerifySemanticModel(comp2, LocalDeclarationKind.DeconstructionVariable);
}
private static void StandAlone_14_VerifySemanticModel(CSharpCompilation comp, LocalDeclarationKind localDeclarationKind)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var a", a.ToTestDisplayString());
Assert.Equal(localDeclarationKind, a.GetSymbol<LocalSymbol>().DeclarationKind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var b", b.ToTestDisplayString());
Assert.Equal(localDeclarationKind, b.GetSymbol<LocalSymbol>().DeclarationKind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var c", c.ToTestDisplayString());
Assert.Equal(localDeclarationKind, c.GetSymbol<LocalSymbol>().DeclarationKind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 d", d.ToTestDisplayString());
Assert.Equal(localDeclarationKind, d.GetSymbol<LocalSymbol>().DeclarationKind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuples = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().ToArray();
Assert.Equal(2, tuples.Length);
Assert.Equal("((var (a,b), var c), int d)", tuples[0].ToString());
typeInfo = model.GetTypeInfo(tuples[0]);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[0]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("(var (a,b), var c)", tuples[1].ToString());
typeInfo = model.GetTypeInfo(tuples[1]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_15()
{
string source1 = @"
((var (a,b), var c), int d);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,8): error CS7019: Type of 'a' cannot be inferred since its initializer directly or indirectly refers to the definition.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "a").WithArguments("a").WithLocation(2, 8),
// (2,10): error CS7019: Type of 'b' cannot be inferred since its initializer directly or indirectly refers to the definition.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "b").WithArguments("b").WithLocation(2, 10),
// (2,18): error CS7019: Type of 'c' cannot be inferred since its initializer directly or indirectly refers to the definition.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "c").WithArguments("c").WithLocation(2, 18),
// (2,3): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (a,b)").WithLocation(2, 3),
// (2,14): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var c").WithLocation(2, 14),
// (2,22): error CS8185: A declaration is not allowed in this context.
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(2, 22),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (a,b), var c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (a,b), var c), int d)").WithLocation(2, 1)
);
StandAlone_15_VerifySemanticModel(comp1);
string source2 = @"
((var (a,b), var c), int d) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_15_VerifySemanticModel(comp2);
}
private static void StandAlone_15_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var Script.a", a.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, a.Kind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var Script.b", b.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, b.Kind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var Script.c", c.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, c.Kind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 Script.d", d.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, d.Kind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (a,b)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var a, var b)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var c", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("var Script.c", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int d", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
Assert.Equal("System.Int32 Script.d", model.GetSymbolInfo(declarations[2]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuples = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().ToArray();
Assert.Equal(2, tuples.Length);
Assert.Equal("((var (a,b), var c), int d)", tuples[0].ToString());
typeInfo = model.GetTypeInfo(tuples[0]);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[0]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("(var (a,b), var c)", tuples[1].ToString());
typeInfo = model.GetTypeInfo(tuples[1]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_16()
{
string source1 = @"
class C
{
static void Main()
{
((var (_, _), var _), int _);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,11): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)").WithLocation(6, 11),
// (6,23): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _").WithLocation(6, 23),
// (6,31): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(6, 31),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (_, _), var _), int _)").WithLocation(6, 9)
);
StandAlone_16_VerifySemanticModel(comp1);
string source2 = @"
class C
{
static void Main()
{
((var (_, _), var _), int _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_16_VerifySemanticModel(comp2);
}
private static void StandAlone_16_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
int count = 0;
foreach (var designation in tree.GetCompilationUnitRoot().DescendantNodes().OfType<DiscardDesignationSyntax>())
{
Assert.Null(model.GetDeclaredSymbol(designation));
count++;
}
Assert.Equal(4, count);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(3, declarations.Count());
Assert.Equal("var (_, _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("(var, var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("var _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("var", typeInfo.Type.ToTestDisplayString());
Assert.Equal(SymbolKind.ErrorType, typeInfo.Type.Kind);
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[1].Type));
Assert.Equal("int _", declarations[2].ToString());
typeInfo = model.GetTypeInfo(declarations[2]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[2].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[2].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[2].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[2].Type));
var tuples = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().ToArray();
Assert.Equal(2, tuples.Length);
Assert.Equal("((var (_, _), var _), int _)", tuples[0].ToString());
typeInfo = model.GetTypeInfo(tuples[0]);
Assert.Equal("(((var, var), var), System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[0]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Equal("(var (_, _), var _)", tuples[1].ToString());
typeInfo = model.GetTypeInfo(tuples[1]);
Assert.Equal("((var, var), var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuples[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuples[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_17()
{
string source1 = @"
((var (_, _), var _), int _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,3): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var (_, _)").WithLocation(2, 3),
// (2,15): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var _").WithLocation(2, 15),
// (2,23): error CS8185: A declaration is not allowed in this context.
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(2, 23),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// ((var (_, _), var _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (_, _), var _), int _)").WithLocation(2, 1)
);
StandAlone_16_VerifySemanticModel(comp1);
string source2 = @"
((var (_, _), var _), int _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_16_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_18()
{
string source1 = @"
class C
{
static void Main()
{
(var ((a,b), c), int d);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((a,b), c)").WithLocation(6, 10),
// (6,26): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(6, 26),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((a,b), c), int d)").WithLocation(6, 9),
// (6,26): error CS0165: Use of unassigned local variable 'd'
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_UseDefViolation, "int d").WithArguments("d").WithLocation(6, 26)
);
StandAlone_18_VerifySemanticModel(comp1, LocalDeclarationKind.DeclarationExpressionVariable);
string source2 = @"
class C
{
static void Main()
{
(var ((a,b), c), int d) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_18_VerifySemanticModel(comp2, LocalDeclarationKind.DeconstructionVariable);
}
private static void StandAlone_18_VerifySemanticModel(CSharpCompilation comp, LocalDeclarationKind localDeclarationKind)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var a", a.ToTestDisplayString());
Assert.Equal(localDeclarationKind, a.GetSymbol<LocalSymbol>().DeclarationKind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var b", b.ToTestDisplayString());
Assert.Equal(localDeclarationKind, b.GetSymbol<LocalSymbol>().DeclarationKind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var c", c.ToTestDisplayString());
Assert.Equal(localDeclarationKind, c.GetSymbol<LocalSymbol>().DeclarationKind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 d", d.ToTestDisplayString());
Assert.Equal(localDeclarationKind, d.GetSymbol<LocalSymbol>().DeclarationKind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var ((a,b), c)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("int d", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 d", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[1].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_19()
{
string source1 = @"
(var ((a,b), c), int d);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,8): error CS7019: Type of 'a' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "a").WithArguments("a").WithLocation(2, 8),
// (2,10): error CS7019: Type of 'b' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "b").WithArguments("b").WithLocation(2, 10),
// (2,14): error CS7019: Type of 'c' cannot be inferred since its initializer directly or indirectly refers to the definition.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_RecursivelyTypedVariable, "c").WithArguments("c").WithLocation(2, 14),
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((a,b), c)").WithLocation(2, 2),
// (2,18): error CS8185: A declaration is not allowed in this context.
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int d").WithLocation(2, 18),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((a,b), c), int d);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((a,b), c), int d)").WithLocation(2, 1)
);
StandAlone_19_VerifySemanticModel(comp1);
string source2 = @"
(var ((a,b), c), int d) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_19_VerifySemanticModel(comp2);
}
private static void StandAlone_19_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
var designations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<SingleVariableDesignationSyntax>().ToArray();
Assert.Equal(4, designations.Count());
var a = model.GetDeclaredSymbol(designations[0]);
Assert.Equal("var Script.a", a.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, a.Kind);
var b = model.GetDeclaredSymbol(designations[1]);
Assert.Equal("var Script.b", b.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, b.Kind);
var c = model.GetDeclaredSymbol(designations[2]);
Assert.Equal("var Script.c", c.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, c.Kind);
var d = model.GetDeclaredSymbol(designations[3]);
Assert.Equal("System.Int32 Script.d", d.ToTestDisplayString());
Assert.Equal(SymbolKind.Field, d.Kind);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var ((a,b), c)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("((var a, var b), var c)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("int d", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
Assert.Equal("System.Int32 Script.d", model.GetSymbolInfo(declarations[1]).Symbol.ToTestDisplayString());
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[1].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("(((var a, var b), var c), System.Int32 d)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_20()
{
string source1 = @"
class C
{
static void Main()
{
(var ((_, _), _), int _);
}
}
";
var comp1 = CreateCompilation(source1);
comp1.VerifyDiagnostics(
// (6,10): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((_, _), _)").WithLocation(6, 10),
// (6,27): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(6, 27),
// (6,9): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((_, _), _), int _)").WithLocation(6, 9)
);
StandAlone_20_VerifySemanticModel(comp1);
string source2 = @"
class C
{
static void Main()
{
(var ((_, _), _), int _) = D;
}
}
";
var comp2 = CreateCompilation(source2);
StandAlone_20_VerifySemanticModel(comp2);
}
private static void StandAlone_20_VerifySemanticModel(CSharpCompilation comp)
{
var tree = comp.SyntaxTrees.First();
var model = comp.GetSemanticModel(tree);
int count = 0;
foreach (var designation in tree.GetCompilationUnitRoot().DescendantNodes().OfType<DiscardDesignationSyntax>())
{
Assert.Null(model.GetDeclaredSymbol(designation));
count++;
}
Assert.Equal(4, count);
var declarations = tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().ToArray();
Assert.Equal(2, declarations.Count());
Assert.Equal("var ((_, _), _)", declarations[0].ToString());
var typeInfo = model.GetTypeInfo(declarations[0]);
Assert.Equal("((var, var), var)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0]).IsIdentity);
var symbolInfo = model.GetSymbolInfo(declarations[0]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[0].Type);
Assert.Null(typeInfo.Type);
Assert.Null(typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[0].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[0].Type);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
Assert.Null(model.GetAliasInfo(declarations[0].Type));
Assert.Equal("int _", declarations[1].ToString());
typeInfo = model.GetTypeInfo(declarations[1]);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1]).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1]);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
typeInfo = model.GetTypeInfo(declarations[1].Type);
Assert.Equal("System.Int32", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(declarations[1].Type).IsIdentity);
symbolInfo = model.GetSymbolInfo(declarations[1].Type);
Assert.Equal("System.Int32", symbolInfo.Symbol.ToTestDisplayString());
Assert.Null(model.GetAliasInfo(declarations[1].Type));
var tuple = tree.GetCompilationUnitRoot().DescendantNodes().OfType<TupleExpressionSyntax>().Single();
typeInfo = model.GetTypeInfo(tuple);
Assert.Equal("(((var, var), var), System.Int32)", typeInfo.Type.ToTestDisplayString());
Assert.Equal(typeInfo.Type, typeInfo.ConvertedType);
Assert.True(model.GetConversion(tuple).IsIdentity);
symbolInfo = model.GetSymbolInfo(tuple);
Assert.Null(symbolInfo.Symbol);
Assert.Empty(symbolInfo.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbolInfo.CandidateReason);
}
[Fact, WorkItem(17572, "https://github.com/dotnet/roslyn/issues/17572")]
public void StandAlone_21()
{
string source1 = @"
(var ((_, _), _), int _);
";
var comp1 = CreateCompilation(source1, parseOptions: TestOptions.Script);
comp1.VerifyDiagnostics(
// (2,2): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "var ((_, _), _)").WithLocation(2, 2),
// (2,19): error CS8185: A declaration is not allowed in this context.
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_DeclarationExpressionNotPermitted, "int _").WithLocation(2, 19),
// (2,1): error CS0201: Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement
// (var ((_, _), _), int _);
Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((_, _), _), int _)").WithLocation(2, 1)
);
StandAlone_20_VerifySemanticModel(comp1);
string source2 = @"
(var ((_, _), _), int _) = D;
";
var comp2 = CreateCompilation(source2, parseOptions: TestOptions.Script);
StandAlone_20_VerifySemanticModel(comp2);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DiscardVoid_01()
{
var source = @"class C
{
static void Main()
{
(_, _) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,22): error CS8210: A tuple may not contain a value of type 'void'.
// (_, _) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 22)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_01()
{
var source = @"class C
{
static void Main()
{
(int x, void y) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,17): error CS1547: Keyword 'void' cannot be used in this context
// (int x, void y) = (1, Main());
Diagnostic(ErrorCode.ERR_NoVoidHere, "void").WithLocation(5, 17),
// (5,31): error CS8210: A tuple may not contain a value of type 'void'.
// (int x, void y) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 31)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_02()
{
var source = @"class C
{
static void Main()
{
var (x, y) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,26): error CS8210: A tuple may not contain a value of type 'void'.
// var (x, y) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 26)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_03()
{
var source = @"class C
{
static void Main()
{
(int x, void y) = (1, 2);
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,17): error CS1547: Keyword 'void' cannot be used in this context
// (int x, void y) = (1, 2);
Diagnostic(ErrorCode.ERR_NoVoidHere, "void").WithLocation(5, 17),
// (5,31): error CS0029: Cannot implicitly convert type 'int' to 'void'
// (int x, void y) = (1, 2);
Diagnostic(ErrorCode.ERR_NoImplicitConv, "2").WithArguments("int", "void").WithLocation(5, 31)
);
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var two = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "2").Single();
var type = model.GetTypeInfo(two);
Assert.Equal(SpecialType.System_Int32, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Int32, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(two).Kind);
var symbols = model.GetSymbolInfo(two);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)two.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[Fact, WorkItem(17921, "https://github.com/dotnet/roslyn/issues/17921")]
public void DeconstructVoid_04()
{
var source = @"class C
{
static void Main()
{
(int x, int y) = (1, Main());
}
}";
var comp = CreateCompilation(source);
comp.VerifyDiagnostics(
// (5,30): error CS8210: A tuple may not contain a value of type 'void'.
// (int x, int y) = (1, Main());
Diagnostic(ErrorCode.ERR_VoidInTuple, "Main()").WithLocation(5, 30)
);
var main = comp.GetMember<MethodSymbol>("C.Main");
var tree = comp.SyntaxTrees[0];
var model = comp.GetSemanticModel(tree);
var mainCall = tree.GetRoot().DescendantNodes().OfType<ExpressionSyntax>().Where(n => n.ToString() == "Main()").Single();
var type = model.GetTypeInfo(mainCall);
Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Assert.Equal(ConversionKind.Identity, model.GetConversion(mainCall).Kind);
var symbols = model.GetSymbolInfo(mainCall);
Assert.Equal(symbols.Symbol, main.GetPublicSymbol());
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
// the ArgumentSyntax above a tuple element doesn't support GetTypeInfo or GetSymbolInfo.
var argument = (ArgumentSyntax)mainCall.Parent;
type = model.GetTypeInfo(argument);
Assert.Null(type.Type);
Assert.Null(type.ConvertedType);
symbols = model.GetSymbolInfo(argument);
Assert.Null(symbols.Symbol);
Assert.Empty(symbols.CandidateSymbols);
Assert.Equal(CandidateReason.None, symbols.CandidateReason);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DiscardDeclarationExpression_IOperation()
{
string source = @"
class C
{
void M()
{
/*<bind>*/var (_, _) = (0, 0)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32, System.Int32)) (Syntax: 'var (_, _) = (0, 0)')
Left:
IDeclarationExpressionOperation (OperationKind.DeclarationExpression, Type: (System.Int32, System.Int32)) (Syntax: 'var (_, _)')
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(_, _)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: '_')
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: '_')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(0, 0)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DiscardDeclarationAssignment_IOperation()
{
string source = @"
class C
{
void M()
{
int x;
/*<bind>*/(x, _) = (0, 0)/*</bind>*/;
}
}
";
string expectedOperationTree = @"
IDeconstructionAssignmentOperation (OperationKind.DeconstructionAssignment, Type: (System.Int32 x, System.Int32)) (Syntax: '(x, _) = (0, 0)')
Left:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32 x, System.Int32)) (Syntax: '(x, _)')
NaturalType: (System.Int32 x, System.Int32)
Elements(2):
ILocalReferenceOperation: x (OperationKind.LocalReference, Type: System.Int32) (Syntax: 'x')
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: '_')
Right:
ITupleOperation (OperationKind.Tuple, Type: (System.Int32, System.Int32)) (Syntax: '(0, 0)')
NaturalType: (System.Int32, System.Int32)
Elements(2):
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
ILiteralOperation (OperationKind.Literal, Type: System.Int32, Constant: 0) (Syntax: '0')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<AssignmentExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[CompilerTrait(CompilerFeature.IOperation)]
[Fact]
public void DiscardOutVarDeclaration_IOperation()
{
string source = @"
class C
{
void M()
{
M2(out /*<bind>*/var _/*</bind>*/);
}
void M2(out int x)
{
x = 0;
}
}
";
string expectedOperationTree = @"
IDiscardOperation (Symbol: System.Int32 _) (OperationKind.Discard, Type: System.Int32) (Syntax: 'var _')
";
var expectedDiagnostics = DiagnosticDescription.None;
VerifyOperationTreeAndDiagnosticsForTest<DeclarationExpressionSyntax>(source, expectedOperationTree, expectedDiagnostics);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_1()
{
var text = @"
class C
{
static void Main()
{
foreach ((var i, i))
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,18): error CS8186: A foreach loop must declare its iteration variables.
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_MustDeclareForeachIteration, "(var i, i)").WithLocation(6, 18),
// (6,23): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'i'.
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "i").WithArguments("i").WithLocation(6, 23),
// (6,26): error CS0841: Cannot use local variable 'i' before it is declared
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "i").WithArguments("i").WithLocation(6, 26),
// (6,28): error CS1515: 'in' expected
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_InExpected, ")").WithLocation(6, 28),
// (6,28): error CS1525: Invalid expression term ')'
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ")").WithArguments(")").WithLocation(6, 28),
// (6,29): error CS1525: Invalid expression term '}'
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "").WithArguments("}").WithLocation(6, 29),
// (6,29): error CS1002: ; expected
// foreach ((var i, i))
Diagnostic(ErrorCode.ERR_SemicolonExpected, "").WithLocation(6, 29)
);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_2()
{
var text = @"
class C
{
static void Main()
{
(var i, i) = ;
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,14): error CS8130: Cannot infer the type of implicitly-typed deconstruction variable 'i'.
// (var i, i) = ;
Diagnostic(ErrorCode.ERR_TypeInferenceFailedForImplicitlyTypedDeconstructionVariable, "i").WithArguments("i").WithLocation(6, 14),
// (6,17): error CS0841: Cannot use local variable 'i' before it is declared
// (var i, i) = ;
Diagnostic(ErrorCode.ERR_VariableUsedBeforeDeclaration, "i").WithArguments("i").WithLocation(6, 17),
// (6,22): error CS1525: Invalid expression term ';'
// (var i, i) = ;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ";").WithArguments(";").WithLocation(6, 22)
);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_3()
{
var text = @"
class C
{
static void Main()
{
foreach ((int i, i))
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,18): error CS8186: A foreach loop must declare its iteration variables.
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_MustDeclareForeachIteration, "(int i, i)").WithLocation(6, 18),
// (6,26): error CS1656: Cannot assign to 'i' because it is a 'foreach iteration variable'
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_AssgReadonlyLocalCause, "i").WithArguments("i", "foreach iteration variable").WithLocation(6, 26),
// (6,28): error CS1515: 'in' expected
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_InExpected, ")").WithLocation(6, 28),
// (6,28): error CS1525: Invalid expression term ')'
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ")").WithArguments(")").WithLocation(6, 28),
// (6,29): error CS1525: Invalid expression term '}'
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_InvalidExprTerm, "").WithArguments("}").WithLocation(6, 29),
// (6,29): error CS1002: ; expected
// foreach ((int i, i))
Diagnostic(ErrorCode.ERR_SemicolonExpected, "").WithLocation(6, 29)
);
}
[Fact]
[WorkItem(46165, "https://github.com/dotnet/roslyn/issues/46165")]
public void Issue46165_4()
{
var text = @"
class C
{
static void Main()
{
(int i, i) = ;
}
}";
CreateCompilation(text).VerifyEmitDiagnostics(
// (6,22): error CS1525: Invalid expression term ';'
// (int i, i) = ;
Diagnostic(ErrorCode.ERR_InvalidExprTerm, ";").WithArguments(";").WithLocation(6, 22)
);
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/CSharp/Test/Symbol/Symbols/AssemblyAndNamespaceTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Linq;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Test.Utilities;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.CSharp.UnitTests
{
public class ContainerTests : CSharpTestBase
{
[Fact]
public void SimpleAssembly()
{
var text = @"namespace N
{
class A {}
}
";
var simpleName = GetUniqueName();
var comp = CreateCompilation(text, assemblyName: simpleName);
var sym = comp.Assembly;
// See bug 2058: the following lines assume System.Reflection.AssemblyName preserves the case of
// the "displayName" passed to it, but it sometimes does not.
Assert.Equal(simpleName, sym.Name, StringComparer.OrdinalIgnoreCase);
Assert.Equal(simpleName + ", Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", sym.ToTestDisplayString(), StringComparer.OrdinalIgnoreCase);
Assert.Equal(String.Empty, sym.GlobalNamespace.Name);
Assert.Equal(SymbolKind.Assembly, sym.Kind);
Assert.Equal(Accessibility.NotApplicable, sym.DeclaredAccessibility);
Assert.False(sym.IsStatic);
Assert.False(sym.IsVirtual);
Assert.False(sym.IsOverride);
Assert.False(sym.IsAbstract);
Assert.False(sym.IsSealed);
Assert.False(sym.IsExtern);
Assert.Null(sym.ContainingAssembly);
Assert.Null(sym.ContainingSymbol);
}
[Theory, MemberData(nameof(FileScopedOrBracedNamespace)), WorkItem(1979, "DevDiv_Projects/Roslyn"), WorkItem(2026, "DevDiv_Projects/Roslyn"), WorkItem(544009, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544009")]
public void SourceModule(string ob, string cb)
{
var text = @"namespace NS.NS1.NS2
" + ob + @"
class A {}
" + cb + @"
";
var comp = CreateCompilation(text, assemblyName: "Test");
var sym = comp.SourceModule;
Assert.Equal("Test.dll", sym.Name);
// Bug: 2026
Assert.Equal("Test.dll", sym.ToDisplayString());
Assert.Equal(String.Empty, sym.GlobalNamespace.Name);
Assert.Equal(SymbolKind.NetModule, sym.Kind);
Assert.Equal(Accessibility.NotApplicable, sym.DeclaredAccessibility);
Assert.False(sym.IsStatic);
Assert.False(sym.IsVirtual);
Assert.False(sym.IsOverride);
Assert.False(sym.IsAbstract);
Assert.False(sym.IsSealed);
Assert.Equal("Test", sym.ContainingAssembly.Name);
Assert.Equal("Test", sym.ContainingSymbol.Name);
var ns = comp.GlobalNamespace.GetMembers("NS").Single() as NamespaceSymbol;
var ns1 = (ns.GetMembers("NS1").Single() as NamespaceSymbol).GetMembers("NS2").Single() as NamespaceSymbol;
// NamespaceExtent
var ext = ns1.Extent;
Assert.Equal(NamespaceKind.Module, ext.Kind);
Assert.Equal(1, ns1.ConstituentNamespaces.Length);
Assert.Same(ns1, ns1.ConstituentNamespaces[0]);
// Bug: 1979
Assert.Equal("Module: Test.dll", ext.ToString());
}
[Fact]
public void SimpleNamespace()
{
var text = @"namespace N1
{
namespace N11 {
namespace N111 {
class A {}
}
}
}
namespace N1 {
struct S {}
}
";
var text1 = @"namespace N1
{
namespace N11 {
namespace N111 {
class B {}
}
}
}
";
var text2 = @"namespace N1
namespace N12 {
struct S {}
}
}
";
var comp1 = CSharpCompilation.Create(assemblyName: "Test", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text) }, references: new MetadataReference[] { });
var compRef = new CSharpCompilationReference(comp1);
var comp = CSharpCompilation.Create(assemblyName: "Test1", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1), SyntaxFactory.ParseSyntaxTree(text2) },
references: new MetadataReference[] { compRef });
var global = comp.GlobalNamespace;
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(1, ns.GetTypeMembers().Length); // S
Assert.Equal(3, ns.GetMembers().Length); // N11, N12, S
var ns1 = (ns.GetMembers("N11").Single() as NamespaceSymbol).GetMembers("N111").Single() as NamespaceSymbol;
Assert.Equal(2, ns1.GetTypeMembers().Length); // A & B
}
[Fact]
public void UsingAliasForNamespace()
{
var text = @"using Gen = System.Collections.Generic;
namespace NS {
public interface IGoo {}
}
namespace NS.NS1 {
using F = NS.IGoo;
class A : F { }
}
";
var text1 = @"namespace NS.NS1 {
public class B {
protected Gen.List<int> field;
}
}
";
var text2 = @"namespace NS {
namespace NS2 {
using NN = NS.NS1;
class C : NN.B { }
}
}
";
var comp1 = CreateCompilation(text);
var compRef = new CSharpCompilationReference(comp1);
var comp = CSharpCompilation.Create(assemblyName: "Test1", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1), SyntaxFactory.ParseSyntaxTree(text2) },
references: new MetadataReference[] { compRef });
var global = comp.GlobalNamespace;
var ns = global.GetMembers("NS").Single() as NamespaceSymbol;
Assert.Equal(1, ns.GetTypeMembers().Length); // IGoo
Assert.Equal(3, ns.GetMembers().Length); // NS1, NS2, IGoo
var ns1 = ns.GetMembers("NS1").Single() as NamespaceSymbol;
var type1 = ns1.GetTypeMembers("A").SingleOrDefault() as NamedTypeSymbol;
Assert.Equal(1, type1.Interfaces().Length);
Assert.Equal("IGoo", type1.Interfaces()[0].Name);
var ns2 = ns.GetMembers("NS2").Single() as NamespaceSymbol;
var type2 = ns2.GetTypeMembers("C").SingleOrDefault() as NamedTypeSymbol;
Assert.NotNull(type2.BaseType());
Assert.Equal("NS.NS1.B", type2.BaseType().ToTestDisplayString());
}
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void MultiModulesNamespace(string ob, string cb)
{
var text1 = @"namespace N1
" + ob + @"
class A {}
" + cb + @"
";
var text2 = @"namespace N1
" + ob + @"
interface IGoo {}
" + cb + @"
";
var text3 = @"namespace N1
" + ob + @"
struct SGoo {}
" + cb + @"
";
var comp1 = CreateCompilation(text1, assemblyName: "Compilation1");
var comp2 = CreateCompilation(text2, assemblyName: "Compilation2");
var compRef1 = new CSharpCompilationReference(comp1);
var compRef2 = new CSharpCompilationReference(comp2);
var comp = CreateEmptyCompilation(new string[] { text3 }, references: new MetadataReference[] { compRef1, compRef2 }.ToList(), assemblyName: "Test3");
//Compilation.Create(outputName: "Test3", options: CompilationOptions.Default,
// syntaxTrees: new SyntaxTree[] { SyntaxTree.ParseCompilationUnit(text3) },
// references: new MetadataReference[] { compRef1, compRef2 });
var global = comp.GlobalNamespace; // throw
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(3, ns.GetTypeMembers().Length); // A, IGoo & SGoo
Assert.Equal(NamespaceKind.Compilation, ns.Extent.Kind);
var constituents = ns.ConstituentNamespaces;
Assert.Equal(3, constituents.Length);
Assert.True(constituents.Contains(comp.SourceAssembly.GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef1).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef2).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
foreach (var constituentNs in constituents)
{
Assert.Equal(NamespaceKind.Module, constituentNs.Extent.Kind);
Assert.Equal(ns.ToTestDisplayString(), constituentNs.ToTestDisplayString());
}
}
[WorkItem(537287, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/537287")]
[Fact]
public void MultiModulesNamespaceCorLibraries()
{
var text1 = @"namespace N1
{
class A {}
}
";
var text2 = @"namespace N1
{
interface IGoo {}
}
";
var text3 = @"namespace N1
{
struct SGoo {}
}
";
var comp1 = CSharpCompilation.Create(assemblyName: "Test1", options: TestOptions.DebugExe, syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1) }, references: new MetadataReference[] { });
var comp2 = CSharpCompilation.Create(assemblyName: "Test2", options: TestOptions.DebugExe, syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text2) }, references: new MetadataReference[] { });
var compRef1 = new CSharpCompilationReference(comp1);
var compRef2 = new CSharpCompilationReference(comp2);
var comp = CSharpCompilation.Create(assemblyName: "Test3", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text3) },
references: new MetadataReference[] { compRef1, compRef2 });
var global = comp.GlobalNamespace; // throw
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(3, ns.GetTypeMembers().Length); // A, IGoo & SGoo
Assert.Equal(NamespaceKind.Compilation, ns.Extent.Kind);
var constituents = ns.ConstituentNamespaces;
Assert.Equal(3, constituents.Length);
Assert.True(constituents.Contains(comp.SourceAssembly.GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef1).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef2).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
}
/// Container with nested types and non-type members with the same name
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void ClassWithNestedTypesAndMembersWithSameName(string ob, string cb)
{
var text1 = @"namespace N1
" + ob + @"
class A
{
class b
{
}
class b<T>
{
}
int b;
int b() {}
int b(string s){}
}
" + cb + @"
";
var comp = CSharpCompilation.Create(
assemblyName: "Test1",
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1) },
references: new MetadataReference[] { });
var global = comp.GlobalNamespace; // throw
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(1, ns.GetTypeMembers().Length); // A
var b = ns.GetTypeMembers("A")[0].GetMembers("b");
Assert.Equal(5, b.Length);
}
[WorkItem(537958, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/537958")]
[Fact]
public void GetDeclaredSymbolDupNsAliasErr()
{
var compilation = CreateEmptyCompilation(@"
namespace NS1 {
class A { }
}
namespace NS2 {
class B { }
}
namespace NS
{
using ns = NS1;
using ns = NS2;
class C : ns.A {}
}
");
var tree = compilation.SyntaxTrees[0];
var root = tree.GetCompilationUnitRoot();
var model = compilation.GetSemanticModel(tree);
var globalNS = compilation.SourceModule.GlobalNamespace;
var ns1 = globalNS.GetMembers("NS").Single() as NamespaceSymbol;
var type1 = ns1.GetTypeMembers("C").First() as NamedTypeSymbol;
var b = type1.BaseType();
}
[WorkItem(540785, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540785")]
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void GenericNamespace(string ob, string cb)
{
var compilation = CreateEmptyCompilation(@"
namespace Goo<T>
" + ob + @"
class Program
{
static void Main()
{
}
}
" + cb + @"
");
var global = compilation.GlobalNamespace;
var @namespace = global.GetMember<NamespaceSymbol>("Goo");
Assert.NotNull(@namespace);
var @class = @namespace.GetMember<NamedTypeSymbol>("Program");
Assert.NotNull(@class);
var method = @class.GetMember<MethodSymbol>("Main");
Assert.NotNull(method);
}
[WorkItem(690871, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/690871")]
[Fact]
public void SpecialTypesAndAliases()
{
var source = @"public class C { }";
var aliasedCorlib = TestMetadata.Net451.mscorlib.WithAliases(ImmutableArray.Create("Goo"));
var comp = CreateEmptyCompilation(source, new[] { aliasedCorlib });
// NOTE: this doesn't compile in dev11 - it reports that it cannot find System.Object.
// However, we've already changed how special type lookup works, so this is not a major issue.
comp.VerifyDiagnostics();
var objectType = comp.GetSpecialType(SpecialType.System_Object);
Assert.Equal(TypeKind.Class, objectType.TypeKind);
Assert.Equal("System.Object", objectType.ToTestDisplayString());
Assert.Equal(objectType, comp.Assembly.GetSpecialType(SpecialType.System_Object));
Assert.Equal(objectType, comp.Assembly.CorLibrary.GetSpecialType(SpecialType.System_Object));
}
[WorkItem(690871, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/690871")]
[Fact]
public void WellKnownTypesAndAliases()
{
var lib = @"
namespace System.Threading.Tasks
{
public class Task
{
public int Status;
}
}
";
var source = @"
extern alias myTask;
using System.Threading;
using System.Threading.Tasks;
class App
{
async void AM() { }
}
";
var libComp = CreateCompilationWithMscorlib45(lib, assemblyName: "lib");
var libRef = libComp.EmitToImageReference(aliases: ImmutableArray.Create("myTask"));
var comp = CreateCompilationWithMscorlib45(source, new[] { libRef });
// NOTE: As in dev11, we don't consider myTask::System.Threading.Tasks.Task to be
// ambiguous with global::System.Threading.Tasks.Task (prefer global).
comp.VerifyDiagnostics(
// (7,16): warning CS1998: This async method lacks 'await' operators and will run synchronously. Consider using the 'await' operator to await non-blocking API calls, or 'await Task.Run(...)' to do CPU-bound work on a background thread.
// async void AM() { }
Diagnostic(ErrorCode.WRN_AsyncLacksAwaits, "AM"),
// (3,1): info CS8019: Unnecessary using directive.
// using System.Threading;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading;"),
// (4,1): info CS8019: Unnecessary using directive.
// using System.Threading.Tasks;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading.Tasks;"),
// (2,1): info CS8020: Unused extern alias.
// extern alias myTask;
Diagnostic(ErrorCode.HDN_UnusedExternAlias, "extern alias myTask;"));
var taskType = comp.GetWellKnownType(WellKnownType.System_Threading_Tasks_Task);
Assert.Equal(TypeKind.Class, taskType.TypeKind);
Assert.Equal("System.Threading.Tasks.Task", taskType.ToTestDisplayString());
// When we look in a single assembly, we don't consider referenced assemblies.
Assert.Null(comp.Assembly.GetTypeByMetadataName("System.Threading.Tasks.Task"));
Assert.Equal(taskType, comp.Assembly.CorLibrary.GetTypeByMetadataName("System.Threading.Tasks.Task"));
}
[WorkItem(863435, "DevDiv/Personal")]
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void CS1671ERR_BadModifiersOnNamespace01(string ob, string cb)
{
var test = @"
public namespace NS // CS1671
" + ob + @"
class Test
{
public static int Main()
{
return 1;
}
}
" + cb + @"
";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,1): error CS1671: A namespace declaration cannot have modifiers or attributes
Diagnostic(ErrorCode.ERR_BadModifiersOnNamespace, "public").WithLocation(2, 1));
}
[Fact]
public void CS1671ERR_BadModifiersOnNamespace02()
{
var test = @"[System.Obsolete]
namespace N { }
";
CreateCompilationWithMscorlib45(test).VerifyDiagnostics(
// (2,1): error CS1671: A namespace declaration cannot have modifiers or attributes
Diagnostic(ErrorCode.ERR_BadModifiersOnNamespace, "[System.Obsolete]").WithLocation(1, 1));
}
[Fact]
public void NamespaceWithSemicolon1()
{
var test =
@"namespace A;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void NamespaceWithSemicolon3()
{
var test =
@"namespace A.B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void MultipleFileScopedNamespaces()
{
var test =
@"namespace A;
namespace B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,11): error CS8907: Source file can only contain one file-scoped namespace declaration.
// namespace B;
Diagnostic(ErrorCode.ERR_MultipleFileScopedNamespace, "B").WithLocation(2, 11));
}
[Fact]
public void FileScopedNamespaceNestedInNormalNamespace()
{
var test =
@"namespace A
{
namespace B;
}";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,15): error CS8908: Source file can not contain both file-scoped and normal namespace declarations.
// namespace B;
Diagnostic(ErrorCode.ERR_FileScopedAndNormalNamespace, "B").WithLocation(3, 15));
}
[Fact]
public void NormalAndFileScopedNamespace1()
{
var test =
@"namespace A;
namespace B
{
}";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,11): error CS8908: error CS8908: Source file can not contain both file-scoped and normal namespace declarations.
// namespace B
Diagnostic(ErrorCode.ERR_FileScopedAndNormalNamespace, "B").WithLocation(2, 11));
}
[Fact]
public void NormalAndFileScopedNamespace2()
{
var test =
@"namespace A
{
}
namespace B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (4,11): error CS8909: File-scoped namespace must precede all other members in a file.
// namespace B;
Diagnostic(ErrorCode.ERR_FileScopedNamespaceNotBeforeAllMembers, "B").WithLocation(4, 11));
}
[Fact]
public void NamespaceWithPrecedingUsing()
{
var test =
@"using System;
namespace A;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (1,1): hidden CS8019: Unnecessary using directive.
// using System;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1));
}
[Fact]
public void NamespaceWithFollowingUsing()
{
var test =
@"namespace X;
using System;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,1): hidden CS8019: Unnecessary using directive.
// using System;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1));
}
[Fact]
public void NamespaceWithPrecedingType()
{
var test =
@"class X { }
namespace System;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,11): error CS8909: File-scoped namespace must precede all other members in a file.
// namespace System;
Diagnostic(ErrorCode.ERR_FileScopedNamespaceNotBeforeAllMembers, "System").WithLocation(2, 11));
}
[Fact]
public void NamespaceWithFollowingType()
{
var test =
@"namespace System;
class X { }";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void FileScopedNamespaceWithPrecedingStatement()
{
var test =
@"
System.Console.WriteLine();
namespace B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,11): error CS8914: File-scoped namespace must precede all other members in a file.
// namespace B;
Diagnostic(ErrorCode.ERR_FileScopedNamespaceNotBeforeAllMembers, "B").WithLocation(3, 11));
}
[Fact]
public void FileScopedNamespaceWithFollowingStatement()
{
var test =
@"
namespace B;
System.Console.WriteLine();";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,16): error CS0116: A namespace cannot directly contain members such as fields or methods
// System.Console.WriteLine();
Diagnostic(ErrorCode.ERR_NamespaceUnexpected, "WriteLine").WithLocation(3, 16),
// (3,26): error CS8124: Tuple must contain at least two elements.
// System.Console.WriteLine();
Diagnostic(ErrorCode.ERR_TupleTooFewElements, ")").WithLocation(3, 26),
// (3,27): error CS1022: Type or namespace definition, or end-of-file expected
// System.Console.WriteLine();
Diagnostic(ErrorCode.ERR_EOFExpected, ";").WithLocation(3, 27));
}
[Fact]
public void FileScopedNamespaceUsingsBeforeAndAfter()
{
var source1 = @"
namespace A
{
class C1 { }
}
namespace B
{
class C2 { }
}
";
var source2 = @"
using A;
namespace X;
using B;
class C
{
void M()
{
new C1();
new C2();
}
}
";
CreateCompilationWithMscorlib45(new[] { source1, source2 }, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void FileScopedNamespaceFollowedByVariable()
{
var test = @"
namespace B;
int x; // 1
";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,5): error CS0116: A namespace cannot directly contain members such as fields, methods or statements
// int x; // 1
Diagnostic(ErrorCode.ERR_NamespaceUnexpected, "x").WithLocation(3, 5));
}
[Fact, WorkItem(54836, "https://github.com/dotnet/roslyn/issues/54836")]
public void AssemblyRetargetableAttributeIsRespected()
{
var code = @"
using System.Reflection;
[assembly: AssemblyFlags(AssemblyNameFlags.Retargetable)]";
var comp = CreateCompilation(code);
Assert.True(comp.Assembly.Identity.IsRetargetable);
comp.VerifyEmitDiagnostics();
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Immutable;
using System.Linq;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.CSharp.Test.Utilities;
using Microsoft.CodeAnalysis.Test.Utilities;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.CSharp.UnitTests
{
public class ContainerTests : CSharpTestBase
{
[Fact]
public void SimpleAssembly()
{
var text = @"namespace N
{
class A {}
}
";
var simpleName = GetUniqueName();
var comp = CreateCompilation(text, assemblyName: simpleName);
var sym = comp.Assembly;
// See bug 2058: the following lines assume System.Reflection.AssemblyName preserves the case of
// the "displayName" passed to it, but it sometimes does not.
Assert.Equal(simpleName, sym.Name, StringComparer.OrdinalIgnoreCase);
Assert.Equal(simpleName + ", Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", sym.ToTestDisplayString(), StringComparer.OrdinalIgnoreCase);
Assert.Equal(String.Empty, sym.GlobalNamespace.Name);
Assert.Equal(SymbolKind.Assembly, sym.Kind);
Assert.Equal(Accessibility.NotApplicable, sym.DeclaredAccessibility);
Assert.False(sym.IsStatic);
Assert.False(sym.IsVirtual);
Assert.False(sym.IsOverride);
Assert.False(sym.IsAbstract);
Assert.False(sym.IsSealed);
Assert.False(sym.IsExtern);
Assert.Null(sym.ContainingAssembly);
Assert.Null(sym.ContainingSymbol);
}
[Theory, MemberData(nameof(FileScopedOrBracedNamespace)), WorkItem(1979, "DevDiv_Projects/Roslyn"), WorkItem(2026, "DevDiv_Projects/Roslyn"), WorkItem(544009, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/544009")]
public void SourceModule(string ob, string cb)
{
var text = @"namespace NS.NS1.NS2
" + ob + @"
class A {}
" + cb + @"
";
var comp = CreateCompilation(text, assemblyName: "Test");
var sym = comp.SourceModule;
Assert.Equal("Test.dll", sym.Name);
// Bug: 2026
Assert.Equal("Test.dll", sym.ToDisplayString());
Assert.Equal(String.Empty, sym.GlobalNamespace.Name);
Assert.Equal(SymbolKind.NetModule, sym.Kind);
Assert.Equal(Accessibility.NotApplicable, sym.DeclaredAccessibility);
Assert.False(sym.IsStatic);
Assert.False(sym.IsVirtual);
Assert.False(sym.IsOverride);
Assert.False(sym.IsAbstract);
Assert.False(sym.IsSealed);
Assert.Equal("Test", sym.ContainingAssembly.Name);
Assert.Equal("Test", sym.ContainingSymbol.Name);
var ns = comp.GlobalNamespace.GetMembers("NS").Single() as NamespaceSymbol;
var ns1 = (ns.GetMembers("NS1").Single() as NamespaceSymbol).GetMembers("NS2").Single() as NamespaceSymbol;
// NamespaceExtent
var ext = ns1.Extent;
Assert.Equal(NamespaceKind.Module, ext.Kind);
Assert.Equal(1, ns1.ConstituentNamespaces.Length);
Assert.Same(ns1, ns1.ConstituentNamespaces[0]);
// Bug: 1979
Assert.Equal("Module: Test.dll", ext.ToString());
}
[Fact]
public void SimpleNamespace()
{
var text = @"namespace N1
{
namespace N11 {
namespace N111 {
class A {}
}
}
}
namespace N1 {
struct S {}
}
";
var text1 = @"namespace N1
{
namespace N11 {
namespace N111 {
class B {}
}
}
}
";
var text2 = @"namespace N1
namespace N12 {
struct S {}
}
}
";
var comp1 = CSharpCompilation.Create(assemblyName: "Test", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text) }, references: new MetadataReference[] { });
var compRef = new CSharpCompilationReference(comp1);
var comp = CSharpCompilation.Create(assemblyName: "Test1", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1), SyntaxFactory.ParseSyntaxTree(text2) },
references: new MetadataReference[] { compRef });
var global = comp.GlobalNamespace;
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(1, ns.GetTypeMembers().Length); // S
Assert.Equal(3, ns.GetMembers().Length); // N11, N12, S
var ns1 = (ns.GetMembers("N11").Single() as NamespaceSymbol).GetMembers("N111").Single() as NamespaceSymbol;
Assert.Equal(2, ns1.GetTypeMembers().Length); // A & B
}
[Fact]
public void UsingAliasForNamespace()
{
var text = @"using Gen = System.Collections.Generic;
namespace NS {
public interface IGoo {}
}
namespace NS.NS1 {
using F = NS.IGoo;
class A : F { }
}
";
var text1 = @"namespace NS.NS1 {
public class B {
protected Gen.List<int> field;
}
}
";
var text2 = @"namespace NS {
namespace NS2 {
using NN = NS.NS1;
class C : NN.B { }
}
}
";
var comp1 = CreateCompilation(text);
var compRef = new CSharpCompilationReference(comp1);
var comp = CSharpCompilation.Create(assemblyName: "Test1", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1), SyntaxFactory.ParseSyntaxTree(text2) },
references: new MetadataReference[] { compRef });
var global = comp.GlobalNamespace;
var ns = global.GetMembers("NS").Single() as NamespaceSymbol;
Assert.Equal(1, ns.GetTypeMembers().Length); // IGoo
Assert.Equal(3, ns.GetMembers().Length); // NS1, NS2, IGoo
var ns1 = ns.GetMembers("NS1").Single() as NamespaceSymbol;
var type1 = ns1.GetTypeMembers("A").SingleOrDefault() as NamedTypeSymbol;
Assert.Equal(1, type1.Interfaces().Length);
Assert.Equal("IGoo", type1.Interfaces()[0].Name);
var ns2 = ns.GetMembers("NS2").Single() as NamespaceSymbol;
var type2 = ns2.GetTypeMembers("C").SingleOrDefault() as NamedTypeSymbol;
Assert.NotNull(type2.BaseType());
Assert.Equal("NS.NS1.B", type2.BaseType().ToTestDisplayString());
}
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void MultiModulesNamespace(string ob, string cb)
{
var text1 = @"namespace N1
" + ob + @"
class A {}
" + cb + @"
";
var text2 = @"namespace N1
" + ob + @"
interface IGoo {}
" + cb + @"
";
var text3 = @"namespace N1
" + ob + @"
struct SGoo {}
" + cb + @"
";
var comp1 = CreateCompilation(text1, assemblyName: "Compilation1");
var comp2 = CreateCompilation(text2, assemblyName: "Compilation2");
var compRef1 = new CSharpCompilationReference(comp1);
var compRef2 = new CSharpCompilationReference(comp2);
var comp = CreateEmptyCompilation(new string[] { text3 }, references: new MetadataReference[] { compRef1, compRef2 }.ToList(), assemblyName: "Test3");
//Compilation.Create(outputName: "Test3", options: CompilationOptions.Default,
// syntaxTrees: new SyntaxTree[] { SyntaxTree.ParseCompilationUnit(text3) },
// references: new MetadataReference[] { compRef1, compRef2 });
var global = comp.GlobalNamespace; // throw
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(3, ns.GetTypeMembers().Length); // A, IGoo & SGoo
Assert.Equal(NamespaceKind.Compilation, ns.Extent.Kind);
var constituents = ns.ConstituentNamespaces;
Assert.Equal(3, constituents.Length);
Assert.True(constituents.Contains(comp.SourceAssembly.GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef1).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef2).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
foreach (var constituentNs in constituents)
{
Assert.Equal(NamespaceKind.Module, constituentNs.Extent.Kind);
Assert.Equal(ns.ToTestDisplayString(), constituentNs.ToTestDisplayString());
}
}
[WorkItem(537287, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/537287")]
[Fact]
public void MultiModulesNamespaceCorLibraries()
{
var text1 = @"namespace N1
{
class A {}
}
";
var text2 = @"namespace N1
{
interface IGoo {}
}
";
var text3 = @"namespace N1
{
struct SGoo {}
}
";
var comp1 = CSharpCompilation.Create(assemblyName: "Test1", options: TestOptions.DebugExe, syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1) }, references: new MetadataReference[] { });
var comp2 = CSharpCompilation.Create(assemblyName: "Test2", options: TestOptions.DebugExe, syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text2) }, references: new MetadataReference[] { });
var compRef1 = new CSharpCompilationReference(comp1);
var compRef2 = new CSharpCompilationReference(comp2);
var comp = CSharpCompilation.Create(assemblyName: "Test3", options: TestOptions.DebugExe,
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text3) },
references: new MetadataReference[] { compRef1, compRef2 });
var global = comp.GlobalNamespace; // throw
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(3, ns.GetTypeMembers().Length); // A, IGoo & SGoo
Assert.Equal(NamespaceKind.Compilation, ns.Extent.Kind);
var constituents = ns.ConstituentNamespaces;
Assert.Equal(3, constituents.Length);
Assert.True(constituents.Contains(comp.SourceAssembly.GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef1).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
Assert.True(constituents.Contains(comp.GetReferencedAssemblySymbol(compRef2).GlobalNamespace.GetMembers("N1").Single() as NamespaceSymbol));
}
/// Container with nested types and non-type members with the same name
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void ClassWithNestedTypesAndMembersWithSameName(string ob, string cb)
{
var text1 = @"namespace N1
" + ob + @"
class A
{
class b
{
}
class b<T>
{
}
int b;
int b() {}
int b(string s){}
}
" + cb + @"
";
var comp = CSharpCompilation.Create(
assemblyName: "Test1",
syntaxTrees: new SyntaxTree[] { SyntaxFactory.ParseSyntaxTree(text1) },
references: new MetadataReference[] { });
var global = comp.GlobalNamespace; // throw
var ns = global.GetMembers("N1").Single() as NamespaceSymbol;
Assert.Equal(1, ns.GetTypeMembers().Length); // A
var b = ns.GetTypeMembers("A")[0].GetMembers("b");
Assert.Equal(5, b.Length);
}
[WorkItem(537958, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/537958")]
[Fact]
public void GetDeclaredSymbolDupNsAliasErr()
{
var compilation = CreateEmptyCompilation(@"
namespace NS1 {
class A { }
}
namespace NS2 {
class B { }
}
namespace NS
{
using ns = NS1;
using ns = NS2;
class C : ns.A {}
}
");
var tree = compilation.SyntaxTrees[0];
var root = tree.GetCompilationUnitRoot();
var model = compilation.GetSemanticModel(tree);
var globalNS = compilation.SourceModule.GlobalNamespace;
var ns1 = globalNS.GetMembers("NS").Single() as NamespaceSymbol;
var type1 = ns1.GetTypeMembers("C").First() as NamedTypeSymbol;
var b = type1.BaseType();
}
[WorkItem(540785, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/540785")]
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void GenericNamespace(string ob, string cb)
{
var compilation = CreateEmptyCompilation(@"
namespace Goo<T>
" + ob + @"
class Program
{
static void Main()
{
}
}
" + cb + @"
");
var global = compilation.GlobalNamespace;
var @namespace = global.GetMember<NamespaceSymbol>("Goo");
Assert.NotNull(@namespace);
var @class = @namespace.GetMember<NamedTypeSymbol>("Program");
Assert.NotNull(@class);
var method = @class.GetMember<MethodSymbol>("Main");
Assert.NotNull(method);
}
[WorkItem(690871, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/690871")]
[Fact]
public void SpecialTypesAndAliases()
{
var source = @"public class C { }";
var aliasedCorlib = TestMetadata.Net451.mscorlib.WithAliases(ImmutableArray.Create("Goo"));
var comp = CreateEmptyCompilation(source, new[] { aliasedCorlib });
// NOTE: this doesn't compile in dev11 - it reports that it cannot find System.Object.
// However, we've already changed how special type lookup works, so this is not a major issue.
comp.VerifyDiagnostics();
var objectType = comp.GetSpecialType(SpecialType.System_Object);
Assert.Equal(TypeKind.Class, objectType.TypeKind);
Assert.Equal("System.Object", objectType.ToTestDisplayString());
Assert.Equal(objectType, comp.Assembly.GetSpecialType(SpecialType.System_Object));
Assert.Equal(objectType, comp.Assembly.CorLibrary.GetSpecialType(SpecialType.System_Object));
}
[WorkItem(690871, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/690871")]
[Fact]
public void WellKnownTypesAndAliases()
{
var lib = @"
namespace System.Threading.Tasks
{
public class Task
{
public int Status;
}
}
";
var source = @"
extern alias myTask;
using System.Threading;
using System.Threading.Tasks;
class App
{
async void AM() { }
}
";
var libComp = CreateCompilationWithMscorlib45(lib, assemblyName: "lib");
var libRef = libComp.EmitToImageReference(aliases: ImmutableArray.Create("myTask"));
var comp = CreateCompilationWithMscorlib45(source, new[] { libRef });
// NOTE: As in dev11, we don't consider myTask::System.Threading.Tasks.Task to be
// ambiguous with global::System.Threading.Tasks.Task (prefer global).
comp.VerifyDiagnostics(
// (7,16): warning CS1998: This async method lacks 'await' operators and will run synchronously. Consider using the 'await' operator to await non-blocking API calls, or 'await Task.Run(...)' to do CPU-bound work on a background thread.
// async void AM() { }
Diagnostic(ErrorCode.WRN_AsyncLacksAwaits, "AM"),
// (3,1): info CS8019: Unnecessary using directive.
// using System.Threading;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading;"),
// (4,1): info CS8019: Unnecessary using directive.
// using System.Threading.Tasks;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System.Threading.Tasks;"),
// (2,1): info CS8020: Unused extern alias.
// extern alias myTask;
Diagnostic(ErrorCode.HDN_UnusedExternAlias, "extern alias myTask;"));
var taskType = comp.GetWellKnownType(WellKnownType.System_Threading_Tasks_Task);
Assert.Equal(TypeKind.Class, taskType.TypeKind);
Assert.Equal("System.Threading.Tasks.Task", taskType.ToTestDisplayString());
// When we look in a single assembly, we don't consider referenced assemblies.
Assert.Null(comp.Assembly.GetTypeByMetadataName("System.Threading.Tasks.Task"));
Assert.Equal(taskType, comp.Assembly.CorLibrary.GetTypeByMetadataName("System.Threading.Tasks.Task"));
}
[WorkItem(863435, "DevDiv/Personal")]
[Theory, MemberData(nameof(FileScopedOrBracedNamespace))]
public void CS1671ERR_BadModifiersOnNamespace01(string ob, string cb)
{
var test = @"
public namespace NS // CS1671
" + ob + @"
class Test
{
public static int Main()
{
return 1;
}
}
" + cb + @"
";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,1): error CS1671: A namespace declaration cannot have modifiers or attributes
Diagnostic(ErrorCode.ERR_BadModifiersOnNamespace, "public").WithLocation(2, 1));
}
[Fact]
public void CS1671ERR_BadModifiersOnNamespace02()
{
var test = @"[System.Obsolete]
namespace N { }
";
CreateCompilationWithMscorlib45(test).VerifyDiagnostics(
// (2,1): error CS1671: A namespace declaration cannot have modifiers or attributes
Diagnostic(ErrorCode.ERR_BadModifiersOnNamespace, "[System.Obsolete]").WithLocation(1, 1));
}
[Fact]
public void NamespaceWithSemicolon1()
{
var test =
@"namespace A;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void NamespaceWithSemicolon3()
{
var test =
@"namespace A.B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void MultipleFileScopedNamespaces()
{
var test =
@"namespace A;
namespace B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,11): error CS8907: Source file can only contain one file-scoped namespace declaration.
// namespace B;
Diagnostic(ErrorCode.ERR_MultipleFileScopedNamespace, "B").WithLocation(2, 11));
}
[Fact]
public void FileScopedNamespaceNestedInNormalNamespace()
{
var test =
@"namespace A
{
namespace B;
}";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,15): error CS8908: Source file can not contain both file-scoped and normal namespace declarations.
// namespace B;
Diagnostic(ErrorCode.ERR_FileScopedAndNormalNamespace, "B").WithLocation(3, 15));
}
[Fact]
public void NormalAndFileScopedNamespace1()
{
var test =
@"namespace A;
namespace B
{
}";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,11): error CS8908: error CS8908: Source file can not contain both file-scoped and normal namespace declarations.
// namespace B
Diagnostic(ErrorCode.ERR_FileScopedAndNormalNamespace, "B").WithLocation(2, 11));
}
[Fact]
public void NormalAndFileScopedNamespace2()
{
var test =
@"namespace A
{
}
namespace B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (4,11): error CS8909: File-scoped namespace must precede all other members in a file.
// namespace B;
Diagnostic(ErrorCode.ERR_FileScopedNamespaceNotBeforeAllMembers, "B").WithLocation(4, 11));
}
[Fact]
public void NamespaceWithPrecedingUsing()
{
var test =
@"using System;
namespace A;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (1,1): hidden CS8019: Unnecessary using directive.
// using System;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(1, 1));
}
[Fact]
public void NamespaceWithFollowingUsing()
{
var test =
@"namespace X;
using System;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,1): hidden CS8019: Unnecessary using directive.
// using System;
Diagnostic(ErrorCode.HDN_UnusedUsingDirective, "using System;").WithLocation(2, 1));
}
[Fact]
public void NamespaceWithPrecedingType()
{
var test =
@"class X { }
namespace System;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (2,11): error CS8909: File-scoped namespace must precede all other members in a file.
// namespace System;
Diagnostic(ErrorCode.ERR_FileScopedNamespaceNotBeforeAllMembers, "System").WithLocation(2, 11));
}
[Fact]
public void NamespaceWithFollowingType()
{
var test =
@"namespace System;
class X { }";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void FileScopedNamespaceWithPrecedingStatement()
{
var test =
@"
System.Console.WriteLine();
namespace B;";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,11): error CS8914: File-scoped namespace must precede all other members in a file.
// namespace B;
Diagnostic(ErrorCode.ERR_FileScopedNamespaceNotBeforeAllMembers, "B").WithLocation(3, 11));
}
[Fact]
public void FileScopedNamespaceWithFollowingStatement()
{
var test =
@"
namespace B;
System.Console.WriteLine();";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,16): error CS0116: A namespace cannot directly contain members such as fields or methods
// System.Console.WriteLine();
Diagnostic(ErrorCode.ERR_NamespaceUnexpected, "WriteLine").WithLocation(3, 16),
// (3,26): error CS8124: Tuple must contain at least two elements.
// System.Console.WriteLine();
Diagnostic(ErrorCode.ERR_TupleTooFewElements, ")").WithLocation(3, 26),
// (3,27): error CS1022: Type or namespace definition, or end-of-file expected
// System.Console.WriteLine();
Diagnostic(ErrorCode.ERR_EOFExpected, ";").WithLocation(3, 27));
}
[Fact]
public void FileScopedNamespaceUsingsBeforeAndAfter()
{
var source1 = @"
namespace A
{
class C1 { }
}
namespace B
{
class C2 { }
}
";
var source2 = @"
using A;
namespace X;
using B;
class C
{
void M()
{
new C1();
new C2();
}
}
";
CreateCompilationWithMscorlib45(new[] { source1, source2 }, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics();
}
[Fact]
public void FileScopedNamespaceFollowedByVariable()
{
var test = @"
namespace B;
int x; // 1
";
CreateCompilationWithMscorlib45(test, parseOptions: TestOptions.RegularWithFileScopedNamespaces).VerifyDiagnostics(
// (3,5): error CS0116: A namespace cannot directly contain members such as fields, methods or statements
// int x; // 1
Diagnostic(ErrorCode.ERR_NamespaceUnexpected, "x").WithLocation(3, 5));
}
[Fact, WorkItem(54836, "https://github.com/dotnet/roslyn/issues/54836")]
public void AssemblyRetargetableAttributeIsRespected()
{
var code = @"
using System.Reflection;
[assembly: AssemblyFlags(AssemblyNameFlags.Retargetable)]";
var comp = CreateCompilation(code);
Assert.True(comp.Assembly.Identity.IsRetargetable);
comp.VerifyEmitDiagnostics();
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/Core/Portable/CommandLine/CommandLineParser.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Text;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis
{
public abstract class CommandLineParser
{
private readonly CommonMessageProvider _messageProvider;
internal readonly bool IsScriptCommandLineParser;
private static readonly char[] s_searchPatternTrimChars = new char[] { '\t', '\n', '\v', '\f', '\r', ' ', '\x0085', '\x00a0' };
internal const string ErrorLogOptionFormat = "<file>[,version={1|1.0|2|2.1}]";
internal CommandLineParser(CommonMessageProvider messageProvider, bool isScriptCommandLineParser)
{
RoslynDebug.Assert(messageProvider != null);
_messageProvider = messageProvider;
IsScriptCommandLineParser = isScriptCommandLineParser;
}
internal CommonMessageProvider MessageProvider
{
get { return _messageProvider; }
}
protected abstract string RegularFileExtension { get; }
protected abstract string ScriptFileExtension { get; }
// internal for testing
internal virtual TextReader CreateTextFileReader(string fullPath)
{
return new StreamReader(
new FileStream(fullPath, FileMode.Open, FileAccess.Read, FileShare.Read),
detectEncodingFromByteOrderMarks: true);
}
/// <summary>
/// Enumerates files in the specified directory and subdirectories whose name matches the given pattern.
/// </summary>
/// <param name="directory">Full path of the directory to enumerate.</param>
/// <param name="fileNamePattern">File name pattern. May contain wildcards '*' (matches zero or more characters) and '?' (matches any character).</param>
/// <param name="searchOption">Specifies whether to search the specified <paramref name="directory"/> only, or all its subdirectories as well.</param>
/// <returns>Sequence of file paths.</returns>
internal virtual IEnumerable<string> EnumerateFiles(string? directory, string fileNamePattern, SearchOption searchOption)
{
if (directory is null)
{
return SpecializedCollections.EmptyEnumerable<string>();
}
Debug.Assert(PathUtilities.IsAbsolute(directory));
return Directory.EnumerateFiles(directory, fileNamePattern, searchOption);
}
internal abstract CommandLineArguments CommonParse(IEnumerable<string> args, string baseDirectory, string? sdkDirectory, string? additionalReferenceDirectories);
/// <summary>
/// Parses a command line.
/// </summary>
/// <param name="args">A collection of strings representing the command line arguments.</param>
/// <param name="baseDirectory">The base directory used for qualifying file locations.</param>
/// <param name="sdkDirectory">The directory to search for mscorlib, or null if not available.</param>
/// <param name="additionalReferenceDirectories">A string representing additional reference paths.</param>
/// <returns>a <see cref="CommandLineArguments"/> object representing the parsed command line.</returns>
public CommandLineArguments Parse(IEnumerable<string> args, string baseDirectory, string? sdkDirectory, string? additionalReferenceDirectories)
{
return CommonParse(args, baseDirectory, sdkDirectory, additionalReferenceDirectories);
}
internal static bool IsOptionName(string optionName, ReadOnlyMemory<char> value) =>
IsOptionName(optionName, value.Span);
internal static bool IsOptionName(string shortOptionName, string longOptionName, ReadOnlyMemory<char> value) =>
IsOptionName(shortOptionName, value) || IsOptionName(longOptionName, value);
/// <summary>
/// Determines if a <see cref="ReadOnlySpan{Char}"/> is equal to the provided option name
/// </summary>
/// <remarks>
/// Prefer this over the Equals methods on <see cref="ReadOnlySpan{Char}"/>. The
/// <see cref="StringComparison.InvariantCultureIgnoreCase"/> implementation allocates a <see cref="String"/>.
/// The 99% case here is that we are dealing with an ASCII string that matches the input hence
/// it's worth special casing that here and falling back to the more complicated comparison
/// when dealing with non-ASCII input
/// </remarks>
internal static bool IsOptionName(string optionName, ReadOnlySpan<char> value)
{
Debug.Assert(isAllAscii(optionName.AsSpan()));
if (isAllAscii(value))
{
if (optionName.Length != value.Length)
return false;
for (int i = 0; i < optionName.Length; i++)
{
if (optionName[i] != char.ToLowerInvariant(value[i]))
{
return false;
}
}
return true;
}
return optionName.AsSpan().Equals(value, StringComparison.InvariantCultureIgnoreCase);
static bool isAllAscii(ReadOnlySpan<char> span)
{
foreach (char ch in span)
{
if (ch > 127)
return false;
}
return true;
}
}
internal static bool IsOption(string arg) => IsOption(arg.AsSpan());
internal static bool IsOption(ReadOnlySpan<char> arg) =>
arg.Length > 0 && (arg[0] == '/' || arg[0] == '-');
internal static bool IsOption(string optionName, string arg, out ReadOnlyMemory<char> name, out ReadOnlyMemory<char>? value) =>
TryParseOption(arg, out name, out value) &&
IsOptionName(optionName, name);
internal static bool TryParseOption(string arg, [NotNullWhen(true)] out string? name, out string? value)
{
if (TryParseOption(arg, out ReadOnlyMemory<char> nameMemory, out ReadOnlyMemory<char>? valueMemory))
{
name = nameMemory.ToString().ToLowerInvariant();
value = valueMemory?.ToString();
return true;
}
name = null;
value = null;
return false;
}
internal static bool TryParseOption(string arg, out ReadOnlyMemory<char> name, out ReadOnlyMemory<char>? value)
{
if (!IsOption(arg))
{
name = default;
value = null;
return false;
}
// handle stdin operator
if (arg == "-")
{
name = arg.AsMemory();
value = null;
return true;
}
int colon = arg.IndexOf(':');
// temporary heuristic to detect Unix-style rooted paths
// pattern /goo/* or //* will not be treated as a compiler option
//
// TODO: consider introducing "/s:path" to disambiguate paths starting with /
if (arg.Length > 1 && arg[0] != '-')
{
int separator = arg.IndexOf('/', 1);
if (separator > 0 && (colon < 0 || separator < colon))
{
// "/goo/
// "//
name = default;
value = null;
return false;
}
}
var argMemory = arg.AsMemory();
if (colon >= 0)
{
name = argMemory.Slice(1, colon - 1);
value = argMemory.Slice(colon + 1);
}
else
{
name = argMemory.Slice(1);
value = null;
}
return true;
}
internal ErrorLogOptions? ParseErrorLogOptions(
ReadOnlyMemory<char> arg,
IList<Diagnostic> diagnostics,
string? baseDirectory,
out bool diagnosticAlreadyReported)
{
diagnosticAlreadyReported = false;
var parts = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
try
{
ParseSeparatedStrings(arg, s_pathSeparators, removeEmptyEntries: true, parts);
if (parts.Count == 0 || parts[0].Length == 0)
{
return null;
}
string? path = ParseGenericPathToFile(parts[0].ToString(), diagnostics, baseDirectory);
if (path is null)
{
// ParseGenericPathToFile already reported the failure, so the caller should not
// report its own failure.
diagnosticAlreadyReported = true;
return null;
}
const char ParameterNameValueSeparator = '=';
SarifVersion sarifVersion = SarifVersion.Default;
if (parts.Count > 1 && parts[1].Length > 0)
{
string part = parts[1].ToString();
string versionParameterDesignator = "version" + ParameterNameValueSeparator;
int versionParameterDesignatorLength = versionParameterDesignator.Length;
if (!(
part.Length > versionParameterDesignatorLength &&
part.Substring(0, versionParameterDesignatorLength).Equals(versionParameterDesignator, StringComparison.OrdinalIgnoreCase) &&
SarifVersionFacts.TryParse(part.Substring(versionParameterDesignatorLength), out sarifVersion)
))
{
return null;
}
}
if (parts.Count > 2)
{
return null;
}
return new ErrorLogOptions(path, sarifVersion);
}
finally
{
parts.Free();
}
}
internal static void ParseAndNormalizeFile(
string unquoted,
string? baseDirectory,
out string? outputFileName,
out string? outputDirectory,
out string invalidPath)
{
outputFileName = null;
outputDirectory = null;
invalidPath = unquoted;
string? resolvedPath = FileUtilities.ResolveRelativePath(unquoted, baseDirectory);
if (resolvedPath != null)
{
try
{
// Check some ancient reserved device names, such as COM1,..9, LPT1..9, PRN, CON, or AUX etc., and bail out earlier
// Win32 API - GetFullFileName - will resolve them, say 'COM1', as "\\.\COM1"
resolvedPath = Path.GetFullPath(resolvedPath);
// preserve possible invalid path info for diagnostic purpose
invalidPath = resolvedPath;
outputFileName = Path.GetFileName(resolvedPath);
outputDirectory = Path.GetDirectoryName(resolvedPath);
}
catch (Exception)
{
resolvedPath = null;
}
if (outputFileName != null)
{
// normalize file
outputFileName = RemoveTrailingSpacesAndDots(outputFileName);
}
}
if (resolvedPath == null ||
// NUL-terminated, non-empty, valid Unicode strings
!MetadataHelpers.IsValidMetadataIdentifier(outputDirectory) ||
!MetadataHelpers.IsValidMetadataIdentifier(outputFileName))
{
outputFileName = null;
}
}
/// <summary>
/// Trims all '.' and whitespace from the end of the path
/// </summary>
[return: NotNullIfNotNull("path")]
internal static string? RemoveTrailingSpacesAndDots(string? path)
{
if (path == null)
{
return path;
}
int length = path.Length;
for (int i = length - 1; i >= 0; i--)
{
char c = path[i];
if (!char.IsWhiteSpace(c) && c != '.')
{
return i == (length - 1) ? path : path.Substring(0, i + 1);
}
}
return string.Empty;
}
protected ImmutableArray<KeyValuePair<string, string>> ParsePathMap(string pathMap, IList<Diagnostic> errors)
{
if (pathMap.IsEmpty())
{
return ImmutableArray<KeyValuePair<string, string>>.Empty;
}
var pathMapBuilder = ArrayBuilder<KeyValuePair<string, string>>.GetInstance();
foreach (var kEqualsV in SplitWithDoubledSeparatorEscaping(pathMap, ','))
{
if (kEqualsV.IsEmpty())
{
continue;
}
var kv = SplitWithDoubledSeparatorEscaping(kEqualsV, '=');
if (kv.Length != 2)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.ERR_InvalidPathMap, kEqualsV));
continue;
}
var from = kv[0];
var to = kv[1];
if (from.Length == 0 || to.Length == 0)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.ERR_InvalidPathMap, kEqualsV));
}
else
{
from = PathUtilities.EnsureTrailingSeparator(from);
to = PathUtilities.EnsureTrailingSeparator(to);
pathMapBuilder.Add(new KeyValuePair<string, string>(from, to));
}
}
return pathMapBuilder.ToImmutableAndFree();
}
/// <summary>
/// Splits specified <paramref name="str"/> on <paramref name="separator"/>
/// treating two consecutive separators as if they were a single non-separating character.
/// E.g. "a,,b,c" split on ',' yields ["a,b", "c"].
/// </summary>
internal static string[] SplitWithDoubledSeparatorEscaping(string str, char separator)
{
if (str.Length == 0)
{
return Array.Empty<string>();
}
var result = ArrayBuilder<string>.GetInstance();
var pooledPart = PooledStringBuilder.GetInstance();
var part = pooledPart.Builder;
int i = 0;
while (i < str.Length)
{
char c = str[i++];
if (c == separator)
{
if (i < str.Length && str[i] == separator)
{
i++;
}
else
{
result.Add(part.ToString());
part.Clear();
continue;
}
}
part.Append(c);
}
result.Add(part.ToString());
pooledPart.Free();
return result.ToArrayAndFree();
}
internal void ParseOutputFile(
string value,
IList<Diagnostic> errors,
string? baseDirectory,
out string? outputFileName,
out string? outputDirectory)
{
string unquoted = RemoveQuotesAndSlashes(value);
ParseAndNormalizeFile(unquoted, baseDirectory, out outputFileName, out outputDirectory, out string? invalidPath);
if (outputFileName == null ||
!MetadataHelpers.IsValidAssemblyOrModuleName(outputFileName))
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, invalidPath));
outputFileName = null;
outputDirectory = baseDirectory;
}
}
internal string? ParsePdbPath(
string value,
IList<Diagnostic> errors,
string? baseDirectory)
{
string? pdbPath = null;
string unquoted = RemoveQuotesAndSlashes(value);
ParseAndNormalizeFile(unquoted, baseDirectory, out string? outputFileName, out string? outputDirectory, out string? invalidPath);
if (outputFileName == null ||
PathUtilities.ChangeExtension(outputFileName, extension: null).Length == 0)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, invalidPath));
}
else
{
// If outputDirectory were null, then outputFileName would be null (see ParseAndNormalizeFile)
Debug.Assert(outputDirectory is object);
pdbPath = Path.ChangeExtension(Path.Combine(outputDirectory, outputFileName), ".pdb");
}
return pdbPath;
}
internal string? ParseGenericPathToFile(
string unquoted,
IList<Diagnostic> errors,
string? baseDirectory,
bool generateDiagnostic = true)
{
string? genericPath = null;
ParseAndNormalizeFile(unquoted, baseDirectory, out string? outputFileName, out string? outputDirectory, out string? invalidPath);
if (string.IsNullOrWhiteSpace(outputFileName))
{
if (generateDiagnostic)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, invalidPath));
}
}
else
{
// If outputDirectory were null, then outputFileName would be null (see ParseAndNormalizeFile)
genericPath = Path.Combine(outputDirectory!, outputFileName);
}
return genericPath;
}
internal void FlattenArgs(
IEnumerable<string> rawArguments,
IList<Diagnostic> diagnostics,
ArrayBuilder<string> processedArgs,
List<string>? scriptArgsOpt,
string? baseDirectory,
List<string>? responsePaths = null)
{
bool parsingScriptArgs = false;
bool sourceFileSeen = false;
bool optionsEnded = false;
var args = ArrayBuilder<string>.GetInstance();
args.AddRange(rawArguments);
args.ReverseContents();
var argsIndex = args.Count - 1;
while (argsIndex >= 0)
{
// EDMAURER trim off whitespace. Otherwise behavioral differences arise
// when the strings which represent args are constructed by cmd or users.
// cmd won't produce args with whitespace at the end.
string arg = args[argsIndex].TrimEnd();
argsIndex--;
if (parsingScriptArgs)
{
scriptArgsOpt!.Add(arg);
continue;
}
if (scriptArgsOpt != null)
{
// The order of the following two checks matters.
//
// Command line: Script: Script args:
// csi -- script.csx a b c script.csx ["a", "b", "c"]
// csi script.csx -- a b c script.csx ["--", "a", "b", "c"]
// csi -- @script.csx a b c @script.csx ["a", "b", "c"]
//
if (sourceFileSeen)
{
// csi/vbi: at most one script can be specified on command line, anything else is a script arg:
parsingScriptArgs = true;
scriptArgsOpt.Add(arg);
continue;
}
if (!optionsEnded && arg == "--")
{
// csi/vbi: no argument past "--" should be treated as an option/response file
optionsEnded = true;
processedArgs.Add(arg);
continue;
}
}
if (!optionsEnded && arg.StartsWith("@", StringComparison.Ordinal))
{
// response file:
string path = RemoveQuotesAndSlashes(arg.Substring(1)).TrimEnd(null);
string? resolvedPath = FileUtilities.ResolveRelativePath(path, baseDirectory);
if (resolvedPath != null)
{
parseResponseFile(resolvedPath);
if (responsePaths != null)
{
string? directory = PathUtilities.GetDirectoryName(resolvedPath);
if (directory is null)
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, path));
}
else
{
responsePaths.Add(FileUtilities.NormalizeAbsolutePath(directory));
}
}
}
else
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, path));
}
}
else
{
processedArgs.Add(arg);
sourceFileSeen |= optionsEnded || !IsOption(arg);
}
}
args.Free();
void parseResponseFile(string fullPath)
{
var stringBuilder = PooledStringBuilder.GetInstance();
var splitList = new List<string>();
try
{
Debug.Assert(PathUtilities.IsAbsolute(fullPath));
using TextReader reader = CreateTextFileReader(fullPath);
Span<char> lineBuffer = stackalloc char[256];
var lineBufferLength = 0;
while (true)
{
var ch = reader.Read();
if (ch == -1)
{
if (lineBufferLength > 0)
{
stringBuilder.Builder.Length = 0;
CommandLineUtilities.SplitCommandLineIntoArguments(
lineBuffer.Slice(0, lineBufferLength),
removeHashComments: true,
stringBuilder.Builder,
splitList,
out _);
}
break;
}
if (ch is '\r' or '\n')
{
if (ch is '\r' && reader.Peek() == '\n')
{
reader.Read();
}
stringBuilder.Builder.Length = 0;
CommandLineUtilities.SplitCommandLineIntoArguments(
lineBuffer.Slice(0, lineBufferLength),
removeHashComments: true,
stringBuilder.Builder,
splitList,
out _);
lineBufferLength = 0;
}
else
{
if (lineBufferLength >= lineBuffer.Length)
{
var temp = new char[lineBuffer.Length * 2];
lineBuffer.CopyTo(temp.AsSpan());
lineBuffer = temp;
}
lineBuffer[lineBufferLength] = (char)ch;
lineBufferLength++;
}
}
}
catch (Exception)
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.ERR_OpenResponseFile, fullPath));
return;
}
for (var i = splitList.Count - 1; i >= 0; i--)
{
var newArg = splitList[i];
// Ignores /noconfig option specified in a response file
if (!string.Equals(newArg, "/noconfig", StringComparison.OrdinalIgnoreCase) && !string.Equals(newArg, "-noconfig", StringComparison.OrdinalIgnoreCase))
{
argsIndex++;
if (argsIndex < args.Count)
{
args[argsIndex] = newArg;
}
else
{
args.Add(newArg);
}
}
else
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.WRN_NoConfigNotOnCommandLine));
}
}
stringBuilder.Free();
}
}
internal static IEnumerable<string> ParseResponseLines(IEnumerable<string> lines)
{
var arguments = new List<string>();
foreach (string line in lines)
{
arguments.AddRange(CommandLineUtilities.SplitCommandLineIntoArguments(line, removeHashComments: true));
}
return arguments;
}
/// <summary>
/// Returns false if any of the client arguments are invalid and true otherwise.
/// </summary>
/// <param name="args">
/// The original args to the client.
/// </param>
/// <param name="parsedArgs">
/// The original args minus the client args, if no errors were encountered.
/// </param>
/// <param name="containsShared">
/// Only defined if no errors were encountered.
/// True if '/shared' was an argument, false otherwise.
/// </param>
/// <param name="keepAliveValue">
/// Only defined if no errors were encountered.
/// The value to the '/keepalive' argument if one was specified, null otherwise.
/// </param>
/// <param name="errorMessage">
/// Only defined if errors were encountered.
/// The error message for the encountered error.
/// </param>
/// <param name="pipeName">
/// Only specified if <paramref name="containsShared"/> is true and the session key
/// was provided. Can be null
/// </param>
internal static bool TryParseClientArgs(
IEnumerable<string> args,
out List<string>? parsedArgs,
out bool containsShared,
out string? keepAliveValue,
out string? pipeName,
out string? errorMessage)
{
containsShared = false;
keepAliveValue = null;
errorMessage = null;
parsedArgs = null;
pipeName = null;
var newArgs = new List<string>();
foreach (var arg in args)
{
if (isClientArgsOption(arg, "keepalive", out bool hasValue, out string? value))
{
if (string.IsNullOrEmpty(value))
{
errorMessage = CodeAnalysisResources.MissingKeepAlive;
return false;
}
if (int.TryParse(value, out int intValue))
{
if (intValue < -1)
{
errorMessage = CodeAnalysisResources.KeepAliveIsTooSmall;
return false;
}
keepAliveValue = value;
}
else
{
errorMessage = CodeAnalysisResources.KeepAliveIsNotAnInteger;
return false;
}
continue;
}
if (isClientArgsOption(arg, "shared", out hasValue, out value))
{
if (hasValue)
{
if (string.IsNullOrEmpty(value))
{
errorMessage = CodeAnalysisResources.SharedArgumentMissing;
return false;
}
pipeName = value;
}
containsShared = true;
continue;
}
newArgs.Add(arg);
}
if (keepAliveValue != null && !containsShared)
{
errorMessage = CodeAnalysisResources.KeepAliveWithoutShared;
return false;
}
else
{
parsedArgs = newArgs;
return true;
}
static bool isClientArgsOption(string arg, string optionName, out bool hasValue, out string? optionValue)
{
hasValue = false;
optionValue = null;
if (arg.Length == 0 || !(arg[0] == '/' || arg[0] == '-'))
{
return false;
}
arg = arg.Substring(1);
if (!arg.StartsWith(optionName, StringComparison.OrdinalIgnoreCase))
{
return false;
}
if (arg.Length > optionName.Length)
{
if (!(arg[optionName.Length] == ':' || arg[optionName.Length] == '='))
{
return false;
}
hasValue = true;
optionValue = arg.Substring(optionName.Length + 1).Trim('"');
}
return true;
}
}
internal static string MismatchedVersionErrorText => CodeAnalysisResources.MismatchedVersion;
private static readonly char[] s_resourceSeparators = { ',' };
internal static void ParseResourceDescription(
ReadOnlyMemory<char> resourceDescriptor,
string? baseDirectory,
bool skipLeadingSeparators, //VB does this
out string? filePath,
out string? fullPath,
out string? fileName,
out string resourceName,
out string? accessibility)
{
filePath = null;
fullPath = null;
fileName = null;
resourceName = "";
accessibility = null;
// resource descriptor is: "<filePath>[,<string name>[,public|private]]"
var parts = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
ParseSeparatedStrings(resourceDescriptor, s_resourceSeparators, removeEmptyEntries: false, parts);
int offset = 0;
int length = parts.Count;
if (skipLeadingSeparators)
{
for (; offset < length && parts[offset].Length == 0; offset++)
{
}
length -= offset;
}
if (length >= 1)
{
filePath = RemoveQuotesAndSlashes(parts[offset + 0]);
}
if (length >= 2)
{
resourceName = RemoveQuotesAndSlashes(parts[offset + 1]);
}
if (length >= 3)
{
accessibility = RemoveQuotesAndSlashes(parts[offset + 2]);
}
parts.Free();
if (RoslynString.IsNullOrWhiteSpace(filePath))
{
return;
}
fileName = PathUtilities.GetFileName(filePath);
fullPath = FileUtilities.ResolveRelativePath(filePath, baseDirectory);
// The default resource name is the file name.
// Also use the file name for the name when user specifies string like "filePath,,private"
if (RoslynString.IsNullOrWhiteSpace(resourceName))
{
resourceName = fileName;
}
}
/// <summary>
/// See <see cref="CommandLineUtilities.SplitCommandLineIntoArguments(string, bool)"/>
/// </summary>
public static IEnumerable<string> SplitCommandLineIntoArguments(string commandLine, bool removeHashComments)
{
return CommandLineUtilities.SplitCommandLineIntoArguments(commandLine, removeHashComments);
}
/// <summary>
/// Remove the extraneous quotes and slashes from the argument. This function is designed to have
/// compat behavior with the native compiler.
/// </summary>
/// <remarks>
/// Mimics the function RemoveQuotes from the native C# compiler. The native VB equivalent of this
/// function is called RemoveQuotesAndSlashes. It has virtually the same behavior except for a few
/// quirks in error cases.
/// </remarks>
[return: NotNullIfNotNull(parameterName: "arg")]
internal static string? RemoveQuotesAndSlashes(string? arg) =>
arg is not null
? RemoveQuotesAndSlashes(arg.AsMemory())
: null;
internal static string RemoveQuotesAndSlashes(ReadOnlyMemory<char> argMemory) =>
RemoveQuotesAndSlashesEx(argMemory).ToString();
internal static string? RemoveQuotesAndSlashes(ReadOnlyMemory<char>? argMemory) =>
argMemory is { } m
? RemoveQuotesAndSlashesEx(m).ToString()
: null;
internal static ReadOnlyMemory<char>? RemoveQuotesAndSlashesEx(ReadOnlyMemory<char>? argMemory) =>
argMemory is { } m
? RemoveQuotesAndSlashesEx(m)
: null;
internal static ReadOnlyMemory<char> RemoveQuotesAndSlashesEx(ReadOnlyMemory<char> argMemory)
{
if (removeFastPath(argMemory) is { } m)
{
return m;
}
var pool = PooledStringBuilder.GetInstance();
var builder = pool.Builder;
var arg = argMemory.Span;
var i = 0;
while (i < arg.Length)
{
var cur = arg[i];
switch (cur)
{
case '\\':
processSlashes(builder, arg, ref i);
break;
case '"':
// Intentionally dropping quotes that don't have explicit escaping.
i++;
break;
default:
builder.Append(cur);
i++;
break;
}
}
return pool.ToStringAndFree().AsMemory();
// Mimic behavior of the native function by the same name.
static void processSlashes(StringBuilder builder, ReadOnlySpan<char> arg, ref int i)
{
RoslynDebug.Assert(arg != null);
Debug.Assert(i < arg.Length);
var slashCount = 0;
while (i < arg.Length && arg[i] == '\\')
{
slashCount++;
i++;
}
if (i < arg.Length && arg[i] == '"')
{
// Before a quote slashes are interpretted as escape sequences for other slashes so
// output one for every two.
while (slashCount >= 2)
{
builder.Append('\\');
slashCount -= 2;
}
Debug.Assert(slashCount >= 0);
// If there is an odd number of slashes then the quote is escaped and hence a part
// of the output. Otherwise it is a normal quote and can be ignored.
if (slashCount == 1)
{
// The quote is escaped so eat it.
builder.Append('"');
}
i++;
}
else
{
// Slashes that aren't followed by quotes are simply slashes.
while (slashCount > 0)
{
builder.Append('\\');
slashCount--;
}
}
}
// The 99% case when using MSBuild is that at worst a path has quotes at the start and
// end of the string but no where else. When that happens there is no need to allocate
// a new string here and instead we can just do a simple Slice on the existing
// ReadOnlyMemory object.
//
// This removes one of the largest allocation paths during command line parsing
static ReadOnlyMemory<char>? removeFastPath(ReadOnlyMemory<char> arg)
{
int start = 0;
int end = arg.Length;
var span = arg.Span;
while (end > 0 && span[end - 1] == '"')
{
end--;
}
while (start < end && span[start] == '"')
{
start++;
}
for (int i = start; i < end; i++)
{
if (span[i] == '"')
{
return null;
}
}
return arg.Slice(start, end - start);
}
}
private static readonly char[] s_pathSeparators = { ';', ',' };
private static readonly char[] s_wildcards = new[] { '*', '?' };
internal static IEnumerable<string> ParseSeparatedPaths(string arg)
{
var builder = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
ParseSeparatedPathsEx(arg.AsMemory(), builder);
return builder.ToArrayAndFree().Select(static x => x.ToString());
}
internal static void ParseSeparatedPathsEx(ReadOnlyMemory<char>? str, ArrayBuilder<ReadOnlyMemory<char>> builder)
{
ParseSeparatedStrings(str, s_pathSeparators, removeEmptyEntries: true, builder);
for (var i = 0; i < builder.Count; i++)
{
builder[i] = RemoveQuotesAndSlashesEx(builder[i]);
}
}
/// <summary>
/// Split a string by a set of separators, taking quotes into account.
/// </summary>
internal static void ParseSeparatedStrings(ReadOnlyMemory<char>? strMemory, char[] separators, bool removeEmptyEntries, ArrayBuilder<ReadOnlyMemory<char>> builder)
{
if (strMemory is null)
{
return;
}
int nextPiece = 0;
var inQuotes = false;
var memory = strMemory.Value;
var span = memory.Span;
for (int i = 0; i < span.Length; i++)
{
var c = span[i];
if (c == '\"')
{
inQuotes = !inQuotes;
}
if (!inQuotes && separators.IndexOf(c) >= 0)
{
var current = memory.Slice(nextPiece, i - nextPiece);
if (!removeEmptyEntries || current.Length > 0)
{
builder.Add(current);
}
nextPiece = i + 1;
}
}
var last = memory.Slice(nextPiece);
if (!removeEmptyEntries || last.Length > 0)
{
builder.Add(last);
}
}
internal IEnumerable<string> ResolveRelativePaths(IEnumerable<string> paths, string baseDirectory, IList<Diagnostic> errors)
{
foreach (var path in paths)
{
string? resolvedPath = FileUtilities.ResolveRelativePath(path, baseDirectory);
if (resolvedPath == null)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, path));
}
else
{
yield return resolvedPath;
}
}
}
private protected CommandLineSourceFile ToCommandLineSourceFile(string resolvedPath, bool isInputRedirected = false)
{
bool isScriptFile;
if (IsScriptCommandLineParser)
{
ReadOnlyMemory<char> extension = PathUtilities.GetExtension(resolvedPath.AsMemory());
isScriptFile = !extension.Span.Equals(RegularFileExtension.AsSpan(), StringComparison.OrdinalIgnoreCase);
}
else
{
// TODO: uncomment when fixing https://github.com/dotnet/roslyn/issues/5325
//isScriptFile = string.Equals(extension, ScriptFileExtension, StringComparison.OrdinalIgnoreCase);
isScriptFile = false;
}
return new CommandLineSourceFile(resolvedPath, isScriptFile, isInputRedirected);
}
internal void ParseFileArgument(ReadOnlyMemory<char> arg, string? baseDirectory, ArrayBuilder<string> filePathBuilder, IList<Diagnostic> errors)
{
Debug.Assert(IsScriptCommandLineParser || !arg.StartsWith('-') && !arg.StartsWith('@'));
// We remove all doubles quotes from a file name. So that, for example:
// "Path With Spaces"\goo.cs
// becomes
// Path With Spaces\goo.cs
string path = RemoveQuotesAndSlashes(arg);
int wildcard = path.IndexOfAny(s_wildcards);
if (wildcard != -1)
{
foreach (var file in ExpandFileNamePattern(path, baseDirectory, SearchOption.TopDirectoryOnly, errors))
{
filePathBuilder.Add(file);
}
}
else
{
string? resolvedPath = FileUtilities.ResolveRelativePath(path, baseDirectory);
if (resolvedPath == null)
{
errors.Add(Diagnostic.Create(MessageProvider, (int)MessageProvider.FTL_InvalidInputFileName, path));
}
else
{
filePathBuilder.Add(resolvedPath);
}
}
}
private protected void ParseSeparatedFileArgument(ReadOnlyMemory<char> value, string? baseDirectory, ArrayBuilder<string> filePathBuilder, IList<Diagnostic> errors)
{
var pathBuilder = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
ParseSeparatedPathsEx(value, pathBuilder);
foreach (ReadOnlyMemory<char> path in pathBuilder)
{
if (path.IsWhiteSpace())
{
continue;
}
ParseFileArgument(path, baseDirectory, filePathBuilder, errors);
}
pathBuilder.Free();
}
private protected IEnumerable<string> ParseSeparatedFileArgument(string value, string? baseDirectory, IList<Diagnostic> errors)
{
var builder = ArrayBuilder<string>.GetInstance();
ParseSeparatedFileArgument(value.AsMemory(), baseDirectory, builder, errors);
foreach (var filePath in builder)
{
yield return filePath;
}
builder.Free();
}
internal IEnumerable<CommandLineSourceFile> ParseRecurseArgument(string arg, string? baseDirectory, IList<Diagnostic> errors)
{
foreach (var path in ExpandFileNamePattern(arg, baseDirectory, SearchOption.AllDirectories, errors))
{
yield return ToCommandLineSourceFile(path);
}
}
internal static Encoding? TryParseEncodingName(string arg)
{
if (!string.IsNullOrWhiteSpace(arg)
&& long.TryParse(arg, NumberStyles.None, CultureInfo.InvariantCulture, out long codepage)
&& (codepage > 0))
{
try
{
return Encoding.GetEncoding((int)codepage);
}
catch (Exception)
{
return null;
}
}
return null;
}
internal static SourceHashAlgorithm TryParseHashAlgorithmName(string arg)
{
if (string.Equals("sha1", arg, StringComparison.OrdinalIgnoreCase))
{
return SourceHashAlgorithm.Sha1;
}
if (string.Equals("sha256", arg, StringComparison.OrdinalIgnoreCase))
{
return SourceHashAlgorithm.Sha256;
}
// MD5 is legacy, not supported
return SourceHashAlgorithm.None;
}
private IEnumerable<string> ExpandFileNamePattern(
string path,
string? baseDirectory,
SearchOption searchOption,
IList<Diagnostic> errors)
{
string? directory = PathUtilities.GetDirectoryName(path);
string pattern = PathUtilities.GetFileName(path);
var resolvedDirectoryPath = string.IsNullOrEmpty(directory) ?
baseDirectory :
FileUtilities.ResolveRelativePath(directory, baseDirectory);
IEnumerator<string>? enumerator = null;
try
{
bool yielded = false;
// NOTE: Directory.EnumerateFiles(...) surprisingly treats pattern "." the
// same way as "*"; as we don't expect anything to be found by this
// pattern, let's just not search in this case
pattern = pattern.Trim(s_searchPatternTrimChars);
bool singleDotPattern = string.Equals(pattern, ".", StringComparison.Ordinal);
if (!singleDotPattern)
{
while (true)
{
string? resolvedPath = null;
try
{
if (enumerator == null)
{
enumerator = EnumerateFiles(resolvedDirectoryPath, pattern, searchOption).GetEnumerator();
}
if (!enumerator.MoveNext())
{
break;
}
resolvedPath = enumerator.Current;
}
catch
{
resolvedPath = null;
}
if (resolvedPath != null)
{
// just in case EnumerateFiles returned a relative path
resolvedPath = FileUtilities.ResolveRelativePath(resolvedPath, baseDirectory);
}
if (resolvedPath == null)
{
errors.Add(Diagnostic.Create(MessageProvider, (int)MessageProvider.FTL_InvalidInputFileName, path));
break;
}
yielded = true;
yield return resolvedPath;
}
}
// the pattern didn't match any files:
if (!yielded)
{
if (searchOption == SearchOption.AllDirectories)
{
// handling /recurse
GenerateErrorForNoFilesFoundInRecurse(path, errors);
}
else
{
// handling wildcard in file spec
errors.Add(Diagnostic.Create(MessageProvider, (int)MessageProvider.ERR_FileNotFound, path));
}
}
}
finally
{
if (enumerator != null)
{
enumerator.Dispose();
}
}
}
internal abstract void GenerateErrorForNoFilesFoundInRecurse(string path, IList<Diagnostic> errors);
internal ReportDiagnostic GetDiagnosticOptionsFromRulesetFile(string? fullPath, out Dictionary<string, ReportDiagnostic> diagnosticOptions, IList<Diagnostic> diagnostics)
{
return RuleSet.GetDiagnosticOptionsFromRulesetFile(fullPath, out diagnosticOptions, diagnostics, _messageProvider);
}
/// <summary>
/// Tries to parse a UInt64 from string in either decimal, octal or hex format.
/// </summary>
/// <param name="value">The string value.</param>
/// <param name="result">The result if parsing was successful.</param>
/// <returns>true if parsing was successful, otherwise false.</returns>
internal static bool TryParseUInt64(string? value, out ulong result)
{
result = 0;
if (RoslynString.IsNullOrEmpty(value))
{
return false;
}
int numBase = 10;
if (value.StartsWith("0x", StringComparison.OrdinalIgnoreCase))
{
numBase = 16;
}
else if (value.StartsWith("0", StringComparison.OrdinalIgnoreCase))
{
numBase = 8;
}
try
{
result = Convert.ToUInt64(value, numBase);
}
catch
{
return false;
}
return true;
}
/// <summary>
/// Tries to parse a UInt16 from string in either decimal, octal or hex format.
/// </summary>
/// <param name="value">The string value.</param>
/// <param name="result">The result if parsing was successful.</param>
/// <returns>true if parsing was successful, otherwise false.</returns>
internal static bool TryParseUInt16(string? value, out ushort result)
{
result = 0;
if (RoslynString.IsNullOrEmpty(value))
{
return false;
}
int numBase = 10;
if (value.StartsWith("0x", StringComparison.OrdinalIgnoreCase))
{
numBase = 16;
}
else if (value.StartsWith("0", StringComparison.OrdinalIgnoreCase))
{
numBase = 8;
}
try
{
result = Convert.ToUInt16(value, numBase);
}
catch
{
return false;
}
return true;
}
internal static ImmutableDictionary<string, string> ParseFeatures(List<string> features)
{
var builder = ImmutableDictionary.CreateBuilder<string, string>();
CompilerOptionParseUtilities.ParseFeatures(builder, features);
return builder.ToImmutable();
}
/// <summary>
/// Sort so that more specific keys precede less specific.
/// When mapping a path we find the first key in the array that is a prefix of the path.
/// If multiple keys are prefixes of the path we want to use the longest (more specific) one for the mapping.
/// </summary>
internal static ImmutableArray<KeyValuePair<string, string>> SortPathMap(ImmutableArray<KeyValuePair<string, string>> pathMap)
=> pathMap.Sort((x, y) => -x.Key.Length.CompareTo(y.Key.Length));
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Text;
using Microsoft.CodeAnalysis.PooledObjects;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis
{
public abstract class CommandLineParser
{
private readonly CommonMessageProvider _messageProvider;
internal readonly bool IsScriptCommandLineParser;
private static readonly char[] s_searchPatternTrimChars = new char[] { '\t', '\n', '\v', '\f', '\r', ' ', '\x0085', '\x00a0' };
internal const string ErrorLogOptionFormat = "<file>[,version={1|1.0|2|2.1}]";
internal CommandLineParser(CommonMessageProvider messageProvider, bool isScriptCommandLineParser)
{
RoslynDebug.Assert(messageProvider != null);
_messageProvider = messageProvider;
IsScriptCommandLineParser = isScriptCommandLineParser;
}
internal CommonMessageProvider MessageProvider
{
get { return _messageProvider; }
}
protected abstract string RegularFileExtension { get; }
protected abstract string ScriptFileExtension { get; }
// internal for testing
internal virtual TextReader CreateTextFileReader(string fullPath)
{
return new StreamReader(
new FileStream(fullPath, FileMode.Open, FileAccess.Read, FileShare.Read),
detectEncodingFromByteOrderMarks: true);
}
/// <summary>
/// Enumerates files in the specified directory and subdirectories whose name matches the given pattern.
/// </summary>
/// <param name="directory">Full path of the directory to enumerate.</param>
/// <param name="fileNamePattern">File name pattern. May contain wildcards '*' (matches zero or more characters) and '?' (matches any character).</param>
/// <param name="searchOption">Specifies whether to search the specified <paramref name="directory"/> only, or all its subdirectories as well.</param>
/// <returns>Sequence of file paths.</returns>
internal virtual IEnumerable<string> EnumerateFiles(string? directory, string fileNamePattern, SearchOption searchOption)
{
if (directory is null)
{
return SpecializedCollections.EmptyEnumerable<string>();
}
Debug.Assert(PathUtilities.IsAbsolute(directory));
return Directory.EnumerateFiles(directory, fileNamePattern, searchOption);
}
internal abstract CommandLineArguments CommonParse(IEnumerable<string> args, string baseDirectory, string? sdkDirectory, string? additionalReferenceDirectories);
/// <summary>
/// Parses a command line.
/// </summary>
/// <param name="args">A collection of strings representing the command line arguments.</param>
/// <param name="baseDirectory">The base directory used for qualifying file locations.</param>
/// <param name="sdkDirectory">The directory to search for mscorlib, or null if not available.</param>
/// <param name="additionalReferenceDirectories">A string representing additional reference paths.</param>
/// <returns>a <see cref="CommandLineArguments"/> object representing the parsed command line.</returns>
public CommandLineArguments Parse(IEnumerable<string> args, string baseDirectory, string? sdkDirectory, string? additionalReferenceDirectories)
{
return CommonParse(args, baseDirectory, sdkDirectory, additionalReferenceDirectories);
}
internal static bool IsOptionName(string optionName, ReadOnlyMemory<char> value) =>
IsOptionName(optionName, value.Span);
internal static bool IsOptionName(string shortOptionName, string longOptionName, ReadOnlyMemory<char> value) =>
IsOptionName(shortOptionName, value) || IsOptionName(longOptionName, value);
/// <summary>
/// Determines if a <see cref="ReadOnlySpan{Char}"/> is equal to the provided option name
/// </summary>
/// <remarks>
/// Prefer this over the Equals methods on <see cref="ReadOnlySpan{Char}"/>. The
/// <see cref="StringComparison.InvariantCultureIgnoreCase"/> implementation allocates a <see cref="String"/>.
/// The 99% case here is that we are dealing with an ASCII string that matches the input hence
/// it's worth special casing that here and falling back to the more complicated comparison
/// when dealing with non-ASCII input
/// </remarks>
internal static bool IsOptionName(string optionName, ReadOnlySpan<char> value)
{
Debug.Assert(isAllAscii(optionName.AsSpan()));
if (isAllAscii(value))
{
if (optionName.Length != value.Length)
return false;
for (int i = 0; i < optionName.Length; i++)
{
if (optionName[i] != char.ToLowerInvariant(value[i]))
{
return false;
}
}
return true;
}
return optionName.AsSpan().Equals(value, StringComparison.InvariantCultureIgnoreCase);
static bool isAllAscii(ReadOnlySpan<char> span)
{
foreach (char ch in span)
{
if (ch > 127)
return false;
}
return true;
}
}
internal static bool IsOption(string arg) => IsOption(arg.AsSpan());
internal static bool IsOption(ReadOnlySpan<char> arg) =>
arg.Length > 0 && (arg[0] == '/' || arg[0] == '-');
internal static bool IsOption(string optionName, string arg, out ReadOnlyMemory<char> name, out ReadOnlyMemory<char>? value) =>
TryParseOption(arg, out name, out value) &&
IsOptionName(optionName, name);
internal static bool TryParseOption(string arg, [NotNullWhen(true)] out string? name, out string? value)
{
if (TryParseOption(arg, out ReadOnlyMemory<char> nameMemory, out ReadOnlyMemory<char>? valueMemory))
{
name = nameMemory.ToString().ToLowerInvariant();
value = valueMemory?.ToString();
return true;
}
name = null;
value = null;
return false;
}
internal static bool TryParseOption(string arg, out ReadOnlyMemory<char> name, out ReadOnlyMemory<char>? value)
{
if (!IsOption(arg))
{
name = default;
value = null;
return false;
}
// handle stdin operator
if (arg == "-")
{
name = arg.AsMemory();
value = null;
return true;
}
int colon = arg.IndexOf(':');
// temporary heuristic to detect Unix-style rooted paths
// pattern /goo/* or //* will not be treated as a compiler option
//
// TODO: consider introducing "/s:path" to disambiguate paths starting with /
if (arg.Length > 1 && arg[0] != '-')
{
int separator = arg.IndexOf('/', 1);
if (separator > 0 && (colon < 0 || separator < colon))
{
// "/goo/
// "//
name = default;
value = null;
return false;
}
}
var argMemory = arg.AsMemory();
if (colon >= 0)
{
name = argMemory.Slice(1, colon - 1);
value = argMemory.Slice(colon + 1);
}
else
{
name = argMemory.Slice(1);
value = null;
}
return true;
}
internal ErrorLogOptions? ParseErrorLogOptions(
ReadOnlyMemory<char> arg,
IList<Diagnostic> diagnostics,
string? baseDirectory,
out bool diagnosticAlreadyReported)
{
diagnosticAlreadyReported = false;
var parts = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
try
{
ParseSeparatedStrings(arg, s_pathSeparators, removeEmptyEntries: true, parts);
if (parts.Count == 0 || parts[0].Length == 0)
{
return null;
}
string? path = ParseGenericPathToFile(parts[0].ToString(), diagnostics, baseDirectory);
if (path is null)
{
// ParseGenericPathToFile already reported the failure, so the caller should not
// report its own failure.
diagnosticAlreadyReported = true;
return null;
}
const char ParameterNameValueSeparator = '=';
SarifVersion sarifVersion = SarifVersion.Default;
if (parts.Count > 1 && parts[1].Length > 0)
{
string part = parts[1].ToString();
string versionParameterDesignator = "version" + ParameterNameValueSeparator;
int versionParameterDesignatorLength = versionParameterDesignator.Length;
if (!(
part.Length > versionParameterDesignatorLength &&
part.Substring(0, versionParameterDesignatorLength).Equals(versionParameterDesignator, StringComparison.OrdinalIgnoreCase) &&
SarifVersionFacts.TryParse(part.Substring(versionParameterDesignatorLength), out sarifVersion)
))
{
return null;
}
}
if (parts.Count > 2)
{
return null;
}
return new ErrorLogOptions(path, sarifVersion);
}
finally
{
parts.Free();
}
}
internal static void ParseAndNormalizeFile(
string unquoted,
string? baseDirectory,
out string? outputFileName,
out string? outputDirectory,
out string invalidPath)
{
outputFileName = null;
outputDirectory = null;
invalidPath = unquoted;
string? resolvedPath = FileUtilities.ResolveRelativePath(unquoted, baseDirectory);
if (resolvedPath != null)
{
try
{
// Check some ancient reserved device names, such as COM1,..9, LPT1..9, PRN, CON, or AUX etc., and bail out earlier
// Win32 API - GetFullFileName - will resolve them, say 'COM1', as "\\.\COM1"
resolvedPath = Path.GetFullPath(resolvedPath);
// preserve possible invalid path info for diagnostic purpose
invalidPath = resolvedPath;
outputFileName = Path.GetFileName(resolvedPath);
outputDirectory = Path.GetDirectoryName(resolvedPath);
}
catch (Exception)
{
resolvedPath = null;
}
if (outputFileName != null)
{
// normalize file
outputFileName = RemoveTrailingSpacesAndDots(outputFileName);
}
}
if (resolvedPath == null ||
// NUL-terminated, non-empty, valid Unicode strings
!MetadataHelpers.IsValidMetadataIdentifier(outputDirectory) ||
!MetadataHelpers.IsValidMetadataIdentifier(outputFileName))
{
outputFileName = null;
}
}
/// <summary>
/// Trims all '.' and whitespace from the end of the path
/// </summary>
[return: NotNullIfNotNull("path")]
internal static string? RemoveTrailingSpacesAndDots(string? path)
{
if (path == null)
{
return path;
}
int length = path.Length;
for (int i = length - 1; i >= 0; i--)
{
char c = path[i];
if (!char.IsWhiteSpace(c) && c != '.')
{
return i == (length - 1) ? path : path.Substring(0, i + 1);
}
}
return string.Empty;
}
protected ImmutableArray<KeyValuePair<string, string>> ParsePathMap(string pathMap, IList<Diagnostic> errors)
{
if (pathMap.IsEmpty())
{
return ImmutableArray<KeyValuePair<string, string>>.Empty;
}
var pathMapBuilder = ArrayBuilder<KeyValuePair<string, string>>.GetInstance();
foreach (var kEqualsV in SplitWithDoubledSeparatorEscaping(pathMap, ','))
{
if (kEqualsV.IsEmpty())
{
continue;
}
var kv = SplitWithDoubledSeparatorEscaping(kEqualsV, '=');
if (kv.Length != 2)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.ERR_InvalidPathMap, kEqualsV));
continue;
}
var from = kv[0];
var to = kv[1];
if (from.Length == 0 || to.Length == 0)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.ERR_InvalidPathMap, kEqualsV));
}
else
{
from = PathUtilities.EnsureTrailingSeparator(from);
to = PathUtilities.EnsureTrailingSeparator(to);
pathMapBuilder.Add(new KeyValuePair<string, string>(from, to));
}
}
return pathMapBuilder.ToImmutableAndFree();
}
/// <summary>
/// Splits specified <paramref name="str"/> on <paramref name="separator"/>
/// treating two consecutive separators as if they were a single non-separating character.
/// E.g. "a,,b,c" split on ',' yields ["a,b", "c"].
/// </summary>
internal static string[] SplitWithDoubledSeparatorEscaping(string str, char separator)
{
if (str.Length == 0)
{
return Array.Empty<string>();
}
var result = ArrayBuilder<string>.GetInstance();
var pooledPart = PooledStringBuilder.GetInstance();
var part = pooledPart.Builder;
int i = 0;
while (i < str.Length)
{
char c = str[i++];
if (c == separator)
{
if (i < str.Length && str[i] == separator)
{
i++;
}
else
{
result.Add(part.ToString());
part.Clear();
continue;
}
}
part.Append(c);
}
result.Add(part.ToString());
pooledPart.Free();
return result.ToArrayAndFree();
}
internal void ParseOutputFile(
string value,
IList<Diagnostic> errors,
string? baseDirectory,
out string? outputFileName,
out string? outputDirectory)
{
string unquoted = RemoveQuotesAndSlashes(value);
ParseAndNormalizeFile(unquoted, baseDirectory, out outputFileName, out outputDirectory, out string? invalidPath);
if (outputFileName == null ||
!MetadataHelpers.IsValidAssemblyOrModuleName(outputFileName))
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, invalidPath));
outputFileName = null;
outputDirectory = baseDirectory;
}
}
internal string? ParsePdbPath(
string value,
IList<Diagnostic> errors,
string? baseDirectory)
{
string? pdbPath = null;
string unquoted = RemoveQuotesAndSlashes(value);
ParseAndNormalizeFile(unquoted, baseDirectory, out string? outputFileName, out string? outputDirectory, out string? invalidPath);
if (outputFileName == null ||
PathUtilities.ChangeExtension(outputFileName, extension: null).Length == 0)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, invalidPath));
}
else
{
// If outputDirectory were null, then outputFileName would be null (see ParseAndNormalizeFile)
Debug.Assert(outputDirectory is object);
pdbPath = Path.ChangeExtension(Path.Combine(outputDirectory, outputFileName), ".pdb");
}
return pdbPath;
}
internal string? ParseGenericPathToFile(
string unquoted,
IList<Diagnostic> errors,
string? baseDirectory,
bool generateDiagnostic = true)
{
string? genericPath = null;
ParseAndNormalizeFile(unquoted, baseDirectory, out string? outputFileName, out string? outputDirectory, out string? invalidPath);
if (string.IsNullOrWhiteSpace(outputFileName))
{
if (generateDiagnostic)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, invalidPath));
}
}
else
{
// If outputDirectory were null, then outputFileName would be null (see ParseAndNormalizeFile)
genericPath = Path.Combine(outputDirectory!, outputFileName);
}
return genericPath;
}
internal void FlattenArgs(
IEnumerable<string> rawArguments,
IList<Diagnostic> diagnostics,
ArrayBuilder<string> processedArgs,
List<string>? scriptArgsOpt,
string? baseDirectory,
List<string>? responsePaths = null)
{
bool parsingScriptArgs = false;
bool sourceFileSeen = false;
bool optionsEnded = false;
var args = ArrayBuilder<string>.GetInstance();
args.AddRange(rawArguments);
args.ReverseContents();
var argsIndex = args.Count - 1;
while (argsIndex >= 0)
{
// EDMAURER trim off whitespace. Otherwise behavioral differences arise
// when the strings which represent args are constructed by cmd or users.
// cmd won't produce args with whitespace at the end.
string arg = args[argsIndex].TrimEnd();
argsIndex--;
if (parsingScriptArgs)
{
scriptArgsOpt!.Add(arg);
continue;
}
if (scriptArgsOpt != null)
{
// The order of the following two checks matters.
//
// Command line: Script: Script args:
// csi -- script.csx a b c script.csx ["a", "b", "c"]
// csi script.csx -- a b c script.csx ["--", "a", "b", "c"]
// csi -- @script.csx a b c @script.csx ["a", "b", "c"]
//
if (sourceFileSeen)
{
// csi/vbi: at most one script can be specified on command line, anything else is a script arg:
parsingScriptArgs = true;
scriptArgsOpt.Add(arg);
continue;
}
if (!optionsEnded && arg == "--")
{
// csi/vbi: no argument past "--" should be treated as an option/response file
optionsEnded = true;
processedArgs.Add(arg);
continue;
}
}
if (!optionsEnded && arg.StartsWith("@", StringComparison.Ordinal))
{
// response file:
string path = RemoveQuotesAndSlashes(arg.Substring(1)).TrimEnd(null);
string? resolvedPath = FileUtilities.ResolveRelativePath(path, baseDirectory);
if (resolvedPath != null)
{
parseResponseFile(resolvedPath);
if (responsePaths != null)
{
string? directory = PathUtilities.GetDirectoryName(resolvedPath);
if (directory is null)
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, path));
}
else
{
responsePaths.Add(FileUtilities.NormalizeAbsolutePath(directory));
}
}
}
else
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, path));
}
}
else
{
processedArgs.Add(arg);
sourceFileSeen |= optionsEnded || !IsOption(arg);
}
}
args.Free();
void parseResponseFile(string fullPath)
{
var stringBuilder = PooledStringBuilder.GetInstance();
var splitList = new List<string>();
try
{
Debug.Assert(PathUtilities.IsAbsolute(fullPath));
using TextReader reader = CreateTextFileReader(fullPath);
Span<char> lineBuffer = stackalloc char[256];
var lineBufferLength = 0;
while (true)
{
var ch = reader.Read();
if (ch == -1)
{
if (lineBufferLength > 0)
{
stringBuilder.Builder.Length = 0;
CommandLineUtilities.SplitCommandLineIntoArguments(
lineBuffer.Slice(0, lineBufferLength),
removeHashComments: true,
stringBuilder.Builder,
splitList,
out _);
}
break;
}
if (ch is '\r' or '\n')
{
if (ch is '\r' && reader.Peek() == '\n')
{
reader.Read();
}
stringBuilder.Builder.Length = 0;
CommandLineUtilities.SplitCommandLineIntoArguments(
lineBuffer.Slice(0, lineBufferLength),
removeHashComments: true,
stringBuilder.Builder,
splitList,
out _);
lineBufferLength = 0;
}
else
{
if (lineBufferLength >= lineBuffer.Length)
{
var temp = new char[lineBuffer.Length * 2];
lineBuffer.CopyTo(temp.AsSpan());
lineBuffer = temp;
}
lineBuffer[lineBufferLength] = (char)ch;
lineBufferLength++;
}
}
}
catch (Exception)
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.ERR_OpenResponseFile, fullPath));
return;
}
for (var i = splitList.Count - 1; i >= 0; i--)
{
var newArg = splitList[i];
// Ignores /noconfig option specified in a response file
if (!string.Equals(newArg, "/noconfig", StringComparison.OrdinalIgnoreCase) && !string.Equals(newArg, "-noconfig", StringComparison.OrdinalIgnoreCase))
{
argsIndex++;
if (argsIndex < args.Count)
{
args[argsIndex] = newArg;
}
else
{
args.Add(newArg);
}
}
else
{
diagnostics.Add(Diagnostic.Create(_messageProvider, _messageProvider.WRN_NoConfigNotOnCommandLine));
}
}
stringBuilder.Free();
}
}
internal static IEnumerable<string> ParseResponseLines(IEnumerable<string> lines)
{
var arguments = new List<string>();
foreach (string line in lines)
{
arguments.AddRange(CommandLineUtilities.SplitCommandLineIntoArguments(line, removeHashComments: true));
}
return arguments;
}
/// <summary>
/// Returns false if any of the client arguments are invalid and true otherwise.
/// </summary>
/// <param name="args">
/// The original args to the client.
/// </param>
/// <param name="parsedArgs">
/// The original args minus the client args, if no errors were encountered.
/// </param>
/// <param name="containsShared">
/// Only defined if no errors were encountered.
/// True if '/shared' was an argument, false otherwise.
/// </param>
/// <param name="keepAliveValue">
/// Only defined if no errors were encountered.
/// The value to the '/keepalive' argument if one was specified, null otherwise.
/// </param>
/// <param name="errorMessage">
/// Only defined if errors were encountered.
/// The error message for the encountered error.
/// </param>
/// <param name="pipeName">
/// Only specified if <paramref name="containsShared"/> is true and the session key
/// was provided. Can be null
/// </param>
internal static bool TryParseClientArgs(
IEnumerable<string> args,
out List<string>? parsedArgs,
out bool containsShared,
out string? keepAliveValue,
out string? pipeName,
out string? errorMessage)
{
containsShared = false;
keepAliveValue = null;
errorMessage = null;
parsedArgs = null;
pipeName = null;
var newArgs = new List<string>();
foreach (var arg in args)
{
if (isClientArgsOption(arg, "keepalive", out bool hasValue, out string? value))
{
if (string.IsNullOrEmpty(value))
{
errorMessage = CodeAnalysisResources.MissingKeepAlive;
return false;
}
if (int.TryParse(value, out int intValue))
{
if (intValue < -1)
{
errorMessage = CodeAnalysisResources.KeepAliveIsTooSmall;
return false;
}
keepAliveValue = value;
}
else
{
errorMessage = CodeAnalysisResources.KeepAliveIsNotAnInteger;
return false;
}
continue;
}
if (isClientArgsOption(arg, "shared", out hasValue, out value))
{
if (hasValue)
{
if (string.IsNullOrEmpty(value))
{
errorMessage = CodeAnalysisResources.SharedArgumentMissing;
return false;
}
pipeName = value;
}
containsShared = true;
continue;
}
newArgs.Add(arg);
}
if (keepAliveValue != null && !containsShared)
{
errorMessage = CodeAnalysisResources.KeepAliveWithoutShared;
return false;
}
else
{
parsedArgs = newArgs;
return true;
}
static bool isClientArgsOption(string arg, string optionName, out bool hasValue, out string? optionValue)
{
hasValue = false;
optionValue = null;
if (arg.Length == 0 || !(arg[0] == '/' || arg[0] == '-'))
{
return false;
}
arg = arg.Substring(1);
if (!arg.StartsWith(optionName, StringComparison.OrdinalIgnoreCase))
{
return false;
}
if (arg.Length > optionName.Length)
{
if (!(arg[optionName.Length] == ':' || arg[optionName.Length] == '='))
{
return false;
}
hasValue = true;
optionValue = arg.Substring(optionName.Length + 1).Trim('"');
}
return true;
}
}
internal static string MismatchedVersionErrorText => CodeAnalysisResources.MismatchedVersion;
private static readonly char[] s_resourceSeparators = { ',' };
internal static void ParseResourceDescription(
ReadOnlyMemory<char> resourceDescriptor,
string? baseDirectory,
bool skipLeadingSeparators, //VB does this
out string? filePath,
out string? fullPath,
out string? fileName,
out string resourceName,
out string? accessibility)
{
filePath = null;
fullPath = null;
fileName = null;
resourceName = "";
accessibility = null;
// resource descriptor is: "<filePath>[,<string name>[,public|private]]"
var parts = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
ParseSeparatedStrings(resourceDescriptor, s_resourceSeparators, removeEmptyEntries: false, parts);
int offset = 0;
int length = parts.Count;
if (skipLeadingSeparators)
{
for (; offset < length && parts[offset].Length == 0; offset++)
{
}
length -= offset;
}
if (length >= 1)
{
filePath = RemoveQuotesAndSlashes(parts[offset + 0]);
}
if (length >= 2)
{
resourceName = RemoveQuotesAndSlashes(parts[offset + 1]);
}
if (length >= 3)
{
accessibility = RemoveQuotesAndSlashes(parts[offset + 2]);
}
parts.Free();
if (RoslynString.IsNullOrWhiteSpace(filePath))
{
return;
}
fileName = PathUtilities.GetFileName(filePath);
fullPath = FileUtilities.ResolveRelativePath(filePath, baseDirectory);
// The default resource name is the file name.
// Also use the file name for the name when user specifies string like "filePath,,private"
if (RoslynString.IsNullOrWhiteSpace(resourceName))
{
resourceName = fileName;
}
}
/// <summary>
/// See <see cref="CommandLineUtilities.SplitCommandLineIntoArguments(string, bool)"/>
/// </summary>
public static IEnumerable<string> SplitCommandLineIntoArguments(string commandLine, bool removeHashComments)
{
return CommandLineUtilities.SplitCommandLineIntoArguments(commandLine, removeHashComments);
}
/// <summary>
/// Remove the extraneous quotes and slashes from the argument. This function is designed to have
/// compat behavior with the native compiler.
/// </summary>
/// <remarks>
/// Mimics the function RemoveQuotes from the native C# compiler. The native VB equivalent of this
/// function is called RemoveQuotesAndSlashes. It has virtually the same behavior except for a few
/// quirks in error cases.
/// </remarks>
[return: NotNullIfNotNull(parameterName: "arg")]
internal static string? RemoveQuotesAndSlashes(string? arg) =>
arg is not null
? RemoveQuotesAndSlashes(arg.AsMemory())
: null;
internal static string RemoveQuotesAndSlashes(ReadOnlyMemory<char> argMemory) =>
RemoveQuotesAndSlashesEx(argMemory).ToString();
internal static string? RemoveQuotesAndSlashes(ReadOnlyMemory<char>? argMemory) =>
argMemory is { } m
? RemoveQuotesAndSlashesEx(m).ToString()
: null;
internal static ReadOnlyMemory<char>? RemoveQuotesAndSlashesEx(ReadOnlyMemory<char>? argMemory) =>
argMemory is { } m
? RemoveQuotesAndSlashesEx(m)
: null;
internal static ReadOnlyMemory<char> RemoveQuotesAndSlashesEx(ReadOnlyMemory<char> argMemory)
{
if (removeFastPath(argMemory) is { } m)
{
return m;
}
var pool = PooledStringBuilder.GetInstance();
var builder = pool.Builder;
var arg = argMemory.Span;
var i = 0;
while (i < arg.Length)
{
var cur = arg[i];
switch (cur)
{
case '\\':
processSlashes(builder, arg, ref i);
break;
case '"':
// Intentionally dropping quotes that don't have explicit escaping.
i++;
break;
default:
builder.Append(cur);
i++;
break;
}
}
return pool.ToStringAndFree().AsMemory();
// Mimic behavior of the native function by the same name.
static void processSlashes(StringBuilder builder, ReadOnlySpan<char> arg, ref int i)
{
RoslynDebug.Assert(arg != null);
Debug.Assert(i < arg.Length);
var slashCount = 0;
while (i < arg.Length && arg[i] == '\\')
{
slashCount++;
i++;
}
if (i < arg.Length && arg[i] == '"')
{
// Before a quote slashes are interpretted as escape sequences for other slashes so
// output one for every two.
while (slashCount >= 2)
{
builder.Append('\\');
slashCount -= 2;
}
Debug.Assert(slashCount >= 0);
// If there is an odd number of slashes then the quote is escaped and hence a part
// of the output. Otherwise it is a normal quote and can be ignored.
if (slashCount == 1)
{
// The quote is escaped so eat it.
builder.Append('"');
}
i++;
}
else
{
// Slashes that aren't followed by quotes are simply slashes.
while (slashCount > 0)
{
builder.Append('\\');
slashCount--;
}
}
}
// The 99% case when using MSBuild is that at worst a path has quotes at the start and
// end of the string but no where else. When that happens there is no need to allocate
// a new string here and instead we can just do a simple Slice on the existing
// ReadOnlyMemory object.
//
// This removes one of the largest allocation paths during command line parsing
static ReadOnlyMemory<char>? removeFastPath(ReadOnlyMemory<char> arg)
{
int start = 0;
int end = arg.Length;
var span = arg.Span;
while (end > 0 && span[end - 1] == '"')
{
end--;
}
while (start < end && span[start] == '"')
{
start++;
}
for (int i = start; i < end; i++)
{
if (span[i] == '"')
{
return null;
}
}
return arg.Slice(start, end - start);
}
}
private static readonly char[] s_pathSeparators = { ';', ',' };
private static readonly char[] s_wildcards = new[] { '*', '?' };
internal static IEnumerable<string> ParseSeparatedPaths(string arg)
{
var builder = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
ParseSeparatedPathsEx(arg.AsMemory(), builder);
return builder.ToArrayAndFree().Select(static x => x.ToString());
}
internal static void ParseSeparatedPathsEx(ReadOnlyMemory<char>? str, ArrayBuilder<ReadOnlyMemory<char>> builder)
{
ParseSeparatedStrings(str, s_pathSeparators, removeEmptyEntries: true, builder);
for (var i = 0; i < builder.Count; i++)
{
builder[i] = RemoveQuotesAndSlashesEx(builder[i]);
}
}
/// <summary>
/// Split a string by a set of separators, taking quotes into account.
/// </summary>
internal static void ParseSeparatedStrings(ReadOnlyMemory<char>? strMemory, char[] separators, bool removeEmptyEntries, ArrayBuilder<ReadOnlyMemory<char>> builder)
{
if (strMemory is null)
{
return;
}
int nextPiece = 0;
var inQuotes = false;
var memory = strMemory.Value;
var span = memory.Span;
for (int i = 0; i < span.Length; i++)
{
var c = span[i];
if (c == '\"')
{
inQuotes = !inQuotes;
}
if (!inQuotes && separators.IndexOf(c) >= 0)
{
var current = memory.Slice(nextPiece, i - nextPiece);
if (!removeEmptyEntries || current.Length > 0)
{
builder.Add(current);
}
nextPiece = i + 1;
}
}
var last = memory.Slice(nextPiece);
if (!removeEmptyEntries || last.Length > 0)
{
builder.Add(last);
}
}
internal IEnumerable<string> ResolveRelativePaths(IEnumerable<string> paths, string baseDirectory, IList<Diagnostic> errors)
{
foreach (var path in paths)
{
string? resolvedPath = FileUtilities.ResolveRelativePath(path, baseDirectory);
if (resolvedPath == null)
{
errors.Add(Diagnostic.Create(_messageProvider, _messageProvider.FTL_InvalidInputFileName, path));
}
else
{
yield return resolvedPath;
}
}
}
private protected CommandLineSourceFile ToCommandLineSourceFile(string resolvedPath, bool isInputRedirected = false)
{
bool isScriptFile;
if (IsScriptCommandLineParser)
{
ReadOnlyMemory<char> extension = PathUtilities.GetExtension(resolvedPath.AsMemory());
isScriptFile = !extension.Span.Equals(RegularFileExtension.AsSpan(), StringComparison.OrdinalIgnoreCase);
}
else
{
// TODO: uncomment when fixing https://github.com/dotnet/roslyn/issues/5325
//isScriptFile = string.Equals(extension, ScriptFileExtension, StringComparison.OrdinalIgnoreCase);
isScriptFile = false;
}
return new CommandLineSourceFile(resolvedPath, isScriptFile, isInputRedirected);
}
internal void ParseFileArgument(ReadOnlyMemory<char> arg, string? baseDirectory, ArrayBuilder<string> filePathBuilder, IList<Diagnostic> errors)
{
Debug.Assert(IsScriptCommandLineParser || !arg.StartsWith('-') && !arg.StartsWith('@'));
// We remove all doubles quotes from a file name. So that, for example:
// "Path With Spaces"\goo.cs
// becomes
// Path With Spaces\goo.cs
string path = RemoveQuotesAndSlashes(arg);
int wildcard = path.IndexOfAny(s_wildcards);
if (wildcard != -1)
{
foreach (var file in ExpandFileNamePattern(path, baseDirectory, SearchOption.TopDirectoryOnly, errors))
{
filePathBuilder.Add(file);
}
}
else
{
string? resolvedPath = FileUtilities.ResolveRelativePath(path, baseDirectory);
if (resolvedPath == null)
{
errors.Add(Diagnostic.Create(MessageProvider, (int)MessageProvider.FTL_InvalidInputFileName, path));
}
else
{
filePathBuilder.Add(resolvedPath);
}
}
}
private protected void ParseSeparatedFileArgument(ReadOnlyMemory<char> value, string? baseDirectory, ArrayBuilder<string> filePathBuilder, IList<Diagnostic> errors)
{
var pathBuilder = ArrayBuilder<ReadOnlyMemory<char>>.GetInstance();
ParseSeparatedPathsEx(value, pathBuilder);
foreach (ReadOnlyMemory<char> path in pathBuilder)
{
if (path.IsWhiteSpace())
{
continue;
}
ParseFileArgument(path, baseDirectory, filePathBuilder, errors);
}
pathBuilder.Free();
}
private protected IEnumerable<string> ParseSeparatedFileArgument(string value, string? baseDirectory, IList<Diagnostic> errors)
{
var builder = ArrayBuilder<string>.GetInstance();
ParseSeparatedFileArgument(value.AsMemory(), baseDirectory, builder, errors);
foreach (var filePath in builder)
{
yield return filePath;
}
builder.Free();
}
internal IEnumerable<CommandLineSourceFile> ParseRecurseArgument(string arg, string? baseDirectory, IList<Diagnostic> errors)
{
foreach (var path in ExpandFileNamePattern(arg, baseDirectory, SearchOption.AllDirectories, errors))
{
yield return ToCommandLineSourceFile(path);
}
}
internal static Encoding? TryParseEncodingName(string arg)
{
if (!string.IsNullOrWhiteSpace(arg)
&& long.TryParse(arg, NumberStyles.None, CultureInfo.InvariantCulture, out long codepage)
&& (codepage > 0))
{
try
{
return Encoding.GetEncoding((int)codepage);
}
catch (Exception)
{
return null;
}
}
return null;
}
internal static SourceHashAlgorithm TryParseHashAlgorithmName(string arg)
{
if (string.Equals("sha1", arg, StringComparison.OrdinalIgnoreCase))
{
return SourceHashAlgorithm.Sha1;
}
if (string.Equals("sha256", arg, StringComparison.OrdinalIgnoreCase))
{
return SourceHashAlgorithm.Sha256;
}
// MD5 is legacy, not supported
return SourceHashAlgorithm.None;
}
private IEnumerable<string> ExpandFileNamePattern(
string path,
string? baseDirectory,
SearchOption searchOption,
IList<Diagnostic> errors)
{
string? directory = PathUtilities.GetDirectoryName(path);
string pattern = PathUtilities.GetFileName(path);
var resolvedDirectoryPath = string.IsNullOrEmpty(directory) ?
baseDirectory :
FileUtilities.ResolveRelativePath(directory, baseDirectory);
IEnumerator<string>? enumerator = null;
try
{
bool yielded = false;
// NOTE: Directory.EnumerateFiles(...) surprisingly treats pattern "." the
// same way as "*"; as we don't expect anything to be found by this
// pattern, let's just not search in this case
pattern = pattern.Trim(s_searchPatternTrimChars);
bool singleDotPattern = string.Equals(pattern, ".", StringComparison.Ordinal);
if (!singleDotPattern)
{
while (true)
{
string? resolvedPath = null;
try
{
if (enumerator == null)
{
enumerator = EnumerateFiles(resolvedDirectoryPath, pattern, searchOption).GetEnumerator();
}
if (!enumerator.MoveNext())
{
break;
}
resolvedPath = enumerator.Current;
}
catch
{
resolvedPath = null;
}
if (resolvedPath != null)
{
// just in case EnumerateFiles returned a relative path
resolvedPath = FileUtilities.ResolveRelativePath(resolvedPath, baseDirectory);
}
if (resolvedPath == null)
{
errors.Add(Diagnostic.Create(MessageProvider, (int)MessageProvider.FTL_InvalidInputFileName, path));
break;
}
yielded = true;
yield return resolvedPath;
}
}
// the pattern didn't match any files:
if (!yielded)
{
if (searchOption == SearchOption.AllDirectories)
{
// handling /recurse
GenerateErrorForNoFilesFoundInRecurse(path, errors);
}
else
{
// handling wildcard in file spec
errors.Add(Diagnostic.Create(MessageProvider, (int)MessageProvider.ERR_FileNotFound, path));
}
}
}
finally
{
if (enumerator != null)
{
enumerator.Dispose();
}
}
}
internal abstract void GenerateErrorForNoFilesFoundInRecurse(string path, IList<Diagnostic> errors);
internal ReportDiagnostic GetDiagnosticOptionsFromRulesetFile(string? fullPath, out Dictionary<string, ReportDiagnostic> diagnosticOptions, IList<Diagnostic> diagnostics)
{
return RuleSet.GetDiagnosticOptionsFromRulesetFile(fullPath, out diagnosticOptions, diagnostics, _messageProvider);
}
/// <summary>
/// Tries to parse a UInt64 from string in either decimal, octal or hex format.
/// </summary>
/// <param name="value">The string value.</param>
/// <param name="result">The result if parsing was successful.</param>
/// <returns>true if parsing was successful, otherwise false.</returns>
internal static bool TryParseUInt64(string? value, out ulong result)
{
result = 0;
if (RoslynString.IsNullOrEmpty(value))
{
return false;
}
int numBase = 10;
if (value.StartsWith("0x", StringComparison.OrdinalIgnoreCase))
{
numBase = 16;
}
else if (value.StartsWith("0", StringComparison.OrdinalIgnoreCase))
{
numBase = 8;
}
try
{
result = Convert.ToUInt64(value, numBase);
}
catch
{
return false;
}
return true;
}
/// <summary>
/// Tries to parse a UInt16 from string in either decimal, octal or hex format.
/// </summary>
/// <param name="value">The string value.</param>
/// <param name="result">The result if parsing was successful.</param>
/// <returns>true if parsing was successful, otherwise false.</returns>
internal static bool TryParseUInt16(string? value, out ushort result)
{
result = 0;
if (RoslynString.IsNullOrEmpty(value))
{
return false;
}
int numBase = 10;
if (value.StartsWith("0x", StringComparison.OrdinalIgnoreCase))
{
numBase = 16;
}
else if (value.StartsWith("0", StringComparison.OrdinalIgnoreCase))
{
numBase = 8;
}
try
{
result = Convert.ToUInt16(value, numBase);
}
catch
{
return false;
}
return true;
}
internal static ImmutableDictionary<string, string> ParseFeatures(List<string> features)
{
var builder = ImmutableDictionary.CreateBuilder<string, string>();
CompilerOptionParseUtilities.ParseFeatures(builder, features);
return builder.ToImmutable();
}
/// <summary>
/// Sort so that more specific keys precede less specific.
/// When mapping a path we find the first key in the array that is a prefix of the path.
/// If multiple keys are prefixes of the path we want to use the longest (more specific) one for the mapping.
/// </summary>
internal static ImmutableArray<KeyValuePair<string, string>> SortPathMap(ImmutableArray<KeyValuePair<string, string>> pathMap)
=> pathMap.Sort((x, y) => -x.Key.Length.CompareTo(y.Key.Length));
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/CSharp/Portable/Symbols/Synthesized/SynthesizedInstanceConstructor.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using Microsoft.CodeAnalysis.PooledObjects;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
internal class SynthesizedInstanceConstructor : SynthesizedInstanceMethodSymbol
{
private readonly NamedTypeSymbol _containingType;
internal SynthesizedInstanceConstructor(NamedTypeSymbol containingType)
{
Debug.Assert((object)containingType != null);
_containingType = containingType;
}
//
// Consider overriding when implementing a synthesized subclass.
//
internal override bool GenerateDebugInfo
{
get { return true; }
}
public override ImmutableArray<ParameterSymbol> Parameters
{
get { return ImmutableArray<ParameterSymbol>.Empty; }
}
public override Accessibility DeclaredAccessibility
{
get { return ContainingType.IsAbstract ? Accessibility.Protected : Accessibility.Public; }
}
internal override bool IsMetadataFinal
{
get
{
return false;
}
}
#region Sealed
public sealed override Symbol ContainingSymbol
{
get { return _containingType; }
}
public sealed override NamedTypeSymbol ContainingType
{
get
{
return _containingType;
}
}
public sealed override string Name
{
get { return WellKnownMemberNames.InstanceConstructorName; }
}
internal sealed override bool HasSpecialName
{
get { return true; }
}
internal sealed override System.Reflection.MethodImplAttributes ImplementationAttributes
{
get
{
if (_containingType.IsComImport)
{
Debug.Assert(_containingType.TypeKind == TypeKind.Class);
return System.Reflection.MethodImplAttributes.Runtime | System.Reflection.MethodImplAttributes.InternalCall;
}
if (_containingType.TypeKind == TypeKind.Delegate)
{
return System.Reflection.MethodImplAttributes.Runtime;
}
return default(System.Reflection.MethodImplAttributes);
}
}
internal sealed override bool RequiresSecurityObject
{
get { return false; }
}
public sealed override DllImportData GetDllImportData()
{
return null;
}
internal sealed override MarshalPseudoCustomAttributeData ReturnValueMarshallingInformation
{
get { return null; }
}
internal sealed override bool HasDeclarativeSecurity
{
get { return false; }
}
internal sealed override IEnumerable<Cci.SecurityAttribute> GetSecurityInformation()
{
throw ExceptionUtilities.Unreachable;
}
internal sealed override ImmutableArray<string> GetAppliedConditionalSymbols()
{
return ImmutableArray<string>.Empty;
}
public sealed override bool IsVararg
{
get { return false; }
}
public sealed override ImmutableArray<TypeParameterSymbol> TypeParameters
{
get { return ImmutableArray<TypeParameterSymbol>.Empty; }
}
internal override LexicalSortKey GetLexicalSortKey()
{
//For the sake of matching the metadata output of the native compiler, make synthesized constructors appear last in the metadata.
//This is not critical, but it makes it easier on tools that are comparing metadata.
return LexicalSortKey.SynthesizedCtor;
}
public sealed override ImmutableArray<Location> Locations
{
get { return ContainingType.Locations; }
}
public override RefKind RefKind
{
get { return RefKind.None; }
}
public sealed override TypeWithAnnotations ReturnTypeWithAnnotations
{
get { return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void)); }
}
public sealed override FlowAnalysisAnnotations ReturnTypeFlowAnalysisAnnotations => FlowAnalysisAnnotations.None;
public sealed override ImmutableHashSet<string> ReturnNotNullIfParameterNotNull => ImmutableHashSet<string>.Empty;
public override ImmutableArray<CustomModifier> RefCustomModifiers
{
get { return ImmutableArray<CustomModifier>.Empty; }
}
public sealed override ImmutableArray<TypeWithAnnotations> TypeArgumentsWithAnnotations
{
get { return ImmutableArray<TypeWithAnnotations>.Empty; }
}
public sealed override Symbol AssociatedSymbol
{
get { return null; }
}
public sealed override int Arity
{
get { return 0; }
}
public sealed override bool ReturnsVoid
{
get { return true; }
}
public sealed override MethodKind MethodKind
{
get { return MethodKind.Constructor; }
}
public sealed override bool IsExtern
{
get
{
// Synthesized constructors of ComImport type are extern
NamedTypeSymbol containingType = this.ContainingType;
return (object)containingType != null && containingType.IsComImport;
}
}
public sealed override bool IsSealed
{
get { return false; }
}
public sealed override bool IsAbstract
{
get { return false; }
}
public sealed override bool IsOverride
{
get { return false; }
}
public sealed override bool IsVirtual
{
get { return false; }
}
public sealed override bool IsStatic
{
get { return false; }
}
public sealed override bool IsAsync
{
get { return false; }
}
public sealed override bool HidesBaseMethodsByName
{
get { return false; }
}
internal sealed override bool IsMetadataNewSlot(bool ignoreInterfaceImplementationChanges = false)
{
return false;
}
internal sealed override bool IsMetadataVirtual(bool ignoreInterfaceImplementationChanges = false)
{
return false;
}
public sealed override bool IsExtensionMethod
{
get { return false; }
}
internal sealed override Cci.CallingConvention CallingConvention
{
get { return Cci.CallingConvention.HasThis; }
}
internal sealed override bool IsExplicitInterfaceImplementation
{
get { return false; }
}
public sealed override ImmutableArray<MethodSymbol> ExplicitInterfaceImplementations
{
get { return ImmutableArray<MethodSymbol>.Empty; }
}
internal sealed override int CalculateLocalSyntaxOffset(int localPosition, SyntaxTree localTree)
{
var containingType = (SourceMemberContainerTypeSymbol)this.ContainingType;
return containingType.CalculateSyntaxOffsetInSynthesizedConstructor(localPosition, localTree, isStatic: false);
}
internal sealed override UseSiteInfo<AssemblySymbol> GetUseSiteInfo()
{
var result = new UseSiteInfo<AssemblySymbol>(PrimaryDependency);
MergeUseSiteInfo(ref result, ReturnTypeWithAnnotations.Type.GetUseSiteInfo());
return result;
}
internal sealed override bool IsNullableAnalysisEnabled() =>
(ContainingType as SourceMemberContainerTypeSymbol)?.IsNullableEnabledForConstructorsAndInitializers(useStatic: false) ?? false;
#endregion
protected void GenerateMethodBodyCore(TypeCompilationState compilationState, BindingDiagnosticBag diagnostics)
{
var factory = new SyntheticBoundNodeFactory(this, this.GetNonNullSyntaxNode(), compilationState, diagnostics);
factory.CurrentFunction = this;
if (ContainingType.BaseTypeNoUseSiteDiagnostics is MissingMetadataTypeSymbol)
{
// System_Attribute was not found or was inaccessible
factory.CloseMethod(factory.Block());
return;
}
var baseConstructorCall = MethodCompiler.GenerateBaseParameterlessConstructorInitializer(this, diagnostics);
if (baseConstructorCall == null)
{
// Attribute..ctor was not found or was inaccessible
factory.CloseMethod(factory.Block());
return;
}
var statements = ArrayBuilder<BoundStatement>.GetInstance();
statements.Add(factory.ExpressionStatement(baseConstructorCall));
GenerateMethodBodyStatements(factory, statements, diagnostics);
statements.Add(factory.Return());
var block = factory.Block(statements.ToImmutableAndFree());
factory.CloseMethod(block);
}
internal virtual void GenerateMethodBodyStatements(SyntheticBoundNodeFactory factory, ArrayBuilder<BoundStatement> statements, BindingDiagnosticBag diagnostics)
{
// overridden in a derived class to add extra statements to the body of the generated constructor
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using Microsoft.CodeAnalysis.PooledObjects;
using Roslyn.Utilities;
namespace Microsoft.CodeAnalysis.CSharp.Symbols
{
internal class SynthesizedInstanceConstructor : SynthesizedInstanceMethodSymbol
{
private readonly NamedTypeSymbol _containingType;
internal SynthesizedInstanceConstructor(NamedTypeSymbol containingType)
{
Debug.Assert((object)containingType != null);
_containingType = containingType;
}
//
// Consider overriding when implementing a synthesized subclass.
//
internal override bool GenerateDebugInfo
{
get { return true; }
}
public override ImmutableArray<ParameterSymbol> Parameters
{
get { return ImmutableArray<ParameterSymbol>.Empty; }
}
public override Accessibility DeclaredAccessibility
{
get { return ContainingType.IsAbstract ? Accessibility.Protected : Accessibility.Public; }
}
internal override bool IsMetadataFinal
{
get
{
return false;
}
}
#region Sealed
public sealed override Symbol ContainingSymbol
{
get { return _containingType; }
}
public sealed override NamedTypeSymbol ContainingType
{
get
{
return _containingType;
}
}
public sealed override string Name
{
get { return WellKnownMemberNames.InstanceConstructorName; }
}
internal sealed override bool HasSpecialName
{
get { return true; }
}
internal sealed override System.Reflection.MethodImplAttributes ImplementationAttributes
{
get
{
if (_containingType.IsComImport)
{
Debug.Assert(_containingType.TypeKind == TypeKind.Class);
return System.Reflection.MethodImplAttributes.Runtime | System.Reflection.MethodImplAttributes.InternalCall;
}
if (_containingType.TypeKind == TypeKind.Delegate)
{
return System.Reflection.MethodImplAttributes.Runtime;
}
return default(System.Reflection.MethodImplAttributes);
}
}
internal sealed override bool RequiresSecurityObject
{
get { return false; }
}
public sealed override DllImportData GetDllImportData()
{
return null;
}
internal sealed override MarshalPseudoCustomAttributeData ReturnValueMarshallingInformation
{
get { return null; }
}
internal sealed override bool HasDeclarativeSecurity
{
get { return false; }
}
internal sealed override IEnumerable<Cci.SecurityAttribute> GetSecurityInformation()
{
throw ExceptionUtilities.Unreachable;
}
internal sealed override ImmutableArray<string> GetAppliedConditionalSymbols()
{
return ImmutableArray<string>.Empty;
}
public sealed override bool IsVararg
{
get { return false; }
}
public sealed override ImmutableArray<TypeParameterSymbol> TypeParameters
{
get { return ImmutableArray<TypeParameterSymbol>.Empty; }
}
internal override LexicalSortKey GetLexicalSortKey()
{
//For the sake of matching the metadata output of the native compiler, make synthesized constructors appear last in the metadata.
//This is not critical, but it makes it easier on tools that are comparing metadata.
return LexicalSortKey.SynthesizedCtor;
}
public sealed override ImmutableArray<Location> Locations
{
get { return ContainingType.Locations; }
}
public override RefKind RefKind
{
get { return RefKind.None; }
}
public sealed override TypeWithAnnotations ReturnTypeWithAnnotations
{
get { return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void)); }
}
public sealed override FlowAnalysisAnnotations ReturnTypeFlowAnalysisAnnotations => FlowAnalysisAnnotations.None;
public sealed override ImmutableHashSet<string> ReturnNotNullIfParameterNotNull => ImmutableHashSet<string>.Empty;
public override ImmutableArray<CustomModifier> RefCustomModifiers
{
get { return ImmutableArray<CustomModifier>.Empty; }
}
public sealed override ImmutableArray<TypeWithAnnotations> TypeArgumentsWithAnnotations
{
get { return ImmutableArray<TypeWithAnnotations>.Empty; }
}
public sealed override Symbol AssociatedSymbol
{
get { return null; }
}
public sealed override int Arity
{
get { return 0; }
}
public sealed override bool ReturnsVoid
{
get { return true; }
}
public sealed override MethodKind MethodKind
{
get { return MethodKind.Constructor; }
}
public sealed override bool IsExtern
{
get
{
// Synthesized constructors of ComImport type are extern
NamedTypeSymbol containingType = this.ContainingType;
return (object)containingType != null && containingType.IsComImport;
}
}
public sealed override bool IsSealed
{
get { return false; }
}
public sealed override bool IsAbstract
{
get { return false; }
}
public sealed override bool IsOverride
{
get { return false; }
}
public sealed override bool IsVirtual
{
get { return false; }
}
public sealed override bool IsStatic
{
get { return false; }
}
public sealed override bool IsAsync
{
get { return false; }
}
public sealed override bool HidesBaseMethodsByName
{
get { return false; }
}
internal sealed override bool IsMetadataNewSlot(bool ignoreInterfaceImplementationChanges = false)
{
return false;
}
internal sealed override bool IsMetadataVirtual(bool ignoreInterfaceImplementationChanges = false)
{
return false;
}
public sealed override bool IsExtensionMethod
{
get { return false; }
}
internal sealed override Cci.CallingConvention CallingConvention
{
get { return Cci.CallingConvention.HasThis; }
}
internal sealed override bool IsExplicitInterfaceImplementation
{
get { return false; }
}
public sealed override ImmutableArray<MethodSymbol> ExplicitInterfaceImplementations
{
get { return ImmutableArray<MethodSymbol>.Empty; }
}
internal sealed override int CalculateLocalSyntaxOffset(int localPosition, SyntaxTree localTree)
{
var containingType = (SourceMemberContainerTypeSymbol)this.ContainingType;
return containingType.CalculateSyntaxOffsetInSynthesizedConstructor(localPosition, localTree, isStatic: false);
}
internal sealed override UseSiteInfo<AssemblySymbol> GetUseSiteInfo()
{
var result = new UseSiteInfo<AssemblySymbol>(PrimaryDependency);
MergeUseSiteInfo(ref result, ReturnTypeWithAnnotations.Type.GetUseSiteInfo());
return result;
}
internal sealed override bool IsNullableAnalysisEnabled() =>
(ContainingType as SourceMemberContainerTypeSymbol)?.IsNullableEnabledForConstructorsAndInitializers(useStatic: false) ?? false;
#endregion
protected void GenerateMethodBodyCore(TypeCompilationState compilationState, BindingDiagnosticBag diagnostics)
{
var factory = new SyntheticBoundNodeFactory(this, this.GetNonNullSyntaxNode(), compilationState, diagnostics);
factory.CurrentFunction = this;
if (ContainingType.BaseTypeNoUseSiteDiagnostics is MissingMetadataTypeSymbol)
{
// System_Attribute was not found or was inaccessible
factory.CloseMethod(factory.Block());
return;
}
var baseConstructorCall = MethodCompiler.GenerateBaseParameterlessConstructorInitializer(this, diagnostics);
if (baseConstructorCall == null)
{
// Attribute..ctor was not found or was inaccessible
factory.CloseMethod(factory.Block());
return;
}
var statements = ArrayBuilder<BoundStatement>.GetInstance();
statements.Add(factory.ExpressionStatement(baseConstructorCall));
GenerateMethodBodyStatements(factory, statements, diagnostics);
statements.Add(factory.Return());
var block = factory.Block(statements.ToImmutableAndFree());
factory.CloseMethod(block);
}
internal virtual void GenerateMethodBodyStatements(SyntheticBoundNodeFactory factory, ArrayBuilder<BoundStatement> statements, BindingDiagnosticBag diagnostics)
{
// overridden in a derived class to add extra statements to the body of the generated constructor
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/VisualStudio/IntegrationTest/IntegrationTests/CSharp/CSharpReplClassification.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities.Input;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
namespace Roslyn.VisualStudio.IntegrationTests.CSharp
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class CSharpReplClassification : AbstractInteractiveWindowTest
{
public CSharpReplClassification(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory)
{
}
[WpfFact]
public void VerifyColorOfSomeTokens()
{
VisualStudio.InteractiveWindow.InsertCode(@"using System.Console;
/// <summary>innertext
/// </summary>
/// <see cref=""System.Environment"" />
/// <!--comment-->
/// <![CDATA[cdata]]]]>>
/// <typeparam name=""attribute"" />
public static void Main(string[] args)
{
WriteLine(""Hello World"");
}");
VisualStudio.InteractiveWindow.PlaceCaret("using");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "keyword");
VisualStudio.InteractiveWindow.PlaceCaret("{");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "punctuation");
VisualStudio.InteractiveWindow.PlaceCaret("Main");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "method name");
VisualStudio.InteractiveWindow.PlaceCaret("Hello");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "string");
VisualStudio.InteractiveWindow.PlaceCaret("<summary", charsOffset: -1);
VisualStudio.SendKeys.Send(new KeyPress(VirtualKey.Right, ShiftState.Alt));
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - delimiter");
VisualStudio.InteractiveWindow.PlaceCaret("summary");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - name");
VisualStudio.InteractiveWindow.PlaceCaret("innertext");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - text");
VisualStudio.InteractiveWindow.PlaceCaret("!--");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - delimiter");
VisualStudio.InteractiveWindow.PlaceCaret("comment");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - comment");
VisualStudio.InteractiveWindow.PlaceCaret("CDATA");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - delimiter");
VisualStudio.InteractiveWindow.PlaceCaret("cdata");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - cdata section");
VisualStudio.InteractiveWindow.PlaceCaret("attribute");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "identifier");
VisualStudio.InteractiveWindow.PlaceCaret("Environment");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "class name");
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using Microsoft.VisualStudio.IntegrationTest.Utilities;
using Microsoft.VisualStudio.IntegrationTest.Utilities.Input;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
namespace Roslyn.VisualStudio.IntegrationTests.CSharp
{
[Collection(nameof(SharedIntegrationHostFixture))]
public class CSharpReplClassification : AbstractInteractiveWindowTest
{
public CSharpReplClassification(VisualStudioInstanceFactory instanceFactory)
: base(instanceFactory)
{
}
[WpfFact]
public void VerifyColorOfSomeTokens()
{
VisualStudio.InteractiveWindow.InsertCode(@"using System.Console;
/// <summary>innertext
/// </summary>
/// <see cref=""System.Environment"" />
/// <!--comment-->
/// <![CDATA[cdata]]]]>>
/// <typeparam name=""attribute"" />
public static void Main(string[] args)
{
WriteLine(""Hello World"");
}");
VisualStudio.InteractiveWindow.PlaceCaret("using");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "keyword");
VisualStudio.InteractiveWindow.PlaceCaret("{");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "punctuation");
VisualStudio.InteractiveWindow.PlaceCaret("Main");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "method name");
VisualStudio.InteractiveWindow.PlaceCaret("Hello");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "string");
VisualStudio.InteractiveWindow.PlaceCaret("<summary", charsOffset: -1);
VisualStudio.SendKeys.Send(new KeyPress(VirtualKey.Right, ShiftState.Alt));
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - delimiter");
VisualStudio.InteractiveWindow.PlaceCaret("summary");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - name");
VisualStudio.InteractiveWindow.PlaceCaret("innertext");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - text");
VisualStudio.InteractiveWindow.PlaceCaret("!--");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - delimiter");
VisualStudio.InteractiveWindow.PlaceCaret("comment");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - comment");
VisualStudio.InteractiveWindow.PlaceCaret("CDATA");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - delimiter");
VisualStudio.InteractiveWindow.PlaceCaret("cdata");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "xml doc comment - cdata section");
VisualStudio.InteractiveWindow.PlaceCaret("attribute");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "identifier");
VisualStudio.InteractiveWindow.PlaceCaret("Environment");
VisualStudio.InteractiveWindow.Verify.CurrentTokenType(tokenType: "class name");
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/Test/Resources/Core/NetFX/Minimal/minasync.cs | using System;
using System.Threading.Tasks;
using System.Runtime.CompilerServices;
namespace System
{
public delegate void Action();
}
namespace System.Threading.Tasks
{
public class Task : IAsyncResult, IDisposable
{
public Awaiter GetAwaiter() => null;
}
public class Task<T> : Task, IAsyncResult, IDisposable
{
public new Awaiter<T> GetAwaiter() => null;
}
public class Awaiter : INotifyCompletion
{
public void OnCompleted(Action continuation) { }
public bool IsCompleted => false;
public void GetResult() { }
}
public class Awaiter<T> : INotifyCompletion
{
public void OnCompleted(Action continuation) { }
public bool IsCompleted => false;
public T GetResult() => default(T);
}
}
namespace System.Runtime.CompilerServices
{
public interface INotifyCompletion
{
void OnCompleted(Action continuation);
}
public interface ICriticalNotifyCompletion : INotifyCompletion
{
void UnsafeOnCompleted(Action continuation);
}
public interface IAsyncStateMachine
{
void MoveNext();
void SetStateMachine(IAsyncStateMachine stateMachine);
}
public struct AsyncVoidMethodBuilder
{
public static AsyncVoidMethodBuilder Create() { throw null; }
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine { }
public void SetStateMachine(IAsyncStateMachine stateMachine) { }
public void AwaitOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void SetResult() { }
public void SetException(Exception exception) { }
}
public struct AsyncTaskMethodBuilder
{
public static AsyncTaskMethodBuilder Create() { throw null; }
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine { }
public void SetStateMachine(IAsyncStateMachine stateMachine) { }
public void AwaitOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public Task Task => null;
public void SetResult() { }
public void SetException(Exception exception) { }
}
public struct AsyncTaskMethodBuilder<TResult>
{
public static AsyncTaskMethodBuilder<TResult> Create() => default(AsyncTaskMethodBuilder<TResult>);
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine { }
public void SetStateMachine(IAsyncStateMachine stateMachine) { }
public void AwaitOnCompleted<TAwaiter, TStateMachine>(
ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(
ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public Task<TResult> Task => null;
public void SetResult(TResult result) { }
public void SetException(Exception exception) { }
}
}
| using System;
using System.Threading.Tasks;
using System.Runtime.CompilerServices;
namespace System
{
public delegate void Action();
}
namespace System.Threading.Tasks
{
public class Task : IAsyncResult, IDisposable
{
public Awaiter GetAwaiter() => null;
}
public class Task<T> : Task, IAsyncResult, IDisposable
{
public new Awaiter<T> GetAwaiter() => null;
}
public class Awaiter : INotifyCompletion
{
public void OnCompleted(Action continuation) { }
public bool IsCompleted => false;
public void GetResult() { }
}
public class Awaiter<T> : INotifyCompletion
{
public void OnCompleted(Action continuation) { }
public bool IsCompleted => false;
public T GetResult() => default(T);
}
}
namespace System.Runtime.CompilerServices
{
public interface INotifyCompletion
{
void OnCompleted(Action continuation);
}
public interface ICriticalNotifyCompletion : INotifyCompletion
{
void UnsafeOnCompleted(Action continuation);
}
public interface IAsyncStateMachine
{
void MoveNext();
void SetStateMachine(IAsyncStateMachine stateMachine);
}
public struct AsyncVoidMethodBuilder
{
public static AsyncVoidMethodBuilder Create() { throw null; }
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine { }
public void SetStateMachine(IAsyncStateMachine stateMachine) { }
public void AwaitOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void SetResult() { }
public void SetException(Exception exception) { }
}
public struct AsyncTaskMethodBuilder
{
public static AsyncTaskMethodBuilder Create() { throw null; }
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine { }
public void SetStateMachine(IAsyncStateMachine stateMachine) { }
public void AwaitOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public Task Task => null;
public void SetResult() { }
public void SetException(Exception exception) { }
}
public struct AsyncTaskMethodBuilder<TResult>
{
public static AsyncTaskMethodBuilder<TResult> Create() => default(AsyncTaskMethodBuilder<TResult>);
public void Start<TStateMachine>(ref TStateMachine stateMachine) where TStateMachine : IAsyncStateMachine { }
public void SetStateMachine(IAsyncStateMachine stateMachine) { }
public void AwaitOnCompleted<TAwaiter, TStateMachine>(
ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : INotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public void AwaitUnsafeOnCompleted<TAwaiter, TStateMachine>(
ref TAwaiter awaiter, ref TStateMachine stateMachine)
where TAwaiter : ICriticalNotifyCompletion
where TStateMachine : IAsyncStateMachine
{
}
public Task<TResult> Task => null;
public void SetResult(TResult result) { }
public void SetException(Exception exception) { }
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/Core/MSBuildTask/MvidReader.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Diagnostics.CodeAnalysis;
using System.IO;
namespace Microsoft.CodeAnalysis.BuildTasks
{
public static class MvidReader
{
private static readonly Guid s_empty = Guid.Empty;
public static Guid ReadAssemblyMvidOrEmpty(Stream stream)
{
return ReadAssemblyMvidOrEmpty(new BinaryReader(stream));
}
private static Guid ReadAssemblyMvidOrEmpty(BinaryReader reader)
{
// DOS Header: Magic number (2)
if (!ReadUInt16(reader, out ushort magicNumber) || magicNumber != 0x5a4d) // "MZ"
{
return s_empty;
}
// DOS Header: Address of PE Signature (at 0x3C)
if (!MoveTo(0x3C, reader))
{
return s_empty;
}
if (!ReadUInt32(reader, out uint pointerToPeSignature))
{
return s_empty;
}
// jump over the MS DOS Stub to the PE Signature
if (!MoveTo(pointerToPeSignature, reader))
{
return s_empty;
}
// PE Signature ('P' 'E' null null)
if (!ReadUInt32(reader, out uint peSig) || peSig != 0x00004550)
{
return s_empty;
}
// COFF Header: Machine (2)
if (!Skip(2, reader))
{
return s_empty;
}
// COFF Header: NumberOfSections (2)
if (!ReadUInt16(reader, out ushort sections))
{
return s_empty;
}
// COFF Header: TimeDateStamp (4), PointerToSymbolTable (4), NumberOfSymbols (4)
if (!Skip(12, reader))
{
return s_empty;
}
// COFF Header: OptionalHeaderSize (2)
if (!ReadUInt16(reader, out ushort optionalHeaderSize))
{
return s_empty;
}
// COFF Header: Characteristics (2)
if (!Skip(2, reader))
{
return s_empty;
}
// Optional header
if (!Skip(optionalHeaderSize, reader))
{
return s_empty;
}
// Section headers
return FindMvidInSections(sections, reader);
}
private static Guid FindMvidInSections(ushort count, BinaryReader reader)
{
for (int i = 0; i < count; i++)
{
// Section: Name (8)
if (!ReadBytes(reader, 8, out byte[]? name))
{
return s_empty;
}
if (name!.Length == 8 && name[0] == '.' &&
name[1] == 'm' && name[2] == 'v' && name[3] == 'i' && name[4] == 'd' && name[5] == '\0')
{
// Section: VirtualSize (4)
if (!ReadUInt32(reader, out uint virtualSize) || virtualSize != 16)
{
// The .mvid section only stores a Guid
return s_empty;
}
// Section: VirtualAddress (4), SizeOfRawData (4)
if (!Skip(8, reader))
{
return s_empty;
}
// Section: PointerToRawData (4)
if (!ReadUInt32(reader, out uint pointerToRawData))
{
return s_empty;
}
return ReadMvidSection(reader, pointerToRawData);
}
else
{
// Section: VirtualSize (4), VirtualAddress (4), SizeOfRawData (4),
// PointerToRawData (4), PointerToRelocations (4), PointerToLineNumbers (4),
// NumberOfRelocations (2), NumberOfLineNumbers (2), Characteristics (4)
if (!Skip(4 + 4 + 4 + 4 + 4 + 4 + 2 + 2 + 4, reader))
{
return s_empty;
}
}
}
return s_empty;
}
private static Guid ReadMvidSection(BinaryReader reader, uint pointerToMvidSection)
{
if (!MoveTo(pointerToMvidSection, reader))
{
return s_empty;
}
if (!ReadBytes(reader, 16, out byte[]? guidBytes))
{
return s_empty;
}
return new Guid(guidBytes!);
}
private static bool ReadUInt16(BinaryReader reader, out ushort output)
{
if (reader.BaseStream.Position + 2 >= reader.BaseStream.Length)
{
output = 0;
return false;
}
output = reader.ReadUInt16();
return true;
}
private static bool ReadUInt32(BinaryReader reader, out uint output)
{
if (reader.BaseStream.Position + 4 >= reader.BaseStream.Length)
{
output = 0;
return false;
}
output = reader.ReadUInt32();
return true;
}
private static bool ReadBytes(BinaryReader reader, int count, out byte[]? output)
{
if (reader.BaseStream.Position + count >= reader.BaseStream.Length)
{
output = null;
return false;
}
output = reader.ReadBytes(count);
return true;
}
private static bool Skip(int bytes, BinaryReader reader)
{
if (reader.BaseStream.Position + bytes >= reader.BaseStream.Length)
{
return false;
}
reader.BaseStream.Seek(bytes, SeekOrigin.Current);
return true;
}
private static bool MoveTo(uint position, BinaryReader reader)
{
if (position >= reader.BaseStream.Length)
{
return false;
}
reader.BaseStream.Seek(position, SeekOrigin.Begin);
return true;
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Diagnostics.CodeAnalysis;
using System.IO;
namespace Microsoft.CodeAnalysis.BuildTasks
{
public static class MvidReader
{
private static readonly Guid s_empty = Guid.Empty;
public static Guid ReadAssemblyMvidOrEmpty(Stream stream)
{
return ReadAssemblyMvidOrEmpty(new BinaryReader(stream));
}
private static Guid ReadAssemblyMvidOrEmpty(BinaryReader reader)
{
// DOS Header: Magic number (2)
if (!ReadUInt16(reader, out ushort magicNumber) || magicNumber != 0x5a4d) // "MZ"
{
return s_empty;
}
// DOS Header: Address of PE Signature (at 0x3C)
if (!MoveTo(0x3C, reader))
{
return s_empty;
}
if (!ReadUInt32(reader, out uint pointerToPeSignature))
{
return s_empty;
}
// jump over the MS DOS Stub to the PE Signature
if (!MoveTo(pointerToPeSignature, reader))
{
return s_empty;
}
// PE Signature ('P' 'E' null null)
if (!ReadUInt32(reader, out uint peSig) || peSig != 0x00004550)
{
return s_empty;
}
// COFF Header: Machine (2)
if (!Skip(2, reader))
{
return s_empty;
}
// COFF Header: NumberOfSections (2)
if (!ReadUInt16(reader, out ushort sections))
{
return s_empty;
}
// COFF Header: TimeDateStamp (4), PointerToSymbolTable (4), NumberOfSymbols (4)
if (!Skip(12, reader))
{
return s_empty;
}
// COFF Header: OptionalHeaderSize (2)
if (!ReadUInt16(reader, out ushort optionalHeaderSize))
{
return s_empty;
}
// COFF Header: Characteristics (2)
if (!Skip(2, reader))
{
return s_empty;
}
// Optional header
if (!Skip(optionalHeaderSize, reader))
{
return s_empty;
}
// Section headers
return FindMvidInSections(sections, reader);
}
private static Guid FindMvidInSections(ushort count, BinaryReader reader)
{
for (int i = 0; i < count; i++)
{
// Section: Name (8)
if (!ReadBytes(reader, 8, out byte[]? name))
{
return s_empty;
}
if (name!.Length == 8 && name[0] == '.' &&
name[1] == 'm' && name[2] == 'v' && name[3] == 'i' && name[4] == 'd' && name[5] == '\0')
{
// Section: VirtualSize (4)
if (!ReadUInt32(reader, out uint virtualSize) || virtualSize != 16)
{
// The .mvid section only stores a Guid
return s_empty;
}
// Section: VirtualAddress (4), SizeOfRawData (4)
if (!Skip(8, reader))
{
return s_empty;
}
// Section: PointerToRawData (4)
if (!ReadUInt32(reader, out uint pointerToRawData))
{
return s_empty;
}
return ReadMvidSection(reader, pointerToRawData);
}
else
{
// Section: VirtualSize (4), VirtualAddress (4), SizeOfRawData (4),
// PointerToRawData (4), PointerToRelocations (4), PointerToLineNumbers (4),
// NumberOfRelocations (2), NumberOfLineNumbers (2), Characteristics (4)
if (!Skip(4 + 4 + 4 + 4 + 4 + 4 + 2 + 2 + 4, reader))
{
return s_empty;
}
}
}
return s_empty;
}
private static Guid ReadMvidSection(BinaryReader reader, uint pointerToMvidSection)
{
if (!MoveTo(pointerToMvidSection, reader))
{
return s_empty;
}
if (!ReadBytes(reader, 16, out byte[]? guidBytes))
{
return s_empty;
}
return new Guid(guidBytes!);
}
private static bool ReadUInt16(BinaryReader reader, out ushort output)
{
if (reader.BaseStream.Position + 2 >= reader.BaseStream.Length)
{
output = 0;
return false;
}
output = reader.ReadUInt16();
return true;
}
private static bool ReadUInt32(BinaryReader reader, out uint output)
{
if (reader.BaseStream.Position + 4 >= reader.BaseStream.Length)
{
output = 0;
return false;
}
output = reader.ReadUInt32();
return true;
}
private static bool ReadBytes(BinaryReader reader, int count, out byte[]? output)
{
if (reader.BaseStream.Position + count >= reader.BaseStream.Length)
{
output = null;
return false;
}
output = reader.ReadBytes(count);
return true;
}
private static bool Skip(int bytes, BinaryReader reader)
{
if (reader.BaseStream.Position + bytes >= reader.BaseStream.Length)
{
return false;
}
reader.BaseStream.Seek(bytes, SeekOrigin.Current);
return true;
}
private static bool MoveTo(uint position, BinaryReader reader)
{
if (position >= reader.BaseStream.Length)
{
return false;
}
reader.BaseStream.Seek(position, SeekOrigin.Begin);
return true;
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Workspaces/CoreTest/CodeCleanup/ReduceTokenTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Globalization;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeCleanup;
using Microsoft.CodeAnalysis.CodeCleanup.Providers;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.UnitTests.CodeCleanup
{
[UseExportProvider]
public class ReduceTokenTests
{
#if NETCOREAPP
private static bool IsNetCoreApp => true;
#else
private static bool IsNetCoreApp => false;
#endif
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_LessThan8Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = .14995F ' Dev11 & Roslyn: Pretty listed to 0.14995F
Const f_5_2 As Single = 0.14995f ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995F ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95f ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5F ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0f ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = .1499995F ' Dev11 & Roslyn: Pretty listed to 0.1499995F
Const f_7_2 As Single = 0.1499995f ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995F ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995f ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5F ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0f ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = 0.14995F ' Dev11 & Roslyn: Pretty listed to 0.14995F
Const f_5_2 As Single = 0.14995F ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995F ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95F ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5F ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0F ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = 0.1499995F ' Dev11 & Roslyn: Pretty listed to 0.1499995F
Const f_7_2 As Single = 0.1499995F ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995F ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995F ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5F ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0F ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_LessThan8Digits_WithTypeCharacterSingle()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = .14995! ' Dev11 & Roslyn: Pretty listed to 0.14995!
Const f_5_2 As Single = 0.14995! ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995! ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95! ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5! ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0! ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = .1499995! ' Dev11 & Roslyn: Pretty listed to 0.1499995!
Const f_7_2 As Single = 0.1499995! ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995! ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995! ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5! ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0! ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = 0.14995! ' Dev11 & Roslyn: Pretty listed to 0.14995!
Const f_5_2 As Single = 0.14995! ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995! ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95! ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5! ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0! ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = 0.1499995! ' Dev11 & Roslyn: Pretty listed to 0.1499995!
Const f_7_2 As Single = 0.1499995! ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995! ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995! ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5! ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0! ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_8Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = .14999795F ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = .14999797f ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797F ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = 1.4999794f ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = 1.4999797F ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = 1499.9794f ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = 1499979.7F ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0F ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = 0.14999795F ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = {(IsNetCoreApp ? "0.14999796F" : "0.149997965F")} ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797F ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = {(IsNetCoreApp ? "1.4999794F" : "1.49997938F")} ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = {(IsNetCoreApp ? "1.4999797F" : "1.49997973F")} ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = {(IsNetCoreApp ? "1499.9794F" : "1499.97937F")} ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = {(IsNetCoreApp ? "1499979.8F" : "1499979.75F")} ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0F ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_8Digits_WithTypeCharacterSingle()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = .14999795! ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = .14999797! ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797! ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = 1.4999794! ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = 1.4999797! ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = 1499.9794! ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = 1499979.7! ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0! ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = 0.14999795! ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = {(IsNetCoreApp ? "0.14999796!" : "0.149997965!")} ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797! ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = {(IsNetCoreApp ? "1.4999794!" : "1.49997938!")} ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = {(IsNetCoreApp ? "1.4999797!" : "1.49997973!")} ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = {(IsNetCoreApp ? "1499.9794!" : "1499.97937!")} ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = {(IsNetCoreApp ? "1499979.8!" : "1499979.75!")} ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0! ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_GreaterThan8Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = .149997938F ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = 0.149997931f ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = 1.49997965F ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = 14999.79652f ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = 149997965.2F ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = 1499979652.0f ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = 111111149999124689999.499F ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47F ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47F ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = {(IsNetCoreApp ? "0.14999793F" : "0.149997935F")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = {(IsNetCoreApp ? "0.14999793F" : "0.149997935F")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = {(IsNetCoreApp ? "1.4999796F" : "1.49997962F")} ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = {(IsNetCoreApp ? "14999.797F" : "14999.7969F")} ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = {(IsNetCoreApp ? "149997970.0F" : "149997968.0F")} ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = {(IsNetCoreApp ? "1.4999796E+9F" : "1.49997965E+9F")} ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = {(IsNetCoreApp ? "1.1111115E+20F" : "1.11111148E+20F")} ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47F ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47F ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_GreaterThan8Digits_WithTypeCharacterSingle()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = .149997938! ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = 0.149997931! ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = 1.49997965! ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = 14999.79652! ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = 149997965.2! ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = 1499979652.0! ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = 111111149999124689999.499! ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47! ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47! ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = {(IsNetCoreApp ? "0.14999793!" : "0.149997935!")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = {(IsNetCoreApp ? "0.14999793!" : "0.149997935!")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = {(IsNetCoreApp ? "1.4999796!" : "1.49997962!")} ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = {(IsNetCoreApp ? "14999.797!" : "14999.7969!")} ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = {(IsNetCoreApp ? "149997970.0!" : "149997968.0!")} ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = {(IsNetCoreApp ? "1.4999796E+9!" : "1.49997965E+9!")} ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = {(IsNetCoreApp ? "1.1111115E+20!" : "1.11111148E+20!")} ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47! ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47! ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_LessThan16Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = .1499599999999 ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999 ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999 ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999 ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9 ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0 ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = .149999999999995 ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995 ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5 ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = 0.1499599999999 ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999 ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999 ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999 ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9 ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0 ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = 0.149999999999995 ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995 ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5 ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_LessThan16Digits_WithTypeCharacter()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = .1499599999999R ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999r ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999# ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999# ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9r ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0R ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = .149999999999995R ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995r ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995# ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995# ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5r ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = 0.1499599999999R ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999R ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999# ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999# ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9R ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0R ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = 0.149999999999995R ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995R ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995# ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995# ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5R ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_16Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = .1499999999799993 ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = .1499999999799997 ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995 ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994 ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = 1.499999999799995 ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994 ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = 14999999.99799995 ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = 149999999997999.2 ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = 149999999997999.8 ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = 0.1499999999799993 ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = {(IsNetCoreApp ? "0.1499999999799997" : "0.14999999997999969")} ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995 ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994 ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = {(IsNetCoreApp ? "1.499999999799995" : "1.4999999997999951")} ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994 ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = {(IsNetCoreApp ? "14999999.99799995" : "14999999.997999949")} ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = {(IsNetCoreApp ? "149999999997999.2" : "149999999997999.19")} ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = {(IsNetCoreApp ? "149999999997999.8" : "149999999997999.81")} ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_16Digits_WithTypeCharacter()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = .1499999999799993R ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = .1499999999799997r ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995# ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994R ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = 1.499999999799995r ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994# ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = 14999999.99799995R ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = 149999999997999.2r ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = 149999999997999.8# ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = 0.1499999999799993R ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = {(IsNetCoreApp ? "0.1499999999799997R" : "0.14999999997999969R")} ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995# ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994R ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = {(IsNetCoreApp ? "1.499999999799995R" : "1.4999999997999951R")} ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994# ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = {(IsNetCoreApp ? "14999999.99799995R" : "14999999.997999949R")} ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = {(IsNetCoreApp ? "149999999997999.2R" : "149999999997999.19R")} ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = {(IsNetCoreApp ? "149999999997999.8#" : "149999999997999.81#")} ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_GreaterThan16Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = .14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = .14999999997999939 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = .14999999997999937 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957 ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = 0.1499999997999958 ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947 ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999945 ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999946 ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.9979999459 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.9979999451 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.9979999454 ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = 14999999999733999.2 ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379995.0 ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = 111111149999124689999.499 ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326 ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326 ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = 0.14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = 0.14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = 0.14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957 ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = {(IsNetCoreApp ? "0.1499999997999958" : "0.14999999979999579")} ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947 ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999944 ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999947 ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.997999946 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.997999946 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.997999946 ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = {(IsNetCoreApp ? "14999999999734000.0" : "1.4999999999734E+16")} ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379996.0 ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = {(IsNetCoreApp ? "1.111111499991247E+20" : "1.1111114999912469E+20")} ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326 ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326 ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_GreaterThan16Digits_WithTypeCharacter()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = .14999999997999938R ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = .14999999997999939r ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = .14999999997999937# ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957R ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = 0.1499999997999958r ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947# ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999945R ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999946r ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.9979999459# ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.9979999451R ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.9979999454r ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = 14999999999733999.2# ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379995.0R ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = 111111149999124689999.499r ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309# ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309R ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326r ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326# ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = 0.14999999997999938R ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = 0.14999999997999938R ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = 0.14999999997999938# ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957R ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = {(IsNetCoreApp ? "0.1499999997999958R" : "0.14999999979999579R")} ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947# ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999944R ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999947R ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.997999946# ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.997999946R ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.997999946R ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = {(IsNetCoreApp ? "14999999999734000.0#" : "1.4999999999734E+16#")} ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379996.0R ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = {(IsNetCoreApp ? "1.111111499991247E+20R" : "1.1111114999912469E+20R")} ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309# ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309R ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326R ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326# ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_LessThan30Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = .123456789012345678901234567D ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567d ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567d ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7D ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567.0d ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = .12345678901234567890123456789D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_2 As Decimal = 0.12345678901234567890123456789d ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789d ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9D ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789.0d ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = 0.123456789012345678901234567D ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7D ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567D ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_2 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789D ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9D ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789D ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_LessThan30Digits_WithTypeCharacterDecimal()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = .123456789012345678901234567@ ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7@ ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567.0@ ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = .12345678901234567890123456789@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_2 As Decimal = 0.12345678901234567890123456789@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_3 As Decimal = 1.2345678901234567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9@ ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789.0@ ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = 0.123456789012345678901234567@ ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7@ ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567@ ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = 0.1234567890123456789012345679@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_2 As Decimal = 0.1234567890123456789012345679@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_3 As Decimal = 1.2345678901234567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9@ ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789@ ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_30Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = .123456789012345678901234567891D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345687891D ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.23456789012345678901234567891D ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.678901234567891D ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789.1D ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0D ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345688D ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.67890123456789D ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789D ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0D ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_30Digits_WithTypeCharacterDecimal()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = .123456789012345678901234567891@ ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345687891@ ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.23456789012345678901234567891@ ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.678901234567891@ ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789.1@ ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0@ ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = 0.1234567890123456789012345679@ ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345688@ ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.2345678901234567890123456789@ ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.67890123456789@ ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789@ ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0@ ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_GreaterThan30Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 30 significant digits
' Dev11 has unpredictable behavior: pretty listed/round off to wrong values in certain cases
' Roslyn behavior: Always rounded off + pretty listed to <= 29 significant digits
' (a) > 30 significant digits overall, but < 30 digits before decimal point.
Const d_32_1 As Decimal = .12345678901234567890123456789012D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_32_2 As Decimal = 0.123456789012345678901234568789012@ ' Dev11 & Roslyn: 0.1234567890123456789012345688@
Const d_32_3 As Decimal = 1.2345678901234567890123456789012d ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_32_4 As Decimal = 123456789012345.67890123456789012@ ' Dev11 & Roslyn: 123456789012345.67890123456789@
' (b) > 30 significant digits before decimal point (Overflow case): Ensure no pretty listing.
Const d_35_1 As Decimal = 123456789012345678901234567890123.45D ' Dev11 & Roslyn: 123456789012345678901234567890123.45D
Console.WriteLine(d_32_1)
Console.WriteLine(d_32_2)
Console.WriteLine(d_32_3)
Console.WriteLine(d_32_4)
Console.WriteLine(d_35_1)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 30 significant digits
' Dev11 has unpredictable behavior: pretty listed/round off to wrong values in certain cases
' Roslyn behavior: Always rounded off + pretty listed to <= 29 significant digits
' (a) > 30 significant digits overall, but < 30 digits before decimal point.
Const d_32_1 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_32_2 As Decimal = 0.1234567890123456789012345688@ ' Dev11 & Roslyn: 0.1234567890123456789012345688@
Const d_32_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_32_4 As Decimal = 123456789012345.67890123456789@ ' Dev11 & Roslyn: 123456789012345.67890123456789@
' (b) > 30 significant digits before decimal point (Overflow case): Ensure no pretty listing.
Const d_35_1 As Decimal = 123456789012345678901234567890123.45D ' Dev11 & Roslyn: 123456789012345678901234567890123.45D
Console.WriteLine(d_32_1)
Console.WriteLine(d_32_2)
Console.WriteLine(d_32_3)
Console.WriteLine(d_32_4)
Console.WriteLine(d_35_1)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceFloatLiteralsWithNegativeExponents()
{
var code = @"[|
Module Program
Sub Main(args As String())
' Floating point values might be represented either in fixed point notation or scientific/exponent notation.
' MSDN comment for Standard Numeric Format Strings used in Single.ToString(String) API (or Double.ToString(String)):
' Fixed-point notation is used if the exponent that would result from expressing the number in scientific notation is greater than -5 and
' less than the precision specifier; otherwise, scientific notation is used.
'
' However, Dev11 pretty lister differs from this for floating point values < 0. It uses fixed point notation as long as exponent is greater than '-(actualPrecision + 1)'.
' For example, consider Single Floating literals:
' (i) Precision = 7
' 0.0000001234567F => 0.0000001234567F (exponent = -7: fixed point notation)
' 0.00000001234567F => 0.00000001234567F (exponent = -8: fixed point notation)
' 0.000000001234567F => 1.234567E-9F (exponent = -9: exponent notation)
' 0.0000000001234567F => 1.234567E-10F (exponent = -10: exponent notation)
' (ii) Precision = 9
' 0.0000000012345678F => 0.00000000123456778F (exponent = -9: fixed point notation)
' 0.00000000012345678F => 0.000000000123456786F (exponent = -10: fixed point notation)
' 0.000000000012345678F => 1.23456783E-11F (exponent = -11: exponent notation)
' 0.0000000000012345678F => 1.23456779E-12F (exponent = -12: exponent notation)
Const f_1 As Single = 0.000001234567F
Const f_2 As Single = 0.0000001234567F
Const f_3 As Single = 0.00000001234567F
Const f_4 As Single = 0.000000001234567F ' Change at -9
Const f_5 As Single = 0.0000000001234567F
Const f_6 As Single = 0.00000000123456778F
Const f_7 As Single = 0.000000000123456786F
Const f_8 As Single = 0.000000000012345678F ' Change at -11
Const f_9 As Single = 0.0000000000012345678F
Const d_1 As Single = 0.00000000000000123456789012345
Const d_2 As Single = 0.000000000000000123456789012345
Const d_3 As Single = 0.0000000000000000123456789012345 ' Change at -17
Const d_4 As Single = 0.00000000000000000123456789012345
Const d_5 As Double = 0.00000000000000001234567890123456
Const d_6 As Double = 0.000000000000000001234567890123456
Const d_7 As Double = 0.0000000000000000001234567890123456 ' Change at -19
Const d_8 As Double = 0.00000000000000000001234567890123456
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' Floating point values might be represented either in fixed point notation or scientific/exponent notation.
' MSDN comment for Standard Numeric Format Strings used in Single.ToString(String) API (or Double.ToString(String)):
' Fixed-point notation is used if the exponent that would result from expressing the number in scientific notation is greater than -5 and
' less than the precision specifier; otherwise, scientific notation is used.
'
' However, Dev11 pretty lister differs from this for floating point values < 0. It uses fixed point notation as long as exponent is greater than '-(actualPrecision + 1)'.
' For example, consider Single Floating literals:
' (i) Precision = 7
' 0.0000001234567F => 0.0000001234567F (exponent = -7: fixed point notation)
' 0.00000001234567F => 0.00000001234567F (exponent = -8: fixed point notation)
' 0.000000001234567F => 1.234567E-9F (exponent = -9: exponent notation)
' 0.0000000001234567F => 1.234567E-10F (exponent = -10: exponent notation)
' (ii) Precision = 9
' 0.0000000012345678F => 0.00000000123456778F (exponent = -9: fixed point notation)
' 0.00000000012345678F => 0.000000000123456786F (exponent = -10: fixed point notation)
' 0.000000000012345678F => 1.23456783E-11F (exponent = -11: exponent notation)
' 0.0000000000012345678F => 1.23456779E-12F (exponent = -12: exponent notation)
Const f_1 As Single = 0.000001234567F
Const f_2 As Single = 0.0000001234567F
Const f_3 As Single = 0.00000001234567F
Const f_4 As Single = 1.234567E-9F ' Change at -9
Const f_5 As Single = 1.234567E-10F
Const f_6 As Single = {(IsNetCoreApp ? "0.0000000012345678F" : "0.00000000123456778F")}
Const f_7 As Single = {(IsNetCoreApp ? "0.00000000012345679F" : "0.000000000123456786F")}
Const f_8 As Single = {(IsNetCoreApp ? "1.2345678E-11F" : "1.23456783E-11F")} ' Change at -11
Const f_9 As Single = {(IsNetCoreApp ? "1.2345678E-12F" : "1.23456779E-12F")}
Const d_1 As Single = 0.00000000000000123456789012345
Const d_2 As Single = 0.000000000000000123456789012345
Const d_3 As Single = 1.23456789012345E-17 ' Change at -17
Const d_4 As Single = 1.23456789012345E-18
Const d_5 As Double = {(IsNetCoreApp ? "0.00000000000000001234567890123456" : "0.000000000000000012345678901234561")}
Const d_6 As Double = 0.000000000000000001234567890123456
Const d_7 As Double = {(IsNetCoreApp ? "1.234567890123456E-19" : "1.2345678901234561E-19")} ' Change at -19
Const d_8 As Double = 1.234567890123456E-20
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiteralsWithTrailingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const f1 As Single = 3.011000F ' Dev11 & Roslyn: 3.011F
Const f2 As Single = 3.000000! ' Dev11 & Roslyn: 3.0!
Const f3 As Single = 3.0F ' Dev11 & Roslyn: Unchanged
Const f4 As Single = 3000f ' Dev11 & Roslyn: 3000.0F
Const f5 As Single = 3000E+10! ' Dev11 & Roslyn: 3.0E+13!
Const f6 As Single = 3000.0E+10F ' Dev11 & Roslyn: 3.0E+13F
Const f7 As Single = 3000.010E+1F ' Dev11 & Roslyn: 30000.1F
Const f8 As Single = 3000.123456789010E+10! ' Dev11 & Roslyn: 3.00012337E+13!
Const f9 As Single = 3000.123456789000E+10F ' Dev11 & Roslyn: 3.00012337E+13F
Const f10 As Single = 30001234567890.10E-10f ' Dev11 & Roslyn: 3000.12354F
Const f11 As Single = 3000E-10! ' Dev11 & Roslyn: 0.0000003!
Console.WriteLine(f1)
Console.WriteLine(f2)
Console.WriteLine(f3)
Console.WriteLine(f4)
Console.WriteLine(f5)
Console.WriteLine(f6)
Console.WriteLine(f7)
Console.WriteLine(f8)
Console.WriteLine(f9)
Console.WriteLine(f10)
Console.WriteLine(f11)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
Const f1 As Single = 3.011F ' Dev11 & Roslyn: 3.011F
Const f2 As Single = 3.0! ' Dev11 & Roslyn: 3.0!
Const f3 As Single = 3.0F ' Dev11 & Roslyn: Unchanged
Const f4 As Single = 3000.0F ' Dev11 & Roslyn: 3000.0F
Const f5 As Single = 3.0E+13! ' Dev11 & Roslyn: 3.0E+13!
Const f6 As Single = 3.0E+13F ' Dev11 & Roslyn: 3.0E+13F
Const f7 As Single = 30000.1F ' Dev11 & Roslyn: 30000.1F
Const f8 As Single = {(IsNetCoreApp ? "3.0001234E+13!" : "3.00012337E+13!")} ' Dev11 & Roslyn: 3.00012337E+13!
Const f9 As Single = {(IsNetCoreApp ? "3.0001234E+13F" : "3.00012337E+13F")} ' Dev11 & Roslyn: 3.00012337E+13F
Const f10 As Single = {(IsNetCoreApp ? "3000.1235F" : "3000.12354F")} ' Dev11 & Roslyn: 3000.12354F
Const f11 As Single = 0.0000003! ' Dev11 & Roslyn: 0.0000003!
Console.WriteLine(f1)
Console.WriteLine(f2)
Console.WriteLine(f3)
Console.WriteLine(f4)
Console.WriteLine(f5)
Console.WriteLine(f6)
Console.WriteLine(f7)
Console.WriteLine(f8)
Console.WriteLine(f9)
Console.WriteLine(f10)
Console.WriteLine(f11)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiteralsWithTrailingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const d1 As Double = 3.011000 ' Dev11 & Roslyn: 3.011
Const d2 As Double = 3.000000 ' Dev11 & Roslyn: 3.0
Const d3 As Double = 3.0 ' Dev11 & Roslyn: Unchanged
Const d4 As Double = 3000R ' Dev11 & Roslyn: 3000.0R
Const d5 As Double = 3000E+10# ' Dev11 & Roslyn: 30000000000000.0#
Const d6 As Double = 3000.0E+10 ' Dev11 & Roslyn: 30000000000000.0
Const d7 As Double = 3000.010E+1 ' Dev11 & Roslyn: 30000.1
Const d8 As Double = 3000.123456789010E+10# ' Dev11 & Roslyn: 30001234567890.1#
Const d9 As Double = 3000.123456789000E+10 ' Dev11 & Roslyn: 30001234567890.0
Const d10 As Double = 30001234567890.10E-10d ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Double = 3000E-10 ' Dev11 & Roslyn: 0.0000003
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const d1 As Double = 3.011 ' Dev11 & Roslyn: 3.011
Const d2 As Double = 3.0 ' Dev11 & Roslyn: 3.0
Const d3 As Double = 3.0 ' Dev11 & Roslyn: Unchanged
Const d4 As Double = 3000.0R ' Dev11 & Roslyn: 3000.0R
Const d5 As Double = 30000000000000.0# ' Dev11 & Roslyn: 30000000000000.0#
Const d6 As Double = 30000000000000.0 ' Dev11 & Roslyn: 30000000000000.0
Const d7 As Double = 30000.1 ' Dev11 & Roslyn: 30000.1
Const d8 As Double = 30001234567890.1# ' Dev11 & Roslyn: 30001234567890.1#
Const d9 As Double = 30001234567890.0 ' Dev11 & Roslyn: 30001234567890.0
Const d10 As Double = 3000.12345678901D ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Double = 0.0000003 ' Dev11 & Roslyn: 0.0000003
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiteralsWithTrailingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const d1 As Decimal = 3.011000D ' Dev11 & Roslyn: 3.011D
Const d2 As Decimal = 3.000000D ' Dev11 & Roslyn: 3D
Const d3 As Decimal = 3.0D ' Dev11 & Roslyn: 3D
Const d4 As Decimal = 3000D ' Dev11 & Roslyn: 3000D
Const d5 As Decimal = 3000E+10D ' Dev11 & Roslyn: 30000000000000D
Const d6 As Decimal = 3000.0E+10D ' Dev11 & Roslyn: 30000000000000D
Const d7 As Decimal = 3000.010E+1D ' Dev11 & Roslyn: 30000.1D
Const d8 As Decimal = 3000.123456789010E+10D ' Dev11 & Roslyn: 30001234567890.1D
Const d9 As Decimal = 3000.123456789000E+10D ' Dev11 & Roslyn: 30001234567890D
Const d10 As Decimal = 30001234567890.10E-10D ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Decimal = 3000E-10D ' Dev11 & Roslyn: 0.0000003D
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const d1 As Decimal = 3.011D ' Dev11 & Roslyn: 3.011D
Const d2 As Decimal = 3D ' Dev11 & Roslyn: 3D
Const d3 As Decimal = 3D ' Dev11 & Roslyn: 3D
Const d4 As Decimal = 3000D ' Dev11 & Roslyn: 3000D
Const d5 As Decimal = 30000000000000D ' Dev11 & Roslyn: 30000000000000D
Const d6 As Decimal = 30000000000000D ' Dev11 & Roslyn: 30000000000000D
Const d7 As Decimal = 30000.1D ' Dev11 & Roslyn: 30000.1D
Const d8 As Decimal = 30001234567890.1D ' Dev11 & Roslyn: 30001234567890.1D
Const d9 As Decimal = 30001234567890D ' Dev11 & Roslyn: 30001234567890D
Const d10 As Decimal = 3000.12345678901D ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Decimal = 0.0000003D ' Dev11 & Roslyn: 0.0000003D
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(623319, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/623319")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceFloatingAndDecimalLiteralsWithDifferentCulture()
{
var savedCulture = System.Threading.Thread.CurrentThread.CurrentCulture;
try
{
System.Threading.Thread.CurrentThread.CurrentCulture =
System.Globalization.CultureInfo.CreateSpecificCulture("de-DE");
var code = @"[|
Module Program
Sub Main(args As String())
Dim d = 1.0D
Dim f = 1.0F
Dim x = 1.0
End Sub
End Module|]";
var expected = @"
Module Program
Sub Main(args As String())
Dim d = 1D
Dim f = 1.0F
Dim x = 1.0
End Sub
End Module";
await VerifyAsync(code, expected);
}
finally
{
System.Threading.Thread.CurrentThread.CurrentCulture = savedCulture;
}
}
[Fact]
[WorkItem(652147, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/652147")]
public async Task ReduceFloatingAndDecimalLiteralsWithInvariantCultureNegatives()
{
var oldCulture = Thread.CurrentThread.CurrentCulture;
try
{
Thread.CurrentThread.CurrentCulture = (CultureInfo)oldCulture.Clone();
Thread.CurrentThread.CurrentCulture.NumberFormat.NegativeSign = "~";
var code = @"[|
Module Program
Sub Main(args As String())
Dim d = -1.0E-11D
Dim f = -1.0E-11F
Dim x = -1.0E-11
End Sub
End Module|]";
var expected = @"
Module Program
Sub Main(args As String())
Dim d = -0.00000000001D
Dim f = -1.0E-11F
Dim x = -0.00000000001
End Sub
End Module";
await VerifyAsync(code, expected);
}
finally
{
Thread.CurrentThread.CurrentCulture = oldCulture;
}
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceIntegerLiteralWithLeadingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const i0 As Integer = 0060
Const i1 As Integer = 0060%
Const i2 As Integer = &H006F
Const i3 As Integer = &O0060
Const i4 As Integer = 0060I
Const i5 As Integer = -0060
Const i6 As Integer = 000
Const i7 As UInteger = 0060UI
Const i8 As Integer = &H0000FFFFI
Const i9 As Integer = &O000
Const i10 As Integer = &H000
Const l0 As Long = 0060L
Const l1 As Long = 0060&
Const l2 As ULong = 0060UL
Const s0 As Short = 0060S
Const s1 As UShort = 0060US
Const s2 As Short = &H0000FFFFS
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const i0 As Integer = 60
Const i1 As Integer = 60%
Const i2 As Integer = &H6F
Const i3 As Integer = &O60
Const i4 As Integer = 60I
Const i5 As Integer = -60
Const i6 As Integer = 0
Const i7 As UInteger = 60UI
Const i8 As Integer = &HFFFFI
Const i9 As Integer = &O0
Const i10 As Integer = &H0
Const l0 As Long = 60L
Const l1 As Long = 60&
Const l2 As ULong = 60UL
Const s0 As Short = 60S
Const s1 As UShort = 60US
Const s2 As Short = &HFFFFS
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceIntegerLiteralWithNegativeHexOrOctalValue()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const s0 As Short = &HFFFFS
Const s1 As Short = &O177777S
Const s2 As Short = &H8000S
Const s3 As Short = &O100000S
Const i0 As Integer = &O37777777777I
Const i1 As Integer = &HFFFFFFFFI
Const i2 As Integer = &H80000000I
Const i3 As Integer = &O20000000000I
Const l0 As Long = &HFFFFFFFFFFFFFFFFL
Const l1 As Long = &O1777777777777777777777L
Const l2 As Long = &H8000000000000000L
Const l2 As Long = &O1000000000000000000000L
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const s0 As Short = &HFFFFS
Const s1 As Short = &O177777S
Const s2 As Short = &H8000S
Const s3 As Short = &O100000S
Const i0 As Integer = &O37777777777I
Const i1 As Integer = &HFFFFFFFFI
Const i2 As Integer = &H80000000I
Const i3 As Integer = &O20000000000I
Const l0 As Long = &HFFFFFFFFFFFFFFFFL
Const l1 As Long = &O1777777777777777777777L
Const l2 As Long = &H8000000000000000L
Const l2 As Long = &O1000000000000000000000L
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceIntegerLiteralWithOverflow()
{
var code = @"[|
Module Module1
Sub Main()
Dim sMax As Short = 0032768S
Dim usMax As UShort = 00655536US
Dim iMax As Integer = 002147483648I
Dim uiMax As UInteger = 004294967296UI
Dim lMax As Long = 009223372036854775808L
Dim ulMax As ULong = 0018446744073709551616UL
Dim z As Long = &O37777777777777777777777
Dim x As Long = &HFFFFFFFFFFFFFFFFF
End Sub
End Module
|]";
var expected = @"
Module Module1
Sub Main()
Dim sMax As Short = 0032768S
Dim usMax As UShort = 00655536US
Dim iMax As Integer = 002147483648I
Dim uiMax As UInteger = 004294967296UI
Dim lMax As Long = 009223372036854775808L
Dim ulMax As ULong = 0018446744073709551616UL
Dim z As Long = &O37777777777777777777777
Dim x As Long = &HFFFFFFFFFFFFFFFFF
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceBinaryIntegerLiteral()
{
var code = @"[|
Module Module1
Sub Main()
' signed
Dim a As SByte = &B0111
Dim b As Short = &B0101
Dim c As Integer = &B00100100
Dim d As Long = &B001001100110
' unsigned
Dim e As Byte = &B01011
Dim f As UShort = &B00100
Dim g As UInteger = &B001001100110
Dim h As ULong = &B001001100110
' negative
Dim i As SByte = -&B0111
Dim j As Short = -&B00101
Dim k As Integer = -&B00100100
Dim l As Long = -&B001001100110
' negative literal
Dim m As SByte = &B10000001
Dim n As Short = &B1000000000000001
Dim o As Integer = &B10000000000000000000000000000001
Dim p As Long = &B1000000000000000000000000000000000000000000000000000000000000001
End Sub
End Module
|]";
var expected = @"
Module Module1
Sub Main()
' signed
Dim a As SByte = &B111
Dim b As Short = &B101
Dim c As Integer = &B100100
Dim d As Long = &B1001100110
' unsigned
Dim e As Byte = &B1011
Dim f As UShort = &B100
Dim g As UInteger = &B1001100110
Dim h As ULong = &B1001100110
' negative
Dim i As SByte = -&B111
Dim j As Short = -&B101
Dim k As Integer = -&B100100
Dim l As Long = -&B1001100110
' negative literal
Dim m As SByte = &B10000001
Dim n As Short = &B1000000000000001
Dim o As Integer = &B10000000000000000000000000000001
Dim p As Long = &B1000000000000000000000000000000000000000000000000000000000000001
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(14034, "https://github.com/dotnet/roslyn/issues/14034")]
[WorkItem(48492, "https://github.com/dotnet/roslyn/issues/48492")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task DoNotReduceDigitSeparators()
{
var source = @"
Module Module1
Sub Main()
Dim x = 100_000
Dim y = 100_000.0F
Dim z = 100_000.0D
End Sub
End Module
";
var expected = source;
await VerifyAsync($"[|{source}|]", expected);
}
private static async Task VerifyAsync(string codeWithMarker, string expectedResult)
{
MarkupTestFile.GetSpans(codeWithMarker,
out var codeWithoutMarker, out ImmutableArray<TextSpan> textSpans);
var document = CreateDocument(codeWithoutMarker, LanguageNames.VisualBasic);
var codeCleanups = CodeCleaner.GetDefaultProviders(document).WhereAsArray(p => p.Name == PredefinedCodeCleanupProviderNames.ReduceTokens || p.Name == PredefinedCodeCleanupProviderNames.CaseCorrection || p.Name == PredefinedCodeCleanupProviderNames.Format);
var cleanDocument = await CodeCleaner.CleanupAsync(document, textSpans[0], codeCleanups);
AssertEx.EqualOrDiff(expectedResult, (await cleanDocument.GetSyntaxRootAsync()).ToFullString());
}
private static Document CreateDocument(string code, string language)
{
var solution = new AdhocWorkspace().CurrentSolution;
var projectId = ProjectId.CreateNewId();
var project = solution.AddProject(projectId, "Project", "Project.dll", language).GetProject(projectId);
return project.AddMetadataReference(TestMetadata.Net451.mscorlib)
.AddDocument("Document", SourceText.From(code));
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Collections.Immutable;
using System.Globalization;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.CodeCleanup;
using Microsoft.CodeAnalysis.CodeCleanup.Providers;
using Microsoft.CodeAnalysis.Test.Utilities;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.UnitTests.CodeCleanup
{
[UseExportProvider]
public class ReduceTokenTests
{
#if NETCOREAPP
private static bool IsNetCoreApp => true;
#else
private static bool IsNetCoreApp => false;
#endif
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_LessThan8Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = .14995F ' Dev11 & Roslyn: Pretty listed to 0.14995F
Const f_5_2 As Single = 0.14995f ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995F ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95f ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5F ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0f ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = .1499995F ' Dev11 & Roslyn: Pretty listed to 0.1499995F
Const f_7_2 As Single = 0.1499995f ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995F ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995f ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5F ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0f ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = 0.14995F ' Dev11 & Roslyn: Pretty listed to 0.14995F
Const f_5_2 As Single = 0.14995F ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995F ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95F ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5F ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0F ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = 0.1499995F ' Dev11 & Roslyn: Pretty listed to 0.1499995F
Const f_7_2 As Single = 0.1499995F ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995F ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995F ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5F ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0F ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_LessThan8Digits_WithTypeCharacterSingle()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = .14995! ' Dev11 & Roslyn: Pretty listed to 0.14995!
Const f_5_2 As Single = 0.14995! ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995! ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95! ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5! ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0! ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = .1499995! ' Dev11 & Roslyn: Pretty listed to 0.1499995!
Const f_7_2 As Single = 0.1499995! ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995! ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995! ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5! ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0! ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 8 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 5 significant digits
Const f_5_1 As Single = 0.14995! ' Dev11 & Roslyn: Pretty listed to 0.14995!
Const f_5_2 As Single = 0.14995! ' Dev11 & Roslyn: Unchanged
Const f_5_3 As Single = 1.4995! ' Dev11 & Roslyn: Unchanged
Const f_5_4 As Single = 149.95! ' Dev11 & Roslyn: Unchanged
Const f_5_5 As Single = 1499.5! ' Dev11 & Roslyn: Unchanged
Const f_5_6 As Single = 14995.0! ' Dev11 & Roslyn: Unchanged
' 7 significant digits
Const f_7_1 As Single = 0.1499995! ' Dev11 & Roslyn: Pretty listed to 0.1499995!
Const f_7_2 As Single = 0.1499995! ' Dev11 & Roslyn: Unchanged
Const f_7_3 As Single = 1.499995! ' Dev11 & Roslyn: Unchanged
Const f_7_4 As Single = 1499.995! ' Dev11 & Roslyn: Unchanged
Const f_7_5 As Single = 149999.5! ' Dev11 & Roslyn: Unchanged
Const f_7_6 As Single = 1499995.0! ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_5_1)
Console.WriteLine(f_5_2)
Console.WriteLine(f_5_3)
Console.WriteLine(f_5_4)
Console.WriteLine(f_5_5)
Console.WriteLine(f_5_6)
Console.WriteLine(f_7_1)
Console.WriteLine(f_7_2)
Console.WriteLine(f_7_3)
Console.WriteLine(f_7_4)
Console.WriteLine(f_7_5)
Console.WriteLine(f_7_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_8Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = .14999795F ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = .14999797f ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797F ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = 1.4999794f ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = 1.4999797F ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = 1499.9794f ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = 1499979.7F ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0F ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = 0.14999795F ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = {(IsNetCoreApp ? "0.14999796F" : "0.149997965F")} ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797F ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = {(IsNetCoreApp ? "1.4999794F" : "1.49997938F")} ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = {(IsNetCoreApp ? "1.4999797F" : "1.49997973F")} ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = {(IsNetCoreApp ? "1499.9794F" : "1499.97937F")} ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = {(IsNetCoreApp ? "1499979.8F" : "1499979.75F")} ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0F ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_8Digits_WithTypeCharacterSingle()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = .14999795! ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = .14999797! ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797! ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = 1.4999794! ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = 1.4999797! ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = 1499.9794! ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = 1499979.7! ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0! ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
Const f_8_1 As Single = 0.14999795! ' Dev11 & Roslyn: 0.14999795F
Const f_8_2 As Single = {(IsNetCoreApp ? "0.14999796!" : "0.149997965!")} ' Dev11 & Roslyn: 0.149997965F
Const f_8_3 As Single = 0.1499797! ' Dev11 & Roslyn: Unchanged
Const f_8_4 As Single = {(IsNetCoreApp ? "1.4999794!" : "1.49997938!")} ' Dev11 & Roslyn: 1.49997938F
Const f_8_5 As Single = {(IsNetCoreApp ? "1.4999797!" : "1.49997973!")} ' Dev11 & Roslyn: 1.49997973F
Const f_8_6 As Single = {(IsNetCoreApp ? "1499.9794!" : "1499.97937!")} ' Dev11 & Roslyn: 1499.97937F
Const f_8_7 As Single = {(IsNetCoreApp ? "1499979.8!" : "1499979.75!")} ' Dev11 & Roslyn: 1499979.75F
Const f_8_8 As Single = 14999797.0! ' Dev11 & Roslyn: unchanged
Console.WriteLine(f_8_1)
Console.WriteLine(f_8_2)
Console.WriteLine(f_8_3)
Console.WriteLine(f_8_4)
Console.WriteLine(f_8_5)
Console.WriteLine(f_8_6)
Console.WriteLine(f_8_7)
Console.WriteLine(f_8_8)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_GreaterThan8Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = .149997938F ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = 0.149997931f ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = 1.49997965F ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = 14999.79652f ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = 149997965.2F ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = 1499979652.0f ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = 111111149999124689999.499F ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47F ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47F ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = {(IsNetCoreApp ? "0.14999793F" : "0.149997935F")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = {(IsNetCoreApp ? "0.14999793F" : "0.149997935F")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = {(IsNetCoreApp ? "1.4999796F" : "1.49997962F")} ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = {(IsNetCoreApp ? "14999.797F" : "14999.7969F")} ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = {(IsNetCoreApp ? "149997970.0F" : "149997968.0F")} ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = {(IsNetCoreApp ? "1.4999796E+9F" : "1.49997965E+9F")} ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = {(IsNetCoreApp ? "1.1111115E+20F" : "1.11111148E+20F")} ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39F ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47F ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47F ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiterals_GreaterThan8Digits_WithTypeCharacterSingle()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = .149997938! ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = 0.149997931! ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = 1.49997965! ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = 14999.79652! ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = 149997965.2! ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = 1499979652.0! ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = 111111149999124689999.499! ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47! ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47! ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 8 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 9 significant digits
' (a) > 8 significant digits overall, but < 8 digits before decimal point.
Const f_9_1 As Single = {(IsNetCoreApp ? "0.14999793!" : "0.149997935!")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_2 As Single = {(IsNetCoreApp ? "0.14999793!" : "0.149997935!")} ' Dev11 & Roslyn: 0.149997935F
Const f_9_3 As Single = {(IsNetCoreApp ? "1.4999796!" : "1.49997962!")} ' Dev11 & Roslyn: 1.49997962F
Const f_10_1 As Single = {(IsNetCoreApp ? "14999.797!" : "14999.7969!")} ' Dev11 & Roslyn: 14999.7969F
' (b) > 8 significant digits before decimal point.
Const f_10_2 As Single = {(IsNetCoreApp ? "149997970.0!" : "149997968.0!")} ' Dev11 & Roslyn: 149997968.0F
Const f_10_3 As Single = {(IsNetCoreApp ? "1.4999796E+9!" : "1.49997965E+9!")} ' Dev11 & Roslyn: 1.49997965E+9F
Const f_24_1 As Single = {(IsNetCoreApp ? "1.1111115E+20!" : "1.11111148E+20!")} ' Dev11 & Roslyn: 1.11111148E+20F
' (c) Overflow/Underflow cases for Single: Ensure no pretty listing/round off
' Holds signed IEEE 32-bit (4-byte) single-precision floating-point numbers ranging in value from -3.4028235E+38 through -1.401298E-45 for negative values and
' from 1.401298E-45 through 3.4028235E+38 for positive values.
Const f_overflow_1 As Single = -3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Single = 3.4028235E+39! ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Single = -1.401298E-47! ' Dev11: -0.0F, Roslyn: Unchanged
Const f_underflow_2 As Single = 1.401298E-47! ' Dev11: 0.0F, Roslyn: Unchanged
Console.WriteLine(f_9_1)
Console.WriteLine(f_9_2)
Console.WriteLine(f_9_3)
Console.WriteLine(f_10_1)
Console.WriteLine(f_10_2)
Console.WriteLine(f_10_3)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_LessThan16Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = .1499599999999 ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999 ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999 ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999 ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9 ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0 ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = .149999999999995 ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995 ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5 ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = 0.1499599999999 ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999 ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999 ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999 ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9 ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0 ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = 0.149999999999995 ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995 ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995 ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5 ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_LessThan16Digits_WithTypeCharacter()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = .1499599999999R ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999r ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999# ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999# ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9r ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0R ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = .149999999999995R ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995r ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995# ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995# ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5r ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 16 significant digits precision,
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 13 significant digits
Const f_13_1 As Double = 0.1499599999999R ' Dev11 & Roslyn: Pretty listed to 0.1499599999999
Const f_13_2 As Double = 0.149959999999R ' Dev11 & Roslyn: Unchanged
Const f_13_3 As Double = 1.499599999999# ' Dev11 & Roslyn: Unchanged
Const f_13_4 As Double = 1499599.999999# ' Dev11 & Roslyn: Unchanged
Const f_13_5 As Double = 149959999999.9R ' Dev11 & Roslyn: Unchanged
Const f_13_6 As Double = 1499599999999.0R ' Dev11 & Roslyn: Unchanged
' 15 significant digits
Const f_15_1 As Double = 0.149999999999995R ' Dev11 & Roslyn: Pretty listed to 0.149999999999995
Const f_15_2 As Double = 0.14999999999995R ' Dev11 & Roslyn: Unchanged
Const f_15_3 As Double = 1.49999999999995# ' Dev11 & Roslyn: Unchanged
Const f_15_4 As Double = 14999999.9999995# ' Dev11 & Roslyn: Unchanged
Const f_15_5 As Double = 14999999999999.5R ' Dev11 & Roslyn: Unchanged
Const f_15_6 As Double = 149999999999995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_13_1)
Console.WriteLine(f_13_2)
Console.WriteLine(f_13_3)
Console.WriteLine(f_13_4)
Console.WriteLine(f_13_5)
Console.WriteLine(f_13_6)
Console.WriteLine(f_15_1)
Console.WriteLine(f_15_2)
Console.WriteLine(f_15_3)
Console.WriteLine(f_15_4)
Console.WriteLine(f_15_5)
Console.WriteLine(f_15_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_16Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = .1499999999799993 ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = .1499999999799997 ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995 ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994 ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = 1.499999999799995 ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994 ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = 14999999.99799995 ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = 149999999997999.2 ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = 149999999997999.8 ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = 0.1499999999799993 ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = {(IsNetCoreApp ? "0.1499999999799997" : "0.14999999997999969")} ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995 ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994 ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = {(IsNetCoreApp ? "1.499999999799995" : "1.4999999997999951")} ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994 ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = {(IsNetCoreApp ? "14999999.99799995" : "14999999.997999949")} ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = {(IsNetCoreApp ? "149999999997999.2" : "149999999997999.19")} ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = {(IsNetCoreApp ? "149999999997999.8" : "149999999997999.81")} ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0 ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_16Digits_WithTypeCharacter()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = .1499999999799993R ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = .1499999999799997r ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995# ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994R ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = 1.499999999799995r ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994# ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = 14999999.99799995R ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = 149999999997999.2r ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = 149999999997999.8# ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 2: 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
Const f_16_1 As Double = 0.1499999999799993R ' Dev11 & Roslyn: 0.1499999999799993
Const f_16_2 As Double = {(IsNetCoreApp ? "0.1499999999799997R" : "0.14999999997999969R")} ' Dev11 & Roslyn: 0.14999999997999969
Const f_16_3 As Double = 0.149999999799995# ' Dev11 & Roslyn: Unchanged
Const f_16_4 As Double = 1.499999999799994R ' Dev11 & Roslyn: Unchanged
Const f_16_5 As Double = {(IsNetCoreApp ? "1.499999999799995R" : "1.4999999997999951R")} ' Dev11 & Roslyn: 1.4999999997999951
Const f_16_6 As Double = 14999999.99799994# ' Dev11 & Roslyn: Unchanged
Const f_16_7 As Double = {(IsNetCoreApp ? "14999999.99799995R" : "14999999.997999949R")} ' Dev11 & Roslyn: 14999999.997999949
Const f_16_8 As Double = {(IsNetCoreApp ? "149999999997999.2R" : "149999999997999.19R")} ' Dev11 & Roslyn: 149999999997999.19
Const f_16_9 As Double = {(IsNetCoreApp ? "149999999997999.8#" : "149999999997999.81#")} ' Dev11 & Roslyn: 149999999997999.81
Const f_16_10 As Double = 1499999999979995.0R ' Dev11 & Roslyn: Unchanged
Console.WriteLine(f_16_1)
Console.WriteLine(f_16_2)
Console.WriteLine(f_16_3)
Console.WriteLine(f_16_4)
Console.WriteLine(f_16_5)
Console.WriteLine(f_16_6)
Console.WriteLine(f_16_7)
Console.WriteLine(f_16_8)
Console.WriteLine(f_16_9)
Console.WriteLine(f_16_10)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_GreaterThan16Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = .14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = .14999999997999939 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = .14999999997999937 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957 ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = 0.1499999997999958 ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947 ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999945 ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999946 ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.9979999459 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.9979999451 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.9979999454 ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = 14999999999733999.2 ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379995.0 ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = 111111149999124689999.499 ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326 ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326 ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = 0.14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = 0.14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = 0.14999999997999938 ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957 ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = {(IsNetCoreApp ? "0.1499999997999958" : "0.14999999979999579")} ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947 ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999944 ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999947 ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.997999946 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.997999946 ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.997999946 ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = {(IsNetCoreApp ? "14999999999734000.0" : "1.4999999999734E+16")} ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379996.0 ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = {(IsNetCoreApp ? "1.111111499991247E+20" : "1.1111114999912469E+20")} ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309 ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326 ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326 ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiterals_GreaterThan16Digits_WithTypeCharacter()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = .14999999997999938R ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = .14999999997999939r ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = .14999999997999937# ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957R ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = 0.1499999997999958r ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947# ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999945R ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999946r ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.9979999459# ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.9979999451R ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.9979999454r ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = 14999999999733999.2# ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379995.0R ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = 111111149999124689999.499r ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309# ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309R ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326r ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326# ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 16 significant digits
' Dev11 and Roslyn behavior are identical: Always rounded off and pretty listed to <= 17 significant digits
' (a) > 16 significant digits overall, but < 16 digits before decimal point.
Const f_17_1 As Double = 0.14999999997999938R ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_2 As Double = 0.14999999997999938R ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_3 As Double = 0.14999999997999938# ' Dev11 & Roslyn: 0.14999999997999938
Const f_17_4 As Double = 0.1499999997999957R ' Dev11 & Roslyn: Unchanged
Const f_17_5 As Double = {(IsNetCoreApp ? "0.1499999997999958R" : "0.14999999979999579R")} ' Dev11 & Roslyn: 0.14999999979999579
Const f_17_6 As Double = 1.4999999997999947# ' Dev11 & Roslyn: Unchanged
Const f_17_7 As Double = 1.4999999997999944R ' Dev11 & Roslyn: 1.4999999997999944
Const f_17_8 As Double = 1.4999999997999947R ' Dev11 & Roslyn: 1.4999999997999947
Const f_18_1 As Double = 14999999.997999946# ' Dev11 & Roslyn: 14999999.997999946
Const f_18_2 As Double = 14999999.997999946R ' Dev11 & Roslyn: 14999999.997999946
Const f_18_3 As Double = 14999999.997999946R ' Dev11 & Roslyn: 14999999.997999946
' (b) > 16 significant digits before decimal point.
Const f_18_4 As Double = {(IsNetCoreApp ? "14999999999734000.0#" : "1.4999999999734E+16#")} ' Dev11 & Roslyn: 1.4999999999734E+16
Const f_18_5 As Double = 14999999999379996.0R ' Dev11 & Roslyn: 14999999999379996.0
Const f_24_1 As Double = {(IsNetCoreApp ? "1.111111499991247E+20R" : "1.1111114999912469E+20R")} ' Dev11 & Roslyn: 1.1111114999912469E+20
' (c) Overflow/Underflow cases for Double: Ensure no pretty listing/round off
' Holds signed IEEE 64-bit (8-byte) double-precision floating-point numbers ranging in value from -1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values and
' from 4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values.
Const f_overflow_1 As Double = -1.79769313486231570E+309# ' Dev11 & Roslyn: Unchanged
Const f_overflow_2 As Double = 1.79769313486231570E+309R ' Dev11 & Roslyn: Unchanged
Const f_underflow_1 As Double = -4.94065645841246544E-326R ' Dev11: -0.0F, Roslyn: unchanged
Const f_underflow_2 As Double = 4.94065645841246544E-326# ' Dev11: 0.0F, Roslyn: unchanged
Console.WriteLine(f_17_1)
Console.WriteLine(f_17_2)
Console.WriteLine(f_17_3)
Console.WriteLine(f_17_4)
Console.WriteLine(f_17_5)
Console.WriteLine(f_17_6)
Console.WriteLine(f_17_7)
Console.WriteLine(f_17_8)
Console.WriteLine(f_18_1)
Console.WriteLine(f_18_2)
Console.WriteLine(f_18_3)
Console.WriteLine(f_18_4)
Console.WriteLine(f_18_5)
Console.WriteLine(f_24_1)
Console.WriteLine(f_overflow_1)
Console.WriteLine(f_overflow_2)
Console.WriteLine(f_underflow_1)
Console.WriteLine(f_underflow_2)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_LessThan30Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = .123456789012345678901234567D ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567d ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567d ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7D ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567.0d ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = .12345678901234567890123456789D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_2 As Decimal = 0.12345678901234567890123456789d ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789d ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9D ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789.0d ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = 0.123456789012345678901234567D ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567D ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7D ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567D ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_2 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_29_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789D ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9D ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789D ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_LessThan30Digits_WithTypeCharacterDecimal()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = .123456789012345678901234567@ ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7@ ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567.0@ ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = .12345678901234567890123456789@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_2 As Decimal = 0.12345678901234567890123456789@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_3 As Decimal = 1.2345678901234567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9@ ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789.0@ ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 1: Less than 30 significant digits
' Dev11 and Roslyn behavior are identical: UNCHANGED
' 27 significant digits
Const d_27_1 As Decimal = 0.123456789012345678901234567@ ' Dev11 & Roslyn: Pretty listed to 0.123456789012345678901234567D
Const d_27_2 As Decimal = 0.123456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_3 As Decimal = 1.23456789012345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_4 As Decimal = 123456789012.345678901234567@ ' Dev11 & Roslyn: Unchanged
Const d_27_5 As Decimal = 12345678901234567890123456.7@ ' Dev11 & Roslyn: Unchanged
Const d_27_6 As Decimal = 123456789012345678901234567@ ' Dev11 & Roslyn: Pretty listed to 123456789012345678901234567D
' 29 significant digits
Const d_29_1 As Decimal = 0.1234567890123456789012345679@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_2 As Decimal = 0.1234567890123456789012345679@ ' Dev11 & Roslyn: 0.1234567890123456789012345679@
Const d_29_3 As Decimal = 1.2345678901234567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_4 As Decimal = 123456789012.34567890123456789@ ' Dev11 & Roslyn: Unchanged
Const d_29_5 As Decimal = 1234567890123456789012345678.9@ ' Dev11 & Roslyn: Unchanged
Const d_29_6 As Decimal = 12345678901234567890123456789@ ' Dev11 & Roslyn: Pretty listed to 12345678901234567890123456789D
Console.WriteLine(d_27_1)
Console.WriteLine(d_27_2)
Console.WriteLine(d_27_3)
Console.WriteLine(d_27_4)
Console.WriteLine(d_27_5)
Console.WriteLine(d_27_6)
Console.WriteLine(d_29_1)
Console.WriteLine(d_29_2)
Console.WriteLine(d_29_3)
Console.WriteLine(d_29_4)
Console.WriteLine(d_29_5)
Console.WriteLine(d_29_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_30Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = .123456789012345678901234567891D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345687891D ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.23456789012345678901234567891D ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.678901234567891D ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789.1D ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0D ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345688D ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.67890123456789D ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789D ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0D ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_30Digits_WithTypeCharacterDecimal()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = .123456789012345678901234567891@ ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345687891@ ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.23456789012345678901234567891@ ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.678901234567891@ ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789.1@ ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0@ ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 2: 30 significant digits
' Dev11 & Roslyn have identical behavior: pretty listed and round off to <= 29 significant digits
Const d_30_1 As Decimal = 0.1234567890123456789012345679@ ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_30_2 As Decimal = 0.1234567890123456789012345688@ ' Dev11 & Roslyn: 0.1234567890123456789012345688D
Const d_30_3 As Decimal = 1.2345678901234567890123456789@ ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_30_4 As Decimal = 123456789012345.67890123456789@ ' Dev11 & Roslyn: 123456789012345.67890123456789D
Const d_30_5 As Decimal = 12345678901234567890123456789@ ' Dev11 & Roslyn: 12345678901234567890123456789D
' Overflow case 30 significant digits before decimal place: Ensure no pretty listing.
Const d_30_6 As Decimal = 123456789012345678901234567891.0@ ' Dev11 & Roslyn: 123456789012345678901234567891.0D
Console.WriteLine(d_30_1)
Console.WriteLine(d_30_2)
Console.WriteLine(d_30_3)
Console.WriteLine(d_30_4)
Console.WriteLine(d_30_5)
Console.WriteLine(d_30_6)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiterals_GreaterThan30Digits()
{
var code = @"[|
Module Program
Sub Main(args As String())
' CATEGORY 3: > 30 significant digits
' Dev11 has unpredictable behavior: pretty listed/round off to wrong values in certain cases
' Roslyn behavior: Always rounded off + pretty listed to <= 29 significant digits
' (a) > 30 significant digits overall, but < 30 digits before decimal point.
Const d_32_1 As Decimal = .12345678901234567890123456789012D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_32_2 As Decimal = 0.123456789012345678901234568789012@ ' Dev11 & Roslyn: 0.1234567890123456789012345688@
Const d_32_3 As Decimal = 1.2345678901234567890123456789012d ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_32_4 As Decimal = 123456789012345.67890123456789012@ ' Dev11 & Roslyn: 123456789012345.67890123456789@
' (b) > 30 significant digits before decimal point (Overflow case): Ensure no pretty listing.
Const d_35_1 As Decimal = 123456789012345678901234567890123.45D ' Dev11 & Roslyn: 123456789012345678901234567890123.45D
Console.WriteLine(d_32_1)
Console.WriteLine(d_32_2)
Console.WriteLine(d_32_3)
Console.WriteLine(d_32_4)
Console.WriteLine(d_35_1)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
' CATEGORY 3: > 30 significant digits
' Dev11 has unpredictable behavior: pretty listed/round off to wrong values in certain cases
' Roslyn behavior: Always rounded off + pretty listed to <= 29 significant digits
' (a) > 30 significant digits overall, but < 30 digits before decimal point.
Const d_32_1 As Decimal = 0.1234567890123456789012345679D ' Dev11 & Roslyn: 0.1234567890123456789012345679D
Const d_32_2 As Decimal = 0.1234567890123456789012345688@ ' Dev11 & Roslyn: 0.1234567890123456789012345688@
Const d_32_3 As Decimal = 1.2345678901234567890123456789D ' Dev11 & Roslyn: 1.2345678901234567890123456789D
Const d_32_4 As Decimal = 123456789012345.67890123456789@ ' Dev11 & Roslyn: 123456789012345.67890123456789@
' (b) > 30 significant digits before decimal point (Overflow case): Ensure no pretty listing.
Const d_35_1 As Decimal = 123456789012345678901234567890123.45D ' Dev11 & Roslyn: 123456789012345678901234567890123.45D
Console.WriteLine(d_32_1)
Console.WriteLine(d_32_2)
Console.WriteLine(d_32_3)
Console.WriteLine(d_32_4)
Console.WriteLine(d_35_1)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceFloatLiteralsWithNegativeExponents()
{
var code = @"[|
Module Program
Sub Main(args As String())
' Floating point values might be represented either in fixed point notation or scientific/exponent notation.
' MSDN comment for Standard Numeric Format Strings used in Single.ToString(String) API (or Double.ToString(String)):
' Fixed-point notation is used if the exponent that would result from expressing the number in scientific notation is greater than -5 and
' less than the precision specifier; otherwise, scientific notation is used.
'
' However, Dev11 pretty lister differs from this for floating point values < 0. It uses fixed point notation as long as exponent is greater than '-(actualPrecision + 1)'.
' For example, consider Single Floating literals:
' (i) Precision = 7
' 0.0000001234567F => 0.0000001234567F (exponent = -7: fixed point notation)
' 0.00000001234567F => 0.00000001234567F (exponent = -8: fixed point notation)
' 0.000000001234567F => 1.234567E-9F (exponent = -9: exponent notation)
' 0.0000000001234567F => 1.234567E-10F (exponent = -10: exponent notation)
' (ii) Precision = 9
' 0.0000000012345678F => 0.00000000123456778F (exponent = -9: fixed point notation)
' 0.00000000012345678F => 0.000000000123456786F (exponent = -10: fixed point notation)
' 0.000000000012345678F => 1.23456783E-11F (exponent = -11: exponent notation)
' 0.0000000000012345678F => 1.23456779E-12F (exponent = -12: exponent notation)
Const f_1 As Single = 0.000001234567F
Const f_2 As Single = 0.0000001234567F
Const f_3 As Single = 0.00000001234567F
Const f_4 As Single = 0.000000001234567F ' Change at -9
Const f_5 As Single = 0.0000000001234567F
Const f_6 As Single = 0.00000000123456778F
Const f_7 As Single = 0.000000000123456786F
Const f_8 As Single = 0.000000000012345678F ' Change at -11
Const f_9 As Single = 0.0000000000012345678F
Const d_1 As Single = 0.00000000000000123456789012345
Const d_2 As Single = 0.000000000000000123456789012345
Const d_3 As Single = 0.0000000000000000123456789012345 ' Change at -17
Const d_4 As Single = 0.00000000000000000123456789012345
Const d_5 As Double = 0.00000000000000001234567890123456
Const d_6 As Double = 0.000000000000000001234567890123456
Const d_7 As Double = 0.0000000000000000001234567890123456 ' Change at -19
Const d_8 As Double = 0.00000000000000000001234567890123456
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
' Floating point values might be represented either in fixed point notation or scientific/exponent notation.
' MSDN comment for Standard Numeric Format Strings used in Single.ToString(String) API (or Double.ToString(String)):
' Fixed-point notation is used if the exponent that would result from expressing the number in scientific notation is greater than -5 and
' less than the precision specifier; otherwise, scientific notation is used.
'
' However, Dev11 pretty lister differs from this for floating point values < 0. It uses fixed point notation as long as exponent is greater than '-(actualPrecision + 1)'.
' For example, consider Single Floating literals:
' (i) Precision = 7
' 0.0000001234567F => 0.0000001234567F (exponent = -7: fixed point notation)
' 0.00000001234567F => 0.00000001234567F (exponent = -8: fixed point notation)
' 0.000000001234567F => 1.234567E-9F (exponent = -9: exponent notation)
' 0.0000000001234567F => 1.234567E-10F (exponent = -10: exponent notation)
' (ii) Precision = 9
' 0.0000000012345678F => 0.00000000123456778F (exponent = -9: fixed point notation)
' 0.00000000012345678F => 0.000000000123456786F (exponent = -10: fixed point notation)
' 0.000000000012345678F => 1.23456783E-11F (exponent = -11: exponent notation)
' 0.0000000000012345678F => 1.23456779E-12F (exponent = -12: exponent notation)
Const f_1 As Single = 0.000001234567F
Const f_2 As Single = 0.0000001234567F
Const f_3 As Single = 0.00000001234567F
Const f_4 As Single = 1.234567E-9F ' Change at -9
Const f_5 As Single = 1.234567E-10F
Const f_6 As Single = {(IsNetCoreApp ? "0.0000000012345678F" : "0.00000000123456778F")}
Const f_7 As Single = {(IsNetCoreApp ? "0.00000000012345679F" : "0.000000000123456786F")}
Const f_8 As Single = {(IsNetCoreApp ? "1.2345678E-11F" : "1.23456783E-11F")} ' Change at -11
Const f_9 As Single = {(IsNetCoreApp ? "1.2345678E-12F" : "1.23456779E-12F")}
Const d_1 As Single = 0.00000000000000123456789012345
Const d_2 As Single = 0.000000000000000123456789012345
Const d_3 As Single = 1.23456789012345E-17 ' Change at -17
Const d_4 As Single = 1.23456789012345E-18
Const d_5 As Double = {(IsNetCoreApp ? "0.00000000000000001234567890123456" : "0.000000000000000012345678901234561")}
Const d_6 As Double = 0.000000000000000001234567890123456
Const d_7 As Double = {(IsNetCoreApp ? "1.234567890123456E-19" : "1.2345678901234561E-19")} ' Change at -19
Const d_8 As Double = 1.234567890123456E-20
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceSingleLiteralsWithTrailingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const f1 As Single = 3.011000F ' Dev11 & Roslyn: 3.011F
Const f2 As Single = 3.000000! ' Dev11 & Roslyn: 3.0!
Const f3 As Single = 3.0F ' Dev11 & Roslyn: Unchanged
Const f4 As Single = 3000f ' Dev11 & Roslyn: 3000.0F
Const f5 As Single = 3000E+10! ' Dev11 & Roslyn: 3.0E+13!
Const f6 As Single = 3000.0E+10F ' Dev11 & Roslyn: 3.0E+13F
Const f7 As Single = 3000.010E+1F ' Dev11 & Roslyn: 30000.1F
Const f8 As Single = 3000.123456789010E+10! ' Dev11 & Roslyn: 3.00012337E+13!
Const f9 As Single = 3000.123456789000E+10F ' Dev11 & Roslyn: 3.00012337E+13F
Const f10 As Single = 30001234567890.10E-10f ' Dev11 & Roslyn: 3000.12354F
Const f11 As Single = 3000E-10! ' Dev11 & Roslyn: 0.0000003!
Console.WriteLine(f1)
Console.WriteLine(f2)
Console.WriteLine(f3)
Console.WriteLine(f4)
Console.WriteLine(f5)
Console.WriteLine(f6)
Console.WriteLine(f7)
Console.WriteLine(f8)
Console.WriteLine(f9)
Console.WriteLine(f10)
Console.WriteLine(f11)
End Sub
End Module
|]";
var expected = $@"
Module Program
Sub Main(args As String())
Const f1 As Single = 3.011F ' Dev11 & Roslyn: 3.011F
Const f2 As Single = 3.0! ' Dev11 & Roslyn: 3.0!
Const f3 As Single = 3.0F ' Dev11 & Roslyn: Unchanged
Const f4 As Single = 3000.0F ' Dev11 & Roslyn: 3000.0F
Const f5 As Single = 3.0E+13! ' Dev11 & Roslyn: 3.0E+13!
Const f6 As Single = 3.0E+13F ' Dev11 & Roslyn: 3.0E+13F
Const f7 As Single = 30000.1F ' Dev11 & Roslyn: 30000.1F
Const f8 As Single = {(IsNetCoreApp ? "3.0001234E+13!" : "3.00012337E+13!")} ' Dev11 & Roslyn: 3.00012337E+13!
Const f9 As Single = {(IsNetCoreApp ? "3.0001234E+13F" : "3.00012337E+13F")} ' Dev11 & Roslyn: 3.00012337E+13F
Const f10 As Single = {(IsNetCoreApp ? "3000.1235F" : "3000.12354F")} ' Dev11 & Roslyn: 3000.12354F
Const f11 As Single = 0.0000003! ' Dev11 & Roslyn: 0.0000003!
Console.WriteLine(f1)
Console.WriteLine(f2)
Console.WriteLine(f3)
Console.WriteLine(f4)
Console.WriteLine(f5)
Console.WriteLine(f6)
Console.WriteLine(f7)
Console.WriteLine(f8)
Console.WriteLine(f9)
Console.WriteLine(f10)
Console.WriteLine(f11)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDoubleLiteralsWithTrailingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const d1 As Double = 3.011000 ' Dev11 & Roslyn: 3.011
Const d2 As Double = 3.000000 ' Dev11 & Roslyn: 3.0
Const d3 As Double = 3.0 ' Dev11 & Roslyn: Unchanged
Const d4 As Double = 3000R ' Dev11 & Roslyn: 3000.0R
Const d5 As Double = 3000E+10# ' Dev11 & Roslyn: 30000000000000.0#
Const d6 As Double = 3000.0E+10 ' Dev11 & Roslyn: 30000000000000.0
Const d7 As Double = 3000.010E+1 ' Dev11 & Roslyn: 30000.1
Const d8 As Double = 3000.123456789010E+10# ' Dev11 & Roslyn: 30001234567890.1#
Const d9 As Double = 3000.123456789000E+10 ' Dev11 & Roslyn: 30001234567890.0
Const d10 As Double = 30001234567890.10E-10d ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Double = 3000E-10 ' Dev11 & Roslyn: 0.0000003
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const d1 As Double = 3.011 ' Dev11 & Roslyn: 3.011
Const d2 As Double = 3.0 ' Dev11 & Roslyn: 3.0
Const d3 As Double = 3.0 ' Dev11 & Roslyn: Unchanged
Const d4 As Double = 3000.0R ' Dev11 & Roslyn: 3000.0R
Const d5 As Double = 30000000000000.0# ' Dev11 & Roslyn: 30000000000000.0#
Const d6 As Double = 30000000000000.0 ' Dev11 & Roslyn: 30000000000000.0
Const d7 As Double = 30000.1 ' Dev11 & Roslyn: 30000.1
Const d8 As Double = 30001234567890.1# ' Dev11 & Roslyn: 30001234567890.1#
Const d9 As Double = 30001234567890.0 ' Dev11 & Roslyn: 30001234567890.0
Const d10 As Double = 3000.12345678901D ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Double = 0.0000003 ' Dev11 & Roslyn: 0.0000003
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(5529, "DevDiv_Projects/Roslyn")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceDecimalLiteralsWithTrailingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const d1 As Decimal = 3.011000D ' Dev11 & Roslyn: 3.011D
Const d2 As Decimal = 3.000000D ' Dev11 & Roslyn: 3D
Const d3 As Decimal = 3.0D ' Dev11 & Roslyn: 3D
Const d4 As Decimal = 3000D ' Dev11 & Roslyn: 3000D
Const d5 As Decimal = 3000E+10D ' Dev11 & Roslyn: 30000000000000D
Const d6 As Decimal = 3000.0E+10D ' Dev11 & Roslyn: 30000000000000D
Const d7 As Decimal = 3000.010E+1D ' Dev11 & Roslyn: 30000.1D
Const d8 As Decimal = 3000.123456789010E+10D ' Dev11 & Roslyn: 30001234567890.1D
Const d9 As Decimal = 3000.123456789000E+10D ' Dev11 & Roslyn: 30001234567890D
Const d10 As Decimal = 30001234567890.10E-10D ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Decimal = 3000E-10D ' Dev11 & Roslyn: 0.0000003D
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const d1 As Decimal = 3.011D ' Dev11 & Roslyn: 3.011D
Const d2 As Decimal = 3D ' Dev11 & Roslyn: 3D
Const d3 As Decimal = 3D ' Dev11 & Roslyn: 3D
Const d4 As Decimal = 3000D ' Dev11 & Roslyn: 3000D
Const d5 As Decimal = 30000000000000D ' Dev11 & Roslyn: 30000000000000D
Const d6 As Decimal = 30000000000000D ' Dev11 & Roslyn: 30000000000000D
Const d7 As Decimal = 30000.1D ' Dev11 & Roslyn: 30000.1D
Const d8 As Decimal = 30001234567890.1D ' Dev11 & Roslyn: 30001234567890.1D
Const d9 As Decimal = 30001234567890D ' Dev11 & Roslyn: 30001234567890D
Const d10 As Decimal = 3000.12345678901D ' Dev11 & Roslyn: 3000.12345678901D
Const d11 As Decimal = 0.0000003D ' Dev11 & Roslyn: 0.0000003D
Console.WriteLine(d1)
Console.WriteLine(d2)
Console.WriteLine(d3)
Console.WriteLine(d4)
Console.WriteLine(d5)
Console.WriteLine(d6)
Console.WriteLine(d7)
Console.WriteLine(d8)
Console.WriteLine(d9)
Console.WriteLine(d10)
Console.WriteLine(d11)
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(623319, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/623319")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceFloatingAndDecimalLiteralsWithDifferentCulture()
{
var savedCulture = System.Threading.Thread.CurrentThread.CurrentCulture;
try
{
System.Threading.Thread.CurrentThread.CurrentCulture =
System.Globalization.CultureInfo.CreateSpecificCulture("de-DE");
var code = @"[|
Module Program
Sub Main(args As String())
Dim d = 1.0D
Dim f = 1.0F
Dim x = 1.0
End Sub
End Module|]";
var expected = @"
Module Program
Sub Main(args As String())
Dim d = 1D
Dim f = 1.0F
Dim x = 1.0
End Sub
End Module";
await VerifyAsync(code, expected);
}
finally
{
System.Threading.Thread.CurrentThread.CurrentCulture = savedCulture;
}
}
[Fact]
[WorkItem(652147, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/652147")]
public async Task ReduceFloatingAndDecimalLiteralsWithInvariantCultureNegatives()
{
var oldCulture = Thread.CurrentThread.CurrentCulture;
try
{
Thread.CurrentThread.CurrentCulture = (CultureInfo)oldCulture.Clone();
Thread.CurrentThread.CurrentCulture.NumberFormat.NegativeSign = "~";
var code = @"[|
Module Program
Sub Main(args As String())
Dim d = -1.0E-11D
Dim f = -1.0E-11F
Dim x = -1.0E-11
End Sub
End Module|]";
var expected = @"
Module Program
Sub Main(args As String())
Dim d = -0.00000000001D
Dim f = -1.0E-11F
Dim x = -0.00000000001
End Sub
End Module";
await VerifyAsync(code, expected);
}
finally
{
Thread.CurrentThread.CurrentCulture = oldCulture;
}
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceIntegerLiteralWithLeadingZeros()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const i0 As Integer = 0060
Const i1 As Integer = 0060%
Const i2 As Integer = &H006F
Const i3 As Integer = &O0060
Const i4 As Integer = 0060I
Const i5 As Integer = -0060
Const i6 As Integer = 000
Const i7 As UInteger = 0060UI
Const i8 As Integer = &H0000FFFFI
Const i9 As Integer = &O000
Const i10 As Integer = &H000
Const l0 As Long = 0060L
Const l1 As Long = 0060&
Const l2 As ULong = 0060UL
Const s0 As Short = 0060S
Const s1 As UShort = 0060US
Const s2 As Short = &H0000FFFFS
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const i0 As Integer = 60
Const i1 As Integer = 60%
Const i2 As Integer = &H6F
Const i3 As Integer = &O60
Const i4 As Integer = 60I
Const i5 As Integer = -60
Const i6 As Integer = 0
Const i7 As UInteger = 60UI
Const i8 As Integer = &HFFFFI
Const i9 As Integer = &O0
Const i10 As Integer = &H0
Const l0 As Long = 60L
Const l1 As Long = 60&
Const l2 As ULong = 60UL
Const s0 As Short = 60S
Const s1 As UShort = 60US
Const s2 As Short = &HFFFFS
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceIntegerLiteralWithNegativeHexOrOctalValue()
{
var code = @"[|
Module Program
Sub Main(args As String())
Const s0 As Short = &HFFFFS
Const s1 As Short = &O177777S
Const s2 As Short = &H8000S
Const s3 As Short = &O100000S
Const i0 As Integer = &O37777777777I
Const i1 As Integer = &HFFFFFFFFI
Const i2 As Integer = &H80000000I
Const i3 As Integer = &O20000000000I
Const l0 As Long = &HFFFFFFFFFFFFFFFFL
Const l1 As Long = &O1777777777777777777777L
Const l2 As Long = &H8000000000000000L
Const l2 As Long = &O1000000000000000000000L
End Sub
End Module
|]";
var expected = @"
Module Program
Sub Main(args As String())
Const s0 As Short = &HFFFFS
Const s1 As Short = &O177777S
Const s2 As Short = &H8000S
Const s3 As Short = &O100000S
Const i0 As Integer = &O37777777777I
Const i1 As Integer = &HFFFFFFFFI
Const i2 As Integer = &H80000000I
Const i3 As Integer = &O20000000000I
Const l0 As Long = &HFFFFFFFFFFFFFFFFL
Const l1 As Long = &O1777777777777777777777L
Const l2 As Long = &H8000000000000000L
Const l2 As Long = &O1000000000000000000000L
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceIntegerLiteralWithOverflow()
{
var code = @"[|
Module Module1
Sub Main()
Dim sMax As Short = 0032768S
Dim usMax As UShort = 00655536US
Dim iMax As Integer = 002147483648I
Dim uiMax As UInteger = 004294967296UI
Dim lMax As Long = 009223372036854775808L
Dim ulMax As ULong = 0018446744073709551616UL
Dim z As Long = &O37777777777777777777777
Dim x As Long = &HFFFFFFFFFFFFFFFFF
End Sub
End Module
|]";
var expected = @"
Module Module1
Sub Main()
Dim sMax As Short = 0032768S
Dim usMax As UShort = 00655536US
Dim iMax As Integer = 002147483648I
Dim uiMax As UInteger = 004294967296UI
Dim lMax As Long = 009223372036854775808L
Dim ulMax As ULong = 0018446744073709551616UL
Dim z As Long = &O37777777777777777777777
Dim x As Long = &HFFFFFFFFFFFFFFFFF
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task ReduceBinaryIntegerLiteral()
{
var code = @"[|
Module Module1
Sub Main()
' signed
Dim a As SByte = &B0111
Dim b As Short = &B0101
Dim c As Integer = &B00100100
Dim d As Long = &B001001100110
' unsigned
Dim e As Byte = &B01011
Dim f As UShort = &B00100
Dim g As UInteger = &B001001100110
Dim h As ULong = &B001001100110
' negative
Dim i As SByte = -&B0111
Dim j As Short = -&B00101
Dim k As Integer = -&B00100100
Dim l As Long = -&B001001100110
' negative literal
Dim m As SByte = &B10000001
Dim n As Short = &B1000000000000001
Dim o As Integer = &B10000000000000000000000000000001
Dim p As Long = &B1000000000000000000000000000000000000000000000000000000000000001
End Sub
End Module
|]";
var expected = @"
Module Module1
Sub Main()
' signed
Dim a As SByte = &B111
Dim b As Short = &B101
Dim c As Integer = &B100100
Dim d As Long = &B1001100110
' unsigned
Dim e As Byte = &B1011
Dim f As UShort = &B100
Dim g As UInteger = &B1001100110
Dim h As ULong = &B1001100110
' negative
Dim i As SByte = -&B111
Dim j As Short = -&B101
Dim k As Integer = -&B100100
Dim l As Long = -&B1001100110
' negative literal
Dim m As SByte = &B10000001
Dim n As Short = &B1000000000000001
Dim o As Integer = &B10000000000000000000000000000001
Dim p As Long = &B1000000000000000000000000000000000000000000000000000000000000001
End Sub
End Module
";
await VerifyAsync(code, expected);
}
[Fact]
[WorkItem(14034, "https://github.com/dotnet/roslyn/issues/14034")]
[WorkItem(48492, "https://github.com/dotnet/roslyn/issues/48492")]
[Trait(Traits.Feature, Traits.Features.ReduceTokens)]
public async Task DoNotReduceDigitSeparators()
{
var source = @"
Module Module1
Sub Main()
Dim x = 100_000
Dim y = 100_000.0F
Dim z = 100_000.0D
End Sub
End Module
";
var expected = source;
await VerifyAsync($"[|{source}|]", expected);
}
private static async Task VerifyAsync(string codeWithMarker, string expectedResult)
{
MarkupTestFile.GetSpans(codeWithMarker,
out var codeWithoutMarker, out ImmutableArray<TextSpan> textSpans);
var document = CreateDocument(codeWithoutMarker, LanguageNames.VisualBasic);
var codeCleanups = CodeCleaner.GetDefaultProviders(document).WhereAsArray(p => p.Name == PredefinedCodeCleanupProviderNames.ReduceTokens || p.Name == PredefinedCodeCleanupProviderNames.CaseCorrection || p.Name == PredefinedCodeCleanupProviderNames.Format);
var cleanDocument = await CodeCleaner.CleanupAsync(document, textSpans[0], codeCleanups);
AssertEx.EqualOrDiff(expectedResult, (await cleanDocument.GetSyntaxRootAsync()).ToFullString());
}
private static Document CreateDocument(string code, string language)
{
var solution = new AdhocWorkspace().CurrentSolution;
var projectId = ProjectId.CreateNewId();
var project = solution.AddProject(projectId, "Project", "Project.dll", language).GetProject(projectId);
return project.AddMetadataReference(TestMetadata.Net451.mscorlib)
.AddDocument("Document", SourceText.From(code));
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/CSharp/Portable/Syntax/ArrayRankSpecifierSyntax.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
namespace Microsoft.CodeAnalysis.CSharp.Syntax
{
public partial class ArrayRankSpecifierSyntax
{
public int Rank
{
get
{
return this.Sizes.Count;
}
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
namespace Microsoft.CodeAnalysis.CSharp.Syntax
{
public partial class ArrayRankSpecifierSyntax
{
public int Rank
{
get
{
return this.Sizes.Count;
}
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/EditorFeatures/CSharpTest/EditAndContinue/SyntaxUtilitiesTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Linq;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Roslyn.Test.Utilities;
using Xunit;
using SyntaxUtilities = Microsoft.CodeAnalysis.CSharp.EditAndContinue.SyntaxUtilities;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.EditAndContinue
{
public class SyntaxUtilitiesTests
{
private static void VerifySyntaxMap(string oldSource, string newSource)
{
var oldRoot = SyntaxFactory.ParseSyntaxTree(oldSource).GetRoot();
var newRoot = SyntaxFactory.ParseSyntaxTree(newSource).GetRoot();
foreach (var oldNode in oldRoot.DescendantNodes().Where(n => n.FullSpan.Length > 0))
{
var newNode = SyntaxUtilities.FindPartner(oldRoot, newRoot, oldNode);
Assert.True(SyntaxFactory.AreEquivalent(oldNode, newNode), $"Node '{oldNode}' not equivalent to '{newNode}'.");
}
}
[Fact]
public void FindPartner1()
{
var source1 = @"
using System;
class C
{
static void Main(string[] args)
{
// sdasd
var b = true;
do
{
Console.WriteLine(""hi"");
} while (b == true);
}
}
";
var source2 = @"
using System;
class C
{
static void Main(string[] args)
{
var b = true;
do
{
Console.WriteLine(""hi"");
} while (b == true);
}
}
";
VerifySyntaxMap(source1, source2);
}
[Fact]
public void FindLeafNodeAndPartner1()
{
var leftRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
Console.WriteLine(0);
}
}
}
").GetRoot();
var leftPosition = leftRoot.DescendantNodes().OfType<LiteralExpressionSyntax>().ElementAt(2).SpanStart; // 0 within Console.WriteLine(0)
var rightRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
if (2 == 3)
{
Console.WriteLine(0);
}
}
}
}
").GetRoot();
SyntaxUtilities.FindLeafNodeAndPartner(leftRoot, leftPosition, rightRoot, out var leftNode, out var rightNodeOpt);
Assert.Equal("0", leftNode.ToString());
Assert.Null(rightNodeOpt);
}
[Fact]
public void FindLeafNodeAndPartner2()
{
// Check that the method does not fail even if the index of the child (4)
// is greater than the count of children on the corresponding (from the upper side) node (3).
var leftRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
Console.WriteLine(0);
Console.WriteLine(1);
Console.WriteLine(2);
Console.WriteLine(3);
}
}
}
").GetRoot();
var leftPosition = leftRoot.DescendantNodes().OfType<LiteralExpressionSyntax>().ElementAt(5).SpanStart; // 3 within Console.WriteLine(3)
var rightRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
if (2 == 3)
{
Console.WriteLine(0);
Console.WriteLine(1);
Console.WriteLine(2);
Console.WriteLine(3);
}
}
}
}
").GetRoot();
SyntaxUtilities.FindLeafNodeAndPartner(leftRoot, leftPosition, rightRoot, out var leftNode, out var rightNodeOpt);
Assert.Equal("3", leftNode.ToString());
Assert.Null(rightNodeOpt);
}
[Fact]
public void IsAsyncDeclaration()
{
var tree = SyntaxFactory.ParseSyntaxTree(@"
class C
{
async Task<int> M0() => 1;
async Task<int> M1() => await Task.FromResult(1);
async Task<int> M2() { return await Task.FromResult(1); }
void M3()
{
async Task<int> f1() => await Task.FromResult(1);
async Task<int> f2() { return await Task.FromResult(1); }
var l1 = new Func<Task<int>>(async () => await Task.FromResult(1));
var l2 = new Func<Task<int>>(async () => { return await Task.FromResult(1); });
var l3 = new Func<Task<int>>(async delegate () { return await Task.FromResult(1); });
}
}
");
var m0 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M0");
var m1 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M1");
var m2 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M2");
var m3 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M3");
var f1 = tree.GetRoot().DescendantNodes().OfType<LocalFunctionStatementSyntax>().Single(m => m.Identifier.ValueText == "f1");
var f2 = tree.GetRoot().DescendantNodes().OfType<LocalFunctionStatementSyntax>().Single(m => m.Identifier.ValueText == "f2");
var l1 = m3.DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "l1").Initializer.
DescendantNodes().OfType<LambdaExpressionSyntax>().Single();
var l2 = m3.DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "l2").Initializer.
DescendantNodes().OfType<LambdaExpressionSyntax>().Single();
var l3 = m3.DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "l3").Initializer.
DescendantNodes().OfType<AnonymousFunctionExpressionSyntax>().Single();
Assert.True(SyntaxUtilities.IsAsyncDeclaration(m0.ExpressionBody));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(m1.ExpressionBody));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(m2));
Assert.False(SyntaxUtilities.IsAsyncDeclaration(m3));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(f1.ExpressionBody));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(f2));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(l1));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(l2));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(l3));
Assert.Equal(0, SyntaxUtilities.GetSuspensionPoints(m0.ExpressionBody).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(m1.ExpressionBody).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(m2.Body).Count());
Assert.Equal(0, SyntaxUtilities.GetSuspensionPoints(m3.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(f1.ExpressionBody).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(f2.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(l1.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(l2.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(l3.Body).Count());
}
[Fact]
public void GetSuspensionPoints()
{
var tree = SyntaxFactory.ParseSyntaxTree(@"
class C
{
IEnumerable<int> X = new[] { 1, 2, 3 };
IEnumerable<int> M1() { yield return 1; }
void M2()
{
IAsyncEnumerable<int> f()
{
yield return 1;
yield break;
await Task.FromResult(1);
await foreach (var x in F()) { }
await foreach (var (x, y) in F()) { }
await using T x1 = F1(), x2 = F2(), x3 = F3();
}
}
}
");
var x = tree.GetRoot().DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "X");
var m1 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M1");
var m2 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M2");
var f = m2.DescendantNodes().OfType<LocalFunctionStatementSyntax>().Single(m => m.Identifier.ValueText == "f");
AssertEx.Empty(SyntaxUtilities.GetSuspensionPoints(x.Initializer));
AssertEx.Equal(new[] { "yield return 1;" }, SyntaxUtilities.GetSuspensionPoints(m1.Body).Select(n => n.ToString()));
AssertEx.Empty(SyntaxUtilities.GetSuspensionPoints(m2.Body));
AssertEx.Equal(new[]
{
"yield return 1;",
"yield break;",
"await Task.FromResult(1)",
"await foreach (var x in F()) { }",
"await foreach (var (x, y) in F()) { }",
"x1 = F1()",
"x2 = F2()",
"x3 = F3()",
}, SyntaxUtilities.GetSuspensionPoints(f.Body).Select(n => n.ToString()));
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System.Linq;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Roslyn.Test.Utilities;
using Xunit;
using SyntaxUtilities = Microsoft.CodeAnalysis.CSharp.EditAndContinue.SyntaxUtilities;
namespace Microsoft.CodeAnalysis.Editor.CSharp.UnitTests.EditAndContinue
{
public class SyntaxUtilitiesTests
{
private static void VerifySyntaxMap(string oldSource, string newSource)
{
var oldRoot = SyntaxFactory.ParseSyntaxTree(oldSource).GetRoot();
var newRoot = SyntaxFactory.ParseSyntaxTree(newSource).GetRoot();
foreach (var oldNode in oldRoot.DescendantNodes().Where(n => n.FullSpan.Length > 0))
{
var newNode = SyntaxUtilities.FindPartner(oldRoot, newRoot, oldNode);
Assert.True(SyntaxFactory.AreEquivalent(oldNode, newNode), $"Node '{oldNode}' not equivalent to '{newNode}'.");
}
}
[Fact]
public void FindPartner1()
{
var source1 = @"
using System;
class C
{
static void Main(string[] args)
{
// sdasd
var b = true;
do
{
Console.WriteLine(""hi"");
} while (b == true);
}
}
";
var source2 = @"
using System;
class C
{
static void Main(string[] args)
{
var b = true;
do
{
Console.WriteLine(""hi"");
} while (b == true);
}
}
";
VerifySyntaxMap(source1, source2);
}
[Fact]
public void FindLeafNodeAndPartner1()
{
var leftRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
Console.WriteLine(0);
}
}
}
").GetRoot();
var leftPosition = leftRoot.DescendantNodes().OfType<LiteralExpressionSyntax>().ElementAt(2).SpanStart; // 0 within Console.WriteLine(0)
var rightRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
if (2 == 3)
{
Console.WriteLine(0);
}
}
}
}
").GetRoot();
SyntaxUtilities.FindLeafNodeAndPartner(leftRoot, leftPosition, rightRoot, out var leftNode, out var rightNodeOpt);
Assert.Equal("0", leftNode.ToString());
Assert.Null(rightNodeOpt);
}
[Fact]
public void FindLeafNodeAndPartner2()
{
// Check that the method does not fail even if the index of the child (4)
// is greater than the count of children on the corresponding (from the upper side) node (3).
var leftRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
Console.WriteLine(0);
Console.WriteLine(1);
Console.WriteLine(2);
Console.WriteLine(3);
}
}
}
").GetRoot();
var leftPosition = leftRoot.DescendantNodes().OfType<LiteralExpressionSyntax>().ElementAt(5).SpanStart; // 3 within Console.WriteLine(3)
var rightRoot = SyntaxFactory.ParseSyntaxTree(@"
using System;
class C
{
public void M()
{
if (0 == 1)
{
if (2 == 3)
{
Console.WriteLine(0);
Console.WriteLine(1);
Console.WriteLine(2);
Console.WriteLine(3);
}
}
}
}
").GetRoot();
SyntaxUtilities.FindLeafNodeAndPartner(leftRoot, leftPosition, rightRoot, out var leftNode, out var rightNodeOpt);
Assert.Equal("3", leftNode.ToString());
Assert.Null(rightNodeOpt);
}
[Fact]
public void IsAsyncDeclaration()
{
var tree = SyntaxFactory.ParseSyntaxTree(@"
class C
{
async Task<int> M0() => 1;
async Task<int> M1() => await Task.FromResult(1);
async Task<int> M2() { return await Task.FromResult(1); }
void M3()
{
async Task<int> f1() => await Task.FromResult(1);
async Task<int> f2() { return await Task.FromResult(1); }
var l1 = new Func<Task<int>>(async () => await Task.FromResult(1));
var l2 = new Func<Task<int>>(async () => { return await Task.FromResult(1); });
var l3 = new Func<Task<int>>(async delegate () { return await Task.FromResult(1); });
}
}
");
var m0 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M0");
var m1 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M1");
var m2 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M2");
var m3 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M3");
var f1 = tree.GetRoot().DescendantNodes().OfType<LocalFunctionStatementSyntax>().Single(m => m.Identifier.ValueText == "f1");
var f2 = tree.GetRoot().DescendantNodes().OfType<LocalFunctionStatementSyntax>().Single(m => m.Identifier.ValueText == "f2");
var l1 = m3.DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "l1").Initializer.
DescendantNodes().OfType<LambdaExpressionSyntax>().Single();
var l2 = m3.DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "l2").Initializer.
DescendantNodes().OfType<LambdaExpressionSyntax>().Single();
var l3 = m3.DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "l3").Initializer.
DescendantNodes().OfType<AnonymousFunctionExpressionSyntax>().Single();
Assert.True(SyntaxUtilities.IsAsyncDeclaration(m0.ExpressionBody));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(m1.ExpressionBody));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(m2));
Assert.False(SyntaxUtilities.IsAsyncDeclaration(m3));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(f1.ExpressionBody));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(f2));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(l1));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(l2));
Assert.True(SyntaxUtilities.IsAsyncDeclaration(l3));
Assert.Equal(0, SyntaxUtilities.GetSuspensionPoints(m0.ExpressionBody).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(m1.ExpressionBody).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(m2.Body).Count());
Assert.Equal(0, SyntaxUtilities.GetSuspensionPoints(m3.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(f1.ExpressionBody).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(f2.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(l1.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(l2.Body).Count());
Assert.Equal(1, SyntaxUtilities.GetSuspensionPoints(l3.Body).Count());
}
[Fact]
public void GetSuspensionPoints()
{
var tree = SyntaxFactory.ParseSyntaxTree(@"
class C
{
IEnumerable<int> X = new[] { 1, 2, 3 };
IEnumerable<int> M1() { yield return 1; }
void M2()
{
IAsyncEnumerable<int> f()
{
yield return 1;
yield break;
await Task.FromResult(1);
await foreach (var x in F()) { }
await foreach (var (x, y) in F()) { }
await using T x1 = F1(), x2 = F2(), x3 = F3();
}
}
}
");
var x = tree.GetRoot().DescendantNodes().OfType<VariableDeclaratorSyntax>().Single(m => m.Identifier.ValueText == "X");
var m1 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M1");
var m2 = tree.GetRoot().DescendantNodes().OfType<MethodDeclarationSyntax>().Single(m => m.Identifier.ValueText == "M2");
var f = m2.DescendantNodes().OfType<LocalFunctionStatementSyntax>().Single(m => m.Identifier.ValueText == "f");
AssertEx.Empty(SyntaxUtilities.GetSuspensionPoints(x.Initializer));
AssertEx.Equal(new[] { "yield return 1;" }, SyntaxUtilities.GetSuspensionPoints(m1.Body).Select(n => n.ToString()));
AssertEx.Empty(SyntaxUtilities.GetSuspensionPoints(m2.Body));
AssertEx.Equal(new[]
{
"yield return 1;",
"yield break;",
"await Task.FromResult(1)",
"await foreach (var x in F()) { }",
"await foreach (var (x, y) in F()) { }",
"x1 = F1()",
"x2 = F2()",
"x3 = F3()",
}, SyntaxUtilities.GetSuspensionPoints(f.Body).Select(n => n.ToString()));
}
}
}
| -1 |
dotnet/roslyn | 56,187 | Add External Access options for TypeScript | Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | tmat | "2021-09-03T22:11:29Z" | "2021-09-07T17:42:47Z" | 4fada24142fb5bfdf4ec530e56eebf712227cbc9 | 409fcc26226c782f306d81cdbeed06d86b2de3f4 | Add External Access options for TypeScript. Used in https://devdiv.visualstudio.com/DevDiv/_git/TypeScript-VS/pullrequest/349183 | ./src/Compilers/Core/CodeAnalysisTest/Text/SourceTextTests.cs | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.IO;
using System.Linq;
using System.Text;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.UnitTests.Text
{
public class SourceTextTests
{
private static readonly Encoding s_utf8 = Encoding.UTF8;
private static readonly Encoding s_unicode = Encoding.Unicode;
private const string HelloWorld = "Hello, World!";
[Fact]
public void Empty()
{
TestIsEmpty(SourceText.From(string.Empty));
TestIsEmpty(SourceText.From(new byte[0], 0));
TestIsEmpty(SourceText.From(new MemoryStream()));
}
private static void TestIsEmpty(SourceText text)
{
Assert.Equal(0, text.Length);
Assert.Same(string.Empty, text.ToString());
Assert.Equal(1, text.Lines.Count);
Assert.Equal(0, text.Lines[0].Span.Length);
}
[Fact]
public void Encoding1()
{
var utf8NoBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false);
Assert.Same(s_utf8, SourceText.From(HelloWorld, s_utf8).Encoding);
Assert.Same(s_unicode, SourceText.From(HelloWorld, s_unicode).Encoding);
var bytes = s_unicode.GetBytes(HelloWorld);
Assert.Same(s_unicode, SourceText.From(bytes, bytes.Length, s_unicode).Encoding);
Assert.Equal(utf8NoBOM, SourceText.From(bytes, bytes.Length, null).Encoding);
var stream = new MemoryStream(bytes);
Assert.Same(s_unicode, SourceText.From(stream, s_unicode).Encoding);
Assert.Equal(utf8NoBOM, SourceText.From(stream, null).Encoding);
}
[Fact]
public void EncodingBOM()
{
var utf8BOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: true);
var bytes = utf8BOM.GetPreamble().Concat(utf8BOM.GetBytes("abc")).ToArray();
Assert.Equal(utf8BOM, SourceText.From(bytes, bytes.Length, s_unicode).Encoding);
Assert.Equal(utf8BOM, SourceText.From(bytes, bytes.Length, null).Encoding);
var stream = new MemoryStream(bytes);
Assert.Equal(utf8BOM, SourceText.From(stream, s_unicode).Encoding);
Assert.Equal(utf8BOM, SourceText.From(stream, null).Encoding);
}
[Fact]
public void ChecksumAlgorithm1()
{
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(HelloWorld).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(HelloWorld, checksumAlgorithm: SourceHashAlgorithm.Sha1).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha256, SourceText.From(HelloWorld, checksumAlgorithm: SourceHashAlgorithm.Sha256).ChecksumAlgorithm);
var bytes = s_unicode.GetBytes(HelloWorld);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(bytes, bytes.Length).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(bytes, bytes.Length, checksumAlgorithm: SourceHashAlgorithm.Sha1).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha256, SourceText.From(bytes, bytes.Length, checksumAlgorithm: SourceHashAlgorithm.Sha256).ChecksumAlgorithm);
var stream = new MemoryStream(bytes);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(stream).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(stream, checksumAlgorithm: SourceHashAlgorithm.Sha1).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha256, SourceText.From(stream, checksumAlgorithm: SourceHashAlgorithm.Sha256).ChecksumAlgorithm);
}
[WorkItem(7225, "https://github.com/dotnet/roslyn/issues/7225")]
[Fact]
public void ChecksumAndBOM()
{
const string source = "Hello, World!";
var checksumAlgorithm = SourceHashAlgorithm.Sha1;
var encodingNoBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false);
var encodingBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: true);
var checksumNoBOM = ImmutableArray.Create<byte>(0xa, 0xa, 0x9f, 0x2a, 0x67, 0x72, 0x94, 0x25, 0x57, 0xab, 0x53, 0x55, 0xd7, 0x6a, 0xf4, 0x42, 0xf8, 0xf6, 0x5e, 0x1);
var checksumBOM = ImmutableArray.Create<byte>(0xb2, 0x19, 0x0, 0x9b, 0x61, 0xce, 0xcd, 0x50, 0x7b, 0x2e, 0x56, 0x3c, 0xc0, 0xeb, 0x96, 0xe2, 0xa1, 0xd9, 0x3f, 0xfc);
// SourceText from string. Checksum should include BOM from explicit encoding.
VerifyChecksum(SourceText.From(source, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(source, encodingBOM, checksumAlgorithm), checksumBOM);
var bytesNoBOM = new byte[] { 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x2c, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x21 };
var bytesBOM = new byte[] { 0xef, 0xbb, 0xbf, 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x2c, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x21 };
var streamNoBOM = new MemoryStream(bytesNoBOM);
var streamBOM = new MemoryStream(bytesBOM);
// SourceText from bytes no BOM. Checksum should ignore explicit encoding.
VerifyChecksum(SourceText.From(bytesNoBOM, bytesNoBOM.Length, null, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(bytesNoBOM, bytesNoBOM.Length, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(bytesNoBOM, bytesNoBOM.Length, encodingBOM, checksumAlgorithm), checksumNoBOM);
// SourceText from bytes with BOM. Checksum should include BOM.
VerifyChecksum(SourceText.From(bytesBOM, bytesBOM.Length, null, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(bytesBOM, bytesBOM.Length, encodingNoBOM, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(bytesBOM, bytesBOM.Length, encodingBOM, checksumAlgorithm), checksumBOM);
// SourceText from stream no BOM. Checksum should ignore explicit encoding.
VerifyChecksum(SourceText.From(streamNoBOM, null, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(streamNoBOM, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(streamNoBOM, encodingBOM, checksumAlgorithm), checksumNoBOM);
// SourceText from stream with BOM. Checksum should include BOM.
VerifyChecksum(SourceText.From(streamBOM, null, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(streamBOM, encodingNoBOM, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(streamBOM, encodingBOM, checksumAlgorithm), checksumBOM);
// LargeText from stream no BOM. Checksum should ignore explicit encoding.
VerifyChecksum(LargeText.Decode(streamNoBOM, encodingNoBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumNoBOM);
VerifyChecksum(LargeText.Decode(streamNoBOM, encodingBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumNoBOM);
// LargeText from stream with BOM. Checksum should include BOM.
VerifyChecksum(LargeText.Decode(streamBOM, encodingNoBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumBOM);
VerifyChecksum(LargeText.Decode(streamBOM, encodingBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumBOM);
// LargeText from writer no BOM. Checksum includes BOM
// from explicit encoding. This is inconsistent with the
// LargeText cases above but LargeTextWriter is only used
// for unsaved edits where the checksum is ignored.
VerifyChecksum(FromLargeTextWriter(source, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(FromLargeTextWriter(source, encodingBOM, checksumAlgorithm), checksumBOM);
// SourceText from string with changes. Checksum includes BOM from explicit encoding.
VerifyChecksum(FromChanges(SourceText.From(source, encodingNoBOM, checksumAlgorithm)), checksumNoBOM);
VerifyChecksum(FromChanges(SourceText.From(source, encodingBOM, checksumAlgorithm)), checksumBOM);
// SourceText from stream with changes, no BOM. Checksum includes BOM
// from explicit encoding. This is inconsistent with the SourceText cases but
// "with changes" is only used for unsaved edits where the checksum is ignored.
VerifyChecksum(FromChanges(SourceText.From(streamNoBOM, encodingNoBOM, checksumAlgorithm)), checksumNoBOM);
VerifyChecksum(FromChanges(SourceText.From(streamNoBOM, encodingBOM, checksumAlgorithm)), checksumBOM);
// SourceText from stream with changes, with BOM. Checksum includes BOM.
VerifyChecksum(FromChanges(SourceText.From(streamBOM, encodingNoBOM, checksumAlgorithm)), checksumBOM);
VerifyChecksum(FromChanges(SourceText.From(streamBOM, encodingBOM, checksumAlgorithm)), checksumBOM);
}
private static SourceText FromLargeTextWriter(string source, Encoding encoding, SourceHashAlgorithm checksumAlgorithm)
{
using (var writer = new LargeTextWriter(encoding, checksumAlgorithm, source.Length))
{
writer.Write(source);
return writer.ToSourceText();
}
}
private static SourceText FromChanges(SourceText text)
{
var span = new TextSpan(0, 1);
var change = new TextChange(span, text.ToString(span));
var changed = text.WithChanges(change);
Assert.NotEqual(text, changed);
return changed;
}
private static void VerifyChecksum(SourceText text, ImmutableArray<byte> expectedChecksum)
{
var actualChecksum = text.GetChecksum();
Assert.Equal<byte>(expectedChecksum, actualChecksum);
}
[Fact]
public void ContentEquals()
{
var f = SourceText.From(HelloWorld, s_utf8);
Assert.True(f.ContentEquals(SourceText.From(HelloWorld, s_utf8)));
Assert.False(f.ContentEquals(SourceText.From(HelloWorld + "o", s_utf8)));
Assert.True(SourceText.From(HelloWorld, s_utf8).ContentEquals(SourceText.From(HelloWorld, s_utf8)));
var e1 = EncodedStringText.Create(new MemoryStream(s_unicode.GetBytes(HelloWorld)), s_unicode);
var e2 = EncodedStringText.Create(new MemoryStream(s_utf8.GetBytes(HelloWorld)), s_utf8);
Assert.True(e1.ContentEquals(e1));
Assert.True(f.ContentEquals(e1));
Assert.True(e1.ContentEquals(f));
Assert.True(e2.ContentEquals(e2));
Assert.True(e1.ContentEquals(e2));
Assert.True(e2.ContentEquals(e1));
}
[Fact]
public void IsBinary()
{
Assert.False(SourceText.IsBinary(""));
Assert.False(SourceText.IsBinary("\0abc"));
Assert.False(SourceText.IsBinary("a\0bc"));
Assert.False(SourceText.IsBinary("abc\0"));
Assert.False(SourceText.IsBinary("a\0b\0c"));
Assert.True(SourceText.IsBinary("\0\0abc"));
Assert.True(SourceText.IsBinary("a\0\0bc"));
Assert.True(SourceText.IsBinary("abc\0\0"));
var encoding = Encoding.UTF8;
Assert.False(SourceText.IsBinary(encoding.GetString(new byte[] { 0x81, 0x8D, 0x8F, 0x90, 0x9D })));
// Unicode string: äëïöüû
Assert.False(SourceText.IsBinary("abc def baz aeiouy \u00E4\u00EB\u00EF\u00F6\u00FC\u00FB"));
Assert.True(SourceText.IsBinary(encoding.GetString(TestMetadata.ResourcesNet451.System)));
}
[Fact]
public void FromThrowsIfBinary()
{
var bytes = TestMetadata.ResourcesNet451.System;
Assert.Throws<InvalidDataException>(() => SourceText.From(bytes, bytes.Length, throwIfBinaryDetected: true));
var stream = new MemoryStream(bytes);
Assert.Throws<InvalidDataException>(() => SourceText.From(stream, throwIfBinaryDetected: true));
}
[Fact]
public void FromTextReader()
{
var expected = "Text reader source text test";
var expectedSourceText = SourceText.From(expected);
var actual = new StringReader(expected);
var actualSourceText = SourceText.From(actual, expected.Length);
Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum());
Assert.Same(s_utf8, SourceText.From(actual, expected.Length, s_utf8).Encoding);
Assert.Same(s_unicode, SourceText.From(actual, expected.Length, s_unicode).Encoding);
Assert.Null(SourceText.From(actual, expected.Length, null).Encoding);
}
[Fact]
public void FromTextReader_Large()
{
var expected = new string('l', SourceText.LargeObjectHeapLimitInChars);
var expectedSourceText = SourceText.From(expected);
var actual = new StringReader(expected);
var actualSourceText = SourceText.From(actual, expected.Length);
Assert.IsType<LargeText>(actualSourceText);
Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum());
var utf8NoBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false);
Assert.Same(s_utf8, SourceText.From(actual, expected.Length, s_utf8).Encoding);
Assert.Same(s_unicode, SourceText.From(actual, expected.Length, s_unicode).Encoding);
Assert.Null(SourceText.From(actual, expected.Length, null).Encoding);
}
private static void TestTryReadByteOrderMark(Encoding expectedEncoding, int expectedPreambleLength, byte[] data)
{
TestTryReadByteOrderMark(expectedEncoding, expectedPreambleLength, data, data == null ? 0 : data.Length);
}
private static void TestTryReadByteOrderMark(Encoding expectedEncoding, int expectedPreambleLength, byte[] data, int validLength)
{
int actualPreambleLength;
Encoding actualEncoding = SourceText.TryReadByteOrderMark(data, validLength, out actualPreambleLength);
if (expectedEncoding == null)
{
Assert.Null(actualEncoding);
}
else
{
Assert.Equal(expectedEncoding, actualEncoding);
}
Assert.Equal(expectedPreambleLength, actualPreambleLength);
}
[Fact]
public void TryReadByteOrderMark()
{
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[0]);
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xef });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xef, 0xbb });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xef, 0xBB, 0xBF }, validLength: 2);
TestTryReadByteOrderMark(expectedEncoding: Encoding.UTF8, expectedPreambleLength: 3, data: new byte[] { 0xef, 0xBB, 0xBF });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xff });
TestTryReadByteOrderMark(expectedEncoding: Encoding.Unicode, expectedPreambleLength: 2, data: new byte[] { 0xff, 0xfe });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xfe });
TestTryReadByteOrderMark(expectedEncoding: Encoding.BigEndianUnicode, expectedPreambleLength: 2, data: new byte[] { 0xfe, 0xff });
}
[Fact]
[WorkItem(41903, "https://github.com/dotnet/roslyn/issues/41903")]
public void WriteWithRangeStartingLaterThanZero()
{
var sourceText = SourceText.From("ABCDEFGHIJKLMNOPQRSTUVWXYZ");
var writer = new StringWriter();
sourceText.Write(writer, TextSpan.FromBounds(1, sourceText.Length));
Assert.Equal("BCDEFGHIJKLMNOPQRSTUVWXYZ", writer.ToString());
}
public static IEnumerable<object[]> AllRanges(int totalLength) =>
from start in Enumerable.Range(0, totalLength)
from length in Enumerable.Range(0, totalLength - start)
select new object[] { new TextSpan(start, length) };
[Theory]
[MemberData(nameof(AllRanges), 10)]
[WorkItem(41903, "https://github.com/dotnet/roslyn/issues/41903")]
public void WriteWithAllRanges(TextSpan span)
{
const string Text = "0123456789";
var sourceText = SourceText.From(Text);
var writer = new StringWriter();
sourceText.Write(writer, span);
Assert.Equal(Text.Substring(span.Start, span.Length), writer.ToString());
}
[Fact]
public void WriteWithSpanStartingAfterEndThrowsOutOfRange()
{
var ex = Assert.ThrowsAny<ArgumentOutOfRangeException>(() =>
SourceText.From("ABC").Write(TextWriter.Null, TextSpan.FromBounds(4, 4)));
Assert.Equal("span", ex.ParamName);
}
[Fact]
public void WriteWithSpanEndingAfterEndThrowsOutOfRange()
{
var ex = Assert.ThrowsAny<ArgumentOutOfRangeException>(() =>
SourceText.From("ABC").Write(TextWriter.Null, TextSpan.FromBounds(2, 4)));
Assert.Equal("span", ex.ParamName);
}
}
}
| // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
#nullable disable
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.IO;
using System.Linq;
using System.Text;
using Microsoft.CodeAnalysis.Text;
using Roslyn.Test.Utilities;
using Xunit;
namespace Microsoft.CodeAnalysis.UnitTests.Text
{
public class SourceTextTests
{
private static readonly Encoding s_utf8 = Encoding.UTF8;
private static readonly Encoding s_unicode = Encoding.Unicode;
private const string HelloWorld = "Hello, World!";
[Fact]
public void Empty()
{
TestIsEmpty(SourceText.From(string.Empty));
TestIsEmpty(SourceText.From(new byte[0], 0));
TestIsEmpty(SourceText.From(new MemoryStream()));
}
private static void TestIsEmpty(SourceText text)
{
Assert.Equal(0, text.Length);
Assert.Same(string.Empty, text.ToString());
Assert.Equal(1, text.Lines.Count);
Assert.Equal(0, text.Lines[0].Span.Length);
}
[Fact]
public void Encoding1()
{
var utf8NoBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false);
Assert.Same(s_utf8, SourceText.From(HelloWorld, s_utf8).Encoding);
Assert.Same(s_unicode, SourceText.From(HelloWorld, s_unicode).Encoding);
var bytes = s_unicode.GetBytes(HelloWorld);
Assert.Same(s_unicode, SourceText.From(bytes, bytes.Length, s_unicode).Encoding);
Assert.Equal(utf8NoBOM, SourceText.From(bytes, bytes.Length, null).Encoding);
var stream = new MemoryStream(bytes);
Assert.Same(s_unicode, SourceText.From(stream, s_unicode).Encoding);
Assert.Equal(utf8NoBOM, SourceText.From(stream, null).Encoding);
}
[Fact]
public void EncodingBOM()
{
var utf8BOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: true);
var bytes = utf8BOM.GetPreamble().Concat(utf8BOM.GetBytes("abc")).ToArray();
Assert.Equal(utf8BOM, SourceText.From(bytes, bytes.Length, s_unicode).Encoding);
Assert.Equal(utf8BOM, SourceText.From(bytes, bytes.Length, null).Encoding);
var stream = new MemoryStream(bytes);
Assert.Equal(utf8BOM, SourceText.From(stream, s_unicode).Encoding);
Assert.Equal(utf8BOM, SourceText.From(stream, null).Encoding);
}
[Fact]
public void ChecksumAlgorithm1()
{
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(HelloWorld).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(HelloWorld, checksumAlgorithm: SourceHashAlgorithm.Sha1).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha256, SourceText.From(HelloWorld, checksumAlgorithm: SourceHashAlgorithm.Sha256).ChecksumAlgorithm);
var bytes = s_unicode.GetBytes(HelloWorld);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(bytes, bytes.Length).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(bytes, bytes.Length, checksumAlgorithm: SourceHashAlgorithm.Sha1).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha256, SourceText.From(bytes, bytes.Length, checksumAlgorithm: SourceHashAlgorithm.Sha256).ChecksumAlgorithm);
var stream = new MemoryStream(bytes);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(stream).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha1, SourceText.From(stream, checksumAlgorithm: SourceHashAlgorithm.Sha1).ChecksumAlgorithm);
Assert.Equal(SourceHashAlgorithm.Sha256, SourceText.From(stream, checksumAlgorithm: SourceHashAlgorithm.Sha256).ChecksumAlgorithm);
}
[WorkItem(7225, "https://github.com/dotnet/roslyn/issues/7225")]
[Fact]
public void ChecksumAndBOM()
{
const string source = "Hello, World!";
var checksumAlgorithm = SourceHashAlgorithm.Sha1;
var encodingNoBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false);
var encodingBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: true);
var checksumNoBOM = ImmutableArray.Create<byte>(0xa, 0xa, 0x9f, 0x2a, 0x67, 0x72, 0x94, 0x25, 0x57, 0xab, 0x53, 0x55, 0xd7, 0x6a, 0xf4, 0x42, 0xf8, 0xf6, 0x5e, 0x1);
var checksumBOM = ImmutableArray.Create<byte>(0xb2, 0x19, 0x0, 0x9b, 0x61, 0xce, 0xcd, 0x50, 0x7b, 0x2e, 0x56, 0x3c, 0xc0, 0xeb, 0x96, 0xe2, 0xa1, 0xd9, 0x3f, 0xfc);
// SourceText from string. Checksum should include BOM from explicit encoding.
VerifyChecksum(SourceText.From(source, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(source, encodingBOM, checksumAlgorithm), checksumBOM);
var bytesNoBOM = new byte[] { 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x2c, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x21 };
var bytesBOM = new byte[] { 0xef, 0xbb, 0xbf, 0x48, 0x65, 0x6c, 0x6c, 0x6f, 0x2c, 0x20, 0x57, 0x6f, 0x72, 0x6c, 0x64, 0x21 };
var streamNoBOM = new MemoryStream(bytesNoBOM);
var streamBOM = new MemoryStream(bytesBOM);
// SourceText from bytes no BOM. Checksum should ignore explicit encoding.
VerifyChecksum(SourceText.From(bytesNoBOM, bytesNoBOM.Length, null, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(bytesNoBOM, bytesNoBOM.Length, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(bytesNoBOM, bytesNoBOM.Length, encodingBOM, checksumAlgorithm), checksumNoBOM);
// SourceText from bytes with BOM. Checksum should include BOM.
VerifyChecksum(SourceText.From(bytesBOM, bytesBOM.Length, null, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(bytesBOM, bytesBOM.Length, encodingNoBOM, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(bytesBOM, bytesBOM.Length, encodingBOM, checksumAlgorithm), checksumBOM);
// SourceText from stream no BOM. Checksum should ignore explicit encoding.
VerifyChecksum(SourceText.From(streamNoBOM, null, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(streamNoBOM, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(SourceText.From(streamNoBOM, encodingBOM, checksumAlgorithm), checksumNoBOM);
// SourceText from stream with BOM. Checksum should include BOM.
VerifyChecksum(SourceText.From(streamBOM, null, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(streamBOM, encodingNoBOM, checksumAlgorithm), checksumBOM);
VerifyChecksum(SourceText.From(streamBOM, encodingBOM, checksumAlgorithm), checksumBOM);
// LargeText from stream no BOM. Checksum should ignore explicit encoding.
VerifyChecksum(LargeText.Decode(streamNoBOM, encodingNoBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumNoBOM);
VerifyChecksum(LargeText.Decode(streamNoBOM, encodingBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumNoBOM);
// LargeText from stream with BOM. Checksum should include BOM.
VerifyChecksum(LargeText.Decode(streamBOM, encodingNoBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumBOM);
VerifyChecksum(LargeText.Decode(streamBOM, encodingBOM, checksumAlgorithm, throwIfBinaryDetected: false, canBeEmbedded: false), checksumBOM);
// LargeText from writer no BOM. Checksum includes BOM
// from explicit encoding. This is inconsistent with the
// LargeText cases above but LargeTextWriter is only used
// for unsaved edits where the checksum is ignored.
VerifyChecksum(FromLargeTextWriter(source, encodingNoBOM, checksumAlgorithm), checksumNoBOM);
VerifyChecksum(FromLargeTextWriter(source, encodingBOM, checksumAlgorithm), checksumBOM);
// SourceText from string with changes. Checksum includes BOM from explicit encoding.
VerifyChecksum(FromChanges(SourceText.From(source, encodingNoBOM, checksumAlgorithm)), checksumNoBOM);
VerifyChecksum(FromChanges(SourceText.From(source, encodingBOM, checksumAlgorithm)), checksumBOM);
// SourceText from stream with changes, no BOM. Checksum includes BOM
// from explicit encoding. This is inconsistent with the SourceText cases but
// "with changes" is only used for unsaved edits where the checksum is ignored.
VerifyChecksum(FromChanges(SourceText.From(streamNoBOM, encodingNoBOM, checksumAlgorithm)), checksumNoBOM);
VerifyChecksum(FromChanges(SourceText.From(streamNoBOM, encodingBOM, checksumAlgorithm)), checksumBOM);
// SourceText from stream with changes, with BOM. Checksum includes BOM.
VerifyChecksum(FromChanges(SourceText.From(streamBOM, encodingNoBOM, checksumAlgorithm)), checksumBOM);
VerifyChecksum(FromChanges(SourceText.From(streamBOM, encodingBOM, checksumAlgorithm)), checksumBOM);
}
private static SourceText FromLargeTextWriter(string source, Encoding encoding, SourceHashAlgorithm checksumAlgorithm)
{
using (var writer = new LargeTextWriter(encoding, checksumAlgorithm, source.Length))
{
writer.Write(source);
return writer.ToSourceText();
}
}
private static SourceText FromChanges(SourceText text)
{
var span = new TextSpan(0, 1);
var change = new TextChange(span, text.ToString(span));
var changed = text.WithChanges(change);
Assert.NotEqual(text, changed);
return changed;
}
private static void VerifyChecksum(SourceText text, ImmutableArray<byte> expectedChecksum)
{
var actualChecksum = text.GetChecksum();
Assert.Equal<byte>(expectedChecksum, actualChecksum);
}
[Fact]
public void ContentEquals()
{
var f = SourceText.From(HelloWorld, s_utf8);
Assert.True(f.ContentEquals(SourceText.From(HelloWorld, s_utf8)));
Assert.False(f.ContentEquals(SourceText.From(HelloWorld + "o", s_utf8)));
Assert.True(SourceText.From(HelloWorld, s_utf8).ContentEquals(SourceText.From(HelloWorld, s_utf8)));
var e1 = EncodedStringText.Create(new MemoryStream(s_unicode.GetBytes(HelloWorld)), s_unicode);
var e2 = EncodedStringText.Create(new MemoryStream(s_utf8.GetBytes(HelloWorld)), s_utf8);
Assert.True(e1.ContentEquals(e1));
Assert.True(f.ContentEquals(e1));
Assert.True(e1.ContentEquals(f));
Assert.True(e2.ContentEquals(e2));
Assert.True(e1.ContentEquals(e2));
Assert.True(e2.ContentEquals(e1));
}
[Fact]
public void IsBinary()
{
Assert.False(SourceText.IsBinary(""));
Assert.False(SourceText.IsBinary("\0abc"));
Assert.False(SourceText.IsBinary("a\0bc"));
Assert.False(SourceText.IsBinary("abc\0"));
Assert.False(SourceText.IsBinary("a\0b\0c"));
Assert.True(SourceText.IsBinary("\0\0abc"));
Assert.True(SourceText.IsBinary("a\0\0bc"));
Assert.True(SourceText.IsBinary("abc\0\0"));
var encoding = Encoding.UTF8;
Assert.False(SourceText.IsBinary(encoding.GetString(new byte[] { 0x81, 0x8D, 0x8F, 0x90, 0x9D })));
// Unicode string: äëïöüû
Assert.False(SourceText.IsBinary("abc def baz aeiouy \u00E4\u00EB\u00EF\u00F6\u00FC\u00FB"));
Assert.True(SourceText.IsBinary(encoding.GetString(TestMetadata.ResourcesNet451.System)));
}
[Fact]
public void FromThrowsIfBinary()
{
var bytes = TestMetadata.ResourcesNet451.System;
Assert.Throws<InvalidDataException>(() => SourceText.From(bytes, bytes.Length, throwIfBinaryDetected: true));
var stream = new MemoryStream(bytes);
Assert.Throws<InvalidDataException>(() => SourceText.From(stream, throwIfBinaryDetected: true));
}
[Fact]
public void FromTextReader()
{
var expected = "Text reader source text test";
var expectedSourceText = SourceText.From(expected);
var actual = new StringReader(expected);
var actualSourceText = SourceText.From(actual, expected.Length);
Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum());
Assert.Same(s_utf8, SourceText.From(actual, expected.Length, s_utf8).Encoding);
Assert.Same(s_unicode, SourceText.From(actual, expected.Length, s_unicode).Encoding);
Assert.Null(SourceText.From(actual, expected.Length, null).Encoding);
}
[Fact]
public void FromTextReader_Large()
{
var expected = new string('l', SourceText.LargeObjectHeapLimitInChars);
var expectedSourceText = SourceText.From(expected);
var actual = new StringReader(expected);
var actualSourceText = SourceText.From(actual, expected.Length);
Assert.IsType<LargeText>(actualSourceText);
Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum());
var utf8NoBOM = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false);
Assert.Same(s_utf8, SourceText.From(actual, expected.Length, s_utf8).Encoding);
Assert.Same(s_unicode, SourceText.From(actual, expected.Length, s_unicode).Encoding);
Assert.Null(SourceText.From(actual, expected.Length, null).Encoding);
}
private static void TestTryReadByteOrderMark(Encoding expectedEncoding, int expectedPreambleLength, byte[] data)
{
TestTryReadByteOrderMark(expectedEncoding, expectedPreambleLength, data, data == null ? 0 : data.Length);
}
private static void TestTryReadByteOrderMark(Encoding expectedEncoding, int expectedPreambleLength, byte[] data, int validLength)
{
int actualPreambleLength;
Encoding actualEncoding = SourceText.TryReadByteOrderMark(data, validLength, out actualPreambleLength);
if (expectedEncoding == null)
{
Assert.Null(actualEncoding);
}
else
{
Assert.Equal(expectedEncoding, actualEncoding);
}
Assert.Equal(expectedPreambleLength, actualPreambleLength);
}
[Fact]
public void TryReadByteOrderMark()
{
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[0]);
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xef });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xef, 0xbb });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xef, 0xBB, 0xBF }, validLength: 2);
TestTryReadByteOrderMark(expectedEncoding: Encoding.UTF8, expectedPreambleLength: 3, data: new byte[] { 0xef, 0xBB, 0xBF });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xff });
TestTryReadByteOrderMark(expectedEncoding: Encoding.Unicode, expectedPreambleLength: 2, data: new byte[] { 0xff, 0xfe });
TestTryReadByteOrderMark(expectedEncoding: null, expectedPreambleLength: 0, data: new byte[] { 0xfe });
TestTryReadByteOrderMark(expectedEncoding: Encoding.BigEndianUnicode, expectedPreambleLength: 2, data: new byte[] { 0xfe, 0xff });
}
[Fact]
[WorkItem(41903, "https://github.com/dotnet/roslyn/issues/41903")]
public void WriteWithRangeStartingLaterThanZero()
{
var sourceText = SourceText.From("ABCDEFGHIJKLMNOPQRSTUVWXYZ");
var writer = new StringWriter();
sourceText.Write(writer, TextSpan.FromBounds(1, sourceText.Length));
Assert.Equal("BCDEFGHIJKLMNOPQRSTUVWXYZ", writer.ToString());
}
public static IEnumerable<object[]> AllRanges(int totalLength) =>
from start in Enumerable.Range(0, totalLength)
from length in Enumerable.Range(0, totalLength - start)
select new object[] { new TextSpan(start, length) };
[Theory]
[MemberData(nameof(AllRanges), 10)]
[WorkItem(41903, "https://github.com/dotnet/roslyn/issues/41903")]
public void WriteWithAllRanges(TextSpan span)
{
const string Text = "0123456789";
var sourceText = SourceText.From(Text);
var writer = new StringWriter();
sourceText.Write(writer, span);
Assert.Equal(Text.Substring(span.Start, span.Length), writer.ToString());
}
[Fact]
public void WriteWithSpanStartingAfterEndThrowsOutOfRange()
{
var ex = Assert.ThrowsAny<ArgumentOutOfRangeException>(() =>
SourceText.From("ABC").Write(TextWriter.Null, TextSpan.FromBounds(4, 4)));
Assert.Equal("span", ex.ParamName);
}
[Fact]
public void WriteWithSpanEndingAfterEndThrowsOutOfRange()
{
var ex = Assert.ThrowsAny<ArgumentOutOfRangeException>(() =>
SourceText.From("ABC").Write(TextWriter.Null, TextSpan.FromBounds(2, 4)));
Assert.Equal("span", ex.ParamName);
}
}
}
| -1 |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.