Remix.run Logo
charcircuit 3 hours ago

A C++ compiler translates C++ to an assembly. This project would translate C++ to another language. It's not that different of a concept.

dagmx 2 hours ago | parent | next [-]

It’s significantly more straight forward to go from a higher level to a lower level representation than it is to go between different high level representations.

That’s not to trivialize what a compiler does, but it’s effectively going from a complex form to its building blocks while maintaining semantics.

Changing high level languages introduces fundamentally different semantics. Both can decompose to the same general building blocks, but you can’t necessarily compose them the same way.

At the simplest example, a compiler backend (the part you’re describing) can’t reason about data access rules. That is the domain of the language’s compiler frontend and a fundamental difference between C++ and Rust that can’t just be directly derived.

monocasa 3 hours ago | parent | prev | next [-]

A compiler isn't using a statistical model of language more complex than anyone could understand with a lifetime of study to do its translation, adheres to a standard for that translation, and if you're important enough (and Microsoft internal teams are for MSVC), you get heads up on what specifically is changing so you know where to look for issues.

This is "lets put our postgres database on blockchain because I think blockchain is cool" level of crap you see in peak bubble.

overgard 3 hours ago | parent | prev [-]

Compilers are deterministic.