[haskell-llvm] Type of function with no arguments

Nathan Howell nathan.d.howell at gmail.com
Thu Nov 22 17:25:12 GMT 2012


I believe it should be "Function (IO Int32)"


On Thu, Nov 22, 2012 at 7:48 AM, José Romildo Malaquias <j.romildo at gmail.com
> wrote:

> Hello.
>
> What should be the type of an LLVM function that has no arguments and
> returns an int32?
>
> I have tried
>
>   Function (() -> Int32)
>
> but the llvm ir compiler does not accept it, with the error:
>
>   llc: prog1.ll:3:18: error: void type only allowed for function results
>   define i32 @main(void) {
>                  ^
> Romildo
>
> _______________________________________________
> Haskell-llvm mailing list
> Haskell-llvm at projects.haskell.org
> http://projects.haskell.org/cgi-bin/mailman/listinfo/haskell-llvm
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://projects.haskell.org/pipermail/haskell-llvm/attachments/20121122/49416418/attachment.htm>


More information about the Haskell-llvm mailing list