We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ghci> sconcat (First 'a' :| [First 'b']) First {getFirst = 'a'} ghci> sconcat ((Rec.rnil & Rec.rcons (#foo Rec.:= First 'a')) :| [(Rec.rnil & Rec.rcons (#foo Rec.:= First 'b'))]) [("foo","First {getFirst = 'b'}")]
I’d expect both to return the same result, since all I did was to wrap the First in a #foo field …
First
#foo
The text was updated successfully, but these errors were encountered:
Oh, I think I get it: The values are not even looked at by the instance:
(Semigroup (Rec lts), UnsafeRecBuild lts lts (ConstC Monoid :: Symbol -> TYPE LiftedRep -> Constraint)) => Monoid (Rec lts)
lts here is completely opaque.
lts
But that also means <> is equivalent of always throwing away the left record, no? Cause there is nothing to be done with the values.
<>
Sorry, something went wrong.
Ah no, I missed the constraint ConstC Monoid, of course the values are looked at.
ConstC Monoid
Better example:
> (rcons (#foo := "a") rnil) <> (rcons (#foo := "b") rnil) [("foo","\"ba\"")]
No branches or pull requests
I’d expect both to return the same result, since all I did was to wrap the
First
in a#foo
field …The text was updated successfully, but these errors were encountered: