ffi002_c.c 294 Bytes
Newer Older
rrt's avatar
rrt committed
1
#include <stdio.h>
2
#include "ffi002_stub.h"
rrt's avatar
rrt committed
3
4
5

#include "RtsAPI.h"

ken's avatar
ken committed
6
extern void __stginit_Foo ( void );
rrt's avatar
rrt committed
7

8
int main(int argc, char *argv[])
rrt's avatar
rrt committed
9
10
11
{
  int i;

12
  startupHaskell(argc, argv, __stginit_Foo);
rrt's avatar
rrt committed
13
14
15
16
17
18
19
20
21

  for (i = 0; i < 5; i++) {
    printf("%d\n", foo(2500));
  }

  shutdownHaskell();

  return 0;
}