Dew
Dew is a little programming language which targets the Lua virtual machine
Install / Use
/learn @rsms/DewREADME
Dew is a little programming language which targets the Lua virtual machine.
Language
Examples
1 + (2 + 3) * (4 - 5)
fun f
fun f(x, y int)
fun f(x, y int) int
fun f(x, y int) int, int
fun f(x, y int) (int, int)
fun ♥︎(x, y, z int) int, int {
return x + y*z
}
Operators
+ & += &= && == != ( )
- | -= |= || < <= [ ]
* ^ *= ^= <- > >= { }
/ << /= <<= ++ = := , ;
% >> %= >>= -- ! ... . :
~
Operator precedence
Binary operators of the same precedence associate from left to right.
E.g. x / y * z is the same as (x / y) * z.
7 .
6 ++ -- + - ! ~ * & ?
5 * / % << >> &
4 + - | ^
3 == != < <= > >=
2 &&
1 ||
0 ,
Building dew
make && o.*/dew examples/hello.dew
Requirements:
- C17 compiler (tested with clang 17)
- GNU Make
- curl for wasm build
Various ways to build:
make— release build for host systemmake DEBUG=1— debug build for host systemmake TARGET=web— release build for web platformmake TARGET=web DEBUG=1— debug build for web platformmake test— build & run tests
Related Skills
node-connect
345.9kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
106.4kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
345.9kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
345.9kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
