Clean up docs
This commit is contained in:
parent
cccbe7a325
commit
57782d3ed6
@ -1,10 +1,10 @@
|
||||
/// Tools for analyzing an abstract syntax tree and catch errors before running the virtual
|
||||
/// machine.
|
||||
///
|
||||
/// This module provides to anlysis options, both of which borrow an abstract syntax tree and a
|
||||
/// hash map of variables:
|
||||
/// - `analyze` convenience function
|
||||
/// - `Analyzer` struct
|
||||
//! Tools for analyzing an abstract syntax tree and catch errors before running the virtual
|
||||
//! machine.
|
||||
//!
|
||||
//! This module provides to anlysis options, both of which borrow an abstract syntax tree and a
|
||||
//! hash map of variables:
|
||||
//! - `analyze` convenience function
|
||||
//! - `Analyzer` struct
|
||||
use std::{
|
||||
collections::HashMap,
|
||||
error::Error,
|
||||
|
@ -1,14 +1,14 @@
|
||||
/// Description of a kind of value.
|
||||
///
|
||||
/// Most types are concrete and specific, the exceptions are the Generic and Any types.
|
||||
///
|
||||
/// Generic types are temporary placeholders that describe a type that will be defined later. The
|
||||
/// interpreter should use the analysis phase to enforce that all Generic types have a concrete
|
||||
/// type assigned to them before the program is run.
|
||||
///
|
||||
/// The Any type is used in cases where a value's type does not matter. For example, the standard
|
||||
/// library's "length" function does not care about the type of item in the list, only the list
|
||||
/// itself. So the input is defined as `[any]`, i.e. `Type::ListOf(Box::new(Type::Any))`.
|
||||
//! Description of a kind of value.
|
||||
//!
|
||||
//! Most types are concrete and specific, the exceptions are the Generic and Any types.
|
||||
//!
|
||||
//! Generic types are temporary placeholders that describe a type that will be defined later. The
|
||||
//! interpreter should use the analysis phase to enforce that all Generic types have a concrete
|
||||
//! type assigned to them before the program is run.
|
||||
//!
|
||||
//! The Any type is used in cases where a value's type does not matter. For example, the standard
|
||||
//! library's "length" function does not care about the type of item in the list, only the list
|
||||
//! itself. So the input is defined as `[any]`, i.e. `Type::ListOf(Box::new(Type::Any))`.
|
||||
use std::{
|
||||
collections::BTreeMap,
|
||||
fmt::{self, Display, Formatter},
|
||||
|
Loading…
Reference in New Issue
Block a user