Giter Site home page Giter Site logo

Comments (6)

CyrusNajmabadi avatar CyrusNajmabadi commented on June 19, 2024 2

Note: we do this in the IDE for huge memory savings. In the IDE we have hte compilation objects just reference each other, without any emitting of IL/Metadata.

The command line doesn't do this at all. When you build, it biulds, and it produces all those dlls (and all that IO). What it produces is fed into the next compiler.

This is ok on the command line (people don't mind seconds or minutes of compile costs when tey make a change). it's not ok in the IDE. People make a change and expect it to be incorporated, globally, immediately.

from roslyn.

jaredpar avatar jaredpar commented on June 19, 2024

Looks like a dupe of #73269

from roslyn.

jaredpar avatar jaredpar commented on June 19, 2024

In short generators are not guaranteed to see private members in external assemblies. That may happen when run in VS but will not when run through the command line. That is due to a combination of factors (ref assemblies and metadata import options) and these behaviors are by design.

from roslyn.

lxymahatma avatar lxymahatma commented on June 19, 2024

In short generators are not guaranteed to see private members in external assemblies. That may happen when run in VS but will not when run through the command line. That is due to a combination of factors (ref assemblies and metadata import options) and these behaviors are by design.

oh.. I thought since source generator cannot access private members in external libraries, the different behavior in debug and inside project is unexpected and is a bug
Cz like it's still a bit weird that you cannot access it, but in project it actually generate the files but can't get compiled. I thought it's a bug because i supposed it should be completely disabled

from roslyn.

jaredpar avatar jaredpar commented on June 19, 2024

It's more an artifact of the different way the IDE handles references compared to the command line. It would be ideal if there was the same behavior but each environment has different constraints they are working with.

from roslyn.

lxymahatma avatar lxymahatma commented on June 19, 2024

It's more an artifact of the different way the IDE handles references compared to the command line. It would be ideal if there was the same behavior but each environment has different constraints they are working with.

Ah i see, then i guess I'll just wait for future improvements. Thank you for the detailed answer 👍🏻

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.