fix removal of typerep
Merge pull request #1835 from janestreet/master

fix #1826