Giter Site home page Giter Site logo

Comments (6)

dotnet-policy-service avatar dotnet-policy-service commented on July 18, 2024

Tagging subscribers to this area: @dotnet/area-system-numerics
See info in area-owners.md if you want to be subscribed.

from roslyn.

huoyaoyuan avatar huoyaoyuan commented on July 18, 2024

The comparison operator of nullables are synthesized by compiler:

https://sharplab.io/#v2:D4AQTAjAsAUCDMACciDCiDetE+UkALIgLIAUAlNrljLnYgCYCmAxgJYC2AhgDYD8iAG6IAvIgAMAOnHiOAbir1kEAJylhIsc3bcekgFpMATgHtycxAHpLiACpGArk0RsAdogBGJgC4ALRAAc0pJg4gCsiFyuDIHB8DKK9BqIrg48PAq0SspqGlqsnLwGxmYW1ogAYrwAzs5unj7+QVKhEVExzZLx4ol0IKrqomJSMhzmVjZVPLUu7p2tkdGI3o51c3EJWTgAvrDbQA==

The difference of SDK version also suggests this. SDK 8.0.205 and 8.0.300 shares the same runtime version of 8.0.5, but different compiler versions. So this is probably a C# compiler bug for https://github.com/dotnet/roslyn.

from roslyn.

huoyaoyuan avatar huoyaoyuan commented on July 18, 2024

Switching to main in SharpLab, the HasValue call disappears in decompilation of the third invocation.

from roslyn.

Quintinon avatar Quintinon commented on July 18, 2024

Do I need to repost this issue over to the roslyn repo?

from roslyn.

333fred avatar 333fred commented on July 18, 2024

Do I need to repost this issue over to the roslyn repo?

No, we're addressing it directly now. Thanks for the report!

from roslyn.

irmen avatar irmen commented on July 18, 2024

Running in visual studio did not reproduce this issue

For us it did, but only after we updated to the most recent version (17.10.0). (that also installed sdk 8.0.300)

from roslyn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.