Verify the install
After installing, three quick checks confirm everything is in place. Open a new terminal first, so the updated PATH is active.
1. Check the version
Section titled “1. Check the version”beansc --versionbeansc 0.1.18 (language 1.0, runtime ABI 6)This tells you three things: the compiler version (0.1.18), the language
contract it implements (1.0), and the runtime ABI (6).
2. Run the doctor
Section titled “2. Run the doctor”beansc doctordoctor reports what your install can build and how to fix any gaps. For
example, if a native build needs a C compiler that is not on your PATH,
doctor says so and tells you what to install.
doctor always exits with code 0. It is a report, not a pass/fail gate, so read
what it prints.
3. Run a program
Section titled “3. Run a program”Save this as hello.b:
import std.io
fn main() { let name: string = "beans" io.println("hello from {name}")}Run it on the reference interpreter:
beansc run hello.bhello from beansIf all three checks worked, your install is good. Next, write and run your
first program or set up a project. For
more on beansc doctor, see doctor and upgrade.