欢迎大家赞助一杯啤酒🍺 我们准备了下酒菜:Formal mathematics/Isabelle/ML, Formal verification/Coq/ACL2, C++/F#/Lisp
Gambit
来自开放百科 - 灰狐
(版本间的差异)
小 (→指南) |
小 (→指南) |
||
(未显示1个用户的6个中间版本) | |||
第8行: | 第8行: | ||
==功能== | ==功能== | ||
+ | *Fast: Gambit is one of the fastest dynamic language implementations. | ||
+ | *Portable: Targets C, JavaScript, Python, and more. | ||
+ | *Concurrent: Millions of lightweight threads on a server. | ||
==指南== | ==指南== | ||
第14行: | 第17行: | ||
或下载二进制安装包,如:[http://www.iro.umontreal.ca/~gambit/download/gambit/v4.8/prebuilt/gambit-v4_8_5-macosx-intel64.dmg OS X版] | 或下载二进制安装包,如:[http://www.iro.umontreal.ca/~gambit/download/gambit/v4.8/prebuilt/gambit-v4_8_5-macosx-intel64.dmg OS X版] | ||
+ | $ gsi -e "(pretty-print (expt 2 100))" | ||
+ | 1267650600228229401496703205376 | ||
$ gsi | $ gsi | ||
Gambit v4.8.5 | Gambit v4.8.5 | ||
第23行: | 第28行: | ||
815915283247897734345611269596115894272000000000 | 815915283247897734345611269596115894272000000000 | ||
> ,q | > ,q | ||
+ | $ cat h.scm | ||
+ | (display "hello") (newline) | ||
+ | $ cat w.six | ||
+ | display("world"); newline(); | ||
+ | $ gsc -o hello.exe -exe h.scm w.six | ||
+ | h.scm: | ||
+ | /home/huihoo/Software/lisp/gambit/h.c: | ||
+ | w.six: | ||
+ | /home/huihoo/Software/lisp/gambit/w.c: | ||
+ | /home/huihoo/Software/lisp/gambit/w_.c: | ||
+ | $ ./hello.exe | ||
+ | hello | ||
+ | world | ||
+ | $ gsc -c h.scm | ||
+ | $ gsc -c w.six | ||
+ | $ gsc -o hello.exe -exe h.c w.c | ||
+ | $ gsc | ||
+ | > (compile-file-to-target "h") | ||
+ | "/home/huihoo/Software/lisp/gambit/h.c" | ||
+ | |||
卸载 gambit | 卸载 gambit | ||
sudo uninstall-gambit v4.8.5 | sudo uninstall-gambit v4.8.5 | ||
第38行: | 第63行: | ||
*[http://gambitscheme.org Gambit官网] | *[http://gambitscheme.org Gambit官网] | ||
*[https://github.com/feeley/gambit Gambit @ GitHub] | *[https://github.com/feeley/gambit Gambit @ GitHub] | ||
− | *[ | + | *[https://docs.huihoo.com/lisp/gambit/ Gambit文档] |
[[category:mobile]] | [[category:mobile]] |
2022年1月28日 (五) 07:04的最后版本
您可以在Wikipedia上了解到此条目的英文信息 Gambit Thanks, Wikipedia. |
Gambit
目录 |
[编辑] 简介
Gambit 是 Scheme 开源实现,可用于移动(iOS, Android)和嵌入式开发。
[编辑] 功能
- Fast: Gambit is one of the fastest dynamic language implementations.
- Portable: Targets C, JavaScript, Python, and more.
- Concurrent: Millions of lightweight threads on a server.
[编辑] 指南
Debian
$ sudo apt install gambc
或下载二进制安装包,如:OS X版
$ gsi -e "(pretty-print (expt 2 100))" 1267650600228229401496703205376 $ gsi Gambit v4.8.5 > (define (fact n) (if (< n 2) 1 (* n (fact (- n 1))))) > (map fact '(1 2 3 4 5 6)) (1 2 6 24 120 720) > (values (fact 10) (fact 40)) 3628800 815915283247897734345611269596115894272000000000 > ,q $ cat h.scm (display "hello") (newline) $ cat w.six display("world"); newline(); $ gsc -o hello.exe -exe h.scm w.six h.scm: /home/huihoo/Software/lisp/gambit/h.c: w.six: /home/huihoo/Software/lisp/gambit/w.c: /home/huihoo/Software/lisp/gambit/w_.c: $ ./hello.exe hello world $ gsc -c h.scm $ gsc -c w.six $ gsc -o hello.exe -exe h.c w.c $ gsc > (compile-file-to-target "h") "/home/huihoo/Software/lisp/gambit/h.c"
卸载 gambit
sudo uninstall-gambit v4.8.5
[编辑] 应用
[编辑] 图集
[编辑] 链接
分享您的观点