A modern, expressive systems language for turning limitless imagination into powerful creations, tools, command-line applications, and experiences.
Silver brings familiar C-style structure together with concise syntax, strong types, native compilation, and a growing standard library, giving you one language for many possibilities.
- Author: Edan M.
- Version: 0.7.15
- Copyright: © 2025 Edan M.
- Credit: Stav A (2026) - Mac OS support, initial QA of the Mac OS version.
- Enabling Silver compiler support on Mac OS (Rosetta x86_64 backend)
- Programming language creator: Edan M.
The macOS stage-1 executable is in executables/macos/.
The macOS workspace's test fixtures are in Mac Tests/.
See their READMEs for the known test failures and unsuccessful stage-3 bootstrap.
Pick either a global binaries directory or a per-user one under AppData.
Option 1 - global C:\bin (needs admin to create):
mkdir C:\bin
setx PATH "$env:PATH;C:\bin"Download or copy silverc.exe into C:\bin.
Option 2 - per-user %appdata%\silver\bin (no admin needed):
mkdir "$env:APPDATA\silver\bin"
setx PATH "$env:PATH;$env:APPDATA\silver\bin"Download or copy silverc.exe into %appdata%\silver\bin.
Reopen the terminal afterwards, then verify with silverc --version.
Both use the same location, ~/.local/bin:
test -d ~/.local/bin || mkdir -p ~/.local/binCopy it from your Downloads folder:
cp ~/Downloads/silverc ~/.local/bin/silverc
chmod +x ~/.local/bin/silvercOr download it straight there with curl:
curl -L -o ~/.local/bin/silverc <download-url>
chmod +x ~/.local/bin/silvercMake sure ~/.local/bin is on your PATH:
export PATH="$HOME/.local/bin:$PATH"Add that line to ~/.bashrc (Linux) or ~/.zshrc (macOS, the default
shell) so it persists. Most Linux distributions pick up ~/.local/bin
automatically once it exists (re-login to apply); macOS always needs the
export line above, then source ~/.zshrc.
Verify with silverc --version.
Run these commands from the workspace root. Place the compiler on your PATH under the command name silverc, then compile a program:
# Example after installing/renaming the compiler to `silverc`
silverc path/to/program.sr -o program.exeSilver source files use the .sr extension. Programs begin at void main():
void main() {
string message = "Hello from Silver";
printline(message);
}
For immediate execution without a native compilation step, use the Silver
interpreter in silveri/:
silveri path/to/program.sr- Native compilation for fast, standalone applications
- Clear, type-first declarations with optional inference through
var - Mutable and immutable variables using explicit
mut - Dynamic arrays with expressive collection operations
- Classes, constructors, properties, inheritance, and foundations
- Nullable types with
?and union types with<type1 | type2> - Pattern matching, ternary expressions, loops, and recursion
- String interpolation with
$"..." - Modules and imports with a simple
importsyntax - Standard-library support for filesystem, networking, JSON, system, and other APIs
- A cross-platform design direction for compilers, interpreters, and native tooling
class Greeter {
public prop string name;
construct (string name) {
this.name = name;
}
public string greet() {
return $"Hello, {this.name}!";
}
}
void main() {
Greeter greeter = new Greeter("Silver");
printline(greeter.greet());
}
Edan M. © 2025 All Rights Reserved Proprietary