Question
Is there a way to create a record with a field called "data"?
data MyRecord =
MyRecord {
otherField :: String,
data :: String -- compilation error
}
Why do I need it?
I've been writing a wrapper around a JSON API using Aeson and the remote service decided to call one of the fields data
.
{
pagination: {
..
},
data: [
{ .. },
{ .. },
]
}