Hacker News new | ask | show | jobs
by jolux 2341 days ago
Are records structural in Standard ML? What happens if you have multiple records with the same structure but different names? I thought structural typing of records was not very useful without row polymorphism.
1 comments

Records of the same structure but different names are equivalent. In fact tuples are just sugar over records with numeric fields starting from 1. Note that this is not the same as in OCaml, afaik.
It depends. OCaml explicitly has polymorphic records as well.