mikeizbicki / HLearn

Homomorphic machine learning
Other
1.63k stars 138 forks source link

Docs: type instance should be just type #14

Closed nh2 closed 9 years ago

nh2 commented 11 years ago

http://hackage.haskell.org/packages/archive/HLearn-distributions/1.0.0.1/doc/html/HLearn-Models-Distributions-Multivariate-Internal-TypeLens.html

The entries

instance TypeLens TH_name where
    type TypeLensIndex TH_name = Nat1Box Zero
instance TypeLens TH_species where
    type TypeLensIndex TH_species = Nat1Box (Succ Zero)
...

are invalid syntax. It should be

instance TypeLens TH_name where
    type TypeLensIndex TH_name = Nat1Box Zero
instance TypeLens TH_species where
    type TypeLensIndex TH_species = Nat1Box (Succ Zero)
...

Unfortunately, that output is also wrong in ghc -ddump-splices.

I've also written a post to Haskell-Cafe on this.

nh2 commented 11 years ago

Also, I think that in

getHList var = name var:::species var:::job var:::isGood var:::age var:::height var:::weight var:::HNil

there should be underscores, e.g. _name var ::: ....