You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a type called Possible that I'm @Encoding to support these types of fields:
Possible<T>
Possible<Optional<T>>
Possible<List<T>>
However when encountering a class with a combination of these types, I get an incompatibility warning:
(immutables:incompat) Encoding conflict for attribute 'field', the winning match:
Possible<T> (from PossibleEncoding).
Other applicable: [Possible<List<T>> (from PossibleListEncoding)]
While this warning is expected, the way a winning match is picked changes between builds. I would hope I could assert a certain order of resolution but it doesn't seem to work.
So far my workaround is changing the implementation of Possible<T> to Possible<? extends T>. Is there another approach to guarantee a given resolution order?
The text was updated successfully, but these errors were encountered:
quanticc
added a commit
to quanticc/immutables
that referenced
this issue
May 3, 2020
I have a type called
Possible
that I'm@Encoding
to support these types of fields:Possible<T>
Possible<Optional<T>>
Possible<List<T>>
However when encountering a class with a combination of these types, I get an incompatibility warning:
While this warning is expected, the way a winning match is picked changes between builds. I would hope I could assert a certain order of resolution but it doesn't seem to work.
So far my workaround is changing the implementation of
Possible<T>
toPossible<? extends T>
. Is there another approach to guarantee a given resolution order?The text was updated successfully, but these errors were encountered: