Git Product home page Git Product logo

Comments (5)

estebank avatar estebank commented on June 20, 2024 1

Copying from #123526 (comment):

we [should] introduce a new, separate, version of panicking that doesn't "look" like an ICE but rather a generic "invalid language state" error that stops the compilation, with no stack trace.

I think this ticket is a good example of a case where having a distinction between "the compiler made a mistake" and "the user modifiable language state is incorrect" in the panic output would be useful. It'd be already great if it only applied to the "expect" methods (like "assume the Sized trait is available" methods). If those weren't an automatic ICE, I think we could clean up rustc code a bunch.

from rust.

Nilstrieb avatar Nilstrieb commented on June 20, 2024 1

i think we should just make the ICE message here a bit clearer
keep the stack trace or whatever but mention way more clearly that internal features are not supported and that if the ICE is related to that, that we don't want a bug report.

from rust.

Nilstrieb avatar Nilstrieb commented on June 20, 2024

note: using internal features is not supported and expected to cause internal compiler errors when used incorrectly

It's a bit hidden in the ICE message, understandable that you've missed it.

from rust.

gurry avatar gurry commented on June 20, 2024

Oh. I should've seen that. Thanks :)

from rust.

Nilstrieb avatar Nilstrieb commented on June 20, 2024

You could replace all of the bugs with that but you can't replace things like indexing with it without making the compiler code uglier. I am not sure where rustc could be cleaned up by making this code less panicky... if there's anything that would be cleaner in the compiler code without panicking then please just do that today!

from rust.

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.