flix / flix

The Flix Programming Language
https://flix.dev/
Other
2.14k stars 151 forks source link

Breaking Changes #5044

Closed magnus-madsen closed 1 year ago

magnus-madsen commented 1 year ago

We are currently in a period of breaking changes. I just wanted to collect these in one place.

Recent, current, and on-going breaking changes:

EDIT: The good news is that the "core" language (other than channels/processes) remain stable.

magnus-madsen commented 1 year ago

CC @stephentetley I hope this is not too painful.

JonathanStarup commented 1 year ago

Maybe we could also use the minor version more for non-breaking versions instead of 0.X.0 for everything.

stephentetley commented 1 year ago

Thanks Magnus, the changes are fine.

One thing that is a problem is "unexpected non-enum" in Resolver.scala gets throw crashing the compiler if use statements try to access enum constructors that don't exist. I don't think Flix checked use imports before so I have quite a few cases in my libraries that were never caught as code got refactored. The stacktrace from the compiler crash doesn't help locate the problem so I've had to append the source location to the "unexpected non-enum" message in a hacked version of the compiler.

magnus-madsen commented 1 year ago

Thanks Magnus, the changes are fine.

One thing that is a problem is "unexpected non-enum" in Resolver.scala gets throw crashing the compiler if use statements try to access enum constructors that don't exist. I don't think Flix checked use imports before so I have quite a few cases in my libraries that were never caught as code got refactored. The stacktrace from the compiler crash doesn't help locate the problem so I've had to append the source location to the "unexpected non-enum" message in a hacked version of the compiler.

I suspect this will be fixed. We are kind of "in between" the old and new system.