[Haskell-cafe] Implementing fixed-sized vectors (using datatype algebra?)

Alfonso Acosta alfonso.acosta at gmail.com
Thu Jan 31 09:15:12 EST 2008


On Jan 31, 2008 3:03 PM, Wolfgang Jeltsch <g9ks157k at acme.softbase.org> wrote:
> Hello Fons,
>
> interestingly, it occured to me yesterday that the graphics part of Grapefruit
> would benefit from fixed sized vectors.  I think we should implement some
> small Cabal package which just provides this and upload it to the HackageDB.
> Are you interested in cooperating with me on this?

Sure I am!

Actually, thanks to the pointers provided by Henning I learned that
Oleg (who else!) already has implemented them. See

http://okmij.org/ftp/Haskell/number-parameterized-types.html
http://www.haskell.org/tmrwiki/NumberParamTypes
http://okmij.org/ftp/Haskell/number-param-vector-code.tar.gz (Oleg's
multiple flavour implementations of fixed-sized vectors)

I think we should base our implementation on Oleg's (for which we need
his permission). Actually, I think we should create two separate
libraries. One for decimal type-level arithmetic and another for the
vector implementation itself. What do you think?


More information about the Haskell-Cafe mailing list