http://www.perlmonks.org?node_id=665231


in reply to Perl Cannot Be Parsed: A Formal Proof

Type inference (and as a consequence parsing?) in ML 'and I suspect many other functional languages, is complete in deterministic expotential time. For any practical reasons that's as close to undecidability as possible.

Replies are listed 'Best First'.
Re^2: Perl Cannot Be Parsed: A Formal Proof
by Anonymous Monk on Aug 13, 2009 at 19:29 UTC
    No, you can parse SML without doing type inference. The (only) tricky part of SML parsing is operator fixity, which doesn't depend on types at all. And yes, SML type inference is superexponential, but only for contrived examples. So for "any practical reasons", it's not even remotely close to undecidability.