Struct mm0b_parser::MmbFile[][src]

#[non_exhaustive]
pub struct MmbFile<'a, X = BasicIndex<'a>> { pub header: Header, pub buf: &'a [u8], pub sorts: &'a [SortData], pub terms: &'a [TermEntry], pub thms: &'a [ThmEntry], pub index: X, }
Expand description

A parsed MMB file, as a borrowed type. This does only shallow parsing; additional parsing is done on demand via functions on this type.

Fields (Non-exhaustive)

This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
header: Header

The file’s header.

buf: &'a [u8]

The full file

sorts: &'a [SortData]

The sort table

terms: &'a [TermEntry]

The term table

thms: &'a [ThmEntry]

The theorem table

index: X

The index, if provided.

Implementations

For error reporting after the initial parse.

For error reporting after the initial parse.

Returns a bad index parse error, for error reporting during index parsing.

Parse a MmbFile from a file, provided as a byte slice. This does the minimum checking to construct the parsed object, it is not a verifier.

Get the sort data for a SortId.

Get the term data for a TermId.

Get the theorem data for a ThmId.

Get the proof stream for the file.

Get the index entry for a sort.

Get the index entry for a term.

Get the index entry for a theorem.

Convenience function for getting an index without having to destructure the StmtCmd every time.

Get the name of a sort, if present.

Get the name of a term, if present.

Get the name of a theorem, if present.

Get the name of a sort, supplying a default name of the form s123 if the index is not present.

Get the name of a term, supplying a default name of the form t123 if the index is not present.

Get the name of a theorem, supplying a default name of the form T123 if the index is not present.

Get the list of variables used in a term, or None if the index does not exist.

Get the list of variables used in a term.

Get the list of variables used in a theorem, or None if the index does not exist.

Get the list of variables used in a theorem.

Convenience function for getting an index without having to destructure the StmtCmd every time.

Get the hypothesis name list for a theorem.

Get the hypothesis name list for a theorem.

Convenience function for getting an index without having to destructure the StmtCmd every time.

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.