Vikari Language Documentation


Available since:  v0.1.1.

Atonement Crystals

The base type for all other types is AtonementCrystal. Everything in Vikari is an AtonementCrystal. This includes every operator and symbol represented by a sequence of characters in Vikari code. However, only Value literals and variables can be assigned to the AtonementCrystal type. For understanding the meaning behind the name of Atonement Crystal, please see the Addendum: Design Notes section of the Vikari GitHub repository README for a succinct explanation.

All presently implemented built-in types follow the following inheritance structure:

• AtonementCrystal
 • Value
  • Boolean
  • Number
   • Integer
   • Long
   • BigInteger
   • Float
   • Double
   • BigDecimal

Null types are special, as each type has its own unique Null type that can be assigned to values of that type.

Built-In Functions

The AtonementCrystal type is planned to have a set of default functions that can be called on any type in Vikari. However none of these have been implemented yet, as function calls are not yet implemented in Vikari. See Atonement Crystal Functions for documentation on all planned functions for the AtonementCrystal type.

Examples

The following demonstrates use of the AtonementCrystal type.

~:An untyped variable automatically has the AtonementCrystal type.:~
~:It can also be explicitly typed.:~
foo
foo:AtonementCrystal

~:Any value can be assigned to a variable of type AtonementCrystal.:~
foo << 2
foo << true
foo:AtonementCrystal << 3.14
foo:AtonementCrystal << null

~:Variables of type AtonementCrystal can be reassigned to any type.:~
foo:AtonementCrystal
foo << 4L
foo << false
foo << 6.28F