wren-port
所属分类:编程语言基础
开发工具:D
文件大小:0KB
下载次数:0
上传日期:2023-08-04 21:01:32
上 传 者:
sh-1993
说明: Wren编程语言到D的端口。因为为什么不。,
(A port of the Wren programming language to D. Because why not.,)
文件列表:
LICENSE (1313, 2023-08-05)
cli/ (0, 2023-08-05)
cli/dub.sdl (250, 2023-08-05)
cli/example/ (0, 2023-08-05)
cli/example/animals.wren (2402, 2023-08-05)
cli/example/guess_number.wren (600, 2023-08-05)
cli/example/hello.wren (133, 2023-08-05)
cli/example/import_module/ (0, 2023-08-05)
cli/example/import_module/cthulu.wren (105, 2023-08-05)
cli/example/import_module/lovecraft.wren (141, 2023-08-05)
cli/example/mandelbrot.wren (658, 2023-08-05)
cli/example/map.wren (637, 2023-08-05)
cli/example/skynet.wren (681, 2023-08-05)
cli/example/syntax.wren (3545, 2023-08-05)
cli/source/ (0, 2023-08-05)
cli/source/wren/ (0, 2023-08-05)
cli/source/wren/cli/ (0, 2023-08-05)
cli/source/wren/cli/main.d (825, 2023-08-05)
cli/source/wren/cli/vm.d (2934, 2023-08-05)
dub.sdl (376, 2023-08-05)
examples/ (0, 2023-08-05)
examples/embedding/ (0, 2023-08-05)
examples/embedding/dub.sdl (175, 2023-08-05)
examples/embedding/source/ (0, 2023-08-05)
examples/embedding/source/app.d (1313, 2023-08-05)
examples/foreign/ (0, 2023-08-05)
examples/foreign/dub.sdl (191, 2023-08-05)
examples/foreign/script/ (0, 2023-08-05)
examples/foreign/script/script.wren (241, 2023-08-05)
examples/foreign/source/ (0, 2023-08-05)
examples/foreign/source/app.d (2718, 2023-08-05)
logo.png (149191, 2023-08-05)
source/ (0, 2023-08-05)
source/wren/ (0, 2023-08-05)
source/wren/common.d (4516, 2023-08-05)
source/wren/compiler.d (136923, 2023-08-05)
... ...
# wren-port
[Wren](https://wren.io/) is a small, fast, class-based concurrent scripting language.
`wren-port` is a port of the Wren programming language implementation to D, intended for embedding. This is useful is you want a `nothrow @nogc` fast interpreter in your D application.
The original Wren implementation is [here](https://github.com/wren-lang).
## Changes from original
### 1. Build information
`System.isDebugBuild` allows to know if the -debug flag was used to build Wren, in case you want to disable some sort of live-scripting at release.
### 2. Float literal terminal character
`1.0f`, `2L` and `2.0F` are valid Wren double literals in this fork.
This helps sharing bits of code between D and Wren.
### 3. `$` operator
The new `$` operator is calling a host-provided function.
This allow to query entities with a nice syntax.
_Example:_
```wren
($"_imageKnob").hasTrail = false
```
### 4. Optional trailing semicolons
This feature can be enabled in `WrenConfiguration` (default = disabled).
```d
config.acceptsTrailingSemicolons = true;
```
When enabled, **imports, statements, and variable declarations MAY end with a single trailing semicolon.**
```wren
var a = 2; // VAR-DECL [;]
a = 7; // STATEMENT [;]
import "beverages"; // IMPORT STRING [;]
import "beverages" for Coffee, Tea;
```
This help porting between D and Wren in practice.
_This translation was performed by [int3 Systems](https://0xcc.pw/) and sponsored by [Auburn Sounds](https://www.auburnsounds.com)._
近期下载者:
相关文件:
收藏者: