Expand description
Mica is an embeddable scripting language for Rust.
This crate exposes a safe, high-level API akin to Rhai.
Re-exports§
pub use mica_language as language;
Modules§
- builtin_
traits - Types for representing implementations of built-in traits.
- ffvariants
- Variants of
ForeignFunction.
Structs§
- Arguments
- Arguments passed to a varargs function.
- Debug
Options - Options for debugging the language implementation.
- Engine
- Start here! An execution engine. Contains information about things like globals, registered types, etc.
- Fiber
- A fiber represents an independent, pausable thread of code execution.
- Gc
- An automatically managed, safe reference to GC memory.
- Global
Id - An ID unique to an engine, identifying a global variable.
- Method
Id - An ID unique to an engine, identifying a method signature.
- Object
- Represents a custom-typed value stored inside a VM.
- RawSelf
- Wrapper struct for marking functions that use the with-raw-self calling convention.
- RawValue
- An unsafe value used internally in the VM.
- Script
- A script pre-compiled into bytecode.
- Trait
Builder - Allows you to build traits programatically from Rust code.
- Type
- A type. This is used to represent user-defined Rust types in the VM (but not their instances).
- Type
Builder - A builder that allows for binding APIs with user-defined types.
Enums§
- Error
- An error.
- RawFunction
Kind - The kind of a raw function. The kind of the function (bytecode or FFI).
- RawValue
Kind - The kind of a
RawValue. The kind of a value. - Value
- A dynamically typed value.
Traits§
- Foreign
Function - A Rust function that can be called from Mica.
- Global
Name - A trait for names convertible to global IDs.
- Method
Signature - Implemented by every type that can be used as a method signature.
- Mica
Language Result Ext - Extensions for converting
Results into amica-languageFFI-friendly structure. - Mica
Result Ext - Extensions for converting
Results into a Mica FFI-friendly structure. - MutSelf
From RawValue - Implemented by all types that can be a
&mut selfparameter in an instance function. - Object
Constructor - A constructor of objects of type
T. - Optional
Global Name - A trait for names convertible to global IDs.
- Self
From RawValue - Implemented by all types that can be a
&selfparameter in an instance function. - Standard
Library - Definitions of basic types provided by a standard library.
This role is usually fulfilled by the
mica-stdcrate. - TryFrom
Value - Implemented by types that can be constructed from
Values. - User
Data - Marker trait for all user data types.
Type Aliases§
- Language
Error - A raw
mica-languageerror, with metadata such as stack traces. - Language
Error Kind - A raw
mica-languageerror kind. - RawForeign
Function - The implementation of a raw foreign function. The ABI of a raw foreign function.