Reference

The specification,
in one place.

The design documents are the specification the compiler is measured against. They are written in Spanish; titles are translated here. Start with the consolidated language reference.

Design documents

documents, one per decision.

Each document records the rule, the alternatives considered and the open questions.

  1. 01 Variables, types and units ↗
  2. 02 Functions and signatures ↗
  3. 03 Traits ↗
  4. 04 Errors, Result and Option ↗
  5. 05 Enums and pattern matching ↗
  6. 06 Ranges, loops and iterators ↗
  7. 07 Modules and visibility ↗
  8. 08 Logic and expressions ↗
  9. 09 Concurrency ↗
  10. 10 Consistency review (01–09) ↗
  11. 11 Memory model ↗
  12. 12 derive and trait inheritance ↗
  13. 13 Map, Set and collection literals ↗
  14. 14 Package system ↗
  15. 15 dyn Trait ↗
  16. 16 Generic as (scalars to quantities) ↗
  17. 17 Language reference (consolidated) ↗
  18. 18 Native backend memory model ↗
  19. 19 Numeric hierarchy and arrays ↗
  20. 20 HIR and IR ↗
  21. 21 Distribution and WebAssembly ↗
  22. 22 Standard library ↗
  23. 23 Visualization engine (std.viz) ↗
  24. 24 Numerical methods (std.numeric) ↗
  25. 25 Measurements and uncertainty ↗
  26. 26 Scientific effects, determinism and provenance ↗
  27. 27 Scalar Quantity ownership and unit labels ↗
  28. 28 Contextual reassignment types ↗
  29. 29 Symbolic core: exact numbers, assumptions and derivatives ↗
  30. 30 Exact arithmetic: arbitrary-precision integers ↗
  31. 31 Polynomials and exact equation solving ↗
  32. 32 Exact equations: linear, quadratic and rational roots ↗
  33. 33 Automatic differentiation: reverse-mode tape ↗
  34. 34 Polished figures: std.viz style and SVG contract ↗

Command line

ostrinc

The main flags. ostrinc --help lists all of them.

--check
Type-check (the default)
--run
Type-check and run
--test
Run every test_* function
--fmt
Print the formatted file (--write, --check)
--new
Create a project
--project
Use the entry declared by ostrin.toml
--locked
Require the existing ostrin.lock
--fetch
Fetch Git dependencies
--emit-c
Transpile to C
--compile
Build a native executable or WASI module
--target
native (default) or wasm32-wasi
--native-threads
OS threads and blocking channels
--leak-check
Report native allocations at exit
--hir
Print the typed, verified HIR
--ir
Print the basic-block IR
--effect-report
Experimental conservative effect inventory
--provenance-report
Experimental source hash, target and reproducibility artifact
--ownership-check
Detect use after channel send (E1101)
--json
Machine-readable diagnostics
--lsp
Language server over stdio
--dap
Debug adapter over stdio
--version
Print the compiler version