Table of contents
Getting Started
Installation
Usage
New Changes
Migration Guide
Basic Syntax
Data Types
Expressions
Variables
Conditions
Commands
Arrays
Loops
Functions
Importing
Advanced Syntax
As Cast
Builtins
Type Condition
Compiler Flags
Standard Library
Array
Date
Environment
FileSystem
HTTP
Math
Text
Contributing
How to
Guide
Compiler structure
Amber by Example
ShellCheck tester
Ubuntu Updater
Bot Detector
LSP Installer
Compiler Flags
Compiler flags enable customization of the compiler’s behavior within the scope of a specific function. These flags are particularly useful for managing edge cases by temporarily relaxing certain restrictions. Below is a list of available compiler flags and their functions:
allow_nested_if_else- Disables warnings that recommend using specialized if-chain syntax.allow_generic_return- Suppresses warnings that prompt the developer to specify a concrete return type when using arguments with defined types.allow_absurd_cast- Turns off warnings about the potential for nonsensical results when using force-type casting, which may result in an absurd cast.
#[allow_nested_if_else]
fun foo() {
// ...
}
Table of contents
Getting Started
Installation
Usage
New Changes
Migration Guide
Basic Syntax
Data Types
Expressions
Variables
Conditions
Commands
Arrays
Loops
Functions
Importing
Advanced Syntax
As Cast
Builtins
Type Condition
Compiler Flags
Standard Library
Array
Date
Environment
FileSystem
HTTP
Math
Text
Contributing
How to
Guide
Compiler structure
Amber by Example
ShellCheck tester
Ubuntu Updater
Bot Detector
LSP Installer