wheaties / AutoLifts

Automatic functional lifting, mapping and folding.
Apache License 2.0
65 stars 4 forks source link

Boilerplate for liftM2 through liftM22 (and liftA*) #25

Closed wheaties closed 8 years ago

wheaties commented 8 years ago

Haskell has up to liftM5. Scala tends to go to 22. I've got all of 3. Writing it by hand a bit of a PITA. Boilerplate.scala a la Shapeless or Cats.

frosforever commented 8 years ago

@wheaties I'm on it

wheaties commented 8 years ago

I've figured out LiftA* boilerplate but #19 and Cats support using Miles' export-hook may prevent past arity 5, basically on par with Haskell.

frosforever commented 8 years ago

@wheaties I don't know enough about export-hook. What seems to be the issue?

wheaties commented 8 years ago

Worries about compilation speed. Miles asked me to cap it at a lower arity until this can be quantified. Hence, I'll be able to keep parity with haskell but not with all function arity.

frosforever commented 8 years ago

would that mean maxArity should be 6 (n + 1 as you need one extra DFunction)?