ocsigen 可以在顶层运行吗?

发布于 2024-12-18 10:37:26 字数 382 浏览 1 评论 0原文

我曾经通过运行 yaws -i 来在 erlang 的 REPL 中运行 YAWS。当yaws运行时,我可以继续使用erlang的REPL。

然后我想知道是否可以在OCaml的顶层运行ocsigen?当然,这不是ocsigen的实际使用,而是作为练习。

我已经尝试过如下线程,但它不起作用:

λ> #thread;;
λ> Thread.create (fun _ -> Sys.command "ocsigen -c ~/ocsigen.conf.qachina") ();;
-: Thread.t = <abstr>

它工作得很好!
顺便说一句,“abstr”代表什么?

任何建议表示赞赏!

I used to run YAWS in erlang's REPL by just running yaws -i. When yaws is running, I can continue to use erlang's REPL.

Then I want to know whether or not it is possible to run ocsigen in OCaml's toplevel? Of course, it is not a practical use of ocsigen, but as an exercise.

I have tried thread as below, but it did not work:

λ> #thread;;
λ> Thread.create (fun _ -> Sys.command "ocsigen -c ~/ocsigen.conf.qachina") ();;
-: Thread.t = <abstr>

it works great!
BTW, What does the "abstr" stands for ?

Any suggestion is appreciated!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

葮薆情 2024-12-25 10:37:26

使用#thread 在顶层启用线程。

虽然我不确定这个问题与 ocsigen 有什么关系。

Enable threads in toplevel with #thread.

Though I am not sure what this question has to do with ocsigen.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文