ocaml-batteries

    4熱度

    2回答

    我有一個帶有OCaml .ml文件和Menhir .mly文件的項目。我使用ocamlbuild來編譯這個項目。 我_tags文件包含此單行: true: use_menhir, package(batteries) 一切運作良好,除了當我想在.mly文件中使用的電池。如果我在我的.mly文件中的%{和%}之間的open Batteries ;;,調用ocamlbuild時會出現「Error:

    1熱度

    1回答

    似乎有關於電池安裝的信息有衝突。我嘗試了幾個建議,但沒有人爲我工作。 我第一次嘗試 ocamlfind batteries/ocaml ,但給了這個錯誤: ocamlfind: Cannot find command: /username/godi/lib/ocaml/pkg-lib/batteries/ocaml 然後我試圖從電池目錄複製ocamlinit文件在我家目錄.ocamlini

    0熱度

    1回答

    這是一個簡單的ocaml文件,目的是讓我瞭解如何將使用電池庫的程序加載到ocamltop中。 batteryassault.ml open Batteries let main = print_string "hello, world ... powered on" 我編譯這與 ocamlfind ocamlc -package batteries -linkpkg batteryassa

    -1熱度

    1回答

    我想使用module List of Ocaml Batteries的功能。我已經安裝了電池,並寫出如下代碼: open Extlib ... Extlib.ExtList.List.remove ... 在編譯時,它給了我一個錯誤Error: Unbound module Extlib。有誰知道會發生什麼?

    19熱度

    2回答

    我希望使用OCaml訪問Yahoo Finance API。從本質上講,它將只是一堆HTTP請求從雅虎財經獲得報價。 我應該使用哪個模塊? 我希望有異步HTTP請求。

    2熱度

    1回答

    我想使用module List of Ocaml Batteries的功能。我已經安裝了電池,並且Getting started的一個微不足道的代碼與ocamlfind ocamlc -package batteries -linkpkg euler001.ml -o euler001一起使用。 現在回來我的項目,我有一個makefile如下: CMO=sib_lexer.cmo sib_pars

    2熱度

    1回答

    $ ocaml Objective Caml version 3.12.1 _________________________ [| + | | Batteries - | |_____|_|_________________| _________________________ | - Type '#help;;' | | + |] |__________

    2熱度

    1回答

    **Build mode: shared ocamlbuild -no-links syntax.otarget byte.otarget src/batteries_help.cmo META shared.otarget Finished, 0 targets (0 cached) in 00:00:00. + ocamlfind ocamlc -c -g -annot -warn-

    0熱度

    1回答

    let find arr word = let rec binaryserach arr word min max = let mid = (min + max)/2 in if max < min then -1 else if (String.compare arr.(mid) word = 0) then mid else if (Strin

    3熱度

    1回答

    極力打造的OCaml的WebSocket,它失敗: File "lib/websocket.ml", line 202, characters 29-42: Error: The function applied to this argument has type ?buffer_size:int -> (Lwt_io.input_channel * Lwt_io.out