What You Need¶
The Pony compiler¶
Before you get started, please check out the installation instructions for the Pony compiler.
A text editor¶
While you can write code using any editor, it’s nice to use one with some support for the language. We maintain a list of editors supporting Pony.
Pony is a compiled language, rather than an interpreted one. In fact, it goes even further: Pony is an ahead-of-time (AOT) compiled language, rather than a just-in-time (JIT) compiled language.
What this means is that once you build your program, you can run it over and over again without needing a compiler or a virtual machine or anything else. It’s a complete program, all on its own.
But it also means you need to build your program before you can run it. In an interpreted language or a JIT compiled language, you tend to do things like this to run your program:
Or maybe you put a shebang in your program (like #!/usr/bin/env python
), then chmod
to set the executable bit, and then do:
When you use Pony, you don’t do any of that!
Compiling your program¶
If you are in the same directory as your program, you can just do:
That tells the Pony compiler that your current working directory contains your source code, and to please compile it. If your source code is in some other directory, you can tell ponyc where it is:
There are other options as well, but we’ll cover those later.