Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mono] Fix Type equality comparisons #52791

Closed
wants to merge 1 commit into from
Closed

[mono] Fix Type equality comparisons #52791

wants to merge 1 commit into from

Conversation

uweigand
Copy link
Contributor

The Mono CoreLib currently implements the equality operator for Type
using an intrinsic that effectively does ReferenceEquals. However,
the CLR CoreLib only does that if both sides are RuntimeType; if not,
it uses the Equals predicate.

This difference causes System.Text.Json.SourceGeneration to fail
when built with the Mono runtime, because it uses a subtype of Type
(TypeWrapper) that implements a non-default Equals predicate. The
Mono logic will simply ignore that, causing various errors.

Fixed by removing the Mono intrinsic and implementing Type equality
in managed code in a way that should be equivalent to CoreCLR (as
implemented there in RuntimeTypeHandle::TypeEQ).

@ghost
Copy link

ghost commented May 14, 2021

Tagging subscribers to this area: @CoffeeFlux
See info in area-owners.md if you want to be subscribed.

Issue Details

The Mono CoreLib currently implements the equality operator for Type
using an intrinsic that effectively does ReferenceEquals. However,
the CLR CoreLib only does that if both sides are RuntimeType; if not,
it uses the Equals predicate.

This difference causes System.Text.Json.SourceGeneration to fail
when built with the Mono runtime, because it uses a subtype of Type
(TypeWrapper) that implements a non-default Equals predicate. The
Mono logic will simply ignore that, causing various errors.

Fixed by removing the Mono intrinsic and implementing Type equality
in managed code in a way that should be equivalent to CoreCLR (as
implemented there in RuntimeTypeHandle::TypeEQ).

Author: uweigand
Assignees: -
Labels:

area-VM-meta-mono

Milestone: -

@marek-safar
Copy link
Contributor

Could you have a look at if there are any tests that could be enabled with the fix or add a new one?

@uweigand
Copy link
Contributor Author

Could you have a look at if there are any tests that could be enabled with the fix or add a new one?

All of System.Text.Json.SourceGeneration.Tests fails without the fix (when using the Mono runtime), because the generator programs invoked by the test emit bogus source code that won't even compile. With the fix the tests build correctly and all pass.

@CoffeeFlux
Copy link
Contributor

I'm curious about the performance impact without the interpreter intrinsic... cc: @BrzVlad

@marek-safar
Copy link
Contributor

All of System.Text.Json.SourceGeneration.Tests fails

I thought there will be simple or more direct test case

@uweigand
Copy link
Contributor Author

All of System.Text.Json.SourceGeneration.Tests fails

I thought there will be simple or more direct test case

There's also some failures in System.Text.Json.SourceGeneration.UnitTests, which is a bit more direct. But there doesn't seem to be any test that verifies just the properties of Type itself. Should there be one, and where should it live?

@marek-safar
Copy link
Contributor

There's also some failures in System.Text.Json.SourceGeneration.UnitTests, which is a bit more direct.

I'm wondering if that's intentional (/cc @layomia @steveharter)

But there doesn't seem to be any test that verifies just the properties of Type itself. Should there be one, and where should it live?

It should go to https://github.com/dotnet/runtime/tree/main/src/libraries/System.Runtime/tests/System/Type

@akoeplinger
Copy link
Member

Looks like there's a failure in the Mono llvmaot Pri0 Runtime Tests Run Linux arm64 release run that happened even after a retry, could be related?

  Starting:    JIT.HardwareIntrinsics.XUnitWrapper
    JIT/HardwareIntrinsics/General/NotSupported/NotSupported_r/NotSupported_r.sh [FAIL]
      LLVM ERROR: Cannot select: 0x558e0a6898: v2i64 = bitcast 0x558e0a6628
        0x558e0a6628: i64,ch = CopyFromReg 0x558e022ac8, Register:i64 %5
          0x558e0a65c0: i64 = Register %5
      In function: System.Runtime.Intrinsics.Vector128:WithLower<bool> (System.Runtime.Intrinsics.Vector128`1<bool>,System.Runtime.Intrinsics.Vector64`1<bool>)
      
      Return code:      1

@uweigand
Copy link
Contributor Author

Looks like there's a failure in the Mono llvmaot Pri0 Runtime Tests Run Linux arm64 release run that happened even after a retry, could be related?

Huh, that's strange. It is not clear to me how this change could cause an LLVM error ... @MichalStrehovsky, I'm now using the implementation from the nativeaot branch -- did you see anything like this error on that branch?

I'm not quite sure how to go about debugging this failure without access to an aarch64 machine, unfortunately. Any suggestion on how to extract the failing case?

@akoeplinger
Copy link
Member

Yeah it's weird. Could you try rebasing on main just to make sure? We can figure something out if it still happens.

@uweigand
Copy link
Contributor Author

Yeah it's weird. Could you try rebasing on main just to make sure? We can figure something out if it still happens.

Looks like this didn't help, the same LLVM error is still there.

@akoeplinger
Copy link
Member

@lambdageek @CoffeeFlux @imhameed would you mind helping @uweigand to figure out why this change causes a failure in the Mono llvmaot Pri0 Runtime Tests Run Linux arm64 release job?

@imhameed
Copy link
Contributor

I'll take a look; I have a working environment ready to go on an arm64 server.

@imhameed
Copy link
Contributor

imhameed commented May 23, 2021

I've submitted a fix for the underlying problem here: #53707

@imhameed
Copy link
Contributor

imhameed commented Jun 5, 2021

This should be fixed. Try rebasing from main.

The Mono CoreLib currently implements the equality operator for Type
using an intrinsic that effectively does ReferenceEquals.  However,
the CLR CoreLib only does that if both sides are RuntimeType; if not,
it uses the Equals predicate.

This difference causes System.Text.Json.SourceGeneration to fail
when built with the Mono runtime, because it uses a subtype of Type
(TypeWrapper) that implements a non-default Equals predicate.  The
Mono logic will simply ignore that, causing various errors.

Fixed by removing the Mono intrinsic and implementing Type equality
in managed code in a way that should be equivalent to CoreCLR (as
implemented there in RuntimeTypeHandle::TypeEQ).
@uweigand
Copy link
Contributor Author

uweigand commented Jun 7, 2021

This should be fixed. Try rebasing from main.

Indeed, looks like this is fixed now, thanks! The two remaining failures on OSX seem unrelated setup problems.

Copy link
Contributor

@CoffeeFlux CoffeeFlux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still suspect we'll want to fix up the interpreter intrinsic rather than remove it entirely, but for now LGTM.

@marek-safar
Copy link
Contributor

@BrzVlad thoughts on removed interpreter intrinsic?

@BrzVlad
Copy link
Member

BrzVlad commented Jun 8, 2021

This will have significant performance impact both on jit and interp since the BCL is full of comparisons like if (typeof (T1) == typeof(T2)) which are meant to be optimized away during compile time

@uweigand
Copy link
Contributor Author

uweigand commented Jun 9, 2021

This will have significant performance impact both on jit and interp since the BCL is full of comparisons like if (typeof (T1) == typeof(T2)) which are meant to be optimized away during compile time

I noticed there is also a specialization for RuntimeType here:
https://github.com/dotnet/runtime/blob/main/src/mono/System.Private.CoreLib/src/System/RuntimeType.Mono.cs#L1250
Does this help with the typeof case you mention above?

In any case, if you have any suggestions on how to fix the intrinsic implementation so it only catches the valid cases, I'd be happy to implement and test something ...

@MichalStrehovsky
Copy link
Member

I noticed there is also a specialization for RuntimeType here:
https://github.com/dotnet/runtime/blob/main/src/mono/System.Private.CoreLib/src/System/RuntimeType.Mono.cs#L1250
Does this help with the typeof case you mention above?

It wouldn't help because the result of typeof and Object.GetType is a System.Type, not RuntimeType. We rarely cast to RuntimeType within the CoreLib and RuntimeType is not visible outside CoreLib at all.

RyuJIT optimizes this by looking at the tree that feeds the comparison. If either one of the sides of the comparison comes out of Object.GetType or Type.GetTypeFromHandle (that one covers the typeof case), it will replace the operator method call with a reference equality comparison.

@BrzVlad
Copy link
Member

BrzVlad commented Jun 9, 2021

@uweigand I can implement this intrinsic both on interp and jit but I'm not sure what exact test suite this fixes. For me the json source gen tests crash with and without this change.

@uweigand
Copy link
Contributor Author

uweigand commented Jun 9, 2021

I see the problem just by running the runtime's "./build.sh libs.tests". During compilation, there are a large number of errors (see below) when building src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj. These all go away and the project successfully builds (and subsequently the tests pass), if this patch is applied.

To be clear, it doesn't matter if the patch is applied to the runtime sources currently being built; the patch needs to be applied to the host runtime used to do the build itself.

Here's the full list of errors I get. They all relate to comparisons between "TypeWrapper" types erroneously being resolved to "false" when they should be "true", which trigger both internal errors in some extension that is being loaded into Roslyn by the generator, as well as generator emitting invalid C# code that causes subsequent compiler errors.

CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.String>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                     
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.Int32,System.String>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                      
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.Text.Json.SourceGeneration.Tests.JsonMessage>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                               
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.Text.Json.SourceGeneration.Tests.ActiveOrUpcomingEvent>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                         
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.DateTimeOffset>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                 
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.Text.Json.SourceGeneration.Tests.HighLowTemps>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                              
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.Text.Json.SourceGeneration.Tests.ActiveOrUpcomingEvent>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                         
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.DateTimeOffset>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                 
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.Text.Json.SourceGeneration.Tests.HighLowTemps>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                              
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.Text.Json.SourceGeneration.Tests.ActiveOrUpcomingEvent>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                         
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.DateTimeOffset>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                 
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.Text.Json.SourceGeneration.Tests.HighLowTemps>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                              
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.Text.Json.SourceGeneration.Tests.ActiveOrUpcomingEvent>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                         
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.DateTimeOffset>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                 
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.Text.Json.SourceGeneration.Tests.HighLowTemps>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                              
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.Text.Json.SourceGeneration.Tests.ActiveOrUpcomingEvent>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                         
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.List<System.DateTimeOffset>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                 
CSC : error SYSLIB1030: Did not generate serialization metadata for type 'global::System.Collections.Generic.Dictionary<System.String,System.Text.Json.SourceGeneration.Tests.HighLowTemps>'. [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(49,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(50,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(62,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(63,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(75,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(76,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(88,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(89,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(101,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(102,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(114,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(115,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(127,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(128,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(49,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                 
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(50,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                 
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(62,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                 
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(63,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                 
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(75,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(76,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(88,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(89,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(101,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(102,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(114,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(115,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(127,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(128,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(49,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(50,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(62,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(63,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(75,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(76,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(88,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(89,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(101,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(102,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(114,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(115,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(127,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(128,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContext.DayOfWeek.g.cs(139,17): error CS0472: The result of the expression is always 'false' since a value of type 'DayOfWeek' is never equal to 'null' of type 'DayOfWeek?' [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                              
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataAndSerializationContext.DayOfWeek.g.cs(139,17): error CS0472: The result of the expression is always 'false' since a value of type 'DayOfWeek' is never equal to 'null' of type 'DayOfWeek?' [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MetadataContext.DayOfWeek.g.cs(139,17): error CS0472: The result of the expression is always 'false' since a value of type 'DayOfWeek' is never equal to 'null' of type 'DayOfWeek?' [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                   
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(49,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(50,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(62,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(63,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                     
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(75,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                    
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(76,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                    
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(88,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(89,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(101,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(102,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(114,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                    
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(115,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                    
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(127,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(128,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/MixedModeContext.DayOfWeek.g.cs(139,17): error CS0472: The result of the expression is always 'false' since a value of type 'DayOfWeek' is never equal to 'null' of type 'DayOfWeek?' [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                  
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/SerializationLogicTests.cs(35,58): error CS1061: 'DictionaryTypeContext' does not contain a definition for 'DictionarySystemStringSystemString' and no accessible extension method 'DictionarySystemStringSystemString' accepting a first argument of type 'DictionaryTypeContext' could be found (are you missing a using directive or an assembly reference?) [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                                                                        
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/SerializationLogicTests.cs(36,58): error CS1061: 'DictionaryTypeContext' does not contain a definition for 'DictionarySystemStringSystemTextJsonSourceGenerationTestsJsonMessage' and no accessible extension method 'DictionarySystemStringSystemTextJsonSourceGenerationTestsJsonMessage' accepting a first argument of type 'DictionaryTypeContext' could be found (are you missing a using directive or an assembly reference?) [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                    
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/SerializationLogicTests.cs(37,58): error CS1061: 'DictionaryTypeContext' does not contain a definition for 'JsonMessage' and no accessible extension method 'JsonMessage' accepting a first argument of type 'DictionaryTypeContext' could be found (are you missing a using directive or an assembly reference?) [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                                                                                                                                                                      
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/SerializationLogicTests.cs(38,55): error CS1061: 'DictionaryTypeContext' does not contain a definition for 'String' and no accessible extension method 'String' accepting a first argument of type 'DictionaryTypeContext' could be found (are you missing a using directive or an assembly reference?) [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]        
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/SerializationLogicTests.cs(39,55): error CS1061: 'DictionaryTypeContext' does not contain a definition for 'Int32' and no accessible extension method 'Int32' accepting a first argument of type 'DictionaryTypeContext' could be found (are you missing a using directive or an assembly reference?) [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]          
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(49,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]                                    
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(50,50): error CS0176: Member 'DayOfWeek.Sunday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(62,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(63,50): error CS0176: Member 'DayOfWeek.Monday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(75,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(76,50): error CS0176: Member 'DayOfWeek.Tuesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(88,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(89,50): error CS0176: Member 'DayOfWeek.Wednesday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(101,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(102,50): error CS0176: Member 'DayOfWeek.Thursday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(114,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(115,50): error CS0176: Member 'DayOfWeek.Friday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(127,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(128,50): error CS0176: Member 'DayOfWeek.Saturday' cannot be accessed with an instance reference; qualify it with a type name instead [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]
/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration/System.Text.Json.SourceGeneration.JsonSourceGenerator/SerializationContextWithCamelCase.DayOfWeek.g.cs(139,17): error CS0472: The result of the expression is always 'false' since a value of type 'DayOfWeek' is never equal to 'null' of type 'DayOfWeek?' [/home/uweigand/runtime/src/libraries/System.Text.Json/tests/System.Text.Json.SourceGeneration.Tests/System.Text.Json.SourceGeneration.Tests.csproj]

@BrzVlad BrzVlad added the NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) label Jun 9, 2021
@BrzVlad
Copy link
Member

BrzVlad commented Jun 17, 2021

Implemented in #54062

@BrzVlad BrzVlad closed this Jun 17, 2021
@uweigand uweigand deleted the mono-typeequality branch June 17, 2021 18:10
@uweigand
Copy link
Contributor Author

Implemented in #54062

This does fix the original problem for me, thank you!

@ghost ghost locked as resolved and limited conversation to collaborators Jul 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-VM-meta-mono NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants