-
Notifications
You must be signed in to change notification settings - Fork 6
Entry Points
Vihan edited this page Nov 15, 2018
·
1 revision
Your program must start somewhere. That somewhere is the 'entry point', a global function which is called by the start-up routines and offers you the command line arguments to the program. VSL has a few ways to specify the entry point:
-
func main() { ... }
Takes no arguments.
-
func main(args: String[]) { ... }
With this entry point. VSL will wrap the input arguments into a string array which you can then access or modify using VSL.
-
func main(argc: Int, argv: Pointer<ByteSequence>) { ... }
This is a C-style entry point which takes the amount of args argc
and a pointer to a list of byte sequence pointers (analogous to char**
)
- Introduction
- Installation
- VSL By Example
- Usage
- WASM (WebAssembly)
- The Basics
- Your First Program
- Syntax
- Concepts
- Modules
- Advanced Details
- Interop
- VSL Development
- Common Errors