j
k
j a
j l
What you can do is use record labels. Here, you just name the two Ints the same thing and get what you want: ...data Test = T1 { test :: Int } | T2 { test :: Int }
What you can do is use record labels. Here, you just name the two Ints the same thing and get what you want:
data Test = T1 { test :: Int } | T2 { test :: Int }
Thank you all, that is exactly what I need!
Back to the thread
Back to the list