camlspotter avatar camlspotter committed d6ba7bb

build depend

Comments (0)

Files changed (3)

 
 val any : 'a t -> any t
 
-val int : int -> int_t
+external int : int -> int t = "%identity"
 
 val alert : string -> unit
   (** JS alert function *)
+OCAMLCFLAGS   += -I ../lib
+OCAMLOPTFLAGS += -I ../lib
+
+# Enforce ../lib/xJs.cmo exists before compilation
+.SCANNER: scan-ocaml-%: ../lib/xJs.cmo
+%.cmx %.cmo %.cmi %.cma %.cmxa %.annot %.spot %.spit : ../lib/xJs.cmo
+
 FILES[] =
+    ../lib/xJs
     chart
 
-OCAML_PREINSTALLED_PACKS[] += xJs
-OCAMLPACKS[] += xJs
-
 MyOCamlJSProgram(chart, $(FILES))
 open Js
 open XJs
-(* open Std *)
+open Std
 open Google
 open Lwt
 
   ignore begin
     Data.get "data.txt" >>= fun rows ->
     data##addRows(Js.array (Array.of_list (List.map (fun (x,y) -> 
-      Js.array [| Obj.magic x; Obj.magic y; |]) rows)));
+      Js.array [| int x; int y; |]) rows)));
     return ()
   end
 
     let rec iter = function
       | [] -> return ()
       | (x,y)::xys ->
-          data##addRows(Js.array [| Js.array [| Obj.magic x; Obj.magic y; |] |]);
+          data##addRows(Js.array [| Js.array [| int x; int y; |] |]);
           Lwt_js.sleep 0.2 >>= fun () ->
           iter xys (* It seems not to be executed.... Hmmm *)
     in
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.