So this is likely a silly question but I am just a little confused.
So I understand the Haskell compiler is itself written in Haskell. How does this work? What does it compile to? What is the OCaml compiler written in?
Also, they say using a functional language like haskell or OCaml. Can someone go through the steps of what is going on when this happens? So the new language would be compiled to haskell which would then be compiled to whatever the haskell compiler compiles to?