Hi All,

I've been looking at compiling from Yhc.Core to Yhc bytecode (instead of from PosLambda) however there are one or two changes that I would need to make to Core to do this. All the changes (so-far) are limited to CorePrim, which would be changed to:

data CoreFunc
  = CoreFunc ...
  | CorePrim {
    coreFuncName :: CoreFuncName,     --^ name of the function in
                                      -- haskell
    corePrimArity :: Int,             --^ arity of the function
corePrimExternal :: Maybe String, --^ name of function in C (or
                                      -- Nothing for same as haskell)
    corePrimConv :: String,           --^ calling convention used
    corePrimImport :: Bool,           --^ true for an import, false for
                                      -- an export
  }

i.e. this would add 3 constructors to the CorePrim data type. This would obviously break things for anyone who used a complete pattern match but if you only use the selectors it would continue to work fine.

Does anyone have any objections (or suggestions for additional ideas) to these changes?

Cheers

Tom

_______________________________________________
Yhc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/yhc

Reply via email to