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
Convert the Data.Map from/to a Data.StrMap, then encode/decode it similarly to Data.StrMap's instance
All keys are first converted to Strings, so I introduced an EncodeKey/DecodeKey class which can encode or decode keys to/from String respectively
Also in the initial implementation only the first decoding error is reported, I think the current StrMap doesn't report all decoding errors either. But that can definitely be fixed.
There are a lot of possibilities, so maybe it would be interesting to discuss the preferred way of doing it first.
The text was updated successfully, but these errors were encountered:
I'm wondering what the preferred way of writing a de/encode instance for
Data.Map
would be?I have an initial implementation in a fork here ( rubenpieters@e2f24ed ).
Some choices I made:
Data.Map
from/to aData.StrMap
, then encode/decode it similarly toData.StrMap
's instanceString
s, so I introduced anEncodeKey
/DecodeKey
class which can encode or decode keys to/fromString
respectivelyAlso in the initial implementation only the first decoding error is reported, I think the current
StrMap
doesn't report all decoding errors either. But that can definitely be fixed.There are a lot of possibilities, so maybe it would be interesting to discuss the preferred way of doing it first.
The text was updated successfully, but these errors were encountered: