Permalink
Browse files

fix issue #3 - properly 'namespace' external C functions

  • Loading branch information...
1 parent 519319e commit a6ba47f018cf9328a0e84991fabe5011cacae2ff Austin Seipp committed Jun 13, 2011
Showing with 10 additions and 10 deletions.
  1. +5 −5 bsl/c/native.c
  2. +5 −5 bsl/c/native.ml
View
@@ -3,7 +3,7 @@
#include <caml/alloc.h>
#include <caml/memory.h>
-CAMLprim value get_memory_usage() {
+CAMLprim value opaque_get_memory_usage() {
CAMLparam0();
static struct rusage usage;
@@ -26,7 +26,7 @@ static void uname_init() {
return;
}
-CAMLprim value get_sys_sysname() {
+CAMLprim value opaque_get_sys_sysname() {
CAMLparam0();
CAMLlocal1(str);
@@ -36,7 +36,7 @@ CAMLprim value get_sys_sysname() {
CAMLreturn(str);
}
-CAMLprim value get_sys_nodename() {
+CAMLprim value opaque_get_sys_nodename() {
CAMLparam0();
CAMLlocal1(str);
@@ -46,7 +46,7 @@ CAMLprim value get_sys_nodename() {
CAMLreturn(str);
}
-CAMLprim value get_sys_release() {
+CAMLprim value opaque_get_sys_release() {
CAMLparam0();
CAMLlocal1(str);
@@ -56,7 +56,7 @@ CAMLprim value get_sys_release() {
CAMLreturn(str);
}
-CAMLprim value get_sys_machine() {
+CAMLprim value opaque_get_sys_machine() {
CAMLparam0();
CAMLlocal1(str);
View
@@ -1,14 +1,14 @@
##register get_sys_sysname: -> string
-external get_sys_sysname : unit -> string = "get_sys_sysname"
+external get_sys_sysname : unit -> string = "opaque_get_sys_sysname"
##register get_sys_nodename: -> string
-external get_sys_nodename : unit -> string = "get_sys_nodename"
+external get_sys_nodename : unit -> string = "opaque_get_sys_nodename"
##register get_sys_release: -> string
-external get_sys_release : unit -> string = "get_sys_release"
+external get_sys_release : unit -> string = "opaque_get_sys_release"
##register get_sys_machine: -> string
-external get_sys_machine : unit -> string = "get_sys_machine"
+external get_sys_machine : unit -> string = "opaque_get_sys_machine"
##register get_memory_usage: -> int
-external get_memory_usage : unit -> int = "get_memory_usage"
+external get_memory_usage : unit -> int = "opaque_get_memory_usage"

0 comments on commit a6ba47f

Please sign in to comment.