[Haskell-cafe] How do you make constant expressions?

Eitan Goldshtrom thesourceofx at gmail.com
Sun Jul 18 16:19:21 EDT 2010


Silly question, but I can't find the answer on the net. I think I'm just 
using the wrong words in my search. I'm looking for a way to create 
constant expressions in Haskell. The C/C++ equivalent of what I'm 
talking about is

#define NAME VALUE

I want an expression, or really just numbers for what I'm doing, that 
the compiler will put into the program at the designated places, instead 
of storing it in memory like a variable.

-Eitan


More information about the Haskell-Cafe mailing list