|
|
|
|
|
by mrkgnao
3303 days ago
|
|
Oh, this is interesting! http://www.cprogramming.com/tutorial/template_specialization... What you have towards the end of that post is actually something like type family Vector a where
type instance Vector (Ptr a) = ...
type instance Vector a = ...
This is a closed type family. (Think of it as a pattern-match on types where the cases are tried in order.) Very cool!I still don't know how the linear algebra/Eigen examples might work, though. |
|