Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
close #120 cc @DavidGregory084
This addresses some of the issues raised #76 and #117
Namely, I took the same strategy as #117, but do not expose
Line
at the top level. This allows us to maintain all the invariants we have, but does not give us the feature request of #76By changing this PR only to remove the sys.error in flatten on Line and allowing Line at the top level, the following laws fail:
Note this is minorly binary incompatible. We will need to bump the minor version here, but it should be source compatible.
Lastly, I want to apologize to anyone who is disappointed at the pace of change here. This code is super highly tested with very strong law coverage, but that also constrains the implementation quite a bit. It seems like we have to give up some of the laws to get a hardLine (feature requested from #76). @seanmcl did some excellent work trying to get this in, and I lost track of it and he possibly lost interest. In the mean time, @olafurpg also started using a fork due to the lack of this feature. It's a bummer. If I had been more engaged we would be further along in this repo.
What I propose is merge this, which is part of @seanmcl 's work, and then we can see explore the minimal set of laws we can lose to expose Line at the top level.
I think flattening and fill seem to be the ones that are the most at risk.