Open jozefg opened 8 years ago
I think this is worth the pain.
one other are of incompatibility may be with structure sharing (which may still occur in a few places?).
@jonsterling It looks like we're mostly doing sharing type
except in one spot in sml-abt-unify, though it's easily fixed. Structure is a mess :/
@jozefg Yeah... If they can fix one thing in Successor ML, I hope it's that.
So, I think the thing to do is first to make sure all dependencies of JonPRL are compliant; then, we should start making the required changes in JonPRL in earnest.
Regarding MLton, I think there are going to be some problems with unicode, though maybe that's not as big of an issue anymore. But strings in the source will have to be escaped and I think there are some other problems with manipulating the strings even if they are escaped but I don't remember the details.
@freebroccolo Oh right, I'd forgotten about that... :(
Making JonPRL fully compliant with '97 has a few nice benefits. We never have to worry about NJ not adapting to a new platform, we can get faster binaries with mlton, we can properly support 64bit (doesn't NJ still have weird issues with it) etc, etc.
As far as making this happen, I can think of three big things off the top of my head
#[]
vector patterns. They unfortunately aren't standard.mlb
files in addition to.cm
files (I really want MLton to work)There is a potential downside, we can fix the second one by adding a series of utility functions along the lines of
and then use
ext*
plus a pattern match on a tuple. This is going to be a lot less readable though, particularly in places likesrc/refiner/extract.fun
where all of those pattern matches would grow an extra let-expression to pattern match on the vector. Is there a nicer way that I'm missing? Is it worth the extra ugliness?