Cylium Error and Warning Codes Documentation
Language version: 0.1.1
This document lists all standard error and
warning codes in Cylium, with explanations and
context.
Each code has a unique identifier and a descriptive
message.
Note:
- Codes starting withAare errors. They stop program execution.
- Codes starting withCare warnings. They indicate non-critical issues but do not stop execution.
Errors (Axx)
Syntax and Operator Errors
| Code | Message | Description |
|---|---|---|
| A01 | Expected parameters for operator. | An operator was used without required arguments. Provide all necessary parameters. |
| A02 | Cannot convert value to numeric type. | Failed to convert a value to a number. Check value type and formatting. |
| A03 | Requested variable does not exist. | Attempted to access a variable that has not been declared. |
| A04 | Expected assignment operator ‘=’ after variable name. | The variable declaration is missing the =
operator. |
| A05 | Invalid variable name. | The variable name does not follow Cylium naming rules (ASCII, not starting with a number, length <= 256). |
| A06 | Unknown operator. | Used an operator that does not exist in Cylium. |
Type and Constant Errors
| Code | Message | Description |
|---|---|---|
| A07 | Cannot modify a constant variable. | Tried to change a variable declared as
const. Constants are immutable. |
| A08 | Unknown data type. | Attempted to convert or declare a type that does not exist. |
| A09 | This operator can only be used with vectors. | The operator requires a vector type, but another type was provided. |
Control Flow and Brackets
| Code | Message | Description |
|---|---|---|
| A10 | Unclosed bracket. | A (, [, or { was
not properly closed. |
| A11 | Requested label does not exist. | goto or a jump statement referred to a
label that is missing. |
| A12 | Expected ‘then’ keyword after condition. | After if or else if, Cylium
requires the then keyword. |
| A13 | Invalid condition. | The condition expression cannot be parsed or is invalid. |
Expression and Type Checking
| Code | Message | Description |
|---|---|---|
| A14 | Expression types do not match. | Tried to operate on incompatible types, e.g., adding a string to a number. |
| A15 | Invalid expression. | The expression syntax is incorrect or cannot be evaluated. |
| A16 | Invalid type for arithmetic operation. | An arithmetic operation was applied to an unsupported type. |
| A17 | Invalid array index. | Tried to access a vector element with an invalid index (negative or out-of-bounds). |
Warnings (Cxx)
| Code | Message | Description |
|---|---|---|
| C01 | Variable is already of the target type. | Attempted to cast a variable to a type it already has. Redundant but does not stop execution. |
Usage Notes
- Errors (
Axx) stop program execution and must be fixed before the code can run correctly.
- Warnings (
Cxx) do not stop execution, but they indicate potential issues or redundant operations.
- Properly handling errors and paying attention to warnings improves code reliability and maintainability.
This system allows developers to quickly distinguish
between critical errors that stop execution
and non-critical warnings that can be
safely ignored or optimized.
Properly handling errors and paying attention to warnings
improves code reliability and maintainability.