Repository navigation
v0.4.1
Install
curl -fsSL https://raw.githubusercontent.com/orelang/ore/main/install.sh | shor brew install orelang/tap/ore; then ore update keeps it up to date.
Each archive carries its LLVM and lld.
| For | File |
|---|---|
| Linux x86-64 | ore-v0.4.1-linux-amd64.tar.gz |
| Linux arm64 | ore-v0.4.1-linux-arm64.tar.gz |
| macOS arm64 | ore-v0.4.1-darwin-arm64.tar.gz |
| VS Code extension | ore-vscode-v0.4.1.vsix |
| Zed extension | ore-zed-v0.4.1.zip |
The editor extensions run ore lsp, so ore must be on PATH. VS Code:
install "Ore" (orelang.ore) from the Marketplace or Open VSX, or
code --install-extension ore-vscode-v0.4.1.vsix. Zed: unzip
ore-zed-v0.4.1.zip and pick its directory in zed: install dev extension
(Zed builds it with Rust, which must be installed with rustup).
What is in 0.4.1
JavaScript's Date as a global class, and checker fixes.
Dateis a global class, JavaScript's, written in Ore
(runtime/core/date.ore): the constructors (new Date(),new Date(ms),
new Date("2024-10-15T12:00Z"),new Date(2024, 9, 15, 12)), the
staticsDate.now(),Date.parseandDate.UTC, the getters and
setters in local time and in UTC with fields out of range carrying over,
toISOString,toJSON,toString,toDateString,toTimeString,
toUTCStringandtoLocale*String(en-US, the only locale). Invalid
dates have a NaN time value andtoISOStringpanics withRangeError: Invalid time value. Local time comes fromTZor /etc/localtime,
read from the TZif files of /usr/share/zoneinfo with their POSIX rules,
and UTC without them.Date.parsereads the ECMAScript format and, as
V8, whattoStringandtoUTCStringprint and the common other forms.
console.logprints a date as Node does, andJSON.stringifywrites it,
as its ISO string.
Date.now()is still anint.- Generic classes can have static fields,
class Box<T> { static count = 0 }:
one for all instances, as in TypeScript, initialized where the class is
declared, and read, assigned and updated from anywhere, its static and
instance methods too. Their types cannot name the class's type
parameters (ORE3082); ORE3079 is no longer reported. - The condition of a
fornarrows its update clause too, as in TypeScript,
unless the body assigns the variable:for (let at = list; at !== null; at = at.next)no longer reports thatatmay be null. typeofof a top-levelconstworks in annotations: after the
constant for any initializer (let x: typeof namewithconst name = "ore"), and before it, as in function signatures, when the initializer
is made of literals, a template literal,new C(...)of a class that is
not generic, or the name of another such constant.