Open densh opened 9 years ago
Yes, I will close them both today.
More detailed desugaring in tex:
\begin{figure}
$ [[ let\ x: T_x = t_x\ in\ t ]] = \\ $
$ ((x: T_x) \ra t)(t_x) \\ \\$
$ [[ let\ type\ T_1 = T_2\ in\ t ]] = \\ $
$ ([T_1 <: T_2] \ra t)[T_2] \\ \\ $
$ [[ let\ class\ C[A](x: T_x) \{ def\ f[B](y: T_y) = t_f \}\ in\ t ]] = \\ $
$ \ let\ type\ C = [A] \ra \{ x: T_x, f: [B] \ra T_y \ra T_f \}\ in \\ $
$ \ let\ C: [A] \ra (x: T_x) \ra C[A] = [A] \ra (x: T_x) \ra \{ x = x, f = [B] \ra (y: T_y) \ra t_f \}\ in\ t$
\end{figure}
Class desugaring
Method desugaring