Skip to content

Instantly share code, notes, and snippets.

@jvanbruegge
Last active November 8, 2018 18:00
Show Gist options
  • Save jvanbruegge/e2297f8e57e783f845f56f0627afc7ba to your computer and use it in GitHub Desktop.
Save jvanbruegge/e2297f8e57e783f845f56f0627afc7ba to your computer and use it in GitHub Desktop.
{-# LANGUAGE CPP #-}
{-# LANGUAGE OverloadedLabels #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
module Main where
-- #define SUPERRECORD
#define MEGARECORD
#ifdef SUPERRECORD
import SuperRecord
#endif
#ifdef MEGARECORD
import Megarecord
#endif
type BigRow =
#ifdef SUPERRECORD
'[ "f1" := Int
, "f2" := Int
, "f3" := Int
, "f4" := Int
, "f5" := Int
, "f6" := Int
, "f7" := Int
, "f8" := Int
, "f9" := Int
, "f10" := Int
, "f11" := Int
, "f12" := Int
, "f13" := Int
, "f14" := Int
, "f15" := Int
, "f16" := Int
, "f17" := Int
, "f18" := Int
, "f19" := Int
, "f20" := Int
, "f21" := Int
, "f22" := Int
, "f23" := Int
, "f24" := Int
, "f25" := Int
, "f26" := Int
, "f27" := Int
, "f28" := Int
, "f29" := Int
, "f30" := Int
, "f31" := Int
, "f32" := Int
, "f33" := Int
, "f34" := Int
, "f35" := Int
, "f36" := Int
, "f37" := Int
, "f38" := Int
, "f39" := Int
, "f40" := Int ]
#endif
#ifdef MEGARECORD
"f1" := Int
& "f2" := Int
& "f3" := Int
& "f4" := Int
& "f5" := Int
& "f6" := Int
& "f7" := Int
& "f8" := Int
& "f9" := Int
& "f10" := Int
& "f11" := Int
& "f12" := Int
& "f13" := Int
& "f14" := Int
& "f15" := Int
& "f16" := Int
& "f17" := Int
& "f18" := Int
& "f19" := Int
& "f20" := Int
& "f21" := Int
& "f22" := Int
& "f23" := Int
& "f24" := Int
& "f25" := Int
& "f26" := Int
& "f27" := Int
& "f28" := Int
& "f29" := Int
& "f30" := Int
& "f31" := Int
& "f32" := Int
& "f33" := Int
& "f34" := Int
& "f35" := Int
& "f36" := Int
& "f37" := Int
& "f38" := Int
& "f39" := Int
& "f40" := Int
& Empty
#endif
bigRec :: Record BigRow
bigRec = #f1 := 1
& #f2 := 2
& #f3 := 3
& #f4 := 4
& #f5 := 5
& #f6 := 6
& #f7 := 7
& #f8 := 8
& #f9 := 9
& #f10 := 10
& #f11 := 11
& #f12 := 12
& #f13 := 13
& #f14 := 14
& #f15 := 15
& #f16 := 16
& #f17 := 17
& #f18 := 18
& #f19 := 19
& #f20 := 20
& #f21 := 21
& #f22 := 22
& #f23 := 23
& #f24 := 24
& #f25 := 25
& #f26 := 26
& #f27 := 27
& #f28 := 28
& #f29 := 29
& #f30 := 30
& #f31 := 31
& #f32 := 32
& #f33 := 33
& #f34 := 34
& #f35 := 35
& #f36 := 36
& #f37 := 37
& #f38 := 38
& #f39 := 39
& #f40 := 40
& rnil
main :: IO ()
main = print "ok"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment