From 894cf30bf2484adc10ec4e11eb797b3e177072b8 Mon Sep 17 00:00:00 2001 From: d0cd Date: Mon, 7 Oct 2024 18:26:34 +0000 Subject: [PATCH] deploy: 0d2eb0223ac5b4a9b0a87b78e5a64afed74a9066 --- help.html | 2 +- .../array_access/struct.ArrayAccess.html | 6 +- .../struct.AssociatedConstant.html | 6 +- .../struct.AssociatedFunction.html | 6 +- .../member_access/struct.MemberAccess.html | 6 +- leo_ast/access/struct.ArrayAccess.html | 6 +- leo_ast/access/struct.AssociatedConstant.html | 6 +- leo_ast/access/struct.AssociatedFunction.html | 6 +- leo_ast/access/struct.MemberAccess.html | 6 +- leo_ast/access/struct.TupleAccess.html | 6 +- .../tuple_access/struct.TupleAccess.html | 6 +- .../common/identifier/struct.Identifier.html | 16 +- .../imported_modules/fn.deserialize.html | 2 +- .../common/imported_modules/fn.serialize.html | 2 +- leo_ast/common/location/struct.Location.html | 8 +- leo_ast/common/node/trait.Node.html | 8 +- .../access/enum.AccessExpression.html | 2 +- .../array/struct.ArrayExpression.html | 6 +- .../binary/enum.BinaryOperation.html | 2 +- .../binary/struct.BinaryExpression.html | 6 +- .../call/struct.CallExpression.html | 10 +- .../cast/struct.CastExpression.html | 6 +- .../expressions/enum.AccessExpression.html | 2 +- leo_ast/expressions/enum.BinaryOperation.html | 2 +- leo_ast/expressions/enum.Expression.html | 2 +- leo_ast/expressions/enum.Literal.html | 28 ++-- leo_ast/expressions/enum.UnaryOperation.html | 2 +- .../expressions/err/struct.ErrExpression.html | 6 +- leo_ast/expressions/literal/enum.Literal.html | 28 ++-- .../locator/struct.LocatorExpression.html | 12 +- .../expressions/struct.ArrayExpression.html | 6 +- .../expressions/struct.BinaryExpression.html | 6 +- .../expressions/struct.CallExpression.html | 10 +- .../expressions/struct.CastExpression.html | 6 +- leo_ast/expressions/struct.ErrExpression.html | 6 +- .../expressions/struct.StructExpression.html | 6 +- .../struct.StructVariableInitializer.html | 6 +- .../expressions/struct.TernaryExpression.html | 6 +- .../expressions/struct.TupleExpression.html | 6 +- .../expressions/struct.UnaryExpression.html | 6 +- .../expressions/struct.UnitExpression.html | 6 +- .../struct_init/struct.StructExpression.html | 6 +- .../struct.StructVariableInitializer.html | 6 +- .../ternary/struct.TernaryExpression.html | 6 +- .../tuple/struct.TupleExpression.html | 6 +- .../unary/enum.UnaryOperation.html | 2 +- .../unary/struct.UnaryExpression.html | 6 +- .../unit/struct.UnitExpression.html | 6 +- .../annotation/struct.Annotation.html | 6 +- .../core_function/enum.CoreFunction.html | 2 +- leo_ast/functions/input/struct.Input.html | 6 +- leo_ast/functions/output/struct.Output.html | 6 +- leo_ast/functions/struct.Function.html | 10 +- .../enum.GroupCoordinate.html | 4 +- .../group_literal/enum.GroupLiteral.html | 6 +- .../group_literal/struct.GroupTuple.html | 4 +- leo_ast/mapping/struct.Mapping.html | 6 +- .../program_scope/struct.ProgramScope.html | 20 +-- leo_ast/program/struct.Program.html | 12 +- .../assert/struct.AssertStatement.html | 6 +- .../assign/struct.AssignStatement.html | 6 +- leo_ast/statement/block/struct.Block.html | 6 +- .../struct.ConditionalStatement.html | 6 +- .../struct.ConsoleStatement.html | 6 +- .../const_/struct.ConstDeclaration.html | 6 +- .../struct.DefinitionStatement.html | 6 +- leo_ast/statement/enum.Statement.html | 4 +- .../struct.ExpressionStatement.html | 6 +- .../iteration/struct.IterationStatement.html | 6 +- .../return_/struct.ReturnStatement.html | 6 +- leo_ast/struct.Ast.html | 10 +- leo_ast/struct/member/struct.Member.html | 8 +- leo_ast/struct/struct.Composite.html | 14 +- .../function_stub/struct.FunctionStub.html | 18 +-- leo_ast/stub/struct.Stub.html | 20 +-- leo_ast/types/array/struct.ArrayType.html | 2 +- .../core_constant/enum.CoreConstant.html | 2 +- .../types/integer_type/enum.IntegerType.html | 2 +- leo_ast/types/mapping/struct.MappingType.html | 4 +- .../struct_type/struct.CompositeType.html | 4 +- leo_ast/types/type_/enum.Type.html | 2 +- leo_ast/value/enum.Value.html | 38 ++--- leo_compiler/compiler/struct.Ast.html | 12 +- leo_compiler/compiler/struct.Compiler.html | 48 +++--- leo_compiler/compiler/struct.SymbolTable.html | 32 ++-- leo_compiler/struct.Ast.html | 12 +- leo_compiler/struct.Compiler.html | 48 +++--- leo_compiler/struct.SymbolTable.html | 32 ++-- leo_lang/cli/account/enum.Account.html | 8 +- leo_lang/cli/add/struct.Add.html | 6 +- leo_lang/cli/build/struct.Build.html | 6 +- leo_lang/cli/clean/struct.Clean.html | 6 +- leo_lang/cli/cli/fn.handle_error.html | 2 +- leo_lang/cli/cli/fn.run_with_args.html | 2 +- .../cli/commands/account/enum.Account.html | 8 +- .../account/fn.display_string_discreetly.html | 2 +- .../account/fn.generate_new_account.html | 2 +- .../commands/account/fn.import_account.html | 2 +- .../cli/commands/account/fn.print_keys.html | 2 +- .../cli/commands/account/fn.sign_message.html | 2 +- .../commands/account/fn.verify_message.html | 2 +- .../account/fn.write_to_env_file.html | 2 +- leo_lang/cli/commands/add/struct.Add.html | 6 +- .../commands/build/fn.compile_leo_file.html | 6 +- .../cli/commands/build/fn.handle_build.html | 2 +- leo_lang/cli/commands/build/struct.Build.html | 6 +- leo_lang/cli/commands/clean/struct.Clean.html | 6 +- .../deploy/fn.deploy_cost_breakdown.html | 2 +- .../cli/commands/deploy/fn.handle_deploy.html | 2 +- .../cli/commands/deploy/struct.Deploy.html | 6 +- .../cli/commands/example/struct.Example.html | 6 +- .../execute/fn.execution_cost_breakdown.html | 2 +- .../commands/execute/fn.handle_execute.html | 2 +- .../execute/fn.load_program_from_network.html | 2 +- .../cli/commands/execute/struct.Execute.html | 6 +- leo_lang/cli/commands/fn.check_balance.html | 2 +- .../cli/commands/fn.handle_broadcast.html | 2 +- leo_lang/cli/commands/fn.parse_record.html | 2 +- leo_lang/cli/commands/new/struct.New.html | 6 +- .../commands/query/block/struct.Block.html | 6 +- .../query/committee/struct.Committee.html | 6 +- .../cli/commands/query/fn.handle_query.html | 2 +- .../query/mempool/struct.Mempool.html | 6 +- .../commands/query/peers/struct.Peers.html | 6 +- .../query/program/struct.Program.html | 6 +- .../query/state_root/struct.StateRoot.html | 6 +- leo_lang/cli/commands/query/struct.Query.html | 6 +- .../query/transaction/struct.Transaction.html | 6 +- .../query/utils/fn.is_valid_field.html | 2 +- .../query/utils/fn.is_valid_hash.html | 2 +- .../utils/fn.is_valid_height_or_hash.html | 2 +- .../utils/fn.is_valid_numerical_input.html | 2 +- .../utils/fn.is_valid_transaction_id.html | 2 +- .../utils/fn.is_valid_transition_id.html | 2 +- .../cli/commands/remove/struct.Remove.html | 6 +- leo_lang/cli/commands/run/fn.handle_run.html | 2 +- leo_lang/cli/commands/run/struct.Run.html | 6 +- leo_lang/cli/commands/trait.Command.html | 16 +- .../cli/commands/update/struct.Update.html | 6 +- leo_lang/cli/context/struct.Context.html | 22 +-- leo_lang/cli/deploy/struct.Deploy.html | 6 +- leo_lang/cli/enum.Account.html | 8 +- leo_lang/cli/example/struct.Example.html | 6 +- leo_lang/cli/execute/struct.Execute.html | 6 +- leo_lang/cli/fn.handle_error.html | 2 +- leo_lang/cli/fn.parse_record.html | 2 +- leo_lang/cli/fn.run_with_args.html | 2 +- .../cli/helpers/context/struct.Context.html | 22 +-- .../cli/helpers/logger/fn.init_logger.html | 2 +- .../cli/helpers/updater/struct.Updater.html | 6 +- leo_lang/cli/logger/fn.init_logger.html | 2 +- leo_lang/cli/new/struct.New.html | 6 +- .../cli/query/program/struct.Program.html | 6 +- leo_lang/cli/query/struct.Program.html | 6 +- leo_lang/cli/query/struct.Query.html | 6 +- leo_lang/cli/remove/struct.Remove.html | 6 +- leo_lang/cli/run/struct.Run.html | 6 +- leo_lang/cli/struct.Add.html | 6 +- leo_lang/cli/struct.Build.html | 6 +- leo_lang/cli/struct.Clean.html | 6 +- leo_lang/cli/struct.Deploy.html | 6 +- leo_lang/cli/struct.Example.html | 6 +- leo_lang/cli/struct.Execute.html | 6 +- leo_lang/cli/struct.New.html | 6 +- leo_lang/cli/struct.Query.html | 6 +- leo_lang/cli/struct.Remove.html | 6 +- leo_lang/cli/struct.Run.html | 6 +- leo_lang/cli/struct.Update.html | 6 +- leo_lang/cli/trait.Command.html | 16 +- leo_lang/cli/update/struct.Update.html | 6 +- leo_lang/cli/updater/struct.Updater.html | 6 +- .../directory/struct.BuildDirectory.html | 6 +- leo_package/fn.parse_file_paths.html | 2 +- .../directory/struct.ImportsDirectory.html | 8 +- .../inputs/directory/fn.parse_file_paths.html | 2 +- .../directory/struct.InputsDirectory.html | 4 +- .../ast_snapshot/struct.SnapshotFile.html | 4 +- .../outputs/checksum/struct.ChecksumFile.html | 6 +- .../outputs/circuit/struct.CircuitFile.html | 6 +- .../directory/struct.OutputsDirectory.html | 4 +- leo_package/package/struct.Package.html | 4 +- leo_package/root/env/struct.Env.html | 2 +- .../root/gitignore/struct.Gitignore.html | 2 +- .../directory/struct.SourceDirectory.html | 6 +- leo_package/source/main/struct.MainFile.html | 2 +- leo_parser/fn.parse_ast.html | 6 +- .../parser/context/struct.ParserContext.html | 146 +++++++++--------- .../expression/fn.assert_no_whitespace.html | 6 +- leo_parser/parser/fn.parse.html | 6 +- leo_parser/tokenizer/fn.tokenize.html | 4 +- leo_parser/tokenizer/fn.tokenize_iter.html | 4 +- .../lexer/fn.ensure_no_bidi_override.html | 2 +- .../tokenizer/lexer/struct.SpannedToken.html | 4 +- leo_parser/tokenizer/token/enum.Token.html | 10 +- .../generator/struct.CodeGenerator.html | 28 ++-- .../visit_expressions/index.html | 2 +- .../code_generation/visit_type/index.html | 2 +- .../common/assigner/struct.Assigner.html | 2 +- .../common/assigner/struct.AssignerInner.html | 2 +- .../struct.ConstantPropagationTable.html | 14 +- leo_passes/common/graph/trait.Node.html | 2 +- leo_passes/common/graph/type.CallGraph.html | 10 +- leo_passes/common/graph/type.ImportGraph.html | 10 +- leo_passes/common/graph/type.StructGraph.html | 10 +- .../rename_table/struct.RenameTable.html | 16 +- .../struct.FunctionSymbol.html | 4 +- .../symbol_table/struct.SymbolTable.html | 32 ++-- .../struct.VariableSymbol.html | 4 +- leo_passes/common/tree_node/trait.Node.html | 2 +- .../tree_node/type.ConditionalTreeNode.html | 6 +- .../struct.DeadCodeEliminator.html | 6 +- .../destructurer/struct.Destructurer.html | 6 +- .../flattener/struct.Flattener.html | 6 +- .../struct.AssignmentRenamer.html | 2 +- .../struct.FunctionInliner.html | 10 +- .../range_iterator/trait.LoopBound.html | 2 +- .../unroller/struct.Unroller.html | 14 +- leo_passes/pass/trait.Pass.html | 2 +- .../struct.StaticSingleAssigner.html | 6 +- .../creator/struct.SymbolTableCreator.html | 16 +- .../await_checker/struct.AwaitChecker.html | 10 +- .../checker/struct.TypeChecker.html | 86 +++++------ .../scope_state/struct.ScopeState.html | 12 +- .../dependency/struct.Dependency.html | 2 +- .../manifest/struct.Manifest.html | 2 +- .../network_name/enum.NetworkName.html | 2 +- .../struct.ProgramContext.html | 12 +- .../retriever/fn.fetch_from_network.html | 2 +- .../retriever/fn.retrieve_from_network.html | 2 +- .../retriever/fn.retrieve_local.html | 2 +- .../retriever/fn.verify_valid_program.html | 2 +- leo_retriever/retriever/struct.Retriever.html | 18 +-- settings.html | 2 +- src/leo_ast/types/type_.rs.html | 2 +- .../code_generation/visit_expressions.rs.html | 8 +- .../code_generation/visit_type.rs.html | 8 +- trait.impl/core/convert/trait.From.js | 2 +- 237 files changed, 926 insertions(+), 916 deletions(-) diff --git a/help.html b/help.html index e99e3aa438..9cfc05f900 100644 --- a/help.html +++ b/help.html @@ -1 +1 @@ -Help

Rustdoc help

Back
\ No newline at end of file +Help

Rustdoc help

Back
\ No newline at end of file diff --git a/leo_ast/access/array_access/struct.ArrayAccess.html b/leo_ast/access/array_access/struct.ArrayAccess.html index fa9bf6f72a..3cc9dbd5a6 100644 --- a/leo_ast/access/array_access/struct.ArrayAccess.html +++ b/leo_ast/access/array_access/struct.ArrayAccess.html @@ -1,15 +1,15 @@ ArrayAccess in leo_ast::access::array_access - Rust

Struct leo_ast::access::array_access::ArrayAccess

source ·
pub struct ArrayAccess {
     pub array: Box<Expression>,
     pub index: Box<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An array access expression, e.g., foo[index].

Fields§

§array: Box<Expression>

An expression evaluating to some array type, e.g., [false, true].

§index: Box<Expression>

The index to access in the array expression. E.g., 0 for [false, true] would yield false.

-
§span: Span

The span for the entire expression foo[index].

+
§span: Span

The span for the entire expression foo[index].

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ArrayAccess

source§

fn clone(&self) -> ArrayAccess

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ArrayAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ArrayAccess

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayAccess

source§

fn eq(&self, other: &ArrayAccess) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayAccess

source§

fn eq(&self, other: &ArrayAccess) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ArrayAccess

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ArrayAccess

source§

impl StructuralPartialEq for ArrayAccess

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/associated_constant_access/struct.AssociatedConstant.html b/leo_ast/access/associated_constant_access/struct.AssociatedConstant.html index 44e7455334..e8c542dee1 100644 --- a/leo_ast/access/associated_constant_access/struct.AssociatedConstant.html +++ b/leo_ast/access/associated_constant_access/struct.AssociatedConstant.html @@ -1,15 +1,15 @@ AssociatedConstant in leo_ast::access::associated_constant_access - Rust
pub struct AssociatedConstant {
     pub ty: Type,
     pub name: Identifier,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An access expression to an struct constant., e.g. u8::MAX.

Fields§

§ty: Type

The inner struct type.

§name: Identifier

The struct constant that is being accessed.

-
§span: Span

The span for the entire expression Foo::bar().

+
§span: Span

The span for the entire expression Foo::bar().

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for AssociatedConstant

source§

fn clone(&self) -> AssociatedConstant

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AssociatedConstant

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AssociatedConstant

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedConstant

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedConstant

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedConstant

source§

fn eq(&self, other: &AssociatedConstant) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedConstant

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedConstant

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedConstant

source§

fn eq(&self, other: &AssociatedConstant) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AssociatedConstant

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AssociatedConstant

source§

impl StructuralPartialEq for AssociatedConstant

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/associated_function_access/struct.AssociatedFunction.html b/leo_ast/access/associated_function_access/struct.AssociatedFunction.html index 3b0daaf293..56ed986734 100644 --- a/leo_ast/access/associated_function_access/struct.AssociatedFunction.html +++ b/leo_ast/access/associated_function_access/struct.AssociatedFunction.html @@ -2,16 +2,16 @@ pub variant: Identifier, pub name: Identifier, pub arguments: Vec<Expression>, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

An access expression to an associated function in a struct, e.g.Pedersen64::hash().

Fields§

§variant: Identifier

The inner struct variant.

§name: Identifier

The static struct member function that is being accessed.

§arguments: Vec<Expression>

The arguments passed to the function name.

-
§span: Span

The span for the entire expression Foo::bar().

+
§span: Span

The span for the entire expression Foo::bar().

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for AssociatedFunction

source§

fn clone(&self) -> AssociatedFunction

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AssociatedFunction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AssociatedFunction

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedFunction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedFunction

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedFunction

source§

fn eq(&self, other: &AssociatedFunction) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedFunction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedFunction

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedFunction

source§

fn eq(&self, other: &AssociatedFunction) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AssociatedFunction

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AssociatedFunction

source§

impl StructuralPartialEq for AssociatedFunction

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/member_access/struct.MemberAccess.html b/leo_ast/access/member_access/struct.MemberAccess.html index a9724d9c95..17a026e5ed 100644 --- a/leo_ast/access/member_access/struct.MemberAccess.html +++ b/leo_ast/access/member_access/struct.MemberAccess.html @@ -1,15 +1,15 @@ MemberAccess in leo_ast::access::member_access - Rust

Struct leo_ast::access::member_access::MemberAccess

source ·
pub struct MemberAccess {
     pub inner: Box<Expression>,
     pub name: Identifier,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A struct member access expression inner.name to some structure with named members.

Fields§

§inner: Box<Expression>

The inner struct that is being accessed.

§name: Identifier

The name of the struct member to access.

-
§span: Span

The span covering all of inner.name.

+
§span: Span

The span covering all of inner.name.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for MemberAccess

source§

fn clone(&self) -> MemberAccess

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for MemberAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for MemberAccess

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for MemberAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for MemberAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for MemberAccess

source§

fn eq(&self, other: &MemberAccess) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for MemberAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for MemberAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for MemberAccess

source§

fn eq(&self, other: &MemberAccess) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for MemberAccess

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for MemberAccess

source§

impl StructuralPartialEq for MemberAccess

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/struct.ArrayAccess.html b/leo_ast/access/struct.ArrayAccess.html index c09a79fc5b..1e9afebae6 100644 --- a/leo_ast/access/struct.ArrayAccess.html +++ b/leo_ast/access/struct.ArrayAccess.html @@ -1,15 +1,15 @@ ArrayAccess in leo_ast::access - Rust

Struct leo_ast::access::ArrayAccess

source ·
pub struct ArrayAccess {
     pub array: Box<Expression>,
     pub index: Box<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An array access expression, e.g., foo[index].

Fields§

§array: Box<Expression>

An expression evaluating to some array type, e.g., [false, true].

§index: Box<Expression>

The index to access in the array expression. E.g., 0 for [false, true] would yield false.

-
§span: Span

The span for the entire expression foo[index].

+
§span: Span

The span for the entire expression foo[index].

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ArrayAccess

source§

fn clone(&self) -> ArrayAccess

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ArrayAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ArrayAccess

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayAccess

source§

fn eq(&self, other: &ArrayAccess) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayAccess

source§

fn eq(&self, other: &ArrayAccess) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ArrayAccess

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ArrayAccess

source§

impl StructuralPartialEq for ArrayAccess

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/struct.AssociatedConstant.html b/leo_ast/access/struct.AssociatedConstant.html index a0ba60cef1..c6d345f63b 100644 --- a/leo_ast/access/struct.AssociatedConstant.html +++ b/leo_ast/access/struct.AssociatedConstant.html @@ -1,15 +1,15 @@ AssociatedConstant in leo_ast::access - Rust

Struct leo_ast::access::AssociatedConstant

source ·
pub struct AssociatedConstant {
     pub ty: Type,
     pub name: Identifier,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An access expression to an struct constant., e.g. u8::MAX.

Fields§

§ty: Type

The inner struct type.

§name: Identifier

The struct constant that is being accessed.

-
§span: Span

The span for the entire expression Foo::bar().

+
§span: Span

The span for the entire expression Foo::bar().

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for AssociatedConstant

source§

fn clone(&self) -> AssociatedConstant

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AssociatedConstant

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AssociatedConstant

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedConstant

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedConstant

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedConstant

source§

fn eq(&self, other: &AssociatedConstant) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedConstant

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedConstant

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedConstant

source§

fn eq(&self, other: &AssociatedConstant) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AssociatedConstant

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AssociatedConstant

source§

impl StructuralPartialEq for AssociatedConstant

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/struct.AssociatedFunction.html b/leo_ast/access/struct.AssociatedFunction.html index 1aacfe7a9d..2d9b223611 100644 --- a/leo_ast/access/struct.AssociatedFunction.html +++ b/leo_ast/access/struct.AssociatedFunction.html @@ -2,16 +2,16 @@ pub variant: Identifier, pub name: Identifier, pub arguments: Vec<Expression>, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

An access expression to an associated function in a struct, e.g.Pedersen64::hash().

Fields§

§variant: Identifier

The inner struct variant.

§name: Identifier

The static struct member function that is being accessed.

§arguments: Vec<Expression>

The arguments passed to the function name.

-
§span: Span

The span for the entire expression Foo::bar().

+
§span: Span

The span for the entire expression Foo::bar().

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for AssociatedFunction

source§

fn clone(&self) -> AssociatedFunction

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AssociatedFunction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AssociatedFunction

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedFunction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedFunction

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedFunction

source§

fn eq(&self, other: &AssociatedFunction) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssociatedFunction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssociatedFunction

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssociatedFunction

source§

fn eq(&self, other: &AssociatedFunction) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AssociatedFunction

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AssociatedFunction

source§

impl StructuralPartialEq for AssociatedFunction

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/struct.MemberAccess.html b/leo_ast/access/struct.MemberAccess.html index 9f624ab508..a98b4f1fc7 100644 --- a/leo_ast/access/struct.MemberAccess.html +++ b/leo_ast/access/struct.MemberAccess.html @@ -1,15 +1,15 @@ MemberAccess in leo_ast::access - Rust

Struct leo_ast::access::MemberAccess

source ·
pub struct MemberAccess {
     pub inner: Box<Expression>,
     pub name: Identifier,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A struct member access expression inner.name to some structure with named members.

Fields§

§inner: Box<Expression>

The inner struct that is being accessed.

§name: Identifier

The name of the struct member to access.

-
§span: Span

The span covering all of inner.name.

+
§span: Span

The span covering all of inner.name.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for MemberAccess

source§

fn clone(&self) -> MemberAccess

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for MemberAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for MemberAccess

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for MemberAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for MemberAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for MemberAccess

source§

fn eq(&self, other: &MemberAccess) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for MemberAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for MemberAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for MemberAccess

source§

fn eq(&self, other: &MemberAccess) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for MemberAccess

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for MemberAccess

source§

impl StructuralPartialEq for MemberAccess

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/struct.TupleAccess.html b/leo_ast/access/struct.TupleAccess.html index 8b0bc15da5..32fac0d769 100644 --- a/leo_ast/access/struct.TupleAccess.html +++ b/leo_ast/access/struct.TupleAccess.html @@ -1,15 +1,15 @@ TupleAccess in leo_ast::access - Rust

Struct leo_ast::access::TupleAccess

source ·
pub struct TupleAccess {
     pub tuple: Box<Expression>,
     pub index: NonNegativeNumber,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A tuple access expression, e.g., tuple.index.

Fields§

§tuple: Box<Expression>

An expression evaluating to some tuple type, e.g., (5, 2).

§index: NonNegativeNumber

The index to access in the tuple expression. E.g., 0 for (5, 2) would yield 5.

-
§span: Span

The span for the entire expression tuple.index.

+
§span: Span

The span for the entire expression tuple.index.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for TupleAccess

source§

fn clone(&self) -> TupleAccess

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for TupleAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for TupleAccess

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleAccess

source§

fn eq(&self, other: &TupleAccess) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleAccess

source§

fn eq(&self, other: &TupleAccess) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for TupleAccess

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for TupleAccess

source§

impl StructuralPartialEq for TupleAccess

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/access/tuple_access/struct.TupleAccess.html b/leo_ast/access/tuple_access/struct.TupleAccess.html index 0a7b7f9cdc..761a67da16 100644 --- a/leo_ast/access/tuple_access/struct.TupleAccess.html +++ b/leo_ast/access/tuple_access/struct.TupleAccess.html @@ -1,15 +1,15 @@ TupleAccess in leo_ast::access::tuple_access - Rust

Struct leo_ast::access::tuple_access::TupleAccess

source ·
pub struct TupleAccess {
     pub tuple: Box<Expression>,
     pub index: NonNegativeNumber,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A tuple access expression, e.g., tuple.index.

Fields§

§tuple: Box<Expression>

An expression evaluating to some tuple type, e.g., (5, 2).

§index: NonNegativeNumber

The index to access in the tuple expression. E.g., 0 for (5, 2) would yield 5.

-
§span: Span

The span for the entire expression tuple.index.

+
§span: Span

The span for the entire expression tuple.index.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for TupleAccess

source§

fn clone(&self) -> TupleAccess

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for TupleAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for TupleAccess

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleAccess

source§

fn eq(&self, other: &TupleAccess) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleAccess

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleAccess

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleAccess

source§

fn eq(&self, other: &TupleAccess) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for TupleAccess

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for TupleAccess

source§

impl StructuralPartialEq for TupleAccess

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/common/identifier/struct.Identifier.html b/leo_ast/common/identifier/struct.Identifier.html index 24bceeffa2..7436b0652a 100644 --- a/leo_ast/common/identifier/struct.Identifier.html +++ b/leo_ast/common/identifier/struct.Identifier.html @@ -1,21 +1,21 @@ Identifier in leo_ast::common::identifier - Rust

Struct leo_ast::common::identifier::Identifier

source ·
pub struct Identifier {
-    pub name: Symbol,
-    pub span: Span,
+    pub name: Symbol,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An identifier in a program.

Attention - When adding or removing fields from this struct, please remember to update its Serialize and Deserialize implementation to reflect the new struct instantiation.

-

Fields§

§name: Symbol

The symbol that the user wrote, e.g., foo.

-
§span: Span

A span locating where the identifier occurred in the source.

+

Fields§

§name: Symbol

The symbol that the user wrote, e.g., foo.

+
§span: Span

A span locating where the identifier occurred in the source.

§id: NodeID

The ID of the node.

-

Implementations§

source§

impl Identifier

source

pub fn new(name: Symbol, id: NodeID) -> Self

Constructs a new identifier with name and id and a default span.

+

Implementations§

source§

impl Identifier

source

pub fn new(name: Symbol, id: NodeID) -> Self

Constructs a new identifier with name and id and a default span.

source

pub fn matches(&self, other: &Self) -> bool

Check if the Identifier name matches the other name.

-

Trait Implementations§

source§

impl Clone for Identifier

source§

fn clone(&self) -> Identifier

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Identifier

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Identifier

source§

fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Identifier

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<N: Network> From<&Identifier<N>> for Identifier

source§

fn from(id: &IdentifierCore<N>) -> Self

Converts to this type from the input type.
source§

impl From<Identifier> for ProgramId

source§

fn from(name: Identifier) -> Self

Converts to this type from the input type.
source§

impl Hash for Identifier

source§

fn hash<H: Hasher>(&self, state: &mut H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where +

Trait Implementations§

source§

impl Clone for Identifier

source§

fn clone(&self) -> Identifier

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Identifier

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Identifier

source§

fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Identifier

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<N: Network> From<&Identifier<N>> for Identifier

source§

fn from(id: &IdentifierCore<N>) -> Self

Converts to this type from the input type.
source§

impl From<Identifier> for ProgramId

source§

fn from(name: Identifier) -> Self

Converts to this type from the input type.
source§

impl Hash for Identifier

source§

fn hash<H: Hasher>(&self, state: &mut H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, - Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Node for Identifier

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Identifier

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used + Self: Sized,
Feeds a slice of this type into the given Hasher. Read more
source§

impl Node for Identifier

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Identifier

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Identifier

source§

fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

Serialize this value into the given Serde serializer. Read more
source§

impl Copy for Identifier

source§

impl Eq for Identifier

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +sufficient, and should not be overridden without very good reason.

source§

impl Serialize for Identifier

source§

fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

Serialize this value into the given Serde serializer. Read more
source§

impl Copy for Identifier

source§

impl Eq for Identifier

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where diff --git a/leo_ast/common/imported_modules/fn.deserialize.html b/leo_ast/common/imported_modules/fn.deserialize.html index 633473d5b5..570119cfbe 100644 --- a/leo_ast/common/imported_modules/fn.deserialize.html +++ b/leo_ast/common/imported_modules/fn.deserialize.html @@ -1,3 +1,3 @@ deserialize in leo_ast::common::imported_modules - Rust

Function leo_ast::common::imported_modules::deserialize

source ·
pub fn deserialize<'de, D: Deserializer<'de>>(
     deserializer: D,
-) -> Result<IndexMap<Vec<Symbol>, Program>, D::Error>
\ No newline at end of file +) -> Result<IndexMap<Vec<Symbol>, Program>, D::Error>

\ No newline at end of file diff --git a/leo_ast/common/imported_modules/fn.serialize.html b/leo_ast/common/imported_modules/fn.serialize.html index 11c43dfcd7..7870f38392 100644 --- a/leo_ast/common/imported_modules/fn.serialize.html +++ b/leo_ast/common/imported_modules/fn.serialize.html @@ -1,4 +1,4 @@ serialize in leo_ast::common::imported_modules - Rust

Function leo_ast::common::imported_modules::serialize

source ·
pub fn serialize<S: Serializer>(
-    imported_modules: &IndexMap<Vec<Symbol>, Program>,
+    imported_modules: &IndexMap<Vec<Symbol>, Program>,
     serializer: S,
 ) -> Result<S::Ok, S::Error>
\ No newline at end of file diff --git a/leo_ast/common/location/struct.Location.html b/leo_ast/common/location/struct.Location.html index 03a9153a82..989f932e69 100644 --- a/leo_ast/common/location/struct.Location.html +++ b/leo_ast/common/location/struct.Location.html @@ -1,12 +1,12 @@ Location in leo_ast::common::location - Rust

Struct leo_ast::common::location::Location

source ·
pub struct Location {
-    pub program: Option<Symbol>,
-    pub name: Symbol,
-}

Fields§

§program: Option<Symbol>§name: Symbol

Implementations§

source§

impl Location

source

pub fn new(program: Option<Symbol>, name: Symbol) -> Location

Trait Implementations§

source§

impl Clone for Location

source§

fn clone(&self) -> Location

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Location

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Location

source§

fn deserialize<D>(deserializer: D) -> Result<Location, D::Error>
where + pub program: Option<Symbol>, + pub name: Symbol, +}

Fields§

§program: Option<Symbol>§name: Symbol

Implementations§

source§

impl Location

source

pub fn new(program: Option<Symbol>, name: Symbol) -> Location

Trait Implementations§

source§

impl Clone for Location

source§

fn clone(&self) -> Location

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Location

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Location

source§

fn deserialize<D>(deserializer: D) -> Result<Location, D::Error>
where D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl From<&CompositeType> for Location

source§

fn from(composite: &CompositeType) -> Location

Converts to this type from the input type.
source§

impl Hash for Location

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq for Location

source§

fn eq(&self, other: &Location) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Location

source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where +sufficient, and should not be overridden without very good reason.

source§

impl Serialize for Location

source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Location

source§

impl StructuralPartialEq for Location

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_ast/common/node/trait.Node.html b/leo_ast/common/node/trait.Node.html index d62b0e7caf..4f1ff30862 100644 --- a/leo_ast/common/node/trait.Node.html +++ b/leo_ast/common/node/trait.Node.html @@ -1,12 +1,12 @@ Node in leo_ast::common::node - Rust

Trait leo_ast::common::node::Node

source ·
pub trait Node: Debug + Display + Clone + PartialEq + Eq + Serialize + DeserializeOwned {
     // Required methods
-    fn span(&self) -> Span;
-    fn set_span(&mut self, span: Span);
+    fn span(&self) -> Span;
+    fn set_span(&mut self, span: Span);
     fn id(&self) -> NodeID;
     fn set_id(&mut self, id: NodeID);
 }
Expand description

A node in the AST.

-

Required Methods§

source

fn span(&self) -> Span

Returns the span of the node.

-
source

fn set_span(&mut self, span: Span)

Sets the span of the node.

+

Required Methods§

source

fn span(&self) -> Span

Returns the span of the node.

+
source

fn set_span(&mut self, span: Span)

Sets the span of the node.

source

fn id(&self) -> NodeID

Returns the ID of the node.

source

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.

Object Safety§

This trait is not object safe.

Implementors§

\ No newline at end of file diff --git a/leo_ast/expressions/access/enum.AccessExpression.html b/leo_ast/expressions/access/enum.AccessExpression.html index 42ff892ae7..4531692f56 100644 --- a/leo_ast/expressions/access/enum.AccessExpression.html +++ b/leo_ast/expressions/access/enum.AccessExpression.html @@ -11,7 +11,7 @@
§

Member(MemberAccess)

An expression accessing a field in a structure, e.g., struct_var.field.

§

Tuple(TupleAccess)

Access to a tuple field using its position, e.g., tuple.1.

Trait Implementations§

source§

impl Clone for AccessExpression

source§

fn clone(&self) -> AccessExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AccessExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AccessExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AccessExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AccessExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AccessExpression

source§

fn eq(&self, other: &AccessExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AccessExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AccessExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AccessExpression

source§

fn eq(&self, other: &AccessExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AccessExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AccessExpression

source§

impl StructuralPartialEq for AccessExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/array/struct.ArrayExpression.html b/leo_ast/expressions/array/struct.ArrayExpression.html index 4621fda14a..581d8da3ba 100644 --- a/leo_ast/expressions/array/struct.ArrayExpression.html +++ b/leo_ast/expressions/array/struct.ArrayExpression.html @@ -1,13 +1,13 @@ ArrayExpression in leo_ast::expressions::array - Rust

Struct leo_ast::expressions::array::ArrayExpression

source ·
pub struct ArrayExpression {
     pub elements: Vec<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An array expression, e.g., [true, false, true, false].

Fields§

§elements: Vec<Expression>

The elements of the array.

-
§span: Span

The span from [ to ].

+
§span: Span

The span from [ to ].

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ArrayExpression

source§

fn clone(&self) -> ArrayExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ArrayExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ArrayExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayExpression

source§

fn eq(&self, other: &ArrayExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayExpression

source§

fn eq(&self, other: &ArrayExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ArrayExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ArrayExpression

source§

impl StructuralPartialEq for ArrayExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/binary/enum.BinaryOperation.html b/leo_ast/expressions/binary/enum.BinaryOperation.html index 31c9604b19..48bd39fb9e 100644 --- a/leo_ast/expressions/binary/enum.BinaryOperation.html +++ b/leo_ast/expressions/binary/enum.BinaryOperation.html @@ -61,7 +61,7 @@
§

Sub

Subtraction, i.e. -, .sub().

§

SubWrapped

Wrapped subtraction, i.e. .sub_wrapped().

§

Xor

Bitwise XOR, i.e. .xor().

-

Implementations§

source§

impl BinaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a BinaryOperation from the given Symbol. +

Implementations§

source§

impl BinaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a BinaryOperation from the given Symbol. This is used to resolve native operators invoked as method calls, e.g. a.add_wrapped(b).

Trait Implementations§

source§

impl Clone for BinaryOperation

source§

fn clone(&self) -> BinaryOperation

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for BinaryOperation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for BinaryOperation

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for BinaryOperation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for BinaryOperation

source§

fn eq(&self, other: &BinaryOperation) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/expressions/binary/struct.BinaryExpression.html b/leo_ast/expressions/binary/struct.BinaryExpression.html index ab78677328..72f580f1e5 100644 --- a/leo_ast/expressions/binary/struct.BinaryExpression.html +++ b/leo_ast/expressions/binary/struct.BinaryExpression.html @@ -2,17 +2,17 @@ pub left: Box<Expression>, pub right: Box<Expression>, pub op: BinaryOperation, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A binary expression left op right of two operands separated by some operator. For example, foo + bar.

Fields§

§left: Box<Expression>

The left operand of the expression.

§right: Box<Expression>

The right operand of the expression.

§op: BinaryOperation

The operand defining the meaning of the resulting binary expression.

-
§span: Span

The span from left to right.

+
§span: Span

The span from left to right.

§id: NodeID

The ID of the expression.

Trait Implementations§

source§

impl Clone for BinaryExpression

source§

fn clone(&self) -> BinaryExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for BinaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for BinaryExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for BinaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for BinaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for BinaryExpression

source§

fn eq(&self, other: &BinaryExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for BinaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for BinaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for BinaryExpression

source§

fn eq(&self, other: &BinaryExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for BinaryExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for BinaryExpression

source§

impl StructuralPartialEq for BinaryExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/call/struct.CallExpression.html b/leo_ast/expressions/call/struct.CallExpression.html index c00b6b47a6..b5681dd2de 100644 --- a/leo_ast/expressions/call/struct.CallExpression.html +++ b/leo_ast/expressions/call/struct.CallExpression.html @@ -1,18 +1,18 @@ CallExpression in leo_ast::expressions::call - Rust

Struct leo_ast::expressions::call::CallExpression

source ·
pub struct CallExpression {
     pub function: Box<Expression>,
     pub arguments: Vec<Expression>,
-    pub program: Option<Symbol>,
-    pub span: Span,
+    pub program: Option<Symbol>,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A function call expression, e.g.foo(args) or Foo::bar(args).

Fields§

§function: Box<Expression>

An expression evaluating to a callable function, either a member of a structure or a free function.

§arguments: Vec<Expression>

Expressions for the arguments passed to the functions parameters.

-
§program: Option<Symbol>

The name of the parent program call, e.g.bar in bar.aleo.

-
§span: Span

Span of the entire call function(arguments).

+
§program: Option<Symbol>

The name of the parent program call, e.g.bar in bar.aleo.

+
§span: Span

Span of the entire call function(arguments).

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for CallExpression

source§

fn clone(&self) -> CallExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CallExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for CallExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CallExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CallExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CallExpression

source§

fn eq(&self, other: &CallExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CallExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CallExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CallExpression

source§

fn eq(&self, other: &CallExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for CallExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for CallExpression

source§

impl StructuralPartialEq for CallExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/cast/struct.CastExpression.html b/leo_ast/expressions/cast/struct.CastExpression.html index e20a41b1bc..db8875c8c3 100644 --- a/leo_ast/expressions/cast/struct.CastExpression.html +++ b/leo_ast/expressions/cast/struct.CastExpression.html @@ -1,15 +1,15 @@ CastExpression in leo_ast::expressions::cast - Rust

Struct leo_ast::expressions::cast::CastExpression

source ·
pub struct CastExpression {
     pub expression: Box<Expression>,
     pub type_: Type,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A cast expression, e.g. 42u8 as u16.

Fields§

§expression: Box<Expression>

The expression to be casted, e.g.42u8 in 42u8 as u16.

§type_: Type

The type to be casted to, e.g. u16 in 42u8 as u16.

-
§span: Span

Span of the entire cast 42u8 as u16.

+
§span: Span

Span of the entire cast 42u8 as u16.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for CastExpression

source§

fn clone(&self) -> CastExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CastExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for CastExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CastExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CastExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CastExpression

source§

fn eq(&self, other: &CastExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CastExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CastExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CastExpression

source§

fn eq(&self, other: &CastExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for CastExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for CastExpression

source§

impl StructuralPartialEq for CastExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/enum.AccessExpression.html b/leo_ast/expressions/enum.AccessExpression.html index de666f1ed0..8d2f4d6d80 100644 --- a/leo_ast/expressions/enum.AccessExpression.html +++ b/leo_ast/expressions/enum.AccessExpression.html @@ -11,7 +11,7 @@
§

Member(MemberAccess)

An expression accessing a field in a structure, e.g., struct_var.field.

§

Tuple(TupleAccess)

Access to a tuple field using its position, e.g., tuple.1.

Trait Implementations§

source§

impl Clone for AccessExpression

source§

fn clone(&self) -> AccessExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AccessExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AccessExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AccessExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AccessExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AccessExpression

source§

fn eq(&self, other: &AccessExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AccessExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AccessExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AccessExpression

source§

fn eq(&self, other: &AccessExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AccessExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AccessExpression

source§

impl StructuralPartialEq for AccessExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/enum.BinaryOperation.html b/leo_ast/expressions/enum.BinaryOperation.html index 25873e8846..d0a03974b6 100644 --- a/leo_ast/expressions/enum.BinaryOperation.html +++ b/leo_ast/expressions/enum.BinaryOperation.html @@ -61,7 +61,7 @@
§

Sub

Subtraction, i.e. -, .sub().

§

SubWrapped

Wrapped subtraction, i.e. .sub_wrapped().

§

Xor

Bitwise XOR, i.e. .xor().

-

Implementations§

source§

impl BinaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a BinaryOperation from the given Symbol. +

Implementations§

source§

impl BinaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a BinaryOperation from the given Symbol. This is used to resolve native operators invoked as method calls, e.g. a.add_wrapped(b).

Trait Implementations§

source§

impl Clone for BinaryOperation

source§

fn clone(&self) -> BinaryOperation

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for BinaryOperation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for BinaryOperation

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for BinaryOperation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for BinaryOperation

source§

fn eq(&self, other: &BinaryOperation) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/expressions/enum.Expression.html b/leo_ast/expressions/enum.Expression.html index d8c88a6a03..0fd021e0e3 100644 --- a/leo_ast/expressions/enum.Expression.html +++ b/leo_ast/expressions/enum.Expression.html @@ -30,7 +30,7 @@
§

Unary(UnaryExpression)

An unary expression.

§

Unit(UnitExpression)

A unit expression e.g. ()

Trait Implementations§

source§

impl Clone for Expression

source§

fn clone(&self) -> Expression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Expression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Expression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Expression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Expression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Expression

source§

fn eq(&self, other: &Expression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Expression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Expression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Expression

source§

fn eq(&self, other: &Expression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Expression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Expression

source§

impl StructuralPartialEq for Expression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/enum.Literal.html b/leo_ast/expressions/enum.Literal.html index eac7508780..a8d08d53a9 100644 --- a/leo_ast/expressions/enum.Literal.html +++ b/leo_ast/expressions/enum.Literal.html @@ -1,27 +1,27 @@ Literal in leo_ast::expressions - Rust

Enum leo_ast::expressions::Literal

source ·
pub enum Literal {
-    Address(String, Span, NodeID),
-    Boolean(bool, Span, NodeID),
-    Field(String, Span, NodeID),
+    Address(String, Span, NodeID),
+    Boolean(bool, Span, NodeID),
+    Field(String, Span, NodeID),
     Group(Box<GroupLiteral>),
-    Integer(IntegerType, String, Span, NodeID),
-    Scalar(String, Span, NodeID),
-    String(String, Span, NodeID),
+    Integer(IntegerType, String, Span, NodeID),
+    Scalar(String, Span, NodeID),
+    String(String, Span, NodeID),
 }
Expand description

A literal.

-

Variants§

§

Address(String, Span, NodeID)

An address literal, e.g., aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8s7pyjh9 or hello.aleo.

-
§

Boolean(bool, Span, NodeID)

A boolean literal, either true or false.

-
§

Field(String, Span, NodeID)

A field literal, e.g., 42field. +

Variants§

§

Address(String, Span, NodeID)

An address literal, e.g., aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8s7pyjh9 or hello.aleo.

+
§

Boolean(bool, Span, NodeID)

A boolean literal, either true or false.

+
§

Field(String, Span, NodeID)

A field literal, e.g., 42field. A signed number followed by the keyword field.

§

Group(Box<GroupLiteral>)

A group literal, either product or affine. For example, 42group or (12, 52)group.

-
§

Integer(IntegerType, String, Span, NodeID)

An integer literal, e.g., 42.

-
§

Scalar(String, Span, NodeID)

A scalar literal, e.g. 1scalar. +

§

Integer(IntegerType, String, Span, NodeID)

An integer literal, e.g., 42.

+
§

Scalar(String, Span, NodeID)

A scalar literal, e.g. 1scalar. An unsigned number followed by the keyword scalar.

-
§

String(String, Span, NodeID)

A string literal, e.g., "foobar".

+
§

String(String, Span, NodeID)

A string literal, e.g., "foobar".

Implementations§

Trait Implementations§

source§

impl Clone for Literal

source§

fn clone(&self) -> Literal

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Literal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Literal

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Literal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Literal

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, new_span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Literal

source§

fn eq(&self, other: &Literal) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Literal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Literal

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, new_span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Literal

source§

fn eq(&self, other: &Literal) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Literal

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where - __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&Literal> for Value

source§

fn try_from(literal: &Literal) -> Result<Self, Self::Error>

Converts a literal to a value.

+ __S: Serializer,
Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&Literal> for Value

source§

fn try_from(literal: &Literal) -> Result<Self, Self::Error>

Converts a literal to a value.

§

type Error = ParseIntError

The type returned in the event of a conversion error.
source§

impl Eq for Literal

source§

impl StructuralPartialEq for Literal

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_ast/expressions/enum.UnaryOperation.html b/leo_ast/expressions/enum.UnaryOperation.html index 71a317b1ea..f27cd3a669 100644 --- a/leo_ast/expressions/enum.UnaryOperation.html +++ b/leo_ast/expressions/enum.UnaryOperation.html @@ -20,7 +20,7 @@
§

SquareRoot

Square root operation, i.e. .sqrt().

§

ToXCoordinate

Converts a group element to its x-coordinate, i.e. .to_x_coordinate().

§

ToYCoordinate

Converts a group element to its y-coordinate, i.e. .to_y_coordinate().

-

Implementations§

source§

impl UnaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a UnaryOperation from the given Symbol.

+

Implementations§

source§

impl UnaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a UnaryOperation from the given Symbol.

source

fn as_str(self) -> &'static str

Represents the opera.tor as a string.

Trait Implementations§

source§

impl Clone for UnaryOperation

source§

fn clone(&self) -> UnaryOperation

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for UnaryOperation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for UnaryOperation

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for UnaryOperation

source§

fn eq(&self, other: &UnaryOperation) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/expressions/err/struct.ErrExpression.html b/leo_ast/expressions/err/struct.ErrExpression.html index 00937dec47..df2da34d06 100644 --- a/leo_ast/expressions/err/struct.ErrExpression.html +++ b/leo_ast/expressions/err/struct.ErrExpression.html @@ -1,11 +1,11 @@ ErrExpression in leo_ast::expressions::err - Rust

Struct leo_ast::expressions::err::ErrExpression

source ·
pub struct ErrExpression {
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

Represents a syntactically invalid expression.

-

Fields§

§span: Span

The span of the invalid expression.

+

Fields§

§span: Span

The span of the invalid expression.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ErrExpression

source§

fn clone(&self) -> ErrExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ErrExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ErrExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ErrExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ErrExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ErrExpression

source§

fn eq(&self, other: &ErrExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ErrExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ErrExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ErrExpression

source§

fn eq(&self, other: &ErrExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ErrExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ErrExpression

source§

impl StructuralPartialEq for ErrExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/literal/enum.Literal.html b/leo_ast/expressions/literal/enum.Literal.html index c0dd64cd42..0ebb08120b 100644 --- a/leo_ast/expressions/literal/enum.Literal.html +++ b/leo_ast/expressions/literal/enum.Literal.html @@ -1,27 +1,27 @@ Literal in leo_ast::expressions::literal - Rust

Enum leo_ast::expressions::literal::Literal

source ·
pub enum Literal {
-    Address(String, Span, NodeID),
-    Boolean(bool, Span, NodeID),
-    Field(String, Span, NodeID),
+    Address(String, Span, NodeID),
+    Boolean(bool, Span, NodeID),
+    Field(String, Span, NodeID),
     Group(Box<GroupLiteral>),
-    Integer(IntegerType, String, Span, NodeID),
-    Scalar(String, Span, NodeID),
-    String(String, Span, NodeID),
+    Integer(IntegerType, String, Span, NodeID),
+    Scalar(String, Span, NodeID),
+    String(String, Span, NodeID),
 }
Expand description

A literal.

-

Variants§

§

Address(String, Span, NodeID)

An address literal, e.g., aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8s7pyjh9 or hello.aleo.

-
§

Boolean(bool, Span, NodeID)

A boolean literal, either true or false.

-
§

Field(String, Span, NodeID)

A field literal, e.g., 42field. +

Variants§

§

Address(String, Span, NodeID)

An address literal, e.g., aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8s7pyjh9 or hello.aleo.

+
§

Boolean(bool, Span, NodeID)

A boolean literal, either true or false.

+
§

Field(String, Span, NodeID)

A field literal, e.g., 42field. A signed number followed by the keyword field.

§

Group(Box<GroupLiteral>)

A group literal, either product or affine. For example, 42group or (12, 52)group.

-
§

Integer(IntegerType, String, Span, NodeID)

An integer literal, e.g., 42.

-
§

Scalar(String, Span, NodeID)

A scalar literal, e.g. 1scalar. +

§

Integer(IntegerType, String, Span, NodeID)

An integer literal, e.g., 42.

+
§

Scalar(String, Span, NodeID)

A scalar literal, e.g. 1scalar. An unsigned number followed by the keyword scalar.

-
§

String(String, Span, NodeID)

A string literal, e.g., "foobar".

+
§

String(String, Span, NodeID)

A string literal, e.g., "foobar".

Implementations§

Trait Implementations§

source§

impl Clone for Literal

source§

fn clone(&self) -> Literal

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Literal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Literal

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Literal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Literal

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, new_span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Literal

source§

fn eq(&self, other: &Literal) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Literal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Literal

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, new_span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Literal

source§

fn eq(&self, other: &Literal) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Literal

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where - __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&Literal> for Value

source§

fn try_from(literal: &Literal) -> Result<Self, Self::Error>

Converts a literal to a value.

+ __S: Serializer,
Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&Literal> for Value

source§

fn try_from(literal: &Literal) -> Result<Self, Self::Error>

Converts a literal to a value.

§

type Error = ParseIntError

The type returned in the event of a conversion error.
source§

impl Eq for Literal

source§

impl StructuralPartialEq for Literal

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_ast/expressions/locator/struct.LocatorExpression.html b/leo_ast/expressions/locator/struct.LocatorExpression.html index 6c723b29ba..0b91991496 100644 --- a/leo_ast/expressions/locator/struct.LocatorExpression.html +++ b/leo_ast/expressions/locator/struct.LocatorExpression.html @@ -1,19 +1,19 @@ LocatorExpression in leo_ast::expressions::locator - Rust

Struct leo_ast::expressions::locator::LocatorExpression

source ·
pub struct LocatorExpression {
     pub program: ProgramId,
-    pub name: Symbol,
-    pub span: Span,
+    pub name: Symbol,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A locator that references an external resource.

Fields§

§program: ProgramId

The program that the resource is in.

-
§name: Symbol

The name of the resource.

-
§span: Span

A span indicating where the locator occurred in the source.

+
§name: Symbol

The name of the resource.

+
§span: Span

A span indicating where the locator occurred in the source.

§id: NodeID

The ID of the node.

-

Implementations§

source§

impl LocatorExpression

source

pub fn new(program: ProgramId, name: Symbol, id: NodeID) -> Self

Constructs a new Locator with name, program and id and a default span.

+

Implementations§

source§

impl LocatorExpression

source

pub fn new(program: ProgramId, name: Symbol, id: NodeID) -> Self

Constructs a new Locator with name, program and id and a default span.

source

pub fn matches(&self, other: &Self) -> bool

Check if the Locator name and program matches the other name and program.

Trait Implementations§

source§

impl Clone for LocatorExpression

source§

fn clone(&self) -> LocatorExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for LocatorExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for LocatorExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for LocatorExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Hash for LocatorExpression

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, - Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Node for LocatorExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for LocatorExpression

source§

fn eq(&self, other: &LocatorExpression) -> bool

This method tests for self and other values to be equal, and is used + Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Node for LocatorExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for LocatorExpression

source§

fn eq(&self, other: &LocatorExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for LocatorExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Copy for LocatorExpression

source§

impl Eq for LocatorExpression

source§

impl StructuralPartialEq for LocatorExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.ArrayExpression.html b/leo_ast/expressions/struct.ArrayExpression.html index 565d6ec216..fe7a83253f 100644 --- a/leo_ast/expressions/struct.ArrayExpression.html +++ b/leo_ast/expressions/struct.ArrayExpression.html @@ -1,13 +1,13 @@ ArrayExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::ArrayExpression

source ·
pub struct ArrayExpression {
     pub elements: Vec<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An array expression, e.g., [true, false, true, false].

Fields§

§elements: Vec<Expression>

The elements of the array.

-
§span: Span

The span from [ to ].

+
§span: Span

The span from [ to ].

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ArrayExpression

source§

fn clone(&self) -> ArrayExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ArrayExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ArrayExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayExpression

source§

fn eq(&self, other: &ArrayExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ArrayExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ArrayExpression

source§

fn eq(&self, other: &ArrayExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ArrayExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ArrayExpression

source§

impl StructuralPartialEq for ArrayExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.BinaryExpression.html b/leo_ast/expressions/struct.BinaryExpression.html index b03d8caac9..6df9019ccc 100644 --- a/leo_ast/expressions/struct.BinaryExpression.html +++ b/leo_ast/expressions/struct.BinaryExpression.html @@ -2,17 +2,17 @@ pub left: Box<Expression>, pub right: Box<Expression>, pub op: BinaryOperation, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A binary expression left op right of two operands separated by some operator. For example, foo + bar.

Fields§

§left: Box<Expression>

The left operand of the expression.

§right: Box<Expression>

The right operand of the expression.

§op: BinaryOperation

The operand defining the meaning of the resulting binary expression.

-
§span: Span

The span from left to right.

+
§span: Span

The span from left to right.

§id: NodeID

The ID of the expression.

Trait Implementations§

source§

impl Clone for BinaryExpression

source§

fn clone(&self) -> BinaryExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for BinaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for BinaryExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for BinaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for BinaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for BinaryExpression

source§

fn eq(&self, other: &BinaryExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for BinaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for BinaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for BinaryExpression

source§

fn eq(&self, other: &BinaryExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for BinaryExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for BinaryExpression

source§

impl StructuralPartialEq for BinaryExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.CallExpression.html b/leo_ast/expressions/struct.CallExpression.html index cba0255dff..e89c175120 100644 --- a/leo_ast/expressions/struct.CallExpression.html +++ b/leo_ast/expressions/struct.CallExpression.html @@ -1,18 +1,18 @@ CallExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::CallExpression

source ·
pub struct CallExpression {
     pub function: Box<Expression>,
     pub arguments: Vec<Expression>,
-    pub program: Option<Symbol>,
-    pub span: Span,
+    pub program: Option<Symbol>,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A function call expression, e.g.foo(args) or Foo::bar(args).

Fields§

§function: Box<Expression>

An expression evaluating to a callable function, either a member of a structure or a free function.

§arguments: Vec<Expression>

Expressions for the arguments passed to the functions parameters.

-
§program: Option<Symbol>

The name of the parent program call, e.g.bar in bar.aleo.

-
§span: Span

Span of the entire call function(arguments).

+
§program: Option<Symbol>

The name of the parent program call, e.g.bar in bar.aleo.

+
§span: Span

Span of the entire call function(arguments).

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for CallExpression

source§

fn clone(&self) -> CallExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CallExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for CallExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CallExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CallExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CallExpression

source§

fn eq(&self, other: &CallExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CallExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CallExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CallExpression

source§

fn eq(&self, other: &CallExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for CallExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for CallExpression

source§

impl StructuralPartialEq for CallExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.CastExpression.html b/leo_ast/expressions/struct.CastExpression.html index 43c545f9d6..12ece1d363 100644 --- a/leo_ast/expressions/struct.CastExpression.html +++ b/leo_ast/expressions/struct.CastExpression.html @@ -1,15 +1,15 @@ CastExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::CastExpression

source ·
pub struct CastExpression {
     pub expression: Box<Expression>,
     pub type_: Type,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A cast expression, e.g. 42u8 as u16.

Fields§

§expression: Box<Expression>

The expression to be casted, e.g.42u8 in 42u8 as u16.

§type_: Type

The type to be casted to, e.g. u16 in 42u8 as u16.

-
§span: Span

Span of the entire cast 42u8 as u16.

+
§span: Span

Span of the entire cast 42u8 as u16.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for CastExpression

source§

fn clone(&self) -> CastExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CastExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for CastExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CastExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CastExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CastExpression

source§

fn eq(&self, other: &CastExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CastExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for CastExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for CastExpression

source§

fn eq(&self, other: &CastExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for CastExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for CastExpression

source§

impl StructuralPartialEq for CastExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.ErrExpression.html b/leo_ast/expressions/struct.ErrExpression.html index 15ff091140..4165ce39d6 100644 --- a/leo_ast/expressions/struct.ErrExpression.html +++ b/leo_ast/expressions/struct.ErrExpression.html @@ -1,11 +1,11 @@ ErrExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::ErrExpression

source ·
pub struct ErrExpression {
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

Represents a syntactically invalid expression.

-

Fields§

§span: Span

The span of the invalid expression.

+

Fields§

§span: Span

The span of the invalid expression.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ErrExpression

source§

fn clone(&self) -> ErrExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ErrExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ErrExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ErrExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ErrExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ErrExpression

source§

fn eq(&self, other: &ErrExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ErrExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ErrExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ErrExpression

source§

fn eq(&self, other: &ErrExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ErrExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ErrExpression

source§

impl StructuralPartialEq for ErrExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.StructExpression.html b/leo_ast/expressions/struct.StructExpression.html index 294bd87556..60b4536ad6 100644 --- a/leo_ast/expressions/struct.StructExpression.html +++ b/leo_ast/expressions/struct.StructExpression.html @@ -1,19 +1,19 @@ StructExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::StructExpression

source ·
pub struct StructExpression {
     pub name: Identifier,
     pub members: Vec<StructVariableInitializer>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A struct initialization expression, e.g., Foo { bar: 42, baz }.

Fields§

§name: Identifier

The name of the structure type to initialize.

§members: Vec<StructVariableInitializer>

Initializer expressions for each of the fields in the struct.

N.B. Any functions or member constants in the struct definition are excluded from this list.

-
§span: Span

A span from name to }.

+
§span: Span

A span from name to }.

§id: NodeID

The ID of the node.

Implementations§

source§

impl StructExpression

source

pub fn check_record(&self) -> bool

Returns true if the record has all required fields and visibility.

source

pub fn to_record_string(&self) -> String

Returns the struct as a record interface with visibility.

Trait Implementations§

source§

impl Clone for StructExpression

source§

fn clone(&self) -> StructExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for StructExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for StructExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructExpression

source§

fn eq(&self, other: &StructExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructExpression

source§

fn eq(&self, other: &StructExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for StructExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for StructExpression

source§

impl StructuralPartialEq for StructExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.StructVariableInitializer.html b/leo_ast/expressions/struct.StructVariableInitializer.html index 160f84af36..e7894a15d6 100644 --- a/leo_ast/expressions/struct.StructVariableInitializer.html +++ b/leo_ast/expressions/struct.StructVariableInitializer.html @@ -1,17 +1,17 @@ StructVariableInitializer in leo_ast::expressions - Rust

Struct leo_ast::expressions::StructVariableInitializer

source ·
pub struct StructVariableInitializer {
     pub identifier: Identifier,
     pub expression: Option<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An initializer for a single field / variable of a struct initializer expression. That is, in Foo { bar: 42, baz }, this is either bar: 42, or baz.

Fields§

§identifier: Identifier

The name of the field / variable to be initialized.

§expression: Option<Expression>

The expression to initialize the field with. When None, a binding, in scope, with the name will be used instead.

-
§span: Span

The span of the node.

+
§span: Span

The span of the node.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for StructVariableInitializer

source§

fn clone(&self) -> StructVariableInitializer

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for StructVariableInitializer

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for StructVariableInitializer

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructVariableInitializer

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructVariableInitializer

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructVariableInitializer

source§

fn eq(&self, other: &StructVariableInitializer) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructVariableInitializer

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructVariableInitializer

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructVariableInitializer

source§

fn eq(&self, other: &StructVariableInitializer) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for StructVariableInitializer

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for StructVariableInitializer

source§

impl StructuralPartialEq for StructVariableInitializer

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.TernaryExpression.html b/leo_ast/expressions/struct.TernaryExpression.html index 8c41875bd5..7c684d6a83 100644 --- a/leo_ast/expressions/struct.TernaryExpression.html +++ b/leo_ast/expressions/struct.TernaryExpression.html @@ -2,16 +2,16 @@ pub condition: Box<Expression>, pub if_true: Box<Expression>, pub if_false: Box<Expression>, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A ternary conditional expression, that is, condition ? if_true : if_false.

Fields§

§condition: Box<Expression>

The condition determining which branch to pick.

§if_true: Box<Expression>

The branch the expression evaluates to if condition evaluates to true.

§if_false: Box<Expression>

The branch the expression evaluates to if condition evaluates to false.

-
§span: Span

The span from condition to if_false.

+
§span: Span

The span from condition to if_false.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for TernaryExpression

source§

fn clone(&self) -> TernaryExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for TernaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for TernaryExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TernaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TernaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TernaryExpression

source§

fn eq(&self, other: &TernaryExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TernaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TernaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TernaryExpression

source§

fn eq(&self, other: &TernaryExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for TernaryExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for TernaryExpression

source§

impl StructuralPartialEq for TernaryExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.TupleExpression.html b/leo_ast/expressions/struct.TupleExpression.html index ce727c6440..6973e415e2 100644 --- a/leo_ast/expressions/struct.TupleExpression.html +++ b/leo_ast/expressions/struct.TupleExpression.html @@ -1,14 +1,14 @@ TupleExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::TupleExpression

source ·
pub struct TupleExpression {
     pub elements: Vec<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A tuple expression, e.g., (foo, false, 42).

Fields§

§elements: Vec<Expression>

The elements of the tuple. In the example above, it would be foo, false, and 42.

-
§span: Span

The span from ( to ).

+
§span: Span

The span from ( to ).

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for TupleExpression

source§

fn clone(&self) -> TupleExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for TupleExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for TupleExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleExpression

source§

fn eq(&self, other: &TupleExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleExpression

source§

fn eq(&self, other: &TupleExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for TupleExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for TupleExpression

source§

impl StructuralPartialEq for TupleExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.UnaryExpression.html b/leo_ast/expressions/struct.UnaryExpression.html index 98bcaabf3b..f6a8a21d6a 100644 --- a/leo_ast/expressions/struct.UnaryExpression.html +++ b/leo_ast/expressions/struct.UnaryExpression.html @@ -1,15 +1,15 @@ UnaryExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::UnaryExpression

source ·
pub struct UnaryExpression {
     pub receiver: Box<Expression>,
     pub op: UnaryOperation,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An unary expression applying an operator to an inner expression.

Fields§

§receiver: Box<Expression>

The inner expression op is applied to.

§op: UnaryOperation

The unary operator to apply to inner.

-
§span: Span

The span covering op inner.

+
§span: Span

The span covering op inner.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for UnaryExpression

source§

fn clone(&self) -> UnaryExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for UnaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for UnaryExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnaryExpression

source§

fn eq(&self, other: &UnaryExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnaryExpression

source§

fn eq(&self, other: &UnaryExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for UnaryExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for UnaryExpression

source§

impl StructuralPartialEq for UnaryExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct.UnitExpression.html b/leo_ast/expressions/struct.UnitExpression.html index f1a3dc4e90..ce1f840fa0 100644 --- a/leo_ast/expressions/struct.UnitExpression.html +++ b/leo_ast/expressions/struct.UnitExpression.html @@ -1,11 +1,11 @@ UnitExpression in leo_ast::expressions - Rust

Struct leo_ast::expressions::UnitExpression

source ·
pub struct UnitExpression {
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

Represents a unit expression.

-

Fields§

§span: Span

The span of the unit expression.

+

Fields§

§span: Span

The span of the unit expression.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for UnitExpression

source§

fn clone(&self) -> UnitExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for UnitExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for UnitExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnitExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnitExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnitExpression

source§

fn eq(&self, other: &UnitExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnitExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnitExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnitExpression

source§

fn eq(&self, other: &UnitExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for UnitExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for UnitExpression

source§

impl StructuralPartialEq for UnitExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct_init/struct.StructExpression.html b/leo_ast/expressions/struct_init/struct.StructExpression.html index 89d3541f3a..01b17572f6 100644 --- a/leo_ast/expressions/struct_init/struct.StructExpression.html +++ b/leo_ast/expressions/struct_init/struct.StructExpression.html @@ -1,19 +1,19 @@ StructExpression in leo_ast::expressions::struct_init - Rust

Struct leo_ast::expressions::struct_init::StructExpression

source ·
pub struct StructExpression {
     pub name: Identifier,
     pub members: Vec<StructVariableInitializer>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A struct initialization expression, e.g., Foo { bar: 42, baz }.

Fields§

§name: Identifier

The name of the structure type to initialize.

§members: Vec<StructVariableInitializer>

Initializer expressions for each of the fields in the struct.

N.B. Any functions or member constants in the struct definition are excluded from this list.

-
§span: Span

A span from name to }.

+
§span: Span

A span from name to }.

§id: NodeID

The ID of the node.

Implementations§

source§

impl StructExpression

source

pub fn check_record(&self) -> bool

Returns true if the record has all required fields and visibility.

source

pub fn to_record_string(&self) -> String

Returns the struct as a record interface with visibility.

Trait Implementations§

source§

impl Clone for StructExpression

source§

fn clone(&self) -> StructExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for StructExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for StructExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructExpression

source§

fn eq(&self, other: &StructExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructExpression

source§

fn eq(&self, other: &StructExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for StructExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for StructExpression

source§

impl StructuralPartialEq for StructExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/struct_init/struct.StructVariableInitializer.html b/leo_ast/expressions/struct_init/struct.StructVariableInitializer.html index 9a28274fd4..92d9655c07 100644 --- a/leo_ast/expressions/struct_init/struct.StructVariableInitializer.html +++ b/leo_ast/expressions/struct_init/struct.StructVariableInitializer.html @@ -1,17 +1,17 @@ StructVariableInitializer in leo_ast::expressions::struct_init - Rust
pub struct StructVariableInitializer {
     pub identifier: Identifier,
     pub expression: Option<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An initializer for a single field / variable of a struct initializer expression. That is, in Foo { bar: 42, baz }, this is either bar: 42, or baz.

Fields§

§identifier: Identifier

The name of the field / variable to be initialized.

§expression: Option<Expression>

The expression to initialize the field with. When None, a binding, in scope, with the name will be used instead.

-
§span: Span

The span of the node.

+
§span: Span

The span of the node.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for StructVariableInitializer

source§

fn clone(&self) -> StructVariableInitializer

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for StructVariableInitializer

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for StructVariableInitializer

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructVariableInitializer

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructVariableInitializer

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructVariableInitializer

source§

fn eq(&self, other: &StructVariableInitializer) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for StructVariableInitializer

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for StructVariableInitializer

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for StructVariableInitializer

source§

fn eq(&self, other: &StructVariableInitializer) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for StructVariableInitializer

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for StructVariableInitializer

source§

impl StructuralPartialEq for StructVariableInitializer

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/ternary/struct.TernaryExpression.html b/leo_ast/expressions/ternary/struct.TernaryExpression.html index 4ff9769176..3b92d348cb 100644 --- a/leo_ast/expressions/ternary/struct.TernaryExpression.html +++ b/leo_ast/expressions/ternary/struct.TernaryExpression.html @@ -2,16 +2,16 @@ pub condition: Box<Expression>, pub if_true: Box<Expression>, pub if_false: Box<Expression>, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A ternary conditional expression, that is, condition ? if_true : if_false.

Fields§

§condition: Box<Expression>

The condition determining which branch to pick.

§if_true: Box<Expression>

The branch the expression evaluates to if condition evaluates to true.

§if_false: Box<Expression>

The branch the expression evaluates to if condition evaluates to false.

-
§span: Span

The span from condition to if_false.

+
§span: Span

The span from condition to if_false.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for TernaryExpression

source§

fn clone(&self) -> TernaryExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for TernaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for TernaryExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TernaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TernaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TernaryExpression

source§

fn eq(&self, other: &TernaryExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TernaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TernaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TernaryExpression

source§

fn eq(&self, other: &TernaryExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for TernaryExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for TernaryExpression

source§

impl StructuralPartialEq for TernaryExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/tuple/struct.TupleExpression.html b/leo_ast/expressions/tuple/struct.TupleExpression.html index 3f94542eef..aac9fb87c2 100644 --- a/leo_ast/expressions/tuple/struct.TupleExpression.html +++ b/leo_ast/expressions/tuple/struct.TupleExpression.html @@ -1,14 +1,14 @@ TupleExpression in leo_ast::expressions::tuple - Rust

Struct leo_ast::expressions::tuple::TupleExpression

source ·
pub struct TupleExpression {
     pub elements: Vec<Expression>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A tuple expression, e.g., (foo, false, 42).

Fields§

§elements: Vec<Expression>

The elements of the tuple. In the example above, it would be foo, false, and 42.

-
§span: Span

The span from ( to ).

+
§span: Span

The span from ( to ).

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for TupleExpression

source§

fn clone(&self) -> TupleExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for TupleExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for TupleExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleExpression

source§

fn eq(&self, other: &TupleExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for TupleExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for TupleExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for TupleExpression

source§

fn eq(&self, other: &TupleExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for TupleExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for TupleExpression

source§

impl StructuralPartialEq for TupleExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/unary/enum.UnaryOperation.html b/leo_ast/expressions/unary/enum.UnaryOperation.html index 5a939710de..57b8373883 100644 --- a/leo_ast/expressions/unary/enum.UnaryOperation.html +++ b/leo_ast/expressions/unary/enum.UnaryOperation.html @@ -20,7 +20,7 @@
§

SquareRoot

Square root operation, i.e. .sqrt().

§

ToXCoordinate

Converts a group element to its x-coordinate, i.e. .to_x_coordinate().

§

ToYCoordinate

Converts a group element to its y-coordinate, i.e. .to_y_coordinate().

-

Implementations§

source§

impl UnaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a UnaryOperation from the given Symbol.

+

Implementations§

source§

impl UnaryOperation

source

pub fn from_symbol(symbol: Symbol) -> Option<Self>

Returns a UnaryOperation from the given Symbol.

source

fn as_str(self) -> &'static str

Represents the opera.tor as a string.

Trait Implementations§

source§

impl Clone for UnaryOperation

source§

fn clone(&self) -> UnaryOperation

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for UnaryOperation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for UnaryOperation

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for UnaryOperation

source§

fn eq(&self, other: &UnaryOperation) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/expressions/unary/struct.UnaryExpression.html b/leo_ast/expressions/unary/struct.UnaryExpression.html index 238c50190a..50d444924d 100644 --- a/leo_ast/expressions/unary/struct.UnaryExpression.html +++ b/leo_ast/expressions/unary/struct.UnaryExpression.html @@ -1,15 +1,15 @@ UnaryExpression in leo_ast::expressions::unary - Rust

Struct leo_ast::expressions::unary::UnaryExpression

source ·
pub struct UnaryExpression {
     pub receiver: Box<Expression>,
     pub op: UnaryOperation,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An unary expression applying an operator to an inner expression.

Fields§

§receiver: Box<Expression>

The inner expression op is applied to.

§op: UnaryOperation

The unary operator to apply to inner.

-
§span: Span

The span covering op inner.

+
§span: Span

The span covering op inner.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for UnaryExpression

source§

fn clone(&self) -> UnaryExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for UnaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for UnaryExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnaryExpression

source§

fn eq(&self, other: &UnaryExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnaryExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnaryExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnaryExpression

source§

fn eq(&self, other: &UnaryExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for UnaryExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for UnaryExpression

source§

impl StructuralPartialEq for UnaryExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/expressions/unit/struct.UnitExpression.html b/leo_ast/expressions/unit/struct.UnitExpression.html index 3155f24050..83f4b01570 100644 --- a/leo_ast/expressions/unit/struct.UnitExpression.html +++ b/leo_ast/expressions/unit/struct.UnitExpression.html @@ -1,11 +1,11 @@ UnitExpression in leo_ast::expressions::unit - Rust

Struct leo_ast::expressions::unit::UnitExpression

source ·
pub struct UnitExpression {
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

Represents a unit expression.

-

Fields§

§span: Span

The span of the unit expression.

+

Fields§

§span: Span

The span of the unit expression.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for UnitExpression

source§

fn clone(&self) -> UnitExpression

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for UnitExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for UnitExpression

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnitExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnitExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnitExpression

source§

fn eq(&self, other: &UnitExpression) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for UnitExpression

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for UnitExpression

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for UnitExpression

source§

fn eq(&self, other: &UnitExpression) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for UnitExpression

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for UnitExpression

source§

impl StructuralPartialEq for UnitExpression

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/functions/annotation/struct.Annotation.html b/leo_ast/functions/annotation/struct.Annotation.html index 0aa4eb178f..460a6b3235 100644 --- a/leo_ast/functions/annotation/struct.Annotation.html +++ b/leo_ast/functions/annotation/struct.Annotation.html @@ -1,13 +1,13 @@ Annotation in leo_ast::functions::annotation - Rust

Struct leo_ast::functions::annotation::Annotation

source ·
pub struct Annotation {
     pub identifier: Identifier,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An annotation, e.g. @program.

Fields§

§identifier: Identifier

The name of the annotation.

-
§span: Span

A span locating where the annotation occurred in the source.

+
§span: Span

A span locating where the annotation occurred in the source.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for Annotation

source§

fn clone(&self) -> Annotation

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Annotation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Annotation

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Annotation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Annotation

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Annotation

source§

fn eq(&self, other: &Annotation) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Annotation

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Annotation

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Annotation

source§

fn eq(&self, other: &Annotation) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Annotation

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Annotation

source§

impl StructuralPartialEq for Annotation

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/functions/core_function/enum.CoreFunction.html b/leo_ast/functions/core_function/enum.CoreFunction.html index ef5327a0c6..43f304ece9 100644 --- a/leo_ast/functions/core_function/enum.CoreFunction.html +++ b/leo_ast/functions/core_function/enum.CoreFunction.html @@ -252,7 +252,7 @@ SignatureVerify, FutureAwait,

}
Expand description

A core instruction that maps directly to an AVM bytecode instruction.

-

Variants§

§

BHP256CommitToAddress

§

BHP256CommitToField

§

BHP256CommitToGroup

§

BHP256HashToAddress

§

BHP256HashToField

§

BHP256HashToGroup

§

BHP256HashToI8

§

BHP256HashToI16

§

BHP256HashToI32

§

BHP256HashToI64

§

BHP256HashToI128

§

BHP256HashToU8

§

BHP256HashToU16

§

BHP256HashToU32

§

BHP256HashToU64

§

BHP256HashToU128

§

BHP256HashToScalar

§

BHP512CommitToAddress

§

BHP512CommitToField

§

BHP512CommitToGroup

§

BHP512HashToAddress

§

BHP512HashToField

§

BHP512HashToGroup

§

BHP512HashToI8

§

BHP512HashToI16

§

BHP512HashToI32

§

BHP512HashToI64

§

BHP512HashToI128

§

BHP512HashToU8

§

BHP512HashToU16

§

BHP512HashToU32

§

BHP512HashToU64

§

BHP512HashToU128

§

BHP512HashToScalar

§

BHP768CommitToAddress

§

BHP768CommitToField

§

BHP768CommitToGroup

§

BHP768HashToAddress

§

BHP768HashToField

§

BHP768HashToGroup

§

BHP768HashToI8

§

BHP768HashToI16

§

BHP768HashToI32

§

BHP768HashToI64

§

BHP768HashToI128

§

BHP768HashToU8

§

BHP768HashToU16

§

BHP768HashToU32

§

BHP768HashToU64

§

BHP768HashToU128

§

BHP768HashToScalar

§

BHP1024CommitToAddress

§

BHP1024CommitToField

§

BHP1024CommitToGroup

§

BHP1024HashToAddress

§

BHP1024HashToField

§

BHP1024HashToGroup

§

BHP1024HashToI8

§

BHP1024HashToI16

§

BHP1024HashToI32

§

BHP1024HashToI64

§

BHP1024HashToI128

§

BHP1024HashToU8

§

BHP1024HashToU16

§

BHP1024HashToU32

§

BHP1024HashToU64

§

BHP1024HashToU128

§

BHP1024HashToScalar

§

ChaChaRandAddress

§

ChaChaRandBool

§

ChaChaRandField

§

ChaChaRandGroup

§

ChaChaRandI8

§

ChaChaRandI16

§

ChaChaRandI32

§

ChaChaRandI64

§

ChaChaRandI128

§

ChaChaRandU8

§

ChaChaRandU16

§

ChaChaRandU32

§

ChaChaRandU64

§

ChaChaRandU128

§

ChaChaRandScalar

§

Keccak256HashToAddress

§

Keccak256HashToField

§

Keccak256HashToGroup

§

Keccak256HashToI8

§

Keccak256HashToI16

§

Keccak256HashToI32

§

Keccak256HashToI64

§

Keccak256HashToI128

§

Keccak256HashToU8

§

Keccak256HashToU16

§

Keccak256HashToU32

§

Keccak256HashToU64

§

Keccak256HashToU128

§

Keccak256HashToScalar

§

Keccak384HashToAddress

§

Keccak384HashToField

§

Keccak384HashToGroup

§

Keccak384HashToI8

§

Keccak384HashToI16

§

Keccak384HashToI32

§

Keccak384HashToI64

§

Keccak384HashToI128

§

Keccak384HashToU8

§

Keccak384HashToU16

§

Keccak384HashToU32

§

Keccak384HashToU64

§

Keccak384HashToU128

§

Keccak384HashToScalar

§

Keccak512HashToAddress

§

Keccak512HashToField

§

Keccak512HashToGroup

§

Keccak512HashToI8

§

Keccak512HashToI16

§

Keccak512HashToI32

§

Keccak512HashToI64

§

Keccak512HashToI128

§

Keccak512HashToU8

§

Keccak512HashToU16

§

Keccak512HashToU32

§

Keccak512HashToU64

§

Keccak512HashToU128

§

Keccak512HashToScalar

§

Pedersen64CommitToAddress

§

Pedersen64CommitToField

§

Pedersen64CommitToGroup

§

Pedersen64HashToAddress

§

Pedersen64HashToField

§

Pedersen64HashToGroup

§

Pedersen64HashToI8

§

Pedersen64HashToI16

§

Pedersen64HashToI32

§

Pedersen64HashToI64

§

Pedersen64HashToI128

§

Pedersen64HashToU8

§

Pedersen64HashToU16

§

Pedersen64HashToU32

§

Pedersen64HashToU64

§

Pedersen64HashToU128

§

Pedersen64HashToScalar

§

Pedersen128CommitToAddress

§

Pedersen128CommitToField

§

Pedersen128CommitToGroup

§

Pedersen128HashToAddress

§

Pedersen128HashToField

§

Pedersen128HashToGroup

§

Pedersen128HashToI8

§

Pedersen128HashToI16

§

Pedersen128HashToI32

§

Pedersen128HashToI64

§

Pedersen128HashToI128

§

Pedersen128HashToU8

§

Pedersen128HashToU16

§

Pedersen128HashToU32

§

Pedersen128HashToU64

§

Pedersen128HashToU128

§

Pedersen128HashToScalar

§

Poseidon2HashToAddress

§

Poseidon2HashToField

§

Poseidon2HashToGroup

§

Poseidon2HashToI8

§

Poseidon2HashToI16

§

Poseidon2HashToI32

§

Poseidon2HashToI64

§

Poseidon2HashToI128

§

Poseidon2HashToU8

§

Poseidon2HashToU16

§

Poseidon2HashToU32

§

Poseidon2HashToU64

§

Poseidon2HashToU128

§

Poseidon2HashToScalar

§

Poseidon4HashToAddress

§

Poseidon4HashToField

§

Poseidon4HashToGroup

§

Poseidon4HashToI8

§

Poseidon4HashToI16

§

Poseidon4HashToI32

§

Poseidon4HashToI64

§

Poseidon4HashToI128

§

Poseidon4HashToU8

§

Poseidon4HashToU16

§

Poseidon4HashToU32

§

Poseidon4HashToU64

§

Poseidon4HashToU128

§

Poseidon4HashToScalar

§

Poseidon8HashToAddress

§

Poseidon8HashToField

§

Poseidon8HashToGroup

§

Poseidon8HashToI8

§

Poseidon8HashToI16

§

Poseidon8HashToI32

§

Poseidon8HashToI64

§

Poseidon8HashToI128

§

Poseidon8HashToU8

§

Poseidon8HashToU16

§

Poseidon8HashToU32

§

Poseidon8HashToU64

§

Poseidon8HashToU128

§

Poseidon8HashToScalar

§

SHA3_256HashToAddress

§

SHA3_256HashToField

§

SHA3_256HashToGroup

§

SHA3_256HashToI8

§

SHA3_256HashToI16

§

SHA3_256HashToI32

§

SHA3_256HashToI64

§

SHA3_256HashToI128

§

SHA3_256HashToU8

§

SHA3_256HashToU16

§

SHA3_256HashToU32

§

SHA3_256HashToU64

§

SHA3_256HashToU128

§

SHA3_256HashToScalar

§

SHA3_384HashToAddress

§

SHA3_384HashToField

§

SHA3_384HashToGroup

§

SHA3_384HashToI8

§

SHA3_384HashToI16

§

SHA3_384HashToI32

§

SHA3_384HashToI64

§

SHA3_384HashToI128

§

SHA3_384HashToU8

§

SHA3_384HashToU16

§

SHA3_384HashToU32

§

SHA3_384HashToU64

§

SHA3_384HashToU128

§

SHA3_384HashToScalar

§

SHA3_512HashToAddress

§

SHA3_512HashToField

§

SHA3_512HashToGroup

§

SHA3_512HashToI8

§

SHA3_512HashToI16

§

SHA3_512HashToI32

§

SHA3_512HashToI64

§

SHA3_512HashToI128

§

SHA3_512HashToU8

§

SHA3_512HashToU16

§

SHA3_512HashToU32

§

SHA3_512HashToU64

§

SHA3_512HashToU128

§

SHA3_512HashToScalar

§

MappingGet

§

MappingGetOrUse

§

MappingSet

§

MappingRemove

§

MappingContains

§

GroupToXCoordinate

§

GroupToYCoordinate

§

SignatureVerify

§

FutureAwait

Implementations§

source§

impl CoreFunction

source

pub fn from_symbols(module: Symbol, function: Symbol) -> Option<Self>

Returns a CoreFunction from the given module and method symbols.

+

Variants§

§

BHP256CommitToAddress

§

BHP256CommitToField

§

BHP256CommitToGroup

§

BHP256HashToAddress

§

BHP256HashToField

§

BHP256HashToGroup

§

BHP256HashToI8

§

BHP256HashToI16

§

BHP256HashToI32

§

BHP256HashToI64

§

BHP256HashToI128

§

BHP256HashToU8

§

BHP256HashToU16

§

BHP256HashToU32

§

BHP256HashToU64

§

BHP256HashToU128

§

BHP256HashToScalar

§

BHP512CommitToAddress

§

BHP512CommitToField

§

BHP512CommitToGroup

§

BHP512HashToAddress

§

BHP512HashToField

§

BHP512HashToGroup

§

BHP512HashToI8

§

BHP512HashToI16

§

BHP512HashToI32

§

BHP512HashToI64

§

BHP512HashToI128

§

BHP512HashToU8

§

BHP512HashToU16

§

BHP512HashToU32

§

BHP512HashToU64

§

BHP512HashToU128

§

BHP512HashToScalar

§

BHP768CommitToAddress

§

BHP768CommitToField

§

BHP768CommitToGroup

§

BHP768HashToAddress

§

BHP768HashToField

§

BHP768HashToGroup

§

BHP768HashToI8

§

BHP768HashToI16

§

BHP768HashToI32

§

BHP768HashToI64

§

BHP768HashToI128

§

BHP768HashToU8

§

BHP768HashToU16

§

BHP768HashToU32

§

BHP768HashToU64

§

BHP768HashToU128

§

BHP768HashToScalar

§

BHP1024CommitToAddress

§

BHP1024CommitToField

§

BHP1024CommitToGroup

§

BHP1024HashToAddress

§

BHP1024HashToField

§

BHP1024HashToGroup

§

BHP1024HashToI8

§

BHP1024HashToI16

§

BHP1024HashToI32

§

BHP1024HashToI64

§

BHP1024HashToI128

§

BHP1024HashToU8

§

BHP1024HashToU16

§

BHP1024HashToU32

§

BHP1024HashToU64

§

BHP1024HashToU128

§

BHP1024HashToScalar

§

ChaChaRandAddress

§

ChaChaRandBool

§

ChaChaRandField

§

ChaChaRandGroup

§

ChaChaRandI8

§

ChaChaRandI16

§

ChaChaRandI32

§

ChaChaRandI64

§

ChaChaRandI128

§

ChaChaRandU8

§

ChaChaRandU16

§

ChaChaRandU32

§

ChaChaRandU64

§

ChaChaRandU128

§

ChaChaRandScalar

§

Keccak256HashToAddress

§

Keccak256HashToField

§

Keccak256HashToGroup

§

Keccak256HashToI8

§

Keccak256HashToI16

§

Keccak256HashToI32

§

Keccak256HashToI64

§

Keccak256HashToI128

§

Keccak256HashToU8

§

Keccak256HashToU16

§

Keccak256HashToU32

§

Keccak256HashToU64

§

Keccak256HashToU128

§

Keccak256HashToScalar

§

Keccak384HashToAddress

§

Keccak384HashToField

§

Keccak384HashToGroup

§

Keccak384HashToI8

§

Keccak384HashToI16

§

Keccak384HashToI32

§

Keccak384HashToI64

§

Keccak384HashToI128

§

Keccak384HashToU8

§

Keccak384HashToU16

§

Keccak384HashToU32

§

Keccak384HashToU64

§

Keccak384HashToU128

§

Keccak384HashToScalar

§

Keccak512HashToAddress

§

Keccak512HashToField

§

Keccak512HashToGroup

§

Keccak512HashToI8

§

Keccak512HashToI16

§

Keccak512HashToI32

§

Keccak512HashToI64

§

Keccak512HashToI128

§

Keccak512HashToU8

§

Keccak512HashToU16

§

Keccak512HashToU32

§

Keccak512HashToU64

§

Keccak512HashToU128

§

Keccak512HashToScalar

§

Pedersen64CommitToAddress

§

Pedersen64CommitToField

§

Pedersen64CommitToGroup

§

Pedersen64HashToAddress

§

Pedersen64HashToField

§

Pedersen64HashToGroup

§

Pedersen64HashToI8

§

Pedersen64HashToI16

§

Pedersen64HashToI32

§

Pedersen64HashToI64

§

Pedersen64HashToI128

§

Pedersen64HashToU8

§

Pedersen64HashToU16

§

Pedersen64HashToU32

§

Pedersen64HashToU64

§

Pedersen64HashToU128

§

Pedersen64HashToScalar

§

Pedersen128CommitToAddress

§

Pedersen128CommitToField

§

Pedersen128CommitToGroup

§

Pedersen128HashToAddress

§

Pedersen128HashToField

§

Pedersen128HashToGroup

§

Pedersen128HashToI8

§

Pedersen128HashToI16

§

Pedersen128HashToI32

§

Pedersen128HashToI64

§

Pedersen128HashToI128

§

Pedersen128HashToU8

§

Pedersen128HashToU16

§

Pedersen128HashToU32

§

Pedersen128HashToU64

§

Pedersen128HashToU128

§

Pedersen128HashToScalar

§

Poseidon2HashToAddress

§

Poseidon2HashToField

§

Poseidon2HashToGroup

§

Poseidon2HashToI8

§

Poseidon2HashToI16

§

Poseidon2HashToI32

§

Poseidon2HashToI64

§

Poseidon2HashToI128

§

Poseidon2HashToU8

§

Poseidon2HashToU16

§

Poseidon2HashToU32

§

Poseidon2HashToU64

§

Poseidon2HashToU128

§

Poseidon2HashToScalar

§

Poseidon4HashToAddress

§

Poseidon4HashToField

§

Poseidon4HashToGroup

§

Poseidon4HashToI8

§

Poseidon4HashToI16

§

Poseidon4HashToI32

§

Poseidon4HashToI64

§

Poseidon4HashToI128

§

Poseidon4HashToU8

§

Poseidon4HashToU16

§

Poseidon4HashToU32

§

Poseidon4HashToU64

§

Poseidon4HashToU128

§

Poseidon4HashToScalar

§

Poseidon8HashToAddress

§

Poseidon8HashToField

§

Poseidon8HashToGroup

§

Poseidon8HashToI8

§

Poseidon8HashToI16

§

Poseidon8HashToI32

§

Poseidon8HashToI64

§

Poseidon8HashToI128

§

Poseidon8HashToU8

§

Poseidon8HashToU16

§

Poseidon8HashToU32

§

Poseidon8HashToU64

§

Poseidon8HashToU128

§

Poseidon8HashToScalar

§

SHA3_256HashToAddress

§

SHA3_256HashToField

§

SHA3_256HashToGroup

§

SHA3_256HashToI8

§

SHA3_256HashToI16

§

SHA3_256HashToI32

§

SHA3_256HashToI64

§

SHA3_256HashToI128

§

SHA3_256HashToU8

§

SHA3_256HashToU16

§

SHA3_256HashToU32

§

SHA3_256HashToU64

§

SHA3_256HashToU128

§

SHA3_256HashToScalar

§

SHA3_384HashToAddress

§

SHA3_384HashToField

§

SHA3_384HashToGroup

§

SHA3_384HashToI8

§

SHA3_384HashToI16

§

SHA3_384HashToI32

§

SHA3_384HashToI64

§

SHA3_384HashToI128

§

SHA3_384HashToU8

§

SHA3_384HashToU16

§

SHA3_384HashToU32

§

SHA3_384HashToU64

§

SHA3_384HashToU128

§

SHA3_384HashToScalar

§

SHA3_512HashToAddress

§

SHA3_512HashToField

§

SHA3_512HashToGroup

§

SHA3_512HashToI8

§

SHA3_512HashToI16

§

SHA3_512HashToI32

§

SHA3_512HashToI64

§

SHA3_512HashToI128

§

SHA3_512HashToU8

§

SHA3_512HashToU16

§

SHA3_512HashToU32

§

SHA3_512HashToU64

§

SHA3_512HashToU128

§

SHA3_512HashToScalar

§

MappingGet

§

MappingGetOrUse

§

MappingSet

§

MappingRemove

§

MappingContains

§

GroupToXCoordinate

§

GroupToYCoordinate

§

SignatureVerify

§

FutureAwait

Implementations§

source§

impl CoreFunction

source

pub fn from_symbols(module: Symbol, function: Symbol) -> Option<Self>

Returns a CoreFunction from the given module and method symbols.

source

pub fn num_args(&self) -> usize

Returns the number of arguments required by the instruction.

source

pub fn is_finalize_command(&self) -> bool

Returns whether or not this function is finalize command.

Trait Implementations§

source§

impl Clone for CoreFunction

source§

fn clone(&self) -> CoreFunction

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl PartialEq for CoreFunction

source§

fn eq(&self, other: &CoreFunction) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/functions/input/struct.Input.html b/leo_ast/functions/input/struct.Input.html index c11a6fc3e8..cdde1918d1 100644 --- a/leo_ast/functions/input/struct.Input.html +++ b/leo_ast/functions/input/struct.Input.html @@ -2,16 +2,16 @@ pub identifier: Identifier, pub mode: Mode, pub type_: Type, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A function parameter.

Fields§

§identifier: Identifier

The name the parameter is accessible as in the function’s body.

§mode: Mode

The mode of the function parameter.

§type_: Type

What’s the parameter’s type?

-
§span: Span

The parameters span from any annotations to its type.

+
§span: Span

The parameters span from any annotations to its type.

§id: NodeID

The ID of the node.

Implementations§

source§

impl Input

source

fn format(&self, f: &mut Formatter<'_>) -> Result

source

pub fn identifier(&self) -> &Identifier

source

pub fn mode(&self) -> Mode

source

pub fn type_(&self) -> &Type

Trait Implementations§

source§

impl Clone for Input

source§

fn clone(&self) -> Input

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Input

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Input

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Input

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Input

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Input

source§

fn eq(&self, other: &Input) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Input

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Input

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Input

source§

fn eq(&self, other: &Input) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Input

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Input

source§

impl StructuralPartialEq for Input

Auto Trait Implementations§

§

impl Freeze for Input

§

impl RefUnwindSafe for Input

§

impl Send for Input

§

impl Sync for Input

§

impl Unpin for Input

§

impl UnwindSafe for Input

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/functions/output/struct.Output.html b/leo_ast/functions/output/struct.Output.html index 8da8140c9b..6ef6524f43 100644 --- a/leo_ast/functions/output/struct.Output.html +++ b/leo_ast/functions/output/struct.Output.html @@ -1,15 +1,15 @@ Output in leo_ast::functions::output - Rust

Struct leo_ast::functions::output::Output

source ·
pub struct Output {
     pub mode: Mode,
     pub type_: Type,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A function output.

Fields§

§mode: Mode

The mode of the function output.

§type_: Type

The type of the function output.

-
§span: Span

The parameters span from any annotations to its type.

+
§span: Span

The parameters span from any annotations to its type.

§id: NodeID

The ID of the node.

Implementations§

source§

impl Output

source

pub fn type_(&self) -> &Type

source

pub fn mode(&self) -> Mode

Trait Implementations§

source§

impl Clone for Output

source§

fn clone(&self) -> Output

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Output

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Output

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Output

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Output

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Output

source§

fn eq(&self, other: &Output) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Output

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Output

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Output

source§

fn eq(&self, other: &Output) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Output

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Output

source§

impl StructuralPartialEq for Output

Auto Trait Implementations§

§

impl Freeze for Output

§

impl RefUnwindSafe for Output

§

impl Send for Output

§

impl Sync for Output

§

impl Unpin for Output

§

impl UnwindSafe for Output

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/functions/struct.Function.html b/leo_ast/functions/struct.Function.html index 864f4e5dab..1e57940325 100644 --- a/leo_ast/functions/struct.Function.html +++ b/leo_ast/functions/struct.Function.html @@ -6,7 +6,7 @@ pub output: Vec<Output>, pub output_type: Type, pub block: Block, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A function definition.

Fields§

§annotations: Vec<Annotation>

Annotations on the function.

@@ -16,7 +16,7 @@
§output: Vec<Output>

The function’s output declarations.

§output_type: Type

The function’s output type.

§block: Block

The body of the function.

-
§span: Span

The entire span of the function definition.

+
§span: Span

The entire span of the function definition.

§id: NodeID

The ID of the node.

Implementations§

source§

impl Function

source

pub fn new( annotations: Vec<Annotation>, @@ -25,13 +25,13 @@ input: Vec<Input>, output: Vec<Output>, block: Block, - span: Span, + span: Span, id: NodeID, ) -> Self

Initialize a new function.

-
source

pub fn name(&self) -> Symbol

Returns function name.

+
source

pub fn name(&self) -> Symbol

Returns function name.

source

fn format(&self, f: &mut Formatter<'_>) -> Result

Private formatting method used for optimizing fmt::Debug and fmt::Display implementations.

Trait Implementations§

source§

impl Clone for Function

source§

fn clone(&self) -> Function

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Function

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Function

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Function

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Function> for FunctionStub

source§

fn from(function: Function) -> Self

Converts to this type from the input type.
source§

impl From<FunctionStub> for Function

source§

fn from(function: FunctionStub) -> Self

Converts to this type from the input type.
source§

impl Node for Function

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Function

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Function

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Function> for FunctionStub

source§

fn from(function: Function) -> Self

Converts to this type from the input type.
source§

impl From<FunctionStub> for Function

source§

fn from(function: FunctionStub) -> Self

Converts to this type from the input type.
source§

impl Node for Function

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Function

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Function

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Function

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/groups/group_coordinate/enum.GroupCoordinate.html b/leo_ast/groups/group_coordinate/enum.GroupCoordinate.html index c7f1602edf..82fc300c0b 100644 --- a/leo_ast/groups/group_coordinate/enum.GroupCoordinate.html +++ b/leo_ast/groups/group_coordinate/enum.GroupCoordinate.html @@ -1,10 +1,10 @@ GroupCoordinate in leo_ast::groups::group_coordinate - Rust

Enum leo_ast::groups::group_coordinate::GroupCoordinate

source ·
pub enum GroupCoordinate {
-    Number(String, Span),
+    Number(String, Span),
     SignHigh,
     SignLow,
     Inferred,
 }
Expand description

A coordinate in a affine group literal.

-

Variants§

§

Number(String, Span)

A number, e.g., 42.

+

Variants§

§

Number(String, Span)

A number, e.g., 42.

§

SignHigh

A sign high recovery, i.e. +.

§

SignLow

A sign low recovery, i.e., -.

§

Inferred

Recovery with an inferred value.

diff --git a/leo_ast/groups/group_literal/enum.GroupLiteral.html b/leo_ast/groups/group_literal/enum.GroupLiteral.html index c86fbc485c..c17466049c 100644 --- a/leo_ast/groups/group_literal/enum.GroupLiteral.html +++ b/leo_ast/groups/group_literal/enum.GroupLiteral.html @@ -1,10 +1,10 @@ GroupLiteral in leo_ast::groups::group_literal - Rust

Enum leo_ast::groups::group_literal::GroupLiteral

source ·
pub enum GroupLiteral {
-    Single(String, Span, NodeID),
+    Single(String, Span, NodeID),
     Tuple(GroupTuple),
 }
Expand description

A group literal.

-

Variants§

§

Single(String, Span, NodeID)

Product group literal, e.g., 42group.

+

Variants§

§

Single(String, Span, NodeID)

Product group literal, e.g., 42group.

§

Tuple(GroupTuple)

An affine group literal with (x, y) coordinates.

-

Implementations§

source§

impl GroupLiteral

source

pub fn set_span(&mut self, new_span: Span)

source

pub fn span(&self) -> &Span

source

pub fn id(&self) -> &NodeID

source

pub fn set_id(&mut self, id: NodeID)

Trait Implementations§

source§

impl Clone for GroupLiteral

source§

fn clone(&self) -> GroupLiteral

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for GroupLiteral

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for GroupLiteral

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +

Implementations§

source§

impl GroupLiteral

source

pub fn set_span(&mut self, new_span: Span)

source

pub fn span(&self) -> &Span

source

pub fn id(&self) -> &NodeID

source

pub fn set_id(&mut self, id: NodeID)

Trait Implementations§

source§

impl Clone for GroupLiteral

source§

fn clone(&self) -> GroupLiteral

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for GroupLiteral

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for GroupLiteral

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for GroupLiteral

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for GroupLiteral

source§

fn eq(&self, other: &GroupLiteral) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for GroupLiteral

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where diff --git a/leo_ast/groups/group_literal/struct.GroupTuple.html b/leo_ast/groups/group_literal/struct.GroupTuple.html index 24af113bb9..5e1491e43b 100644 --- a/leo_ast/groups/group_literal/struct.GroupTuple.html +++ b/leo_ast/groups/group_literal/struct.GroupTuple.html @@ -1,12 +1,12 @@ GroupTuple in leo_ast::groups::group_literal - Rust

Struct leo_ast::groups::group_literal::GroupTuple

source ·
pub struct GroupTuple {
     pub x: GroupCoordinate,
     pub y: GroupCoordinate,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An affine group literal, e.g., (42, 24)group.

Fields§

§x: GroupCoordinate

The left component of the type, e.g., 42 in the case above.

§y: GroupCoordinate

The right component of the type, e.g., 24 in the case above.

-
§span: Span

The span from ( to ).

+
§span: Span

The span from ( to ).

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for GroupTuple

source§

fn clone(&self) -> GroupTuple

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for GroupTuple

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for GroupTuple

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for GroupTuple

source§

fn eq(&self, other: &GroupTuple) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/mapping/struct.Mapping.html b/leo_ast/mapping/struct.Mapping.html index 2e46808ed5..40b43e63dd 100644 --- a/leo_ast/mapping/struct.Mapping.html +++ b/leo_ast/mapping/struct.Mapping.html @@ -2,16 +2,16 @@ pub identifier: Identifier, pub key_type: Type, pub value_type: Type, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A mapping declaration, e.g mapping balances: address => u128.

Fields§

§identifier: Identifier

The name of the mapping.

§key_type: Type

The type of the key.

§value_type: Type

The type of the value.

-
§span: Span

The entire span of the mapping declaration.

+
§span: Span

The entire span of the mapping declaration.

§id: NodeID

The ID of the node.

Implementations§

source§

impl Mapping

source

pub fn from_snarkvm<N: Network>(mapping: &MappingCore<N>) -> Self

Trait Implementations§

source§

impl Clone for Mapping

source§

fn clone(&self) -> Mapping

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Mapping

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Mapping

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Mapping

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Mapping

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Mapping

source§

fn eq(&self, other: &Mapping) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Mapping

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Mapping

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Mapping

source§

fn eq(&self, other: &Mapping) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Mapping

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Mapping

source§

impl StructuralPartialEq for Mapping

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/program/program_scope/struct.ProgramScope.html b/leo_ast/program/program_scope/struct.ProgramScope.html index 4b6af0c8e1..91f1443c6b 100644 --- a/leo_ast/program/program_scope/struct.ProgramScope.html +++ b/leo_ast/program/program_scope/struct.ProgramScope.html @@ -1,17 +1,17 @@ ProgramScope in leo_ast::program::program_scope - Rust

Struct leo_ast::program::program_scope::ProgramScope

source ·
pub struct ProgramScope {
     pub program_id: ProgramId,
-    pub consts: Vec<(Symbol, ConstDeclaration)>,
-    pub structs: Vec<(Symbol, Composite)>,
-    pub mappings: Vec<(Symbol, Mapping)>,
-    pub functions: Vec<(Symbol, Function)>,
-    pub span: Span,
+    pub consts: Vec<(Symbol, ConstDeclaration)>,
+    pub structs: Vec<(Symbol, Composite)>,
+    pub mappings: Vec<(Symbol, Mapping)>,
+    pub functions: Vec<(Symbol, Function)>,
+    pub span: Span,
 }
Expand description

Stores the Leo program scope abstract syntax tree.

Fields§

§program_id: ProgramId

The program id of the program scope.

-
§consts: Vec<(Symbol, ConstDeclaration)>

A vector of const definitions

-
§structs: Vec<(Symbol, Composite)>

A vector of struct definitions.

-
§mappings: Vec<(Symbol, Mapping)>

A vector of mapping definitions.

-
§functions: Vec<(Symbol, Function)>

A vector of function definitions.

-
§span: Span

The span associated with the program scope.

+
§consts: Vec<(Symbol, ConstDeclaration)>

A vector of const definitions

+
§structs: Vec<(Symbol, Composite)>

A vector of struct definitions.

+
§mappings: Vec<(Symbol, Mapping)>

A vector of mapping definitions.

+
§functions: Vec<(Symbol, Function)>

A vector of function definitions.

+
§span: Span

The span associated with the program scope.

Trait Implementations§

source§

impl Clone for ProgramScope

source§

fn clone(&self) -> ProgramScope

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ProgramScope

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ProgramScope

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ProgramScope

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Stub> for ProgramScope

source§

fn from(stub: Stub) -> Self

Converts to this type from the input type.
source§

impl PartialEq for ProgramScope

source§

fn eq(&self, other: &ProgramScope) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always diff --git a/leo_ast/program/struct.Program.html b/leo_ast/program/struct.Program.html index 2b2f8873ee..8862f2229b 100644 --- a/leo_ast/program/struct.Program.html +++ b/leo_ast/program/struct.Program.html @@ -1,11 +1,11 @@ Program in leo_ast::program - Rust

Struct leo_ast::program::Program

source ·
pub struct Program {
-    pub imports: IndexMap<Symbol, (Program, Span)>,
-    pub stubs: IndexMap<Symbol, Stub>,
-    pub program_scopes: IndexMap<Symbol, ProgramScope>,
+    pub imports: IndexMap<Symbol, (Program, Span)>,
+    pub stubs: IndexMap<Symbol, Stub>,
+    pub program_scopes: IndexMap<Symbol, ProgramScope>,
 }
Expand description

Stores the Leo program abstract syntax tree.

-

Fields§

§imports: IndexMap<Symbol, (Program, Span)>

A map from import names to import definitions.

-
§stubs: IndexMap<Symbol, Stub>

A map from program stub names to program stub scopes.

-
§program_scopes: IndexMap<Symbol, ProgramScope>

A map from program names to program scopes.

+

Fields§

§imports: IndexMap<Symbol, (Program, Span)>

A map from import names to import definitions.

+
§stubs: IndexMap<Symbol, Stub>

A map from program stub names to program stub scopes.

+
§program_scopes: IndexMap<Symbol, ProgramScope>

A map from program names to program scopes.

Trait Implementations§

source§

impl AsRef<Program> for Ast

source§

fn as_ref(&self) -> &Program

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Program

source§

fn clone(&self) -> Program

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Program

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Program

source§

fn default() -> Self

Constructs an empty program node.

source§

impl<'de> Deserialize<'de> for Program

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Program

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for Program

source§

fn eq(&self, other: &Program) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/statement/assert/struct.AssertStatement.html b/leo_ast/statement/assert/struct.AssertStatement.html index d1b4decec2..8b3eb2cbb1 100644 --- a/leo_ast/statement/assert/struct.AssertStatement.html +++ b/leo_ast/statement/assert/struct.AssertStatement.html @@ -1,13 +1,13 @@ AssertStatement in leo_ast::statement::assert - Rust

Struct leo_ast::statement::assert::AssertStatement

source ·
pub struct AssertStatement {
     pub variant: AssertVariant,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An assert statement, assert(<expr>), assert_eq(<expr>) or assert_neq(<expr>).

Fields§

§variant: AssertVariant

The variant of the assert statement.

-
§span: Span

The span, excluding the semicolon.

+
§span: Span

The span, excluding the semicolon.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for AssertStatement

source§

fn clone(&self) -> AssertStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AssertStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AssertStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssertStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssertStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssertStatement

source§

fn eq(&self, other: &AssertStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssertStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssertStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssertStatement

source§

fn eq(&self, other: &AssertStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AssertStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AssertStatement

source§

impl StructuralPartialEq for AssertStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/assign/struct.AssignStatement.html b/leo_ast/statement/assign/struct.AssignStatement.html index f18b6f2a4f..d29223274a 100644 --- a/leo_ast/statement/assign/struct.AssignStatement.html +++ b/leo_ast/statement/assign/struct.AssignStatement.html @@ -1,17 +1,17 @@ AssignStatement in leo_ast::statement::assign - Rust

Struct leo_ast::statement::assign::AssignStatement

source ·
pub struct AssignStatement {
     pub place: Expression,
     pub value: Expression,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An assignment statement, assignee = value. Note that there is no operation associated with the assignment.

Fields§

§place: Expression

The place to assign to. Note that place can either be an identifier or tuple.

§value: Expression

The value to assign to the assignee.

-
§span: Span

The span, excluding the semicolon.

+
§span: Span

The span, excluding the semicolon.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for AssignStatement

source§

fn clone(&self) -> AssignStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for AssignStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for AssignStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssignStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssignStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssignStatement

source§

fn eq(&self, other: &AssignStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for AssignStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for AssignStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for AssignStatement

source§

fn eq(&self, other: &AssignStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for AssignStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for AssignStatement

source§

impl StructuralPartialEq for AssignStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/block/struct.Block.html b/leo_ast/statement/block/struct.Block.html index ad90cf0c0c..e485777783 100644 --- a/leo_ast/statement/block/struct.Block.html +++ b/leo_ast/statement/block/struct.Block.html @@ -1,13 +1,13 @@ Block in leo_ast::statement::block - Rust

Struct leo_ast::statement::block::Block

source ·
pub struct Block {
     pub statements: Vec<Statement>,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A block { [stmt]* } consisting of a list of statements to execute in order.

Fields§

§statements: Vec<Statement>

The list of statements to execute.

-
§span: Span

The span from { to }.

+
§span: Span

The span from { to }.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for Block

source§

fn clone(&self) -> Block

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Block

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Block

source§

fn default() -> Block

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

impl<'de> Deserialize<'de> for Block

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Block

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Block

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Block

source§

fn eq(&self, other: &Block) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Block

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Block

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Block

source§

fn eq(&self, other: &Block) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Block

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Block

source§

impl StructuralPartialEq for Block

Auto Trait Implementations§

§

impl Freeze for Block

§

impl !RefUnwindSafe for Block

§

impl Send for Block

§

impl !Sync for Block

§

impl Unpin for Block

§

impl UnwindSafe for Block

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/conditional/struct.ConditionalStatement.html b/leo_ast/statement/conditional/struct.ConditionalStatement.html index 43b39c06eb..2a865a943b 100644 --- a/leo_ast/statement/conditional/struct.ConditionalStatement.html +++ b/leo_ast/statement/conditional/struct.ConditionalStatement.html @@ -2,16 +2,16 @@ pub condition: Expression, pub then: Block, pub otherwise: Option<Box<Statement>>, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

An if condition block (else next)? statement.

Fields§

§condition: Expression

The bool-typed condition deciding what to evaluate.

§then: Block

The block to evaluate in case condition yields true.

§otherwise: Option<Box<Statement>>

The statement, if any, to evaluate when condition yields false.

-
§span: Span

The span from if to next or to block.

+
§span: Span

The span from if to next or to block.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ConditionalStatement

source§

fn clone(&self) -> ConditionalStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ConditionalStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ConditionalStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ConditionalStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ConditionalStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ConditionalStatement

source§

fn eq(&self, other: &ConditionalStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ConditionalStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ConditionalStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ConditionalStatement

source§

fn eq(&self, other: &ConditionalStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ConditionalStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ConditionalStatement

source§

impl StructuralPartialEq for ConditionalStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/console/console_statement/struct.ConsoleStatement.html b/leo_ast/statement/console/console_statement/struct.ConsoleStatement.html index e19524075a..028300413f 100644 --- a/leo_ast/statement/console/console_statement/struct.ConsoleStatement.html +++ b/leo_ast/statement/console/console_statement/struct.ConsoleStatement.html @@ -1,13 +1,13 @@ ConsoleStatement in leo_ast::statement::console::console_statement - Rust
pub struct ConsoleStatement {
     pub function: ConsoleFunction,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A console logging statement like console.log(...);.

Fields§

§function: ConsoleFunction

The logging function to run.

-
§span: Span

The span excluding the semicolon.

+
§span: Span

The span excluding the semicolon.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ConsoleStatement

source§

fn clone(&self) -> ConsoleStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ConsoleStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ConsoleStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ConsoleStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ConsoleStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ConsoleStatement

source§

fn eq(&self, other: &ConsoleStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ConsoleStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ConsoleStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ConsoleStatement

source§

fn eq(&self, other: &ConsoleStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ConsoleStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ConsoleStatement

source§

impl StructuralPartialEq for ConsoleStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/const_/struct.ConstDeclaration.html b/leo_ast/statement/const_/struct.ConstDeclaration.html index 1a081ab958..59be5af275 100644 --- a/leo_ast/statement/const_/struct.ConstDeclaration.html +++ b/leo_ast/statement/const_/struct.ConstDeclaration.html @@ -2,16 +2,16 @@ pub place: Identifier, pub type_: Type, pub value: Expression, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A constant declaration statement.

Fields§

§place: Identifier

The place to assign to. As opposed to DefinitionStatement, this can only be an identifier

§type_: Type

The type of the binding, if specified, or inferred otherwise.

§value: Expression

An initializer value for the binding.

-
§span: Span

The span excluding the semicolon.

+
§span: Span

The span excluding the semicolon.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ConstDeclaration

source§

fn clone(&self) -> ConstDeclaration

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ConstDeclaration

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ConstDeclaration

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ConstDeclaration

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ConstDeclaration

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ConstDeclaration

source§

fn eq(&self, other: &ConstDeclaration) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ConstDeclaration

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ConstDeclaration

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ConstDeclaration

source§

fn eq(&self, other: &ConstDeclaration) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ConstDeclaration

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ConstDeclaration

source§

impl StructuralPartialEq for ConstDeclaration

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/definition/struct.DefinitionStatement.html b/leo_ast/statement/definition/struct.DefinitionStatement.html index 350357071d..ed53cb3ef4 100644 --- a/leo_ast/statement/definition/struct.DefinitionStatement.html +++ b/leo_ast/statement/definition/struct.DefinitionStatement.html @@ -3,17 +3,17 @@ pub place: Expression, pub type_: Type, pub value: Expression, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A let or const declaration statement.

Fields§

§declaration_type: DeclarationType

What sort of declaration is this? let or const?.

§place: Expression

The bindings / variable names to declare.

§type_: Type

The types of the bindings, if specified, or inferred otherwise.

§value: Expression

An initializer value for the bindings.

-
§span: Span

The span excluding the semicolon.

+
§span: Span

The span excluding the semicolon.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for DefinitionStatement

source§

fn clone(&self) -> DefinitionStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for DefinitionStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for DefinitionStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for DefinitionStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for DefinitionStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for DefinitionStatement

source§

fn eq(&self, other: &DefinitionStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for DefinitionStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for DefinitionStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for DefinitionStatement

source§

fn eq(&self, other: &DefinitionStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for DefinitionStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for DefinitionStatement

source§

impl StructuralPartialEq for DefinitionStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/enum.Statement.html b/leo_ast/statement/enum.Statement.html index b16af756d2..fd70c056b9 100644 --- a/leo_ast/statement/enum.Statement.html +++ b/leo_ast/statement/enum.Statement.html @@ -20,9 +20,9 @@
§

Expression(ExpressionStatement)

An expression statement

§

Iteration(Box<IterationStatement>)

A for statement.

§

Return(ReturnStatement)

A return statement return expr;.

-

Implementations§

source§

impl Statement

source

pub fn dummy(span: Span, id: NodeID) -> Self

Returns a dummy statement made from an empty block {}.

+

Implementations§

source§

impl Statement

source

pub fn dummy(span: Span, id: NodeID) -> Self

Returns a dummy statement made from an empty block {}.

Trait Implementations§

source§

impl Clone for Statement

source§

fn clone(&self) -> Statement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Statement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Statement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Statement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Statement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Statement

source§

fn eq(&self, other: &Statement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Statement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Statement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Statement

source§

fn eq(&self, other: &Statement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Statement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Statement

source§

impl StructuralPartialEq for Statement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/expression/struct.ExpressionStatement.html b/leo_ast/statement/expression/struct.ExpressionStatement.html index dd50731b6d..0534a19d95 100644 --- a/leo_ast/statement/expression/struct.ExpressionStatement.html +++ b/leo_ast/statement/expression/struct.ExpressionStatement.html @@ -1,13 +1,13 @@ ExpressionStatement in leo_ast::statement::expression - Rust

Struct leo_ast::statement::expression::ExpressionStatement

source ·
pub struct ExpressionStatement {
     pub expression: Expression,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

An expression statement, foo(a);.

Fields§

§expression: Expression

The expression associated with the statement.

-
§span: Span

The span.

+
§span: Span

The span.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ExpressionStatement

source§

fn clone(&self) -> ExpressionStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ExpressionStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ExpressionStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ExpressionStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ExpressionStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ExpressionStatement

source§

fn eq(&self, other: &ExpressionStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ExpressionStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ExpressionStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ExpressionStatement

source§

fn eq(&self, other: &ExpressionStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ExpressionStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ExpressionStatement

source§

impl StructuralPartialEq for ExpressionStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/iteration/struct.IterationStatement.html b/leo_ast/statement/iteration/struct.IterationStatement.html index 289de30a2a..d5a19d9ccd 100644 --- a/leo_ast/statement/iteration/struct.IterationStatement.html +++ b/leo_ast/statement/iteration/struct.IterationStatement.html @@ -7,7 +7,7 @@ pub stop_value: RefCell<Option<Value>>, pub inclusive: bool, pub block: Block, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A bounded for loop statement for variable in start .. =? stop block.

Fields§

§variable: Identifier

The binding / variable to introduce in the body block.

@@ -19,10 +19,10 @@
§inclusive: bool

Whether stop is inclusive or not. Signified with = when parsing.

§block: Block

The block to run on each iteration.

-
§span: Span

The span from for to block.

+
§span: Span

The span from for to block.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for IterationStatement

source§

fn clone(&self) -> IterationStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for IterationStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for IterationStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for IterationStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for IterationStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for IterationStatement

source§

fn eq(&self, other: &IterationStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for IterationStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for IterationStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for IterationStatement

source§

fn eq(&self, other: &IterationStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for IterationStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for IterationStatement

source§

impl StructuralPartialEq for IterationStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/statement/return_/struct.ReturnStatement.html b/leo_ast/statement/return_/struct.ReturnStatement.html index 83dd61a073..bc6cd36318 100644 --- a/leo_ast/statement/return_/struct.ReturnStatement.html +++ b/leo_ast/statement/return_/struct.ReturnStatement.html @@ -1,13 +1,13 @@ ReturnStatement in leo_ast::statement::return_ - Rust

Struct leo_ast::statement::return_::ReturnStatement

source ·
pub struct ReturnStatement {
     pub expression: Expression,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A return statement return expression;.

Fields§

§expression: Expression

The expression to return to the function caller.

-
§span: Span

The span of return expression excluding the semicolon.

+
§span: Span

The span of return expression excluding the semicolon.

§id: NodeID

The ID of the node.

Trait Implementations§

source§

impl Clone for ReturnStatement

source§

fn clone(&self) -> ReturnStatement

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ReturnStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ReturnStatement

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ReturnStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ReturnStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ReturnStatement

source§

fn eq(&self, other: &ReturnStatement) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ReturnStatement

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for ReturnStatement

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for ReturnStatement

source§

fn eq(&self, other: &ReturnStatement) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ReturnStatement

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ReturnStatement

source§

impl StructuralPartialEq for ReturnStatement

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/struct.Ast.html b/leo_ast/struct.Ast.html index d53aa6097d..685f95926d 100644 --- a/leo_ast/struct.Ast.html +++ b/leo_ast/struct.Ast.html @@ -5,16 +5,16 @@ These data types form a tree that begins from a Program type root.

Fields§

§ast: Program

Implementations§

source§

impl Ast

source

pub fn new(program: Program) -> Self

Creates a new AST from a given program tree.

source

pub fn as_repr(&self) -> &Program

Returns a reference to the inner program AST representation.

-
source

pub fn into_repr(self) -> Program

source

pub fn to_json_string(&self) -> Result<String>

Serializes the ast into a JSON string.

-
source

pub fn to_json_value(&self) -> Result<Value>

source

pub fn to_json_file(&self, path: PathBuf, file_name: &str) -> Result<()>

Serializes the ast into a JSON file.

+
source

pub fn into_repr(self) -> Program

source

pub fn to_json_string(&self) -> Result<String>

Serializes the ast into a JSON string.

+
source

pub fn to_json_value(&self) -> Result<Value>

source

pub fn to_json_file(&self, path: PathBuf, file_name: &str) -> Result<()>

Serializes the ast into a JSON file.

source

pub fn to_json_file_without_keys( &self, path: PathBuf, file_name: &str, excluded_keys: &[&str], -) -> Result<()>

Serializes the ast into a JSON value and removes keys from object mappings before writing to a file.

-
source

pub fn from_json_string(json: &str) -> Result<Self>

Deserializes the JSON string into a ast.

-
source

pub fn from_json_file(path: PathBuf) -> Result<Self>

Deserializes the JSON string into a ast from a file.

+) -> Result<()>

Serializes the ast into a JSON value and removes keys from object mappings before writing to a file.

+
source

pub fn from_json_string(json: &str) -> Result<Self>

Deserializes the JSON string into a ast.

+
source

pub fn from_json_file(path: PathBuf) -> Result<Self>

Deserializes the JSON string into a ast from a file.

Trait Implementations§

source§

impl AsRef<Program> for Ast

source§

fn as_ref(&self) -> &Program

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Ast

source§

fn clone(&self) -> Ast

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Ast

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Ast

source§

fn default() -> Ast

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

impl PartialEq for Ast

source§

fn eq(&self, other: &Ast) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for Ast

source§

impl StructuralPartialEq for Ast

Auto Trait Implementations§

§

impl Freeze for Ast

§

impl !RefUnwindSafe for Ast

§

impl Send for Ast

§

impl !Sync for Ast

§

impl Unpin for Ast

§

impl UnwindSafe for Ast

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/struct/member/struct.Member.html b/leo_ast/struct/member/struct.Member.html index df96e5387c..7477b3e315 100644 --- a/leo_ast/struct/member/struct.Member.html +++ b/leo_ast/struct/member/struct.Member.html @@ -2,17 +2,17 @@ pub mode: Mode, pub identifier: Identifier, pub type_: Type, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A member of a structured data type, e.g foobar: u8 or private baz: bool .

Fields§

§mode: Mode

The mode of the member.

§identifier: Identifier

The identifier of the member.

§type_: Type

The type of the member.

-
§span: Span

The span of the member.

+
§span: Span

The span of the member.

§id: NodeID

The ID of the node.

-

Implementations§

source§

impl Member

source

pub fn name(&self) -> Symbol

Returns the name of the struct member without span.

+

Implementations§

source§

impl Member

source

pub fn name(&self) -> Symbol

Returns the name of the struct member without span.

Trait Implementations§

source§

impl Clone for Member

source§

fn clone(&self) -> Member

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Member

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Member

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Member

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Member

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Member

source§

fn eq(&self, other: &Member) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Member

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Member

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Member

source§

fn eq(&self, other: &Member) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Member

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Member

source§

impl StructuralPartialEq for Member

Auto Trait Implementations§

§

impl Freeze for Member

§

impl RefUnwindSafe for Member

§

impl Send for Member

§

impl Sync for Member

§

impl Unpin for Member

§

impl UnwindSafe for Member

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/struct/struct.Composite.html b/leo_ast/struct/struct.Composite.html index e394ec8fb5..3e96e94101 100644 --- a/leo_ast/struct/struct.Composite.html +++ b/leo_ast/struct/struct.Composite.html @@ -1,9 +1,9 @@ Composite in leo_ast::struct - Rust

Struct leo_ast::struct::Composite

source ·
pub struct Composite {
     pub identifier: Identifier,
     pub members: Vec<Member>,
-    pub external: Option<Symbol>,
+    pub external: Option<Symbol>,
     pub is_record: bool,
-    pub span: Span,
+    pub span: Span,
     pub id: NodeID,
 }
Expand description

A composite type definition, e.g., struct Foo { my_field: Bar } and record Token { owner: address, amount: u64}. In some languages these are called structs.

@@ -12,17 +12,17 @@ The fields are named so struct Foo(u8, u16) is not allowed.

Fields§

§identifier: Identifier

The name of the type in the type system in this module.

§members: Vec<Member>

The fields, constant variables, and functions of this structure.

-
§external: Option<Symbol>

The external program the struct is defined in.

+
§external: Option<Symbol>

The external program the struct is defined in.

§is_record: bool

Was this a record Foo { ... }? If so, it wasn’t a composite.

-
§span: Span

The entire span of the composite definition.

+
§span: Span

The entire span of the composite definition.

§id: NodeID

The ID of the node.

-

Implementations§

source§

impl Composite

source

pub fn name(&self) -> Symbol

Returns the composite name as a Symbol.

+

Implementations§

source§

impl Composite

source

pub fn name(&self) -> Symbol

Returns the composite name as a Symbol.

source

pub fn from_external_record<N: Network>( input: &RecordType<N>, - external_program: Symbol, + external_program: Symbol, ) -> Self

source

pub fn from_snarkvm<N: Network>(input: &StructType<N>) -> Self

Trait Implementations§

source§

impl Clone for Composite

source§

fn clone(&self) -> Composite

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Composite

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Composite

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Composite

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Composite

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Composite

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Composite

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Node for Composite

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for Composite

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Composite

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for Composite

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/stub/function_stub/struct.FunctionStub.html b/leo_ast/stub/function_stub/struct.FunctionStub.html index 27b3a56198..c6b7ccaa10 100644 --- a/leo_ast/stub/function_stub/struct.FunctionStub.html +++ b/leo_ast/stub/function_stub/struct.FunctionStub.html @@ -5,7 +5,7 @@ pub input: Vec<Input>, pub output: Vec<Output>, pub output_type: Type, - pub span: Span, + pub span: Span, pub id: NodeID, }
Expand description

A function stub definition.

Fields§

§annotations: Vec<Annotation>

Annotations on the function.

@@ -14,7 +14,7 @@
§input: Vec<Input>

The function’s input parameters.

§output: Vec<Output>

The function’s output declarations.

§output_type: Type

The function’s output type.

-
§span: Span

The entire span of the function definition.

+
§span: Span

The entire span of the function definition.

§id: NodeID

The ID of the node.

Implementations§

source§

impl FunctionStub

source

pub fn new( annotations: Vec<Annotation>, @@ -23,25 +23,25 @@ identifier: Identifier, input: Vec<Input>, output: Vec<Output>, - span: Span, + span: Span, id: NodeID, ) -> Self

Initialize a new function.

-
source

pub fn name(&self) -> Symbol

Returns function name.

+
source

pub fn name(&self) -> Symbol

Returns function name.

source

pub fn is_main(&self) -> bool

Returns true if the function name is main.

source

fn format(&self, f: &mut Formatter<'_>) -> Result

Private formatting method used for optimizing fmt::Debug and fmt::Display implementations.

source

pub fn from_function_core<N: Network, Instruction: InstructionTrait<N>, Command: CommandTrait<N>>( function: &FunctionCore<N, Instruction, Command>, - program: Symbol, + program: Symbol, ) -> Self

Converts from snarkvm function type to leo FunctionStub, while also carrying the parent program name.

source

pub fn from_finalize<N: Network, Instruction: InstructionTrait<N>, Command: CommandTrait<N>>( function: &FunctionCore<N, Instruction, Command>, - key_name: Symbol, - program: Symbol, + key_name: Symbol, + program: Symbol, ) -> Self

source

pub fn from_closure<N: Network, Instruction: InstructionTrait<N>>( closure: &ClosureCore<N, Instruction>, - program: Symbol, + program: Symbol, ) -> Self

Trait Implementations§

source§

impl Clone for FunctionStub

source§

fn clone(&self) -> FunctionStub

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for FunctionStub

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for FunctionStub

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for FunctionStub

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Function> for FunctionStub

source§

fn from(function: Function) -> Self

Converts to this type from the input type.
source§

impl From<FunctionStub> for Function

source§

fn from(function: FunctionStub) -> Self

Converts to this type from the input type.
source§

impl Node for FunctionStub

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for FunctionStub

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for FunctionStub

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Function> for FunctionStub

source§

fn from(function: Function) -> Self

Converts to this type from the input type.
source§

impl From<FunctionStub> for Function

source§

fn from(function: FunctionStub) -> Self

Converts to this type from the input type.
source§

impl Node for FunctionStub

source§

fn span(&self) -> Span

Returns the span of the node.
source§

fn set_span(&mut self, span: Span)

Sets the span of the node.
source§

fn id(&self) -> NodeID

Returns the ID of the node.
source§

fn set_id(&mut self, id: NodeID)

Sets the ID of the node.
source§

impl PartialEq for FunctionStub

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for FunctionStub

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for FunctionStub

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_ast/stub/struct.Stub.html b/leo_ast/stub/struct.Stub.html index e5ba32c7c9..c08d4d93ee 100644 --- a/leo_ast/stub/struct.Stub.html +++ b/leo_ast/stub/struct.Stub.html @@ -1,19 +1,19 @@ Stub in leo_ast::stub - Rust

Struct leo_ast::stub::Stub

source ·
pub struct Stub {
     pub imports: Vec<ProgramId>,
     pub stub_id: ProgramId,
-    pub consts: Vec<(Symbol, ConstDeclaration)>,
-    pub structs: Vec<(Symbol, Composite)>,
-    pub mappings: Vec<(Symbol, Mapping)>,
-    pub functions: Vec<(Symbol, FunctionStub)>,
-    pub span: Span,
+    pub consts: Vec<(Symbol, ConstDeclaration)>,
+    pub structs: Vec<(Symbol, Composite)>,
+    pub mappings: Vec<(Symbol, Mapping)>,
+    pub functions: Vec<(Symbol, FunctionStub)>,
+    pub span: Span,
 }
Expand description

Stores the Leo stub abstract syntax tree.

Fields§

§imports: Vec<ProgramId>

A vector of imported programs.

§stub_id: ProgramId

The stub id

-
§consts: Vec<(Symbol, ConstDeclaration)>

A vector of const definitions.

-
§structs: Vec<(Symbol, Composite)>

A vector of struct definitions.

-
§mappings: Vec<(Symbol, Mapping)>

A vector of mapping definitions.

-
§functions: Vec<(Symbol, FunctionStub)>

A vector of function stub definitions.

-
§span: Span

The span associated with the stub.

+
§consts: Vec<(Symbol, ConstDeclaration)>

A vector of const definitions.

+
§structs: Vec<(Symbol, Composite)>

A vector of struct definitions.

+
§mappings: Vec<(Symbol, Mapping)>

A vector of mapping definitions.

+
§functions: Vec<(Symbol, FunctionStub)>

A vector of function stub definitions.

+
§span: Span

The span associated with the stub.

Trait Implementations§

source§

impl Clone for Stub

source§

fn clone(&self) -> Stub

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Stub

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Stub

source§

fn default() -> Self

Constructs an empty program stub

source§

impl<'de> Deserialize<'de> for Stub

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Stub

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Stub> for ProgramScope

source§

fn from(stub: Stub) -> Self

Converts to this type from the input type.
source§

impl PartialEq for Stub

source§

fn eq(&self, other: &Stub) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/types/array/struct.ArrayType.html b/leo_ast/types/array/struct.ArrayType.html index 9414e6e29b..55a91f076e 100644 --- a/leo_ast/types/array/struct.ArrayType.html +++ b/leo_ast/types/array/struct.ArrayType.html @@ -8,7 +8,7 @@
source

pub fn base_element_type(&self) -> &Type

Returns the base element type of the array.

source

pub fn from_snarkvm<N: Network>( array_type: &ConsoleArrayType<N>, - program: Option<Symbol>, + program: Option<Symbol>, ) -> Self

Trait Implementations§

source§

impl Clone for ArrayType

source§

fn clone(&self) -> ArrayType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ArrayType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ArrayType

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for ArrayType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Hash for ArrayType

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, diff --git a/leo_ast/types/core_constant/enum.CoreConstant.html b/leo_ast/types/core_constant/enum.CoreConstant.html index 2744d2a496..7f2a85f625 100644 --- a/leo_ast/types/core_constant/enum.CoreConstant.html +++ b/leo_ast/types/core_constant/enum.CoreConstant.html @@ -1,7 +1,7 @@ CoreConstant in leo_ast::types::core_constant - Rust

Enum leo_ast::types::core_constant::CoreConstant

source ·
pub enum CoreConstant {
     GroupGenerator,
 }
Expand description

A core constant that maps directly to an AVM bytecode constant.

-

Variants§

§

GroupGenerator

Implementations§

source§

impl CoreConstant

source

pub fn from_symbols(type_: Symbol, constant: Symbol) -> Option<Self>

Returns a CoreConstant from the given type and constant symbols.

+

Variants§

§

GroupGenerator

Implementations§

source§

impl CoreConstant

source

pub fn from_symbols(type_: Symbol, constant: Symbol) -> Option<Self>

Returns a CoreConstant from the given type and constant symbols.

source

pub fn to_type(&self) -> Type

Returns the Type of the CoreConstant.

Trait Implementations§

source§

impl Clone for CoreConstant

source§

fn clone(&self) -> CoreConstant

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl PartialEq for CoreConstant

source§

fn eq(&self, other: &CoreConstant) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always diff --git a/leo_ast/types/integer_type/enum.IntegerType.html b/leo_ast/types/integer_type/enum.IntegerType.html index 52bf6dc282..17f290e9a0 100644 --- a/leo_ast/types/integer_type/enum.IntegerType.html +++ b/leo_ast/types/integer_type/enum.IntegerType.html @@ -11,7 +11,7 @@ I128, }
Expand description

Explicit integer type.

Variants§

§

U8

§

U16

§

U32

§

U64

§

U128

§

I8

§

I16

§

I32

§

I64

§

I128

Implementations§

source§

impl IntegerType

source

pub fn is_signed(&self) -> bool

Is the integer type a signed one?

-
source

pub fn symbol(self) -> Symbol

Returns the symbol for the integer type.

+
source

pub fn symbol(self) -> Symbol

Returns the symbol for the integer type.

Trait Implementations§

source§

impl Clone for IntegerType

source§

fn clone(&self) -> IntegerType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for IntegerType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for IntegerType

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for IntegerType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Hash for IntegerType

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, diff --git a/leo_ast/types/mapping/struct.MappingType.html b/leo_ast/types/mapping/struct.MappingType.html index 73eff2dbd9..c1b012cd53 100644 --- a/leo_ast/types/mapping/struct.MappingType.html +++ b/leo_ast/types/mapping/struct.MappingType.html @@ -1,9 +1,9 @@ MappingType in leo_ast::types::mapping - Rust

Struct leo_ast::types::mapping::MappingType

source ·
pub struct MappingType {
     pub key: Box<Type>,
     pub value: Box<Type>,
-    pub program: Symbol,
+    pub program: Symbol,
 }
Expand description

A mapping type of a key and value type.

-

Fields§

§key: Box<Type>§value: Box<Type>§program: Symbol

Trait Implementations§

source§

impl Clone for MappingType

source§

fn clone(&self) -> MappingType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for MappingType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for MappingType

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +

Fields§

§key: Box<Type>§value: Box<Type>§program: Symbol

Trait Implementations§

source§

impl Clone for MappingType

source§

fn clone(&self) -> MappingType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for MappingType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for MappingType

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for MappingType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Hash for MappingType

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq for MappingType

source§

fn eq(&self, other: &MappingType) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/types/struct_type/struct.CompositeType.html b/leo_ast/types/struct_type/struct.CompositeType.html index f3a2f18831..5f7f159bfd 100644 --- a/leo_ast/types/struct_type/struct.CompositeType.html +++ b/leo_ast/types/struct_type/struct.CompositeType.html @@ -1,8 +1,8 @@ CompositeType in leo_ast::types::struct_type - Rust

Struct leo_ast::types::struct_type::CompositeType

source ·
pub struct CompositeType {
     pub id: Identifier,
-    pub program: Option<Symbol>,
+    pub program: Option<Symbol>,
 }
Expand description

A composite type of a identifier and external program name.

-

Fields§

§id: Identifier§program: Option<Symbol>

Trait Implementations§

source§

impl Clone for CompositeType

source§

fn clone(&self) -> CompositeType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CompositeType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for CompositeType

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +

Fields§

§id: Identifier§program: Option<Symbol>

Trait Implementations§

source§

impl Clone for CompositeType

source§

fn clone(&self) -> CompositeType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CompositeType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for CompositeType

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for CompositeType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<&CompositeType> for Location

source§

fn from(composite: &CompositeType) -> Location

Converts to this type from the input type.
source§

impl Hash for CompositeType

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq for CompositeType

source§

fn eq(&self, other: &CompositeType) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_ast/types/type_/enum.Type.html b/leo_ast/types/type_/enum.Type.html index 968ef86d68..e5160fb877 100644 --- a/leo_ast/types/type_/enum.Type.html +++ b/leo_ast/types/type_/enum.Type.html @@ -40,7 +40,7 @@

Flattens array syntax: [[u8; 1]; 2] == [u8; (2, 1)] == true

source

pub fn from_snarkvm<N: Network>( t: &PlaintextType<N>, - program: Option<Symbol>, + program: Option<Symbol>, ) -> Self

Trait Implementations§

source§

impl Clone for Type

source§

fn clone(&self) -> Type

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Type

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Type

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Type

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<&Value> for Type

source§

fn from(v: &Value) -> Self

Converts to this type from the input type.
source§

impl From<Value> for Type

source§

fn from(v: Value) -> Self

Converts to this type from the input type.
source§

impl Hash for Type

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, diff --git a/leo_ast/value/enum.Value.html b/leo_ast/value/enum.Value.html index 35526a6ef8..42b51a2ffa 100644 --- a/leo_ast/value/enum.Value.html +++ b/leo_ast/value/enum.Value.html @@ -1,26 +1,26 @@ Value in leo_ast::value - Rust

Enum leo_ast::value::Value

source ·
pub enum Value {
 
Show 18 variants Input(Type, Identifier), - Address(String, Span), - Boolean(bool, Span), - Struct(Identifier, IndexMap<Symbol, Value>), - Field(String, Span), + Address(String, Span), + Boolean(bool, Span), + Struct(Identifier, IndexMap<Symbol, Value>), + Field(String, Span), Group(Box<GroupLiteral>), - I8(i8, Span), - I16(i16, Span), - I32(i32, Span), - I64(i64, Span), - I128(i128, Span), - U8(u8, Span), - U16(u16, Span), - U32(u32, Span), - U64(u64, Span), - U128(u128, Span), - Scalar(String, Span), - String(String, Span), -
}

Variants§

§

Input(Type, Identifier)

§

Address(String, Span)

§

Boolean(bool, Span)

§

Struct(Identifier, IndexMap<Symbol, Value>)

§

Field(String, Span)

§

Group(Box<GroupLiteral>)

§

I8(i8, Span)

§

I16(i16, Span)

§

I32(i32, Span)

§

I64(i64, Span)

§

I128(i128, Span)

§

U8(u8, Span)

§

U16(u16, Span)

§

U32(u32, Span)

§

U64(u64, Span)

§

U128(u128, Span)

§

Scalar(String, Span)

§

String(String, Span)

Implementations§

source§

impl Value

source

pub(crate) fn abs(self, span: Span) -> Result<Self>

source

pub(crate) fn abs_wrapped(self, span: Span) -> Result<Self>

source

pub(crate) fn neg(self, span: Span) -> Result<Self>

source

pub(crate) fn not(self, span: Span) -> Result<Self>

source

pub(crate) fn add(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn add_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn bitand(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn div(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn div_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn eq(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn ge(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn gt(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn le(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn lt(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn mul(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn mul_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn bitor(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn pow(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn pow_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shl(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shl_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shr(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shr_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn sub(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn sub_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn xor(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn is_supported_const_fold_type(&self) -> bool

Trait Implementations§

source§

impl AsRef<Value> for Value

source§

fn as_ref(&self) -> &Self

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Value

source§

fn clone(&self) -> Value

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Value

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for Value

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<&Value> for Type

source§

fn from(v: &Value) -> Self

Converts to this type from the input type.
source§

impl From<Value> for Type

source§

fn from(v: Value) -> Self

Converts to this type from the input type.
source§

impl PartialEq for Value

source§

fn eq(&self, other: &Value) -> bool

This method tests for self and other values to be equal, and is used + I8(i8, Span), + I16(i16, Span), + I32(i32, Span), + I64(i64, Span), + I128(i128, Span), + U8(u8, Span), + U16(u16, Span), + U32(u32, Span), + U64(u64, Span), + U128(u128, Span), + Scalar(String, Span), + String(String, Span), +
}

Variants§

§

Input(Type, Identifier)

§

Address(String, Span)

§

Boolean(bool, Span)

§

Struct(Identifier, IndexMap<Symbol, Value>)

§

Field(String, Span)

§

Group(Box<GroupLiteral>)

§

I8(i8, Span)

§

I16(i16, Span)

§

I32(i32, Span)

§

I64(i64, Span)

§

I128(i128, Span)

§

U8(u8, Span)

§

U16(u16, Span)

§

U32(u32, Span)

§

U64(u64, Span)

§

U128(u128, Span)

§

Scalar(String, Span)

§

String(String, Span)

Implementations§

source§

impl Value

source

pub(crate) fn abs(self, span: Span) -> Result<Self>

source

pub(crate) fn abs_wrapped(self, span: Span) -> Result<Self>

source

pub(crate) fn neg(self, span: Span) -> Result<Self>

source

pub(crate) fn not(self, span: Span) -> Result<Self>

source

pub(crate) fn add(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn add_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn bitand(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn div(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn div_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn eq(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn ge(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn gt(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn le(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn lt(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn mul(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn mul_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn bitor(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn pow(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn pow_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shl(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shl_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shr(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn shr_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn sub(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn sub_wrapped(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn xor(self, other: Self, span: Span) -> Result<Self>

source

pub(crate) fn is_supported_const_fold_type(&self) -> bool

Trait Implementations§

source§

impl AsRef<Value> for Value

source§

fn as_ref(&self) -> &Self

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Value

source§

fn clone(&self) -> Value

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Value

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for Value

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<&Value> for Type

source§

fn from(v: &Value) -> Self

Converts to this type from the input type.
source§

impl From<Value> for Type

source§

fn from(v: Value) -> Self

Converts to this type from the input type.
source§

impl PartialEq for Value

source§

fn eq(&self, other: &Value) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl TryFrom<&Literal> for Value

source§

fn try_from(literal: &Literal) -> Result<Self, Self::Error>

Converts a literal to a value.

-
§

type Error = ParseIntError

The type returned in the event of a conversion error.
source§

impl TryFrom<&Value> for i128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: &Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl TryFrom<&Value> for u128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: &Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl TryFrom<Value> for i128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl TryFrom<Value> for u128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl Eq for Value

source§

impl StructuralPartialEq for Value

Auto Trait Implementations§

§

impl Freeze for Value

§

impl RefUnwindSafe for Value

§

impl Send for Value

§

impl Sync for Value

§

impl Unpin for Value

§

impl UnwindSafe for Value

Blanket Implementations§

source§

impl<T> Any for T
where +sufficient, and should not be overridden without very good reason.

source§

impl TryFrom<&Literal> for Value

source§

fn try_from(literal: &Literal) -> Result<Self, Self::Error>

Converts a literal to a value.

+
§

type Error = ParseIntError

The type returned in the event of a conversion error.
source§

impl TryFrom<&Value> for i128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: &Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl TryFrom<&Value> for u128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: &Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl TryFrom<Value> for i128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl TryFrom<Value> for u128

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(value: Value) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl Eq for Value

source§

impl StructuralPartialEq for Value

Auto Trait Implementations§

§

impl Freeze for Value

§

impl RefUnwindSafe for Value

§

impl Send for Value

§

impl Sync for Value

§

impl Unpin for Value

§

impl UnwindSafe for Value

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where diff --git a/leo_compiler/compiler/struct.Ast.html b/leo_compiler/compiler/struct.Ast.html index c38f144aa1..48eecefacd 100644 --- a/leo_compiler/compiler/struct.Ast.html +++ b/leo_compiler/compiler/struct.Ast.html @@ -5,20 +5,20 @@ These data types form a tree that begins from a Program type root.

Fields§

§ast: Program

Implementations§

source§

impl Ast

source

pub fn new(program: Program) -> Ast

Creates a new AST from a given program tree.

source

pub fn as_repr(&self) -> &Program

Returns a reference to the inner program AST representation.

-
source

pub fn into_repr(self) -> Program

source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the ast into a JSON string.

-
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

source

pub fn to_json_file( +

source

pub fn into_repr(self) -> Program

source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the ast into a JSON string.

+
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

source

pub fn to_json_file( &self, path: PathBuf, file_name: &str, -) -> Result<(), LeoError>

Serializes the ast into a JSON file.

+) -> Result<(), LeoError>

Serializes the ast into a JSON file.

source

pub fn to_json_file_without_keys( &self, path: PathBuf, file_name: &str, excluded_keys: &[&str], -) -> Result<(), LeoError>

Serializes the ast into a JSON value and removes keys from object mappings before writing to a file.

-
source

pub fn from_json_string(json: &str) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast.

-
source

pub fn from_json_file(path: PathBuf) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast from a file.

+) -> Result<(), LeoError>

Serializes the ast into a JSON value and removes keys from object mappings before writing to a file.

+
source

pub fn from_json_string(json: &str) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast.

+
source

pub fn from_json_file(path: PathBuf) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast from a file.

Trait Implementations§

source§

impl AsRef<Program> for Ast

source§

fn as_ref(&self) -> &Program

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Ast

source§

fn clone(&self) -> Ast

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Ast

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for Ast

source§

fn default() -> Ast

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

impl PartialEq for Ast

source§

fn eq(&self, other: &Ast) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for Ast

source§

impl StructuralPartialEq for Ast

Auto Trait Implementations§

§

impl Freeze for Ast

§

impl !RefUnwindSafe for Ast

§

impl Send for Ast

§

impl !Sync for Ast

§

impl Unpin for Ast

§

impl UnwindSafe for Ast

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_compiler/compiler/struct.Compiler.html b/leo_compiler/compiler/struct.Compiler.html index 3d424bd7b4..d747d4537c 100644 --- a/leo_compiler/compiler/struct.Compiler.html +++ b/leo_compiler/compiler/struct.Compiler.html @@ -1,5 +1,5 @@ Compiler in leo_compiler::compiler - Rust

Struct leo_compiler::compiler::Compiler

source ·
pub struct Compiler<'a, N: Network> {
-    handler: &'a Handler,
+    handler: &'a Handler,
     main_file_path: PathBuf,
     output_directory: PathBuf,
     pub program_name: String,
@@ -9,10 +9,10 @@
     node_builder: NodeBuilder,
     assigner: Assigner,
     type_table: TypeTable,
-    import_stubs: IndexMap<Symbol, Stub>,
+    import_stubs: IndexMap<Symbol, Stub>,
     phantom: PhantomData<N>,
 }
Expand description

The primary entry point of the Leo compiler.

-

Fields§

§handler: &'a Handler

The handler is used for error and warning emissions.

+

Fields§

§handler: &'a Handler

The handler is used for error and warning emissions.

§main_file_path: PathBuf

The path to the main leo file.

§output_directory: PathBuf

The path to where the compiler outputs all generated files.

§program_name: String

The program name,

@@ -22,57 +22,57 @@
§node_builder: NodeBuilder

The NodeCounter used to generate sequentially increasing NodeIDs.

§assigner: Assigner

The Assigner is used to construct (unique) assignment statements.

§type_table: TypeTable

The type table.

-
§import_stubs: IndexMap<Symbol, Stub>

The stubs for imported programs. Produced by Retriever module.

+
§import_stubs: IndexMap<Symbol, Stub>

The stubs for imported programs. Produced by Retriever module.

§phantom: PhantomData<N>

Implementations§

source§

impl<'a, N: Network> Compiler<'a, N>

source

pub fn new( program_name: String, network: String, - handler: &'a Handler, + handler: &'a Handler, main_file_path: PathBuf, output_directory: PathBuf, compiler_options: Option<CompilerOptions>, - import_stubs: IndexMap<Symbol, Stub>, + import_stubs: IndexMap<Symbol, Stub>, ) -> Self

Returns a new Leo compiler.

-
source

pub fn checksum(&self) -> Result<String>

Returns a SHA256 checksum of the program file.

+
source

pub fn checksum(&self) -> Result<String>

Returns a SHA256 checksum of the program file.

source

pub fn parse_program_from_string( &mut self, program_string: &str, - name: FileName, -) -> Result<()>

Parses and stores a program file content from a string, constructs a syntax tree, and generates a program.

-
source

pub fn parse_program(&mut self) -> Result<()>

Parses and stores the main program file, constructs a syntax tree, and generates a program.

-
source

pub fn symbol_table_pass(&self) -> Result<SymbolTable>

Runs the symbol table pass.

+ name: FileName, +) -> Result<()>

Parses and stores a program file content from a string, constructs a syntax tree, and generates a program.

+
source

pub fn parse_program(&mut self) -> Result<()>

Parses and stores the main program file, constructs a syntax tree, and generates a program.

+
source

pub fn symbol_table_pass(&self) -> Result<SymbolTable>

Runs the symbol table pass.

source

pub fn type_checker_pass( &'a self, symbol_table: SymbolTable, -) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the type checker pass.

+) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the type checker pass.

source

pub fn loop_unrolling_pass( &mut self, symbol_table: SymbolTable, -) -> Result<SymbolTable>

Runs the loop unrolling pass.

+) -> Result<SymbolTable>

Runs the loop unrolling pass.

source

pub fn static_single_assignment_pass( &mut self, symbol_table: &SymbolTable, -) -> Result<()>

Runs the static single assignment pass.

-
source

pub fn flattening_pass(&mut self, symbol_table: &SymbolTable) -> Result<()>

Runs the flattening pass.

-
source

pub fn destructuring_pass(&mut self) -> Result<()>

Runs the destructuring pass.

-
source

pub fn function_inlining_pass(&mut self, call_graph: &CallGraph) -> Result<()>

Runs the function inlining pass.

-
source

pub fn dead_code_elimination_pass(&mut self) -> Result<()>

Runs the dead code elimination pass.

+) -> Result<()>

Runs the static single assignment pass.

+
source

pub fn flattening_pass(&mut self, symbol_table: &SymbolTable) -> Result<()>

Runs the flattening pass.

+
source

pub fn destructuring_pass(&mut self) -> Result<()>

Runs the destructuring pass.

+
source

pub fn function_inlining_pass(&mut self, call_graph: &CallGraph) -> Result<()>

Runs the function inlining pass.

+
source

pub fn dead_code_elimination_pass(&mut self) -> Result<()>

Runs the dead code elimination pass.

source

pub fn code_generation_pass( &mut self, symbol_table: &SymbolTable, struct_graph: &StructGraph, call_graph: &CallGraph, -) -> Result<String>

Runs the code generation pass.

+) -> Result<String>

Runs the code generation pass.

source

pub fn compiler_stages( &mut self, -) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the compiler stages.

-
source

pub fn compile(&mut self) -> Result<String>

Returns a compiled Leo program.

-
source

fn write_ast_to_json(&self, file_suffix: &str) -> Result<()>

Writes the AST to a JSON file.

+) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the compiler stages.

+
source

pub fn compile(&mut self) -> Result<String>

Returns a compiled Leo program.

+
source

fn write_ast_to_json(&self, file_suffix: &str) -> Result<()>

Writes the AST to a JSON file.

source

fn write_symbol_table_to_json( &self, file_suffix: &str, symbol_table: &SymbolTable, -) -> Result<()>

Writes the Symbol Table to a JSON file.

-
source

pub fn add_import_stubs(&mut self) -> Result<()>

Merges the dependencies defined in program.json with the dependencies imported in .leo file

+) -> Result<()>

Writes the Symbol Table to a JSON file.

+
source

pub fn add_import_stubs(&mut self) -> Result<()>

Merges the dependencies defined in program.json with the dependencies imported in .leo file

Trait Implementations§

source§

impl<'a, N: Clone + Network> Clone for Compiler<'a, N>

source§

fn clone(&self) -> Compiler<'a, N>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more

Auto Trait Implementations§

§

impl<'a, N> !Freeze for Compiler<'a, N>

§

impl<'a, N> !RefUnwindSafe for Compiler<'a, N>

§

impl<'a, N> !Send for Compiler<'a, N>

§

impl<'a, N> !Sync for Compiler<'a, N>

§

impl<'a, N> Unpin for Compiler<'a, N>
where N: Unpin,

§

impl<'a, N> !UnwindSafe for Compiler<'a, N>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_compiler/compiler/struct.SymbolTable.html b/leo_compiler/compiler/struct.SymbolTable.html index 03c3889966..ddbfb4d133 100644 --- a/leo_compiler/compiler/struct.SymbolTable.html +++ b/leo_compiler/compiler/struct.SymbolTable.html @@ -13,8 +13,8 @@ &self, location: &Location, is_struct: bool, - span: Span, -) -> Result<(), LeoError>

Recursively checks if the symbol table contains an entry for the given symbol. + span: Span, +) -> Result<(), LeoError>

Recursively checks if the symbol table contains an entry for the given symbol. Leo does not allow any variable shadowing or overlap between different symbols.

source

pub fn scope_index(&mut self) -> usize

Returns the current scope index. Increments the scope index.

@@ -22,35 +22,35 @@ &mut self, location: Location, insert: &Function, -) -> Result<(), LeoError>

Inserts a function into the symbol table.

+) -> Result<(), LeoError>

Inserts a function into the symbol table.

source

pub fn insert_struct( &mut self, location: Location, insert: &Composite, -) -> Result<(), LeoError>

Inserts a struct into the symbol table.

+) -> Result<(), LeoError>

Inserts a struct into the symbol table.

source

pub fn attach_finalize( &mut self, caller: Location, callee: Location, -) -> Result<(), LeoError>

Attach a finalize to a function.

+) -> Result<(), LeoError>

Attach a finalize to a function.

source

pub fn insert_variable( &mut self, location: Location, insert: VariableSymbol, -) -> Result<(), LeoError>

Inserts a variable into the symbol table.

+) -> Result<(), LeoError>

Inserts a variable into the symbol table.

source

pub fn insert_futures( &mut self, - program: Symbol, - function: Symbol, + program: Symbol, + function: Symbol, futures: Vec<Location>, -) -> Result<(), LeoError>

Inserts futures into the function definition.

+) -> Result<(), LeoError>

Inserts futures into the function definition.

source

pub fn remove_variable_from_current_scope(&mut self, location: Location)

Removes a variable from the symbol table.

source

pub fn insert_block(&mut self) -> usize

Creates a new scope for the block and stores it in the symbol table.

source

pub fn lookup_fn_symbol(&self, location: Location) -> Option<&FunctionSymbol>

Attempts to lookup a function in the symbol table.

source

pub fn lookup_struct( &self, location: Location, - main_program: Option<Symbol>, + main_program: Option<Symbol>, ) -> Option<&Composite>

Attempts to lookup a struct in the symbol table.

source

pub fn lookup_variable(&self, location: Location) -> Option<&VariableSymbol>

Attempts to lookup a variable in the symbol table.

source

pub fn lookup_variable_in_current_scope( @@ -61,20 +61,20 @@ &self, index: usize, ) -> Option<&RefCell<SymbolTable>>

Returns the scope associated with index, if it exists in the symbol table.

-
source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the symbol table into a JSON string.

-
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

Converts the symbol table into a JSON value

+
source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the symbol table into a JSON string.

+
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

Converts the symbol table into a JSON value

source

pub fn to_json_file( &self, path: PathBuf, file_name: &str, -) -> Result<(), LeoError>

source

pub fn to_json_file_without_keys( +) -> Result<(), LeoError>

source

pub fn to_json_file_without_keys( &self, path: PathBuf, file_name: &str, excluded_keys: &[&str], -) -> Result<(), LeoError>

Serializes the symbol table into a JSON value and removes keys from object mappings before writing to a file.

-
source

pub fn from_json_string(json: &str) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table.

-
source

pub fn from_json_file(path: PathBuf) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table from a file.

+) -> Result<(), LeoError>

Serializes the symbol table into a JSON value and removes keys from object mappings before writing to a file.

+
source

pub fn from_json_string(json: &str) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table.

+
source

pub fn from_json_file(path: PathBuf) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table from a file.

Trait Implementations§

source§

impl Clone for SymbolTable

source§

fn clone(&self) -> SymbolTable

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for SymbolTable

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for SymbolTable

source§

fn default() -> SymbolTable

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

impl<'de> Deserialize<'de> for SymbolTable

source§

fn deserialize<__D>( __deserializer: __D, ) -> Result<SymbolTable, <__D as Deserializer<'de>>::Error>
where diff --git a/leo_compiler/struct.Ast.html b/leo_compiler/struct.Ast.html index edf9d107b5..2f3350d8fe 100644 --- a/leo_compiler/struct.Ast.html +++ b/leo_compiler/struct.Ast.html @@ -5,20 +5,20 @@ These data types form a tree that begins from a Program type root.

Fields§

§ast: Program

Implementations§

source§

impl Ast

source

pub fn new(program: Program) -> Ast

Creates a new AST from a given program tree.

source

pub fn as_repr(&self) -> &Program

Returns a reference to the inner program AST representation.

-
source

pub fn into_repr(self) -> Program

source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the ast into a JSON string.

-
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

source

pub fn to_json_file( +

source

pub fn into_repr(self) -> Program

source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the ast into a JSON string.

+
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

source

pub fn to_json_file( &self, path: PathBuf, file_name: &str, -) -> Result<(), LeoError>

Serializes the ast into a JSON file.

+) -> Result<(), LeoError>

Serializes the ast into a JSON file.

source

pub fn to_json_file_without_keys( &self, path: PathBuf, file_name: &str, excluded_keys: &[&str], -) -> Result<(), LeoError>

Serializes the ast into a JSON value and removes keys from object mappings before writing to a file.

-
source

pub fn from_json_string(json: &str) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast.

-
source

pub fn from_json_file(path: PathBuf) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast from a file.

+) -> Result<(), LeoError>

Serializes the ast into a JSON value and removes keys from object mappings before writing to a file.

+
source

pub fn from_json_string(json: &str) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast.

+
source

pub fn from_json_file(path: PathBuf) -> Result<Ast, LeoError>

Deserializes the JSON string into a ast from a file.

Trait Implementations§

source§

impl AsRef<Program> for Ast

source§

fn as_ref(&self) -> &Program

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Ast

source§

fn clone(&self) -> Ast

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Ast

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for Ast

source§

fn default() -> Ast

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

impl PartialEq for Ast

source§

fn eq(&self, other: &Ast) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for Ast

source§

impl StructuralPartialEq for Ast

Auto Trait Implementations§

§

impl Freeze for Ast

§

impl !RefUnwindSafe for Ast

§

impl Send for Ast

§

impl !Sync for Ast

§

impl Unpin for Ast

§

impl UnwindSafe for Ast

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_compiler/struct.Compiler.html b/leo_compiler/struct.Compiler.html index d201d155f4..a29f73c56a 100644 --- a/leo_compiler/struct.Compiler.html +++ b/leo_compiler/struct.Compiler.html @@ -1,5 +1,5 @@ Compiler in leo_compiler - Rust

Struct leo_compiler::Compiler

source ·
pub struct Compiler<'a, N: Network> {
-    handler: &'a Handler,
+    handler: &'a Handler,
     main_file_path: PathBuf,
     output_directory: PathBuf,
     pub program_name: String,
@@ -9,10 +9,10 @@
     node_builder: NodeBuilder,
     assigner: Assigner,
     type_table: TypeTable,
-    import_stubs: IndexMap<Symbol, Stub>,
+    import_stubs: IndexMap<Symbol, Stub>,
     phantom: PhantomData<N>,
 }
Expand description

The primary entry point of the Leo compiler.

-

Fields§

§handler: &'a Handler

The handler is used for error and warning emissions.

+

Fields§

§handler: &'a Handler

The handler is used for error and warning emissions.

§main_file_path: PathBuf

The path to the main leo file.

§output_directory: PathBuf

The path to where the compiler outputs all generated files.

§program_name: String

The program name,

@@ -22,57 +22,57 @@
§node_builder: NodeBuilder

The NodeCounter used to generate sequentially increasing NodeIDs.

§assigner: Assigner

The Assigner is used to construct (unique) assignment statements.

§type_table: TypeTable

The type table.

-
§import_stubs: IndexMap<Symbol, Stub>

The stubs for imported programs. Produced by Retriever module.

+
§import_stubs: IndexMap<Symbol, Stub>

The stubs for imported programs. Produced by Retriever module.

§phantom: PhantomData<N>

Implementations§

source§

impl<'a, N: Network> Compiler<'a, N>

source

pub fn new( program_name: String, network: String, - handler: &'a Handler, + handler: &'a Handler, main_file_path: PathBuf, output_directory: PathBuf, compiler_options: Option<CompilerOptions>, - import_stubs: IndexMap<Symbol, Stub>, + import_stubs: IndexMap<Symbol, Stub>, ) -> Self

Returns a new Leo compiler.

-
source

pub fn checksum(&self) -> Result<String>

Returns a SHA256 checksum of the program file.

+
source

pub fn checksum(&self) -> Result<String>

Returns a SHA256 checksum of the program file.

source

pub fn parse_program_from_string( &mut self, program_string: &str, - name: FileName, -) -> Result<()>

Parses and stores a program file content from a string, constructs a syntax tree, and generates a program.

-
source

pub fn parse_program(&mut self) -> Result<()>

Parses and stores the main program file, constructs a syntax tree, and generates a program.

-
source

pub fn symbol_table_pass(&self) -> Result<SymbolTable>

Runs the symbol table pass.

+ name: FileName, +) -> Result<()>

Parses and stores a program file content from a string, constructs a syntax tree, and generates a program.

+
source

pub fn parse_program(&mut self) -> Result<()>

Parses and stores the main program file, constructs a syntax tree, and generates a program.

+
source

pub fn symbol_table_pass(&self) -> Result<SymbolTable>

Runs the symbol table pass.

source

pub fn type_checker_pass( &'a self, symbol_table: SymbolTable, -) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the type checker pass.

+) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the type checker pass.

source

pub fn loop_unrolling_pass( &mut self, symbol_table: SymbolTable, -) -> Result<SymbolTable>

Runs the loop unrolling pass.

+) -> Result<SymbolTable>

Runs the loop unrolling pass.

source

pub fn static_single_assignment_pass( &mut self, symbol_table: &SymbolTable, -) -> Result<()>

Runs the static single assignment pass.

-
source

pub fn flattening_pass(&mut self, symbol_table: &SymbolTable) -> Result<()>

Runs the flattening pass.

-
source

pub fn destructuring_pass(&mut self) -> Result<()>

Runs the destructuring pass.

-
source

pub fn function_inlining_pass(&mut self, call_graph: &CallGraph) -> Result<()>

Runs the function inlining pass.

-
source

pub fn dead_code_elimination_pass(&mut self) -> Result<()>

Runs the dead code elimination pass.

+) -> Result<()>

Runs the static single assignment pass.

+
source

pub fn flattening_pass(&mut self, symbol_table: &SymbolTable) -> Result<()>

Runs the flattening pass.

+
source

pub fn destructuring_pass(&mut self) -> Result<()>

Runs the destructuring pass.

+
source

pub fn function_inlining_pass(&mut self, call_graph: &CallGraph) -> Result<()>

Runs the function inlining pass.

+
source

pub fn dead_code_elimination_pass(&mut self) -> Result<()>

Runs the dead code elimination pass.

source

pub fn code_generation_pass( &mut self, symbol_table: &SymbolTable, struct_graph: &StructGraph, call_graph: &CallGraph, -) -> Result<String>

Runs the code generation pass.

+) -> Result<String>

Runs the code generation pass.

source

pub fn compiler_stages( &mut self, -) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the compiler stages.

-
source

pub fn compile(&mut self) -> Result<String>

Returns a compiled Leo program.

-
source

fn write_ast_to_json(&self, file_suffix: &str) -> Result<()>

Writes the AST to a JSON file.

+) -> Result<(SymbolTable, StructGraph, CallGraph)>

Runs the compiler stages.

+
source

pub fn compile(&mut self) -> Result<String>

Returns a compiled Leo program.

+
source

fn write_ast_to_json(&self, file_suffix: &str) -> Result<()>

Writes the AST to a JSON file.

source

fn write_symbol_table_to_json( &self, file_suffix: &str, symbol_table: &SymbolTable, -) -> Result<()>

Writes the Symbol Table to a JSON file.

-
source

pub fn add_import_stubs(&mut self) -> Result<()>

Merges the dependencies defined in program.json with the dependencies imported in .leo file

+) -> Result<()>

Writes the Symbol Table to a JSON file.

+
source

pub fn add_import_stubs(&mut self) -> Result<()>

Merges the dependencies defined in program.json with the dependencies imported in .leo file

Trait Implementations§

source§

impl<'a, N: Clone + Network> Clone for Compiler<'a, N>

source§

fn clone(&self) -> Compiler<'a, N>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more

Auto Trait Implementations§

§

impl<'a, N> !Freeze for Compiler<'a, N>

§

impl<'a, N> !RefUnwindSafe for Compiler<'a, N>

§

impl<'a, N> !Send for Compiler<'a, N>

§

impl<'a, N> !Sync for Compiler<'a, N>

§

impl<'a, N> Unpin for Compiler<'a, N>
where N: Unpin,

§

impl<'a, N> !UnwindSafe for Compiler<'a, N>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_compiler/struct.SymbolTable.html b/leo_compiler/struct.SymbolTable.html index 9529c9b1ba..4cb4510a1e 100644 --- a/leo_compiler/struct.SymbolTable.html +++ b/leo_compiler/struct.SymbolTable.html @@ -13,8 +13,8 @@ &self, location: &Location, is_struct: bool, - span: Span, -) -> Result<(), LeoError>

Recursively checks if the symbol table contains an entry for the given symbol. + span: Span, +) -> Result<(), LeoError>

Recursively checks if the symbol table contains an entry for the given symbol. Leo does not allow any variable shadowing or overlap between different symbols.

source

pub fn scope_index(&mut self) -> usize

Returns the current scope index. Increments the scope index.

@@ -22,35 +22,35 @@ &mut self, location: Location, insert: &Function, -) -> Result<(), LeoError>

Inserts a function into the symbol table.

+) -> Result<(), LeoError>

Inserts a function into the symbol table.

source

pub fn insert_struct( &mut self, location: Location, insert: &Composite, -) -> Result<(), LeoError>

Inserts a struct into the symbol table.

+) -> Result<(), LeoError>

Inserts a struct into the symbol table.

source

pub fn attach_finalize( &mut self, caller: Location, callee: Location, -) -> Result<(), LeoError>

Attach a finalize to a function.

+) -> Result<(), LeoError>

Attach a finalize to a function.

source

pub fn insert_variable( &mut self, location: Location, insert: VariableSymbol, -) -> Result<(), LeoError>

Inserts a variable into the symbol table.

+) -> Result<(), LeoError>

Inserts a variable into the symbol table.

source

pub fn insert_futures( &mut self, - program: Symbol, - function: Symbol, + program: Symbol, + function: Symbol, futures: Vec<Location>, -) -> Result<(), LeoError>

Inserts futures into the function definition.

+) -> Result<(), LeoError>

Inserts futures into the function definition.

source

pub fn remove_variable_from_current_scope(&mut self, location: Location)

Removes a variable from the symbol table.

source

pub fn insert_block(&mut self) -> usize

Creates a new scope for the block and stores it in the symbol table.

source

pub fn lookup_fn_symbol(&self, location: Location) -> Option<&FunctionSymbol>

Attempts to lookup a function in the symbol table.

source

pub fn lookup_struct( &self, location: Location, - main_program: Option<Symbol>, + main_program: Option<Symbol>, ) -> Option<&Composite>

Attempts to lookup a struct in the symbol table.

source

pub fn lookup_variable(&self, location: Location) -> Option<&VariableSymbol>

Attempts to lookup a variable in the symbol table.

source

pub fn lookup_variable_in_current_scope( @@ -61,20 +61,20 @@ &self, index: usize, ) -> Option<&RefCell<SymbolTable>>

Returns the scope associated with index, if it exists in the symbol table.

-
source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the symbol table into a JSON string.

-
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

Converts the symbol table into a JSON value

+
source

pub fn to_json_string(&self) -> Result<String, LeoError>

Serializes the symbol table into a JSON string.

+
source

pub fn to_json_value(&self) -> Result<Value, LeoError>

Converts the symbol table into a JSON value

source

pub fn to_json_file( &self, path: PathBuf, file_name: &str, -) -> Result<(), LeoError>

source

pub fn to_json_file_without_keys( +) -> Result<(), LeoError>

source

pub fn to_json_file_without_keys( &self, path: PathBuf, file_name: &str, excluded_keys: &[&str], -) -> Result<(), LeoError>

Serializes the symbol table into a JSON value and removes keys from object mappings before writing to a file.

-
source

pub fn from_json_string(json: &str) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table.

-
source

pub fn from_json_file(path: PathBuf) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table from a file.

+) -> Result<(), LeoError>

Serializes the symbol table into a JSON value and removes keys from object mappings before writing to a file.

+
source

pub fn from_json_string(json: &str) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table.

+
source

pub fn from_json_file(path: PathBuf) -> Result<SymbolTable, LeoError>

Deserializes the JSON string into a symbol table from a file.

Trait Implementations§

source§

impl Clone for SymbolTable

source§

fn clone(&self) -> SymbolTable

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for SymbolTable

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for SymbolTable

source§

fn default() -> SymbolTable

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

impl<'de> Deserialize<'de> for SymbolTable

source§

fn deserialize<__D>( __deserializer: __D, ) -> Result<SymbolTable, <__D as Deserializer<'de>>::Error>
where diff --git a/leo_lang/cli/account/enum.Account.html b/leo_lang/cli/account/enum.Account.html index 37d9541e36..ff4275c124 100644 --- a/leo_lang/cli/account/enum.Account.html +++ b/leo_lang/cli/account/enum.Account.html @@ -50,15 +50,15 @@ and needs its output result, this is where the result type is defined. Example: type Input: ::Out

§

type Output = ()

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, -this field may be left empty.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>
where - Self: Sized,

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, ctx: Context, _: Self::Input) -> Result<Self::Output>
where +this field may be left empty.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>
where + Self: Sized,

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, ctx: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Account

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Account

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Account

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/add/struct.Add.html b/leo_lang/cli/add/struct.Add.html index a3b4d55443..1737ffaa75 100644 --- a/leo_lang/cli/add/struct.Add.html +++ b/leo_lang/cli/add/struct.Add.html @@ -13,10 +13,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Add

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Add

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Add

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/build/struct.Build.html b/leo_lang/cli/build/struct.Build.html index be74f1c1d2..64985d03dd 100644 --- a/leo_lang/cli/build/struct.Build.html +++ b/leo_lang/cli/build/struct.Build.html @@ -10,10 +10,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Build

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Build

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Build

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/clean/struct.Clean.html b/leo_lang/cli/clean/struct.Clean.html index 6d93278d81..bf2b58bb7e 100644 --- a/leo_lang/cli/clean/struct.Clean.html +++ b/leo_lang/cli/clean/struct.Clean.html @@ -8,10 +8,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Clean

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Clean

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Clean

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/cli/fn.handle_error.html b/leo_lang/cli/cli/fn.handle_error.html index fd3ac865ed..3c461c2b5d 100644 --- a/leo_lang/cli/cli/fn.handle_error.html +++ b/leo_lang/cli/cli/fn.handle_error.html @@ -1 +1 @@ -handle_error in leo_lang::cli::cli - Rust

Function leo_lang::cli::cli::handle_error

source ·
pub fn handle_error<T>(res: Result<T>) -> T
\ No newline at end of file +handle_error in leo_lang::cli::cli - Rust

Function leo_lang::cli::cli::handle_error

source ·
pub fn handle_error<T>(res: Result<T>) -> T
\ No newline at end of file diff --git a/leo_lang/cli/cli/fn.run_with_args.html b/leo_lang/cli/cli/fn.run_with_args.html index fc6b846eda..3a7d9e0a29 100644 --- a/leo_lang/cli/cli/fn.run_with_args.html +++ b/leo_lang/cli/cli/fn.run_with_args.html @@ -1,2 +1,2 @@ -run_with_args in leo_lang::cli::cli - Rust

Function leo_lang::cli::cli::run_with_args

source ·
pub fn run_with_args(cli: CLI) -> Result<()>
Expand description

Run command with custom build arguments.

+run_with_args in leo_lang::cli::cli - Rust

Function leo_lang::cli::cli::run_with_args

source ·
pub fn run_with_args(cli: CLI) -> Result<()>
Expand description

Run command with custom build arguments.

\ No newline at end of file diff --git a/leo_lang/cli/commands/account/enum.Account.html b/leo_lang/cli/commands/account/enum.Account.html index 12233f115b..81c694b47a 100644 --- a/leo_lang/cli/commands/account/enum.Account.html +++ b/leo_lang/cli/commands/account/enum.Account.html @@ -50,15 +50,15 @@ and needs its output result, this is where the result type is defined. Example: type Input: ::Out
§

type Output = ()

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, -this field may be left empty.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>
where - Self: Sized,

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, ctx: Context, _: Self::Input) -> Result<Self::Output>
where +this field may be left empty.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>
where + Self: Sized,

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, ctx: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error

source§

impl CommandFactory for Account

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Account

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Account

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/account/fn.display_string_discreetly.html b/leo_lang/cli/commands/account/fn.display_string_discreetly.html index 2d0c999c67..fb0fccc9b4 100644 --- a/leo_lang/cli/commands/account/fn.display_string_discreetly.html +++ b/leo_lang/cli/commands/account/fn.display_string_discreetly.html @@ -1,5 +1,5 @@ display_string_discreetly in leo_lang::cli::commands::account - Rust

Function leo_lang::cli::commands::account::display_string_discreetly

source ·
fn display_string_discreetly(
     discreet_string: &str,
     continue_message: &str,
-) -> Result<()>
Expand description

Print the string to an alternate screen, so that the string won’t been printed to the terminal.

+) -> Result<()>
Expand description

Print the string to an alternate screen, so that the string won’t been printed to the terminal.

\ No newline at end of file diff --git a/leo_lang/cli/commands/account/fn.generate_new_account.html b/leo_lang/cli/commands/account/fn.generate_new_account.html index 601b25bf57..af3ecca00c 100644 --- a/leo_lang/cli/commands/account/fn.generate_new_account.html +++ b/leo_lang/cli/commands/account/fn.generate_new_account.html @@ -4,4 +4,4 @@ discreet: bool, ctx: &Context, endpoint: String, -) -> Result<()>

\ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/account/fn.import_account.html b/leo_lang/cli/commands/account/fn.import_account.html index 58c1b67415..a079e90007 100644 --- a/leo_lang/cli/commands/account/fn.import_account.html +++ b/leo_lang/cli/commands/account/fn.import_account.html @@ -4,4 +4,4 @@ discreet: bool, ctx: &Context, endpoint: String, -) -> Result<()> \ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/account/fn.print_keys.html b/leo_lang/cli/commands/account/fn.print_keys.html index 854db35f2a..5d2cf032ad 100644 --- a/leo_lang/cli/commands/account/fn.print_keys.html +++ b/leo_lang/cli/commands/account/fn.print_keys.html @@ -1,4 +1,4 @@ print_keys in leo_lang::cli::commands::account - Rust

Function leo_lang::cli::commands::account::print_keys

source ·
fn print_keys<N: Network>(
     private_key: PrivateKey<N>,
     discreet: bool,
-) -> Result<()>
\ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/account/fn.sign_message.html b/leo_lang/cli/commands/account/fn.sign_message.html index ceb141b95f..e1485d42bb 100644 --- a/leo_lang/cli/commands/account/fn.sign_message.html +++ b/leo_lang/cli/commands/account/fn.sign_message.html @@ -3,4 +3,4 @@ raw: bool, private_key: Option<String>, private_key_file: Option<String>, -) -> Result<String> \ No newline at end of file +) -> Result<String> \ No newline at end of file diff --git a/leo_lang/cli/commands/account/fn.verify_message.html b/leo_lang/cli/commands/account/fn.verify_message.html index 0d9b7c82c8..0936db5c1a 100644 --- a/leo_lang/cli/commands/account/fn.verify_message.html +++ b/leo_lang/cli/commands/account/fn.verify_message.html @@ -3,4 +3,4 @@ signature: String, message: String, raw: bool, -) -> Result<String> \ No newline at end of file +) -> Result<String> \ No newline at end of file diff --git a/leo_lang/cli/commands/account/fn.write_to_env_file.html b/leo_lang/cli/commands/account/fn.write_to_env_file.html index 78c0732f6f..2aaa24a3d5 100644 --- a/leo_lang/cli/commands/account/fn.write_to_env_file.html +++ b/leo_lang/cli/commands/account/fn.write_to_env_file.html @@ -2,4 +2,4 @@ private_key: PrivateKey<N>, ctx: &Context, endpoint: String, -) -> Result<()> \ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/add/struct.Add.html b/leo_lang/cli/commands/add/struct.Add.html index 254ede3652..4c9255b982 100644 --- a/leo_lang/cli/commands/add/struct.Add.html +++ b/leo_lang/cli/commands/add/struct.Add.html @@ -13,10 +13,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Add

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Add

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Add

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/build/fn.compile_leo_file.html b/leo_lang/cli/commands/build/fn.compile_leo_file.html index a312f58a5b..e804322deb 100644 --- a/leo_lang/cli/commands/build/fn.compile_leo_file.html +++ b/leo_lang/cli/commands/build/fn.compile_leo_file.html @@ -3,8 +3,8 @@ program_id: &ProgramID<N>, outputs: &Path, build: &Path, - handler: &Handler, + handler: &Handler, options: BuildOptions, - stubs: IndexMap<Symbol, Stub>, -) -> Result<()>
Expand description

Compiles a Leo file in the src/ directory.

+ stubs: IndexMap<Symbol, Stub>, +) -> Result<()>
Expand description

Compiles a Leo file in the src/ directory.

\ No newline at end of file diff --git a/leo_lang/cli/commands/build/fn.handle_build.html b/leo_lang/cli/commands/build/fn.handle_build.html index 368b75a70c..27f7f66626 100644 --- a/leo_lang/cli/commands/build/fn.handle_build.html +++ b/leo_lang/cli/commands/build/fn.handle_build.html @@ -1,4 +1,4 @@ handle_build in leo_lang::cli::commands::build - Rust

Function leo_lang::cli::commands::build::handle_build

source ·
fn handle_build<N: Network>(
     command: &Build,
     context: Context,
-) -> Result<<Build as Command>::Output>
\ No newline at end of file +) -> Result<<Build as Command>::Output> \ No newline at end of file diff --git a/leo_lang/cli/commands/build/struct.Build.html b/leo_lang/cli/commands/build/struct.Build.html index dcfa5dbbba..0c6c1d7de5 100644 --- a/leo_lang/cli/commands/build/struct.Build.html +++ b/leo_lang/cli/commands/build/struct.Build.html @@ -10,10 +10,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Build

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Build

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Build

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/clean/struct.Clean.html b/leo_lang/cli/commands/clean/struct.Clean.html index a52165a470..bcabb2970e 100644 --- a/leo_lang/cli/commands/clean/struct.Clean.html +++ b/leo_lang/cli/commands/clean/struct.Clean.html @@ -8,10 +8,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Clean

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Clean

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Clean

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/deploy/fn.deploy_cost_breakdown.html b/leo_lang/cli/commands/deploy/fn.deploy_cost_breakdown.html index 01cbc8fe6f..295fcf736c 100644 --- a/leo_lang/cli/commands/deploy/fn.deploy_cost_breakdown.html +++ b/leo_lang/cli/commands/deploy/fn.deploy_cost_breakdown.html @@ -5,4 +5,4 @@ synthesis_cost: f64, namespace_cost: f64, priority_fee: f64, -) -> Result<()>

\ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/deploy/fn.handle_deploy.html b/leo_lang/cli/commands/deploy/fn.handle_deploy.html index 584f055df2..7970f7b085 100644 --- a/leo_lang/cli/commands/deploy/fn.handle_deploy.html +++ b/leo_lang/cli/commands/deploy/fn.handle_deploy.html @@ -3,4 +3,4 @@ context: Context, network: NetworkName, endpoint: &str, -) -> Result<<Deploy as Command>::Output> \ No newline at end of file +) -> Result<<Deploy as Command>::Output> \ No newline at end of file diff --git a/leo_lang/cli/commands/deploy/struct.Deploy.html b/leo_lang/cli/commands/deploy/struct.Deploy.html index 47ed42a0e4..e39959ccfa 100644 --- a/leo_lang/cli/commands/deploy/struct.Deploy.html +++ b/leo_lang/cli/commands/deploy/struct.Deploy.html @@ -14,10 +14,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Deploy

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Deploy

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Deploy

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/example/struct.Example.html b/leo_lang/cli/commands/example/struct.Example.html index 5a9df5806a..b36c569a32 100644 --- a/leo_lang/cli/commands/example/struct.Example.html +++ b/leo_lang/cli/commands/example/struct.Example.html @@ -9,14 +9,14 @@ and needs its output result, this is where the result type is defined. Example: type Input: ::Out

§

type Output = ()

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, -this field may be left empty.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>
where +this field may be left empty.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Example

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Example

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Example

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/execute/fn.execution_cost_breakdown.html b/leo_lang/cli/commands/execute/fn.execution_cost_breakdown.html index dd1b92b655..f92acc97d6 100644 --- a/leo_lang/cli/commands/execute/fn.execution_cost_breakdown.html +++ b/leo_lang/cli/commands/execute/fn.execution_cost_breakdown.html @@ -4,4 +4,4 @@ storage_cost: f64, finalize_cost: f64, priority_fee: f64, -) -> Result<()>

\ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/execute/fn.handle_execute.html b/leo_lang/cli/commands/execute/fn.handle_execute.html index f180aa8117..f6570b3e78 100644 --- a/leo_lang/cli/commands/execute/fn.handle_execute.html +++ b/leo_lang/cli/commands/execute/fn.handle_execute.html @@ -3,4 +3,4 @@ context: Context, network: NetworkName, endpoint: &str, -) -> Result<<Execute as Command>::Output> \ No newline at end of file +) -> Result<<Execute as Command>::Output> \ No newline at end of file diff --git a/leo_lang/cli/commands/execute/fn.load_program_from_network.html b/leo_lang/cli/commands/execute/fn.load_program_from_network.html index 3720a0c252..71cd24ec73 100644 --- a/leo_lang/cli/commands/execute/fn.load_program_from_network.html +++ b/leo_lang/cli/commands/execute/fn.load_program_from_network.html @@ -4,5 +4,5 @@ program_id: &ProgramID<N>, network: NetworkName, endpoint: &str, -) -> Result<()>
Expand description

A helper function to recursively load the program and all of its imports into the process. Lifted from snarkOS.

+) -> Result<()>
Expand description

A helper function to recursively load the program and all of its imports into the process. Lifted from snarkOS.

\ No newline at end of file diff --git a/leo_lang/cli/commands/execute/struct.Execute.html b/leo_lang/cli/commands/execute/struct.Execute.html index 246313c03b..7f8b09348a 100644 --- a/leo_lang/cli/commands/execute/struct.Execute.html +++ b/leo_lang/cli/commands/execute/struct.Execute.html @@ -18,10 +18,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Execute

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Execute

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Execute

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/fn.check_balance.html b/leo_lang/cli/commands/fn.check_balance.html index 78e48aa94e..7ef6ade9e5 100644 --- a/leo_lang/cli/commands/fn.check_balance.html +++ b/leo_lang/cli/commands/fn.check_balance.html @@ -4,4 +4,4 @@ network: &str, context: Context, total_cost: u64, -) -> Result<()>

\ No newline at end of file +) -> Result<()> \ No newline at end of file diff --git a/leo_lang/cli/commands/fn.handle_broadcast.html b/leo_lang/cli/commands/fn.handle_broadcast.html index 3919228248..393dc5ae60 100644 --- a/leo_lang/cli/commands/fn.handle_broadcast.html +++ b/leo_lang/cli/commands/fn.handle_broadcast.html @@ -2,5 +2,5 @@ endpoint: &String, transaction: Transaction<N>, operation: &String, -) -> Result<()>
Expand description

Determine if the transaction should be broadcast or displayed to user.

+) -> Result<()>
Expand description

Determine if the transaction should be broadcast or displayed to user.

\ No newline at end of file diff --git a/leo_lang/cli/commands/fn.parse_record.html b/leo_lang/cli/commands/fn.parse_record.html index 0cdcda6c60..ae39fd220a 100644 --- a/leo_lang/cli/commands/fn.parse_record.html +++ b/leo_lang/cli/commands/fn.parse_record.html @@ -1,5 +1,5 @@ parse_record in leo_lang::cli::commands - Rust

Function leo_lang::cli::commands::parse_record

source ·
pub fn parse_record<N: Network>(
     private_key: &PrivateKey<N>,
     record: &str,
-) -> Result<Record<N, Plaintext<N>>>
Expand description

Parses the record string. If the string is a ciphertext, then attempt to decrypt it. Lifted from snarkOS.

+) -> Result<Record<N, Plaintext<N>>>
Expand description

Parses the record string. If the string is a ciphertext, then attempt to decrypt it. Lifted from snarkOS.

\ No newline at end of file diff --git a/leo_lang/cli/commands/new/struct.New.html b/leo_lang/cli/commands/new/struct.New.html index e2b0ac3c87..a183357248 100644 --- a/leo_lang/cli/commands/new/struct.New.html +++ b/leo_lang/cli/commands/new/struct.New.html @@ -12,10 +12,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for New

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for New

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for New

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/block/struct.Block.html b/leo_lang/cli/commands/query/block/struct.Block.html index 03be515be3..79c2f4fdbe 100644 --- a/leo_lang/cli/commands/query/block/struct.Block.html +++ b/leo_lang/cli/commands/query/block/struct.Block.html @@ -15,10 +15,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Block

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Block

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Block

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/committee/struct.Committee.html b/leo_lang/cli/commands/query/committee/struct.Committee.html index 65a631fd08..59bb61c0b0 100644 --- a/leo_lang/cli/commands/query/committee/struct.Committee.html +++ b/leo_lang/cli/commands/query/committee/struct.Committee.html @@ -8,10 +8,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Committee

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Committee

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Committee

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/fn.handle_query.html b/leo_lang/cli/commands/query/fn.handle_query.html index 9beba13f8a..3a8a092a06 100644 --- a/leo_lang/cli/commands/query/fn.handle_query.html +++ b/leo_lang/cli/commands/query/fn.handle_query.html @@ -3,4 +3,4 @@ context: Context, network: &str, endpoint: &str, -) -> Result<<Query as Command>::Output>

\ No newline at end of file +) -> Result<<Query as Command>::Output> \ No newline at end of file diff --git a/leo_lang/cli/commands/query/mempool/struct.Mempool.html b/leo_lang/cli/commands/query/mempool/struct.Mempool.html index b146ebdead..14d1886dc6 100644 --- a/leo_lang/cli/commands/query/mempool/struct.Mempool.html +++ b/leo_lang/cli/commands/query/mempool/struct.Mempool.html @@ -10,10 +10,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Mempool

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Mempool

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Mempool

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/peers/struct.Peers.html b/leo_lang/cli/commands/query/peers/struct.Peers.html index 61a801c3b0..9605522451 100644 --- a/leo_lang/cli/commands/query/peers/struct.Peers.html +++ b/leo_lang/cli/commands/query/peers/struct.Peers.html @@ -10,10 +10,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Peers

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Peers

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Peers

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/program/struct.Program.html b/leo_lang/cli/commands/query/program/struct.Program.html index a37452a30d..337faf1c56 100644 --- a/leo_lang/cli/commands/query/program/struct.Program.html +++ b/leo_lang/cli/commands/query/program/struct.Program.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Program

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Program

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Program

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/state_root/struct.StateRoot.html b/leo_lang/cli/commands/query/state_root/struct.StateRoot.html index 37cb943484..99f64e9074 100644 --- a/leo_lang/cli/commands/query/state_root/struct.StateRoot.html +++ b/leo_lang/cli/commands/query/state_root/struct.StateRoot.html @@ -8,10 +8,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for StateRoot

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for StateRoot

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for StateRoot

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/struct.Query.html b/leo_lang/cli/commands/query/struct.Query.html index cebed68e2e..266037afb7 100644 --- a/leo_lang/cli/commands/query/struct.Query.html +++ b/leo_lang/cli/commands/query/struct.Query.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Query

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Query

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Query

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/transaction/struct.Transaction.html b/leo_lang/cli/commands/query/transaction/struct.Transaction.html index 3477581df5..1d9fbbff0e 100644 --- a/leo_lang/cli/commands/query/transaction/struct.Transaction.html +++ b/leo_lang/cli/commands/query/transaction/struct.Transaction.html @@ -14,10 +14,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Transaction

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Transaction

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Transaction

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/query/utils/fn.is_valid_field.html b/leo_lang/cli/commands/query/utils/fn.is_valid_field.html index 824e033a6a..c5aa261658 100644 --- a/leo_lang/cli/commands/query/utils/fn.is_valid_field.html +++ b/leo_lang/cli/commands/query/utils/fn.is_valid_field.html @@ -1 +1 @@ -is_valid_field in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_field

source ·
pub fn is_valid_field(field: &str) -> Result<String, LeoError>
\ No newline at end of file +is_valid_field in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_field

source ·
pub fn is_valid_field(field: &str) -> Result<String, LeoError>
\ No newline at end of file diff --git a/leo_lang/cli/commands/query/utils/fn.is_valid_hash.html b/leo_lang/cli/commands/query/utils/fn.is_valid_hash.html index acb0d04773..37552968de 100644 --- a/leo_lang/cli/commands/query/utils/fn.is_valid_hash.html +++ b/leo_lang/cli/commands/query/utils/fn.is_valid_hash.html @@ -1 +1 @@ -is_valid_hash in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_hash

source ·
pub fn is_valid_hash(hash: &str) -> Result<(), LeoError>
\ No newline at end of file +is_valid_hash in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_hash

source ·
pub fn is_valid_hash(hash: &str) -> Result<(), LeoError>
\ No newline at end of file diff --git a/leo_lang/cli/commands/query/utils/fn.is_valid_height_or_hash.html b/leo_lang/cli/commands/query/utils/fn.is_valid_height_or_hash.html index 43a996ad6d..5a2c16cb57 100644 --- a/leo_lang/cli/commands/query/utils/fn.is_valid_height_or_hash.html +++ b/leo_lang/cli/commands/query/utils/fn.is_valid_height_or_hash.html @@ -1 +1 @@ -is_valid_height_or_hash in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_height_or_hash

source ·
pub fn is_valid_height_or_hash(input: &str) -> Result<(), LeoError>
\ No newline at end of file +is_valid_height_or_hash in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_height_or_hash

source ·
pub fn is_valid_height_or_hash(input: &str) -> Result<(), LeoError>
\ No newline at end of file diff --git a/leo_lang/cli/commands/query/utils/fn.is_valid_numerical_input.html b/leo_lang/cli/commands/query/utils/fn.is_valid_numerical_input.html index a475494729..52001e6c63 100644 --- a/leo_lang/cli/commands/query/utils/fn.is_valid_numerical_input.html +++ b/leo_lang/cli/commands/query/utils/fn.is_valid_numerical_input.html @@ -1 +1 @@ -is_valid_numerical_input in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_numerical_input

source ·
pub fn is_valid_numerical_input(num: &str) -> Result<(), LeoError>
\ No newline at end of file +is_valid_numerical_input in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_numerical_input

source ·
pub fn is_valid_numerical_input(num: &str) -> Result<(), LeoError>
\ No newline at end of file diff --git a/leo_lang/cli/commands/query/utils/fn.is_valid_transaction_id.html b/leo_lang/cli/commands/query/utils/fn.is_valid_transaction_id.html index 264e8fd1d5..214bde7892 100644 --- a/leo_lang/cli/commands/query/utils/fn.is_valid_transaction_id.html +++ b/leo_lang/cli/commands/query/utils/fn.is_valid_transaction_id.html @@ -1 +1 @@ -is_valid_transaction_id in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_transaction_id

source ·
pub fn is_valid_transaction_id(transaction: &str) -> Result<(), LeoError>
\ No newline at end of file +is_valid_transaction_id in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_transaction_id

source ·
pub fn is_valid_transaction_id(transaction: &str) -> Result<(), LeoError>
\ No newline at end of file diff --git a/leo_lang/cli/commands/query/utils/fn.is_valid_transition_id.html b/leo_lang/cli/commands/query/utils/fn.is_valid_transition_id.html index 158df3276c..63ee88d84c 100644 --- a/leo_lang/cli/commands/query/utils/fn.is_valid_transition_id.html +++ b/leo_lang/cli/commands/query/utils/fn.is_valid_transition_id.html @@ -1 +1 @@ -is_valid_transition_id in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_transition_id

source ·
pub fn is_valid_transition_id(transition: &str) -> Result<(), LeoError>
\ No newline at end of file +is_valid_transition_id in leo_lang::cli::commands::query::utils - Rust

Function leo_lang::cli::commands::query::utils::is_valid_transition_id

source ·
pub fn is_valid_transition_id(transition: &str) -> Result<(), LeoError>
\ No newline at end of file diff --git a/leo_lang/cli/commands/remove/struct.Remove.html b/leo_lang/cli/commands/remove/struct.Remove.html index d01920bb1b..004682e0ac 100644 --- a/leo_lang/cli/commands/remove/struct.Remove.html +++ b/leo_lang/cli/commands/remove/struct.Remove.html @@ -11,10 +11,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Remove

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Remove

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Remove

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/run/fn.handle_run.html b/leo_lang/cli/commands/run/fn.handle_run.html index f4e366638f..a3be65547f 100644 --- a/leo_lang/cli/commands/run/fn.handle_run.html +++ b/leo_lang/cli/commands/run/fn.handle_run.html @@ -1,4 +1,4 @@ handle_run in leo_lang::cli::commands::run - Rust

Function leo_lang::cli::commands::run::handle_run

source ·
fn handle_run<N: Network>(
     command: Run,
     context: Context,
-) -> Result<<Run as Command>::Output>
\ No newline at end of file +) -> Result<<Run as Command>::Output>

\ No newline at end of file diff --git a/leo_lang/cli/commands/run/struct.Run.html b/leo_lang/cli/commands/run/struct.Run.html index ff83b8bd51..cdce4e25f0 100644 --- a/leo_lang/cli/commands/run/struct.Run.html +++ b/leo_lang/cli/commands/run/struct.Run.html @@ -13,10 +13,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Run

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Run

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Run

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/commands/trait.Command.html b/leo_lang/cli/commands/trait.Command.html index 363ef737ef..cab79dc751 100644 --- a/leo_lang/cli/commands/trait.Command.html +++ b/leo_lang/cli/commands/trait.Command.html @@ -3,16 +3,16 @@ type Output; // Required methods - fn prelude(&self, context: Context) -> Result<Self::Input> + fn prelude(&self, context: Context) -> Result<Self::Input> where Self: Sized; - fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output> + fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output> where Self: Sized; // Provided methods fn log_span(&self) -> Span { ... } - fn execute(self, context: Context) -> Result<Self::Output> + fn execute(self, context: Context) -> Result<Self::Output> where Self: Sized { ... } - fn try_execute(self, context: Context) -> Result<()> + fn try_execute(self, context: Context) -> Result<()> where Self: Sized { ... } }
Expand description

Base trait for the Leo CLI, see methods and their documentation for details.

Required Associated Types§

source

type Input

If the current command requires running another command beforehand @@ -21,19 +21,19 @@

source

type Output

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, this field may be left empty.

-

Required Methods§

source

fn prelude(&self, context: Context) -> Result<Self::Input>
where +

Required Methods§

source

fn prelude(&self, context: Context) -> Result<Self::Input>
where Self: Sized,

Runs the prelude and returns the Input of the current command.

-
source

fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output>
where +

source

fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.

Provided Methods§

source

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this variable is a &’static str.

-
source

fn execute(self, context: Context) -> Result<Self::Output>
where +

source

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. This function sets up tracing, timing, and the context.

-
source

fn try_execute(self, context: Context) -> Result<()>
where +

source

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error

diff --git a/leo_lang/cli/commands/update/struct.Update.html b/leo_lang/cli/commands/update/struct.Update.html index 62b7fa976c..1afc4571ef 100644 --- a/leo_lang/cli/commands/update/struct.Update.html +++ b/leo_lang/cli/commands/update/struct.Update.html @@ -13,11 +13,11 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _: Context, _: Self::Input) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +context of ‘execute’ function, which sets logging and timers.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Update

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Update

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Update

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/context/struct.Context.html b/leo_lang/cli/context/struct.Context.html index b3eb00b657..966434a58d 100644 --- a/leo_lang/cli/context/struct.Context.html +++ b/leo_lang/cli/context/struct.Context.html @@ -11,24 +11,24 @@ path: Option<PathBuf>, home: Option<PathBuf>, recursive: bool, -) -> Result<Context>

source

pub fn parent_dir(&self) -> Result<PathBuf>

Returns the path of the parent directory to the Leo package.

-
source

pub fn dir(&self) -> Result<PathBuf>

Returns the path to the Leo package.

-
source

pub fn home(&self) -> Result<PathBuf>

Returns the path to the Aleo registry directory.

-
source

pub fn open_manifest<N: Network>(&self) -> Result<Manifest<N>>

Returns the package name as a String. +) -> Result<Context>

source

pub fn parent_dir(&self) -> Result<PathBuf>

Returns the path of the parent directory to the Leo package.

+
source

pub fn dir(&self) -> Result<PathBuf>

Returns the path to the Leo package.

+
source

pub fn home(&self) -> Result<PathBuf>

Returns the path to the Aleo registry directory.

+
source

pub fn open_manifest<N: Network>(&self) -> Result<Manifest<N>>

Returns the package name as a String. Opens the manifest file program.json and creates the build directory if it doesn’t exist.

-
source

pub fn local_dependency_paths(&self) -> Result<Vec<(String, PathBuf)>>

Returns a post ordering of the local dependencies. +

source

pub fn local_dependency_paths(&self) -> Result<Vec<(String, PathBuf)>>

Returns a post ordering of the local dependencies. Found by reading the lock file leo.lock.

-
source

pub fn dotenv_private_key<N: Network>(&self) -> Result<PrivateKey<N>>

Returns the private key from the .env file specified in the directory.

-
source

pub fn dotenv_endpoint(&self) -> Result<String>

Returns the endpoint from the .env file specified in the directory.

-
source

pub fn dotenv_network(&self) -> Result<String>

Returns the network from the .env file specified in the directory.

-
source

pub fn get_endpoint(&self, endpoint: &Option<String>) -> Result<String>

Returns the endpoint to interact with the network. +

source

pub fn dotenv_private_key<N: Network>(&self) -> Result<PrivateKey<N>>

Returns the private key from the .env file specified in the directory.

+
source

pub fn dotenv_endpoint(&self) -> Result<String>

Returns the endpoint from the .env file specified in the directory.

+
source

pub fn dotenv_network(&self) -> Result<String>

Returns the network from the .env file specified in the directory.

+
source

pub fn get_endpoint(&self, endpoint: &Option<String>) -> Result<String>

Returns the endpoint to interact with the network. If the --endpoint options is not provided, it will default to the one in the .env file.

-
source

pub fn get_network(&self, network: &Option<String>) -> Result<String>

Returns the network name. +

source

pub fn get_network(&self, network: &Option<String>) -> Result<String>

Returns the network name. If the --network options is not provided, it will default to the one in the .env file.

source

pub fn get_private_key<N: Network>( &self, private_key: &Option<String>, -) -> Result<PrivateKey<N>>

Returns the private key. +) -> Result<PrivateKey<N>>

Returns the private key. If the --private-key options is not provided, it will default to the one in the .env file.

Trait Implementations§

source§

impl Clone for Context

source§

fn clone(&self) -> Context

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_lang/cli/deploy/struct.Deploy.html b/leo_lang/cli/deploy/struct.Deploy.html index f231966333..968647117b 100644 --- a/leo_lang/cli/deploy/struct.Deploy.html +++ b/leo_lang/cli/deploy/struct.Deploy.html @@ -14,10 +14,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Deploy

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Deploy

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Deploy

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/enum.Account.html b/leo_lang/cli/enum.Account.html index 1f4a1578fe..21b04da33e 100644 --- a/leo_lang/cli/enum.Account.html +++ b/leo_lang/cli/enum.Account.html @@ -50,15 +50,15 @@ and needs its output result, this is where the result type is defined. Example: type Input: ::Out

§

type Output = ()

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, -this field may be left empty.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>
where - Self: Sized,

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, ctx: Context, _: Self::Input) -> Result<Self::Output>
where +this field may be left empty.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>
where + Self: Sized,

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, ctx: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Account

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Account

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Account

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/example/struct.Example.html b/leo_lang/cli/example/struct.Example.html index 88ffefeaab..1724da195b 100644 --- a/leo_lang/cli/example/struct.Example.html +++ b/leo_lang/cli/example/struct.Example.html @@ -9,14 +9,14 @@ and needs its output result, this is where the result type is defined. Example: type Input: ::Out

§

type Output = ()

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, -this field may be left empty.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>
where +this field may be left empty.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Example

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Example

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Example

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/execute/struct.Execute.html b/leo_lang/cli/execute/struct.Execute.html index a90dde1c01..0954c349a2 100644 --- a/leo_lang/cli/execute/struct.Execute.html +++ b/leo_lang/cli/execute/struct.Execute.html @@ -18,10 +18,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Execute

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Execute

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Execute

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/fn.handle_error.html b/leo_lang/cli/fn.handle_error.html index bad5c47ca8..32c2b64cc9 100644 --- a/leo_lang/cli/fn.handle_error.html +++ b/leo_lang/cli/fn.handle_error.html @@ -1 +1 @@ -handle_error in leo_lang::cli - Rust

Function leo_lang::cli::handle_error

source ·
pub fn handle_error<T>(res: Result<T>) -> T
\ No newline at end of file +handle_error in leo_lang::cli - Rust

Function leo_lang::cli::handle_error

source ·
pub fn handle_error<T>(res: Result<T>) -> T
\ No newline at end of file diff --git a/leo_lang/cli/fn.parse_record.html b/leo_lang/cli/fn.parse_record.html index 9d8de9a8dc..6def2f2366 100644 --- a/leo_lang/cli/fn.parse_record.html +++ b/leo_lang/cli/fn.parse_record.html @@ -1,5 +1,5 @@ parse_record in leo_lang::cli - Rust

Function leo_lang::cli::parse_record

source ·
pub fn parse_record<N: Network>(
     private_key: &PrivateKey<N>,
     record: &str,
-) -> Result<Record<N, Plaintext<N>>>
Expand description

Parses the record string. If the string is a ciphertext, then attempt to decrypt it. Lifted from snarkOS.

+) -> Result<Record<N, Plaintext<N>>>
Expand description

Parses the record string. If the string is a ciphertext, then attempt to decrypt it. Lifted from snarkOS.

\ No newline at end of file diff --git a/leo_lang/cli/fn.run_with_args.html b/leo_lang/cli/fn.run_with_args.html index b220f31991..b717e8ba6f 100644 --- a/leo_lang/cli/fn.run_with_args.html +++ b/leo_lang/cli/fn.run_with_args.html @@ -1,2 +1,2 @@ -run_with_args in leo_lang::cli - Rust

Function leo_lang::cli::run_with_args

source ·
pub fn run_with_args(cli: CLI) -> Result<()>
Expand description

Run command with custom build arguments.

+run_with_args in leo_lang::cli - Rust

Function leo_lang::cli::run_with_args

source ·
pub fn run_with_args(cli: CLI) -> Result<()>
Expand description

Run command with custom build arguments.

\ No newline at end of file diff --git a/leo_lang/cli/helpers/context/struct.Context.html b/leo_lang/cli/helpers/context/struct.Context.html index 4a6caa3148..81305e72af 100644 --- a/leo_lang/cli/helpers/context/struct.Context.html +++ b/leo_lang/cli/helpers/context/struct.Context.html @@ -11,24 +11,24 @@ path: Option<PathBuf>, home: Option<PathBuf>, recursive: bool, -) -> Result<Context>

source

pub fn parent_dir(&self) -> Result<PathBuf>

Returns the path of the parent directory to the Leo package.

-
source

pub fn dir(&self) -> Result<PathBuf>

Returns the path to the Leo package.

-
source

pub fn home(&self) -> Result<PathBuf>

Returns the path to the Aleo registry directory.

-
source

pub fn open_manifest<N: Network>(&self) -> Result<Manifest<N>>

Returns the package name as a String. +) -> Result<Context>

source

pub fn parent_dir(&self) -> Result<PathBuf>

Returns the path of the parent directory to the Leo package.

+
source

pub fn dir(&self) -> Result<PathBuf>

Returns the path to the Leo package.

+
source

pub fn home(&self) -> Result<PathBuf>

Returns the path to the Aleo registry directory.

+
source

pub fn open_manifest<N: Network>(&self) -> Result<Manifest<N>>

Returns the package name as a String. Opens the manifest file program.json and creates the build directory if it doesn’t exist.

-
source

pub fn local_dependency_paths(&self) -> Result<Vec<(String, PathBuf)>>

Returns a post ordering of the local dependencies. +

source

pub fn local_dependency_paths(&self) -> Result<Vec<(String, PathBuf)>>

Returns a post ordering of the local dependencies. Found by reading the lock file leo.lock.

-
source

pub fn dotenv_private_key<N: Network>(&self) -> Result<PrivateKey<N>>

Returns the private key from the .env file specified in the directory.

-
source

pub fn dotenv_endpoint(&self) -> Result<String>

Returns the endpoint from the .env file specified in the directory.

-
source

pub fn dotenv_network(&self) -> Result<String>

Returns the network from the .env file specified in the directory.

-
source

pub fn get_endpoint(&self, endpoint: &Option<String>) -> Result<String>

Returns the endpoint to interact with the network. +

source

pub fn dotenv_private_key<N: Network>(&self) -> Result<PrivateKey<N>>

Returns the private key from the .env file specified in the directory.

+
source

pub fn dotenv_endpoint(&self) -> Result<String>

Returns the endpoint from the .env file specified in the directory.

+
source

pub fn dotenv_network(&self) -> Result<String>

Returns the network from the .env file specified in the directory.

+
source

pub fn get_endpoint(&self, endpoint: &Option<String>) -> Result<String>

Returns the endpoint to interact with the network. If the --endpoint options is not provided, it will default to the one in the .env file.

-
source

pub fn get_network(&self, network: &Option<String>) -> Result<String>

Returns the network name. +

source

pub fn get_network(&self, network: &Option<String>) -> Result<String>

Returns the network name. If the --network options is not provided, it will default to the one in the .env file.

source

pub fn get_private_key<N: Network>( &self, private_key: &Option<String>, -) -> Result<PrivateKey<N>>

Returns the private key. +) -> Result<PrivateKey<N>>

Returns the private key. If the --private-key options is not provided, it will default to the one in the .env file.

Trait Implementations§

source§

impl Clone for Context

source§

fn clone(&self) -> Context

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more

Auto Trait Implementations§

§

impl Freeze for Context

§

impl RefUnwindSafe for Context

§

impl Send for Context

§

impl Sync for Context

§

impl Unpin for Context

§

impl UnwindSafe for Context

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_lang/cli/helpers/logger/fn.init_logger.html b/leo_lang/cli/helpers/logger/fn.init_logger.html index 99c53cce93..ddc845942c 100644 --- a/leo_lang/cli/helpers/logger/fn.init_logger.html +++ b/leo_lang/cli/helpers/logger/fn.init_logger.html @@ -1,2 +1,2 @@ -init_logger in leo_lang::cli::helpers::logger - Rust

Function leo_lang::cli::helpers::logger::init_logger

source ·
pub fn init_logger(_app_name: &'static str, verbosity: usize) -> Result<()>
Expand description

Initialize logger with custom format and verbosity.

+init_logger in leo_lang::cli::helpers::logger - Rust

Function leo_lang::cli::helpers::logger::init_logger

source ·
pub fn init_logger(_app_name: &'static str, verbosity: usize) -> Result<()>
Expand description

Initialize logger with custom format and verbosity.

\ No newline at end of file diff --git a/leo_lang/cli/helpers/updater/struct.Updater.html b/leo_lang/cli/helpers/updater/struct.Updater.html index 3700a3a313..1d5769bb7c 100644 --- a/leo_lang/cli/helpers/updater/struct.Updater.html +++ b/leo_lang/cli/helpers/updater/struct.Updater.html @@ -1,6 +1,6 @@ -Updater in leo_lang::cli::helpers::updater - Rust

Struct leo_lang::cli::helpers::updater::Updater

source ·
pub struct Updater;

Implementations§

source§

impl Updater

source

const LEO_BIN_NAME: &'static str = "leo"

source

const LEO_REPO_NAME: &'static str = "leo"

source

const LEO_REPO_OWNER: &'static str = "AleoHQ"

source

pub fn show_available_releases() -> Result<String>

Show all available releases for leo.

-
source

pub fn update_to_latest_release(show_output: bool) -> Result<Status>

Update leo to the latest release.

-
source

pub fn update_available() -> Result<String>

Check if there is an available update for leo and return the newest release.

+Updater in leo_lang::cli::helpers::updater - Rust

Struct leo_lang::cli::helpers::updater::Updater

source ·
pub struct Updater;

Implementations§

source§

impl Updater

source

const LEO_BIN_NAME: &'static str = "leo"

source

const LEO_REPO_NAME: &'static str = "leo"

source

const LEO_REPO_OWNER: &'static str = "AleoHQ"

source

pub fn show_available_releases() -> Result<String>

Show all available releases for leo.

+
source

pub fn update_to_latest_release(show_output: bool) -> Result<Status>

Update leo to the latest release.

+
source

pub fn update_available() -> Result<String>

Check if there is an available update for leo and return the newest release.

source

pub fn print_cli()

Display the CLI message, if the Leo configuration allows.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_lang/cli/logger/fn.init_logger.html b/leo_lang/cli/logger/fn.init_logger.html index 8aaea6b2a1..7c9cbe7156 100644 --- a/leo_lang/cli/logger/fn.init_logger.html +++ b/leo_lang/cli/logger/fn.init_logger.html @@ -1,2 +1,2 @@ -init_logger in leo_lang::cli::logger - Rust

Function leo_lang::cli::logger::init_logger

source ·
pub fn init_logger(_app_name: &'static str, verbosity: usize) -> Result<()>
Expand description

Initialize logger with custom format and verbosity.

+init_logger in leo_lang::cli::logger - Rust

Function leo_lang::cli::logger::init_logger

source ·
pub fn init_logger(_app_name: &'static str, verbosity: usize) -> Result<()>
Expand description

Initialize logger with custom format and verbosity.

\ No newline at end of file diff --git a/leo_lang/cli/new/struct.New.html b/leo_lang/cli/new/struct.New.html index a5ab866d52..818a0838c8 100644 --- a/leo_lang/cli/new/struct.New.html +++ b/leo_lang/cli/new/struct.New.html @@ -12,10 +12,10 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error

source§

impl CommandFactory for New

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for New

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for New

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/query/program/struct.Program.html b/leo_lang/cli/query/program/struct.Program.html index 2c0a6e8ff6..1939d137f5 100644 --- a/leo_lang/cli/query/program/struct.Program.html +++ b/leo_lang/cli/query/program/struct.Program.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Program

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Program

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Program

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/query/struct.Program.html b/leo_lang/cli/query/struct.Program.html index 917b8f07a3..0e49b78356 100644 --- a/leo_lang/cli/query/struct.Program.html +++ b/leo_lang/cli/query/struct.Program.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Program

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Program

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Program

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/query/struct.Query.html b/leo_lang/cli/query/struct.Query.html index 7c33d4967e..178f277f1e 100644 --- a/leo_lang/cli/query/struct.Query.html +++ b/leo_lang/cli/query/struct.Query.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Query

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Query

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Query

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/remove/struct.Remove.html b/leo_lang/cli/remove/struct.Remove.html index 0fcb812647..086a0a3dcc 100644 --- a/leo_lang/cli/remove/struct.Remove.html +++ b/leo_lang/cli/remove/struct.Remove.html @@ -11,10 +11,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error

source§

impl CommandFactory for Remove

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Remove

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Remove

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/run/struct.Run.html b/leo_lang/cli/run/struct.Run.html index 751febcefd..de47cb55a2 100644 --- a/leo_lang/cli/run/struct.Run.html +++ b/leo_lang/cli/run/struct.Run.html @@ -13,10 +13,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Run

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Run

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Run

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Add.html b/leo_lang/cli/struct.Add.html index 99be60afd5..c2e21c5e0c 100644 --- a/leo_lang/cli/struct.Add.html +++ b/leo_lang/cli/struct.Add.html @@ -13,10 +13,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Add

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Add

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Add

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Build.html b/leo_lang/cli/struct.Build.html index 5c5c057edb..1d083767e5 100644 --- a/leo_lang/cli/struct.Build.html +++ b/leo_lang/cli/struct.Build.html @@ -10,10 +10,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Build

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Build

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Build

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Clean.html b/leo_lang/cli/struct.Clean.html index ec326bab04..fd9328aa22 100644 --- a/leo_lang/cli/struct.Clean.html +++ b/leo_lang/cli/struct.Clean.html @@ -8,10 +8,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Clean

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Clean

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Clean

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Deploy.html b/leo_lang/cli/struct.Deploy.html index 6a0237b383..e71794e864 100644 --- a/leo_lang/cli/struct.Deploy.html +++ b/leo_lang/cli/struct.Deploy.html @@ -14,10 +14,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Deploy

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Deploy

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Deploy

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Example.html b/leo_lang/cli/struct.Example.html index 1e33248a9b..44a3df14e3 100644 --- a/leo_lang/cli/struct.Example.html +++ b/leo_lang/cli/struct.Example.html @@ -9,14 +9,14 @@ and needs its output result, this is where the result type is defined. Example: type Input: ::Out

§

type Output = ()

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, -this field may be left empty.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>
where +this field may be left empty.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Example

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Example

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Example

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Execute.html b/leo_lang/cli/struct.Execute.html index fc529e2355..00072ba9a1 100644 --- a/leo_lang/cli/struct.Execute.html +++ b/leo_lang/cli/struct.Execute.html @@ -18,10 +18,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _input: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Execute

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Execute

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Execute

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.New.html b/leo_lang/cli/struct.New.html index 68ddda05b9..8933462da6 100644 --- a/leo_lang/cli/struct.New.html +++ b/leo_lang/cli/struct.New.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for New

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for New

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for New

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Query.html b/leo_lang/cli/struct.Query.html index 5be919c7a2..2e936312da 100644 --- a/leo_lang/cli/struct.Query.html +++ b/leo_lang/cli/struct.Query.html @@ -12,10 +12,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Query

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Query

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Query

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Remove.html b/leo_lang/cli/struct.Remove.html index a215edfe31..aaae9f73d4 100644 --- a/leo_lang/cli/struct.Remove.html +++ b/leo_lang/cli/struct.Remove.html @@ -11,10 +11,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Remove

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Remove

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Remove

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Run.html b/leo_lang/cli/struct.Run.html index b028eab9b3..eaa08044e9 100644 --- a/leo_lang/cli/struct.Run.html +++ b/leo_lang/cli/struct.Run.html @@ -13,10 +13,10 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, context: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, context: Context, _: Self::Input) -> Result<Self::Output>

Runs the main operation of this command. This function is run within +context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Run

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Run

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Run

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/struct.Update.html b/leo_lang/cli/struct.Update.html index f1874be840..18e57175b4 100644 --- a/leo_lang/cli/struct.Update.html +++ b/leo_lang/cli/struct.Update.html @@ -13,11 +13,11 @@ this field may be left empty.

source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _: Context, _: Self::Input) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +context of ‘execute’ function, which sets logging and timers.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Update

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Update

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Update

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/trait.Command.html b/leo_lang/cli/trait.Command.html index 75c4fb36c6..dbe32542b1 100644 --- a/leo_lang/cli/trait.Command.html +++ b/leo_lang/cli/trait.Command.html @@ -3,16 +3,16 @@ type Output; // Required methods - fn prelude(&self, context: Context) -> Result<Self::Input> + fn prelude(&self, context: Context) -> Result<Self::Input> where Self: Sized; - fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output> + fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output> where Self: Sized; // Provided methods fn log_span(&self) -> Span { ... } - fn execute(self, context: Context) -> Result<Self::Output> + fn execute(self, context: Context) -> Result<Self::Output> where Self: Sized { ... } - fn try_execute(self, context: Context) -> Result<()> + fn try_execute(self, context: Context) -> Result<()> where Self: Sized { ... } }
Expand description

Base trait for the Leo CLI, see methods and their documentation for details.

Required Associated Types§

source

type Input

If the current command requires running another command beforehand @@ -21,19 +21,19 @@

source

type Output

Defines the output of this command, which may be used as Input for another command. If this command is not used as a prelude for another command, this field may be left empty.

-

Required Methods§

source

fn prelude(&self, context: Context) -> Result<Self::Input>
where +

Required Methods§

source

fn prelude(&self, context: Context) -> Result<Self::Input>
where Self: Sized,

Runs the prelude and returns the Input of the current command.

-
source

fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output>
where +

source

fn apply(self, context: Context, input: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within context of ‘execute’ function, which sets logging and timers.

Provided Methods§

source

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this variable is a &’static str.

-
source

fn execute(self, context: Context) -> Result<Self::Output>
where +

source

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. This function sets up tracing, timing, and the context.

-
source

fn try_execute(self, context: Context) -> Result<()>
where +

source

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error

diff --git a/leo_lang/cli/update/struct.Update.html b/leo_lang/cli/update/struct.Update.html index 93c14d6572..6e899a1788 100644 --- a/leo_lang/cli/update/struct.Update.html +++ b/leo_lang/cli/update/struct.Update.html @@ -13,11 +13,11 @@ this field may be left empty.
source§

fn log_span(&self) -> Span

Adds a span to the logger via tracing::span. Because of the specifics of the macro implementation, it is not possible to set the span name with a non-literal i.e. a dynamic variable even if this -variable is a &’static str.
source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _: Context, _: Self::Input) -> Result<Self::Output>
where +variable is a &’static str.

source§

fn prelude(&self, _: Context) -> Result<Self::Input>

Runs the prelude and returns the Input of the current command.
source§

fn apply(self, _: Context, _: Self::Input) -> Result<Self::Output>
where Self: Sized,

Runs the main operation of this command. This function is run within -context of ‘execute’ function, which sets logging and timers.
source§

fn execute(self, context: Context) -> Result<Self::Output>
where +context of ‘execute’ function, which sets logging and timers.

source§

fn execute(self, context: Context) -> Result<Self::Output>
where Self: Sized,

A wrapper around the apply method. -This function sets up tracing, timing, and the context.
source§

fn try_execute(self, context: Context) -> Result<()>
where +This function sets up tracing, timing, and the context.

source§

fn try_execute(self, context: Context) -> Result<()>
where Self: Sized,

Executes command but empty the result. Comes in handy where there’s a need to make match arms compatible while keeping implementation-specific output possible. Errors however are all of the type Error
source§

impl CommandFactory for Update

source§

fn command<'b>() -> Command

Build a [Command] that can instantiate Self. Read more
source§

fn command_for_update<'b>() -> Command

Build a [Command] that can update self. Read more
source§

impl Debug for Update

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for Update

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from [ArgMatches], parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( diff --git a/leo_lang/cli/updater/struct.Updater.html b/leo_lang/cli/updater/struct.Updater.html index b9da50f092..d3408a4486 100644 --- a/leo_lang/cli/updater/struct.Updater.html +++ b/leo_lang/cli/updater/struct.Updater.html @@ -1,6 +1,6 @@ -Updater in leo_lang::cli::updater - Rust

Struct leo_lang::cli::updater::Updater

source ·
pub struct Updater;

Implementations§

source§

impl Updater

source

const LEO_BIN_NAME: &'static str = "leo"

source

const LEO_REPO_NAME: &'static str = "leo"

source

const LEO_REPO_OWNER: &'static str = "AleoHQ"

source

pub fn show_available_releases() -> Result<String>

Show all available releases for leo.

-
source

pub fn update_to_latest_release(show_output: bool) -> Result<Status>

Update leo to the latest release.

-
source

pub fn update_available() -> Result<String>

Check if there is an available update for leo and return the newest release.

+Updater in leo_lang::cli::updater - Rust

Struct leo_lang::cli::updater::Updater

source ·
pub struct Updater;

Implementations§

source§

impl Updater

source

const LEO_BIN_NAME: &'static str = "leo"

source

const LEO_REPO_NAME: &'static str = "leo"

source

const LEO_REPO_OWNER: &'static str = "AleoHQ"

source

pub fn show_available_releases() -> Result<String>

Show all available releases for leo.

+
source

pub fn update_to_latest_release(show_output: bool) -> Result<Status>

Update leo to the latest release.

+
source

pub fn update_available() -> Result<String>

Check if there is an available update for leo and return the newest release.

source

pub fn print_cli()

Display the CLI message, if the Leo configuration allows.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_package/build/directory/struct.BuildDirectory.html b/leo_package/build/directory/struct.BuildDirectory.html index f0c851bec5..e53e7d3864 100644 --- a/leo_package/build/directory/struct.BuildDirectory.html +++ b/leo_package/build/directory/struct.BuildDirectory.html @@ -1,6 +1,6 @@ -BuildDirectory in leo_package::build::directory - Rust

Struct leo_package::build::directory::BuildDirectory

source ·
pub struct BuildDirectory;

Implementations§

source§

impl BuildDirectory

source

pub fn open(path: &Path) -> Result<PathBuf>

Returns the path to the build directory if it exists.

-
source

pub fn create(path: &Path) -> Result<PathBuf>

Creates a directory at the provided path with the default directory name.

-
source

pub fn remove(path: &Path) -> Result<String>

Removes the directory at the provided path.

+BuildDirectory in leo_package::build::directory - Rust

Struct leo_package::build::directory::BuildDirectory

source ·
pub struct BuildDirectory;

Implementations§

source§

impl BuildDirectory

source

pub fn open(path: &Path) -> Result<PathBuf>

Returns the path to the build directory if it exists.

+
source

pub fn create(path: &Path) -> Result<PathBuf>

Creates a directory at the provided path with the default directory name.

+
source

pub fn remove(path: &Path) -> Result<String>

Removes the directory at the provided path.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_package/fn.parse_file_paths.html b/leo_package/fn.parse_file_paths.html index 93f36b783e..bf8a2b73aa 100644 --- a/leo_package/fn.parse_file_paths.html +++ b/leo_package/fn.parse_file_paths.html @@ -1,4 +1,4 @@ parse_file_paths in leo_package - Rust

Function leo_package::parse_file_paths

source ·
pub(crate) fn parse_file_paths(
     directory: ReadDir,
     file_paths: &mut Vec<PathBuf>,
-) -> Result<()>
\ No newline at end of file +) -> Result<()>

\ No newline at end of file diff --git a/leo_package/imports/directory/struct.ImportsDirectory.html b/leo_package/imports/directory/struct.ImportsDirectory.html index 01a3f2d448..ee10d168c8 100644 --- a/leo_package/imports/directory/struct.ImportsDirectory.html +++ b/leo_package/imports/directory/struct.ImportsDirectory.html @@ -1,7 +1,7 @@ -ImportsDirectory in leo_package::imports::directory - Rust

Struct leo_package::imports::directory::ImportsDirectory

source ·
pub struct ImportsDirectory;

Implementations§

source§

impl ImportsDirectory

source

pub fn create(path: &Path) -> Result<PathBuf>

Creates a directory at the provided path with the default directory name if it does not exist.

-
source

pub fn remove(path: &Path) -> Result<String>

Removes the directory at the provided path.

-
source

pub fn is_empty(path: &Path) -> Result<bool>

Returns true if the imports directory does not exist or does not contain files.

-
source

pub fn files(path: &Path) -> Result<Vec<PathBuf>>

Returns a list of files in the imports directory.

+ImportsDirectory in leo_package::imports::directory - Rust

Struct leo_package::imports::directory::ImportsDirectory

source ·
pub struct ImportsDirectory;

Implementations§

source§

impl ImportsDirectory

source

pub fn create(path: &Path) -> Result<PathBuf>

Creates a directory at the provided path with the default directory name if it does not exist.

+
source

pub fn remove(path: &Path) -> Result<String>

Removes the directory at the provided path.

+
source

pub fn is_empty(path: &Path) -> Result<bool>

Returns true if the imports directory does not exist or does not contain files.

+
source

pub fn files(path: &Path) -> Result<Vec<PathBuf>>

Returns a list of files in the imports directory.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_package/inputs/directory/fn.parse_file_paths.html b/leo_package/inputs/directory/fn.parse_file_paths.html index 6493b634a9..f19ff08003 100644 --- a/leo_package/inputs/directory/fn.parse_file_paths.html +++ b/leo_package/inputs/directory/fn.parse_file_paths.html @@ -1,4 +1,4 @@ parse_file_paths in leo_package::inputs::directory - Rust

Function leo_package::inputs::directory::parse_file_paths

source ·
fn parse_file_paths(
     directory: ReadDir,
     file_paths: &mut Vec<PathBuf>,
-) -> Result<()>
\ No newline at end of file +) -> Result<()>

\ No newline at end of file diff --git a/leo_package/inputs/directory/struct.InputsDirectory.html b/leo_package/inputs/directory/struct.InputsDirectory.html index 7fc3651434..1722be8877 100644 --- a/leo_package/inputs/directory/struct.InputsDirectory.html +++ b/leo_package/inputs/directory/struct.InputsDirectory.html @@ -1,5 +1,5 @@ -InputsDirectory in leo_package::inputs::directory - Rust

Struct leo_package::inputs::directory::InputsDirectory

source ·
pub struct InputsDirectory;

Implementations§

source§

impl InputsDirectory

source

pub fn create(path: &Path) -> Result<()>

Creates a directory at the provided path with the default directory name.

-
source

pub fn files(path: &Path) -> Result<Vec<PathBuf>>

Returns a list of files in the input directory.

+InputsDirectory in leo_package::inputs::directory - Rust

Struct leo_package::inputs::directory::InputsDirectory

source ·
pub struct InputsDirectory;

Implementations§

source§

impl InputsDirectory

source

pub fn create(path: &Path) -> Result<()>

Creates a directory at the provided path with the default directory name.

+
source

pub fn files(path: &Path) -> Result<Vec<PathBuf>>

Returns a list of files in the input directory.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_package/outputs/ast_snapshot/struct.SnapshotFile.html b/leo_package/outputs/ast_snapshot/struct.SnapshotFile.html index 6254e1e2fb..f901290504 100644 --- a/leo_package/outputs/ast_snapshot/struct.SnapshotFile.html +++ b/leo_package/outputs/ast_snapshot/struct.SnapshotFile.html @@ -3,8 +3,8 @@ pub snapshot: Snapshot, }
Expand description

Generic Snapshot file wrapper. Each package can have up to 3 different snapshots: initial_ast, canonicalization_ast and type_inferenced_ast;

-

Fields§

§package_name: String§snapshot: Snapshot

Implementations§

source§

impl SnapshotFile

source

pub fn new(package_name: &str, snapshot: Snapshot) -> Self

source

pub fn exists_at(&self, path: &Path) -> bool

source

pub fn read_from(&self, path: &Path) -> Result<String>

Reads the serialized struct from the given file path if it exists.

-
source

pub fn remove(&self, path: &Path) -> Result<bool>

Removes the serialized struct at the given path if it exists. Returns true on success, +

Fields§

§package_name: String§snapshot: Snapshot

Implementations§

source§

impl SnapshotFile

source

pub fn new(package_name: &str, snapshot: Snapshot) -> Self

source

pub fn exists_at(&self, path: &Path) -> bool

source

pub fn read_from(&self, path: &Path) -> Result<String>

Reads the serialized struct from the given file path if it exists.

+
source

pub fn remove(&self, path: &Path) -> Result<bool>

Removes the serialized struct at the given path if it exists. Returns true on success, false if the file doesn’t exist, and Error if the file system fails during operation.

source

fn snapshot_file_path<'a>(&self, path: &'a Path) -> Cow<'a, Path>

Trait Implementations§

source§

impl<'de> Deserialize<'de> for SnapshotFile

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_package/outputs/checksum/struct.ChecksumFile.html b/leo_package/outputs/checksum/struct.ChecksumFile.html index bb7a9b0e32..b7e0f5fc88 100644 --- a/leo_package/outputs/checksum/struct.ChecksumFile.html +++ b/leo_package/outputs/checksum/struct.ChecksumFile.html @@ -1,8 +1,8 @@ ChecksumFile in leo_package::outputs::checksum - Rust

Struct leo_package::outputs::checksum::ChecksumFile

source ·
pub struct ChecksumFile {
     pub package_name: String,
-}

Fields§

§package_name: String

Implementations§

source§

impl ChecksumFile

source

pub fn new(package_name: &str) -> Self

source

pub fn exists_at(&self, path: &Path) -> bool

source

pub fn read_from(&self, path: &Path) -> Result<String>

Reads the checksum from the given file path if it exists.

-
source

pub fn write_to(&self, path: &Path, checksum: String) -> Result<()>

Writes the given checksum to a file.

-
source

pub fn remove(&self, path: &Path) -> Result<bool>

Removes the checksum at the given path if it exists. Returns true on success, +}

Fields§

§package_name: String

Implementations§

source§

impl ChecksumFile

source

pub fn new(package_name: &str) -> Self

source

pub fn exists_at(&self, path: &Path) -> bool

source

pub fn read_from(&self, path: &Path) -> Result<String>

Reads the checksum from the given file path if it exists.

+
source

pub fn write_to(&self, path: &Path, checksum: String) -> Result<()>

Writes the given checksum to a file.

+
source

pub fn remove(&self, path: &Path) -> Result<bool>

Removes the checksum at the given path if it exists. Returns true on success, false if the file doesn’t exist, and Error if the file system fails during operation.

source

fn setup_file_path<'a>(&self, path: &'a Path) -> Cow<'a, Path>

Trait Implementations§

source§

impl<'de> Deserialize<'de> for ChecksumFile

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_package/outputs/circuit/struct.CircuitFile.html b/leo_package/outputs/circuit/struct.CircuitFile.html index 478161d51a..8fbcf5aa63 100644 --- a/leo_package/outputs/circuit/struct.CircuitFile.html +++ b/leo_package/outputs/circuit/struct.CircuitFile.html @@ -1,8 +1,8 @@ CircuitFile in leo_package::outputs::circuit - Rust

Struct leo_package::outputs::circuit::CircuitFile

source ·
pub struct CircuitFile {
     pub package_name: String,
-}

Fields§

§package_name: String

Implementations§

source§

impl CircuitFile

source

pub fn new(package_name: &str) -> Self

source

pub fn exists_at(&self, path: &Path) -> bool

source

pub fn read_from(&self, path: &Path) -> Result<String>

Reads the serialized struct from the given file path if it exists.

-
source

pub fn write_to(&self, path: &Path, circuit: String) -> Result<()>

Writes the given serialized struct to a file.

-
source

pub fn remove(&self, path: &Path) -> Result<bool>

Removes the serialized struct at the given path if it exists. Returns true on success, +}

Fields§

§package_name: String

Implementations§

source§

impl CircuitFile

source

pub fn new(package_name: &str) -> Self

source

pub fn exists_at(&self, path: &Path) -> bool

source

pub fn read_from(&self, path: &Path) -> Result<String>

Reads the serialized struct from the given file path if it exists.

+
source

pub fn write_to(&self, path: &Path, circuit: String) -> Result<()>

Writes the given serialized struct to a file.

+
source

pub fn remove(&self, path: &Path) -> Result<bool>

Removes the serialized struct at the given path if it exists. Returns true on success, false if the file doesn’t exist, and Error if the file system fails during operation.

source

fn setup_file_path<'a>(&self, path: &'a Path) -> Cow<'a, Path>

Trait Implementations§

source§

impl<'de> Deserialize<'de> for CircuitFile

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_package/outputs/directory/struct.OutputsDirectory.html b/leo_package/outputs/directory/struct.OutputsDirectory.html index 51c3363dc0..3af6a2044b 100644 --- a/leo_package/outputs/directory/struct.OutputsDirectory.html +++ b/leo_package/outputs/directory/struct.OutputsDirectory.html @@ -1,5 +1,5 @@ -OutputsDirectory in leo_package::outputs::directory - Rust

Struct leo_package::outputs::directory::OutputsDirectory

source ·
pub struct OutputsDirectory;

Implementations§

source§

impl OutputsDirectory

source

pub fn create(path: &Path) -> Result<PathBuf>

Creates a directory at the provided path with the default directory name.

-
source

pub fn remove(path: &Path) -> Result<String>

Removes the directory at the provided path.

+OutputsDirectory in leo_package::outputs::directory - Rust

Struct leo_package::outputs::directory::OutputsDirectory

source ·
pub struct OutputsDirectory;

Implementations§

source§

impl OutputsDirectory

source

pub fn create(path: &Path) -> Result<PathBuf>

Creates a directory at the provided path with the default directory name.

+
source

pub fn remove(path: &Path) -> Result<String>

Removes the directory at the provided path.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_package/package/struct.Package.html b/leo_package/package/struct.Package.html index 2735a291ab..084e0d16dc 100644 --- a/leo_package/package/struct.Package.html +++ b/leo_package/package/struct.Package.html @@ -4,7 +4,7 @@ pub description: Option<String>, pub license: Option<String>, pub network: NetworkName, -}

Fields§

§name: String§version: String§description: Option<String>§license: Option<String>§network: NetworkName

Implementations§

source§

impl Package

source

pub fn new(package_name: &str, network: NetworkName) -> Result<Self>

source

pub fn is_aleo_name_valid(name: &str) -> bool

Returns true if it is a valid Aleo name.

+}

Fields§

§name: String§version: String§description: Option<String>§license: Option<String>§network: NetworkName

Implementations§

source§

impl Package

source

pub fn new(package_name: &str, network: NetworkName) -> Result<Self>

source

pub fn is_aleo_name_valid(name: &str) -> bool

Returns true if it is a valid Aleo name.

Aleo names can only contain ASCII alphanumeric characters and underscores.

source

pub fn can_initialize(package_name: &str, path: &Path) -> bool

Returns true if a package is can be initialized at a given path.

source

pub fn is_initialized(package_name: &str, path: &Path) -> bool

Returns true if a package is initialized at the given path

@@ -12,7 +12,7 @@ package_name: &str, path: &Path, endpoint: String, -) -> Result<()>

Creates a Leo package at the given path

+) -> Result<()>

Creates a Leo package at the given path

Trait Implementations§

source§

impl<'de> Deserialize<'de> for Package

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_package/root/env/struct.Env.html b/leo_package/root/env/struct.Env.html index 333cc5d64c..910d44037e 100644 --- a/leo_package/root/env/struct.Env.html +++ b/leo_package/root/env/struct.Env.html @@ -1,7 +1,7 @@ Env in leo_package::root::env - Rust

Struct leo_package::root::env::Env

source ·
pub struct Env<N: Network> {
     private_key: PrivateKey<N>,
     endpoint: String,
-}

Fields§

§private_key: PrivateKey<N>§endpoint: String

Implementations§

source§

impl<N: Network> Env<N>

source

pub fn new(private_key: Option<PrivateKey<N>>, endpoint: String) -> Result<Self>

source

pub fn exists_at(path: &Path) -> bool

source

pub fn write_to(self, path: &Path) -> Result<()>

Trait Implementations§

source§

impl<'de, N: Network> Deserialize<'de> for Env<N>

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +}

Fields§

§private_key: PrivateKey<N>§endpoint: String

Implementations§

source§

impl<N: Network> Env<N>

source

pub fn new(private_key: Option<PrivateKey<N>>, endpoint: String) -> Result<Self>

source

pub fn exists_at(path: &Path) -> bool

source

pub fn write_to(self, path: &Path) -> Result<()>

Trait Implementations§

source§

impl<'de, N: Network> Deserialize<'de> for Env<N>

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl<N: Network> Display for Env<N>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<N> Freeze for Env<N>
where <N as Environment>::Field: Freeze, <N as Environment>::Scalar: Freeze,

§

impl<N> RefUnwindSafe for Env<N>
where diff --git a/leo_package/root/gitignore/struct.Gitignore.html b/leo_package/root/gitignore/struct.Gitignore.html index d5342755d6..e5ffb5b8fd 100644 --- a/leo_package/root/gitignore/struct.Gitignore.html +++ b/leo_package/root/gitignore/struct.Gitignore.html @@ -1,4 +1,4 @@ -Gitignore in leo_package::root::gitignore - Rust

Struct leo_package::root::gitignore::Gitignore

source ·
pub struct Gitignore;

Implementations§

source§

impl Gitignore

source

pub fn new() -> Self

source

pub fn exists_at(path: &Path) -> bool

source

pub fn write_to(self, path: &Path) -> Result<()>

source

fn template(&self) -> String

Trait Implementations§

source§

impl Default for Gitignore

source§

fn default() -> Gitignore

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

impl<'de> Deserialize<'de> for Gitignore

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +Gitignore in leo_package::root::gitignore - Rust

Struct leo_package::root::gitignore::Gitignore

source ·
pub struct Gitignore;

Implementations§

source§

impl Gitignore

source

pub fn new() -> Self

source

pub fn exists_at(path: &Path) -> bool

source

pub fn write_to(self, path: &Path) -> Result<()>

source

fn template(&self) -> String

Trait Implementations§

source§

impl Default for Gitignore

source§

fn default() -> Gitignore

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

impl<'de> Deserialize<'de> for Gitignore

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_package/source/directory/struct.SourceDirectory.html b/leo_package/source/directory/struct.SourceDirectory.html index 2a49292a81..17f53850bd 100644 --- a/leo_package/source/directory/struct.SourceDirectory.html +++ b/leo_package/source/directory/struct.SourceDirectory.html @@ -1,6 +1,6 @@ -SourceDirectory in leo_package::source::directory - Rust

Struct leo_package::source::directory::SourceDirectory

source ·
pub struct SourceDirectory;

Implementations§

source§

impl SourceDirectory

source

pub fn create(path: &Path) -> Result<()>

Creates a directory at the provided path with the default directory name.

-
source

pub fn files(path: &Path) -> Result<Vec<PathBuf>>

Returns a list of files in the source directory.

-
source

pub fn check_files(paths: &[PathBuf]) -> Result<()>

Check that the files in the source directory are valid.

+SourceDirectory in leo_package::source::directory - Rust

Struct leo_package::source::directory::SourceDirectory

source ·
pub struct SourceDirectory;

Implementations§

source§

impl SourceDirectory

source

pub fn create(path: &Path) -> Result<()>

Creates a directory at the provided path with the default directory name.

+
source

pub fn files(path: &Path) -> Result<Vec<PathBuf>>

Returns a list of files in the source directory.

+
source

pub fn check_files(paths: &[PathBuf]) -> Result<()>

Check that the files in the source directory are valid.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_package/source/main/struct.MainFile.html b/leo_package/source/main/struct.MainFile.html index bf739a8fe8..c9cd2fbf6b 100644 --- a/leo_package/source/main/struct.MainFile.html +++ b/leo_package/source/main/struct.MainFile.html @@ -1,6 +1,6 @@ MainFile in leo_package::source::main - Rust

Struct leo_package::source::main::MainFile

source ·
pub struct MainFile {
     pub package_name: String,
-}

Fields§

§package_name: String

Implementations§

source§

impl MainFile

source

pub fn new(package_name: &str) -> Self

source

pub fn filename() -> String

source

pub fn exists_at(path: &Path) -> bool

source

pub fn write_to(self, path: &Path) -> Result<()>

source

fn template(&self) -> String

Trait Implementations§

source§

impl<'de> Deserialize<'de> for MainFile

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +}

Fields§

§package_name: String

Implementations§

source§

impl MainFile

source

pub fn new(package_name: &str) -> Self

source

pub fn filename() -> String

source

pub fn exists_at(path: &Path) -> bool

source

pub fn write_to(self, path: &Path) -> Result<()>

source

fn template(&self) -> String

Trait Implementations§

source§

impl<'de> Deserialize<'de> for MainFile

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where diff --git a/leo_parser/fn.parse_ast.html b/leo_parser/fn.parse_ast.html index 71481ceb4b..34decf7ac9 100644 --- a/leo_parser/fn.parse_ast.html +++ b/leo_parser/fn.parse_ast.html @@ -1,7 +1,7 @@ parse_ast in leo_parser - Rust

Function leo_parser::parse_ast

source ·
pub fn parse_ast<N: Network>(
-    handler: &Handler,
+    handler: &Handler,
     node_builder: &NodeBuilder,
     source: &str,
-    start_pos: BytePos,
-) -> Result<Ast>
Expand description

Creates a new AST from a given file path and source code text.

+ start_pos: BytePos, +) -> Result<Ast>
Expand description

Creates a new AST from a given file path and source code text.

\ No newline at end of file diff --git a/leo_parser/parser/context/struct.ParserContext.html b/leo_parser/parser/context/struct.ParserContext.html index 55058287c4..6d43ac79be 100644 --- a/leo_parser/parser/context/struct.ParserContext.html +++ b/leo_parser/parser/context/struct.ParserContext.html @@ -1,15 +1,15 @@ ParserContext in leo_parser::parser::context - Rust

Struct leo_parser::parser::context::ParserContext

source ·
pub(crate) struct ParserContext<'a, N: Network> {
-    pub(crate) handler: &'a Handler,
+    pub(crate) handler: &'a Handler,
     pub(crate) node_builder: &'a NodeBuilder,
     tokens: Vec<SpannedToken>,
     pub(crate) token: SpannedToken,
     pub(crate) prev_token: SpannedToken,
     pub(crate) disallow_struct_construction: bool,
-    pub(crate) program_name: Option<Symbol>,
+    pub(crate) program_name: Option<Symbol>,
     phantom: PhantomData<N>,
 }
Expand description

Stores a program in tokenized format plus additional context. May be converted into a Program AST by parsing all tokens.

-

Fields§

§handler: &'a Handler

Handler used to side-channel emit errors from the parser.

+

Fields§

§handler: &'a Handler

Handler used to side-channel emit errors from the parser.

§node_builder: &'a NodeBuilder

Counter used to generate unique node ids.

§tokens: Vec<SpannedToken>

All un-bumped tokens.

§token: SpannedToken

The current token, i.e., if p.tokens = ['3', *, '4'], @@ -17,9 +17,9 @@

§prev_token: SpannedToken

The previous token, i.e., if p.tokens = ['3', *, '4'], then after two p.bump()s, we’ll have p.token = '*' and p.prev_token = '3'.

§disallow_struct_construction: bool

True if parsing an expression for if and loop statements – means struct inits are not legal.

-
§program_name: Option<Symbol>

The name of the program being parsed.

+
§program_name: Option<Symbol>

The name of the program being parsed.

§phantom: PhantomData<N>

Implementations§

source§

impl<'a, N: Network> ParserContext<'a, N>

source

pub fn new( - handler: &'a Handler, + handler: &'a Handler, node_builder: &'a NodeBuilder, tokens: Vec<SpannedToken>, ) -> Self

Returns a new ParserContext type given a vector of tokens.

@@ -36,39 +36,39 @@ looker: impl FnOnce(&'s SpannedToken) -> R, ) -> R

Look-ahead dist tokens of self.token and get access to that token there. When dist == 0 then the current token is looked at.

-
source

pub(super) fn emit_err(&self, err: ParserError)

Emit the error err.

-
source

pub(super) fn emit_warning(&self, warning: ParserWarning)

Emit the warning warning.

+
source

pub(super) fn emit_err(&self, err: ParserError)

Emit the error err.

+
source

pub(super) fn emit_warning(&self, warning: ParserWarning)

Emit the warning warning.

source

pub(crate) fn has_next(&self) -> bool

Returns true if the next token exists.

-
source

fn mk_ident_prev(&self, name: Symbol) -> Identifier

At the previous token, return and make an identifier with name.

+
source

fn mk_ident_prev(&self, name: Symbol) -> Identifier

At the previous token, return and make an identifier with name.

source

pub(super) fn eat_identifier(&mut self) -> Option<Identifier>

Eats the next token if it is an identifier and returns it.

-
source

pub(super) fn expect_identifier(&mut self) -> Result<Identifier>

Expects an Identifier, or errors.

-
source

pub fn eat_whole_number(&mut self) -> Result<(NonNegativeNumber, Span)>

Removes the next token if it is a [Token::Integer(_)] and returns it, or None if +

source

pub(super) fn expect_identifier(&mut self) -> Result<Identifier>

Expects an Identifier, or errors.

+
source

pub fn eat_whole_number(&mut self) -> Result<(NonNegativeNumber, Span)>

Removes the next token if it is a [Token::Integer(_)] and returns it, or None if the next token is not a [Token::Integer(_)] or if the next token does not exist.

source

pub(super) fn eat_any(&mut self, tokens: &[Token]) -> bool

Eats any of the given tokens, returning true if anything was eaten.

-
source

pub(super) fn unexpected<T>(&self, expected: impl Display) -> Result<T>

Returns an unexpected error at the current token.

-
source

pub(super) fn expect(&mut self, token: &Token) -> Result<Span>

Eats the expected token, or errors.

-
source

pub(super) fn expect_any(&mut self, tokens: &[Token]) -> Result<Span>

Eats one of the expected tokens, or errors.

+
source

pub(super) fn unexpected<T>(&self, expected: impl Display) -> Result<T>

Returns an unexpected error at the current token.

+
source

pub(super) fn expect(&mut self, token: &Token) -> Result<Span>

Eats the expected token, or errors.

+
source

pub(super) fn expect_any(&mut self, tokens: &[Token]) -> Result<Span>

Eats one of the expected tokens, or errors.

source

pub(super) fn parse_list<T>( &mut self, delimiter: Delimiter, sep: Option<Token>, - inner: impl FnMut(&mut Self) -> Result<Option<T>>, -) -> Result<(Vec<T>, bool, Span)>

Parses a list of Ts using inner + inner: impl FnMut(&mut Self) -> Result<Option<T>>, +) -> Result<(Vec<T>, bool, Span)>

Parses a list of Ts using inner The opening and closing delimiters are specified in delimiter, and elements in the list are optionally separated by sep. When (list, true) is returned, sep was a terminator.

source

pub(super) fn parse_paren_comma_list<T>( &mut self, - f: impl FnMut(&mut Self) -> Result<Option<T>>, -) -> Result<(Vec<T>, bool, Span)>

Parse a list separated by , and delimited by parens.

+ f: impl FnMut(&mut Self) -> Result<Option<T>>, +) -> Result<(Vec<T>, bool, Span)>

Parse a list separated by , and delimited by parens.

source

pub(super) fn parse_bracket_comma_list<T>( &mut self, - f: impl FnMut(&mut Self) -> Result<Option<T>>, -) -> Result<(Vec<T>, bool, Span)>

Parse a list separated by , and delimited by brackets.

+ f: impl FnMut(&mut Self) -> Result<Option<T>>, +) -> Result<(Vec<T>, bool, Span)>

Parse a list separated by , and delimited by brackets.

source

pub(super) fn peek_is_left_par(&self) -> bool

Returns true if the current token is (.

-
source§

impl<N: Network> ParserContext<'_, N>

source

pub(crate) fn parse_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next token is an expression. +

source§

impl<N: Network> ParserContext<'_, N>

source

pub(crate) fn parse_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next token is an expression. Includes struct init expressions.

-
source

pub(super) fn parse_conditional_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent +

source

pub(super) fn parse_conditional_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a ternary expression. May or may not include struct init expressions.

Otherwise, tries to parse the next token using [parse_boolean_or_expression].

source

fn bin_expr( @@ -80,94 +80,94 @@

source

fn parse_bin_expr( &mut self, tokens: &[Token], - f: impl FnMut(&mut Self) -> Result<Expression>, -) -> Result<Expression>

Parses a left-associative binary expression <left> token <right> using f for left/right. + f: impl FnMut(&mut Self) -> Result<Expression>, +) -> Result<Expression>

Parses a left-associative binary expression <left> token <right> using f for left/right. The token is translated to op in the AST.

-
source

fn parse_boolean_or_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent +

source

fn parse_boolean_or_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary OR expression.

Otherwise, tries to parse the next token using [parse_boolean_and_expression].

-
source

fn parse_boolean_and_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_boolean_and_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary AND expression.

Otherwise, tries to parse the next token using [parse_equality_expression].

source

fn eat_bin_op(&mut self, tokens: &[Token]) -> Option<BinaryOperation>

Eats one of binary operators matching any in tokens.

-
source

fn parse_ordering_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_ordering_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary relational expression: less than, less than or equals, greater than, greater than or equals.

Otherwise, tries to parse the next token using [parse_additive_expression].

-
source

fn parse_equality_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_equality_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary equals or not equals expression.

Otherwise, tries to parse the next token using [parse_ordering_expression].

-
source

fn parse_bitwise_exclusive_or_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_bitwise_exclusive_or_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a bitwise exclusive or expression.

Otherwise, tries to parse the next token using [parse_bitwise_inclusive_or_expression].

-
source

fn parse_bitwise_inclusive_or_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_bitwise_inclusive_or_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a bitwise inclusive or expression.

Otherwise, tries to parse the next token using [parse_bitwise_and_expression].

-
source

fn parse_bitwise_and_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_bitwise_and_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a bitwise and expression.

Otherwise, tries to parse the next token using [parse_shift_expression].

-
source

fn parse_shift_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_shift_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a shift left or a shift right expression.

Otherwise, tries to parse the next token using [parse_additive_expression].

-
source

fn parse_additive_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_additive_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary addition or subtraction expression.

Otherwise, tries to parse the next token using [parse_mul_div_pow_expression].

-
source

fn parse_multiplicative_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_multiplicative_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary multiplication, division, or a remainder expression.

Otherwise, tries to parse the next token using [parse_exponential_expression].

-
source

fn parse_exponential_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_exponential_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a binary exponentiation expression.

Otherwise, tries to parse the next token using [parse_cast_expression].

-
source

fn parse_cast_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

fn parse_cast_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a cast expression.

Otherwise, tries to parse the next token using [parse_unary_expression].

-
source

pub(super) fn parse_unary_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +

source

pub(super) fn parse_unary_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a unary not, negate, or bitwise not expression.

Otherwise, tries to parse the next token using [parse_postfix_expression].

source

fn parse_method_call_expression( &mut self, receiver: Expression, method: Identifier, -) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a method call expression.

source

fn parse_associated_access_expression( &mut self, module_name: Expression, -) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a static access expression.

source

pub(crate) fn parse_expr_tuple( &mut self, -) -> Result<(Vec<Expression>, bool, Span)>

Parses a tuple of Expression AST nodes.

+) -> Result<(Vec<Expression>, bool, Span)>

Parses a tuple of Expression AST nodes.

source

fn parse_external_resource( &mut self, expr: Expression, - network_span: Span, -) -> Result<Expression>

Parses an external function call credits.aleo/transfer() or locator token.aleo/accounts.

+ network_span: Span, +) -> Result<Expression>

Parses an external function call credits.aleo/transfer() or locator token.aleo/accounts.

In the ABNF grammar, an external function call is one of the two kinds of free function calls, namely the one that uses a locator to designate the function; a locator is a kind of primary expression.

-
source

fn parse_postfix_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent an +

source

fn parse_postfix_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent an array access, struct member access, tuple access, or method call expression.

Otherwise, tries to parse the next token using [parse_primary_expression]. Note that, as mentioned in [parse_primary_expression], this function also completes the parsing of some primary expressions (as defined in the ABNF grammar), which [parse_primary_expression] only starts to parse.

-
source

fn parse_tuple_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent +

source

fn parse_tuple_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a parenthesized expression or a unit expression or a tuple initialization expression or an affine group literal.

-
source

fn parse_array_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent an array initialization expression.

+
source

fn parse_array_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next tokens represent an array initialization expression.

source

fn peek_group_coordinate(&self, dist: &mut usize) -> Option<GroupCoordinate>

Returns a reference to the next token if it is a GroupCoordinate, or None if the next token is not a GroupCoordinate.

-
source

fn eat_group_partial(&mut self) -> Option<Result<GroupTuple>>

Attempts to parse an affine group literal, if present. +

source

fn eat_group_partial(&mut self) -> Option<Result<GroupTuple>>

Attempts to parse an affine group literal, if present. If absent, returns None.

-
source

fn parse_struct_member(&mut self) -> Result<StructVariableInitializer>

source

pub fn parse_struct_init_expression( +

source

fn parse_struct_member(&mut self) -> Result<StructVariableInitializer>

source

pub fn parse_struct_init_expression( &mut self, identifier: Identifier, -) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a +) -> Result<Expression>

Returns an Expression AST node if the next tokens represent a struct initialization expression. let foo = Foo { x: 1u8 };

-
source

fn parse_primary_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next token is a primary expression:

+
source

fn parse_primary_expression(&mut self) -> Result<Expression>

Returns an Expression AST node if the next token is a primary expression:

  • Literals: field, group, unsigned integer, signed integer, boolean, address, string
  • Aggregate type constructors: array, tuple, structs
  • @@ -183,40 +183,40 @@ but it is only a temporary expression that is combined into a larger one by [self.parse_postfix_expression], yielding an actual expression according to the grammar.

    Returns an expression error if the token cannot be matched.

    -
source§

impl<N: Network> ParserContext<'_, N>

source

pub fn parse_program(&mut self) -> Result<Program>

Returns a Program AST if all tokens can be consumed and represent a valid Leo program.

-
source

fn unexpected_item(token: &SpannedToken, expected: &[Token]) -> ParserError

source

pub(super) fn parse_import(&mut self) -> Result<(Symbol, (Program, Span))>

Parses an import statement import foo.leo;.

-
source

fn parse_program_scope(&mut self) -> Result<ProgramScope>

Parses a program scope program foo.aleo { ... }.

-
source

fn parse_struct_members(&mut self) -> Result<(Vec<Member>, Span)>

Returns a Vec<Member> AST node if the next tokens represent a struct member.

-
source

pub(super) fn parse_typed_ident(&mut self) -> Result<(Identifier, Type, Span)>

Parses IDENT: TYPE.

-
source

fn parse_member_variable_declaration(&mut self) -> Result<Member>

Returns a Member AST node if the next tokens represent a struct member variable.

-
source

pub(super) fn parse_struct(&mut self) -> Result<(Symbol, Composite)>

Parses a struct or record definition, e.g., struct Foo { ... } or record Foo { ... }.

-
source

pub(super) fn parse_mapping(&mut self) -> Result<(Symbol, Mapping)>

Parses a mapping declaration, e.g. mapping balances: address => u128.

-
source

pub(super) fn parse_mode(&mut self) -> Result<Mode>

Returns a [ParamMode] AST node if the next tokens represent a function parameter mode.

-
source

fn parse_input(&mut self) -> Result<Input>

Returns an Input AST node if the next tokens represent a function input.

-
source

fn parse_output(&mut self) -> Result<Output>

Returns an Output AST node if the next tokens represent a function output.

-
source

fn parse_annotation(&mut self) -> Result<Annotation>

Returns an Annotation AST node if the next tokens represent an annotation.

-
source

fn parse_function(&mut self) -> Result<(Symbol, Function)>

Returns an [(Identifier, Function)] AST node if the next tokens represent a function name +

source§

impl<N: Network> ParserContext<'_, N>

source

pub fn parse_program(&mut self) -> Result<Program>

Returns a Program AST if all tokens can be consumed and represent a valid Leo program.

+
source

fn unexpected_item(token: &SpannedToken, expected: &[Token]) -> ParserError

source

pub(super) fn parse_import(&mut self) -> Result<(Symbol, (Program, Span))>

Parses an import statement import foo.leo;.

+
source

fn parse_program_scope(&mut self) -> Result<ProgramScope>

Parses a program scope program foo.aleo { ... }.

+
source

fn parse_struct_members(&mut self) -> Result<(Vec<Member>, Span)>

Returns a Vec<Member> AST node if the next tokens represent a struct member.

+
source

pub(super) fn parse_typed_ident(&mut self) -> Result<(Identifier, Type, Span)>

Parses IDENT: TYPE.

+
source

fn parse_member_variable_declaration(&mut self) -> Result<Member>

Returns a Member AST node if the next tokens represent a struct member variable.

+
source

pub(super) fn parse_struct(&mut self) -> Result<(Symbol, Composite)>

Parses a struct or record definition, e.g., struct Foo { ... } or record Foo { ... }.

+
source

pub(super) fn parse_mapping(&mut self) -> Result<(Symbol, Mapping)>

Parses a mapping declaration, e.g. mapping balances: address => u128.

+
source

pub(super) fn parse_mode(&mut self) -> Result<Mode>

Returns a [ParamMode] AST node if the next tokens represent a function parameter mode.

+
source

fn parse_input(&mut self) -> Result<Input>

Returns an Input AST node if the next tokens represent a function input.

+
source

fn parse_output(&mut self) -> Result<Output>

Returns an Output AST node if the next tokens represent a function output.

+
source

fn parse_annotation(&mut self) -> Result<Annotation>

Returns an Annotation AST node if the next tokens represent an annotation.

+
source

fn parse_function(&mut self) -> Result<(Symbol, Function)>

Returns an [(Identifier, Function)] AST node if the next tokens represent a function name and function definition.

-
source§

impl<N: Network> ParserContext<'_, N>

source

pub(crate) fn parse_statement(&mut self) -> Result<Statement>

Returns a Statement AST node if the next tokens represent a statement.

-
source

fn parse_assert_statement(&mut self) -> Result<Statement>

Returns an AssertStatement AST node if the next tokens represent an assertion statement.

-
source

fn parse_assign_statement(&mut self) -> Result<Statement>

Returns an AssignStatement AST node if the next tokens represent an assignment, otherwise expects an expression statement.

-
source

pub(super) fn parse_block(&mut self) -> Result<Block>

Returns a Block AST node if the next tokens represent a block of statements.

-
source

fn parse_return_statement(&mut self) -> Result<ReturnStatement>

Returns a ReturnStatement AST node if the next tokens represent a return statement.

-
source

fn parse_conditional_statement(&mut self) -> Result<ConditionalStatement>

Returns a ConditionalStatement AST node if the next tokens represent a conditional statement.

-
source

fn parse_loop_statement(&mut self) -> Result<IterationStatement>

Returns an IterationStatement AST node if the next tokens represent an iteration statement.

-
source

fn parse_console_statement(&mut self) -> Result<ConsoleStatement>

Returns a ConsoleStatement AST node if the next tokens represent a console statement.

+
source§

impl<N: Network> ParserContext<'_, N>

source

pub(crate) fn parse_statement(&mut self) -> Result<Statement>

Returns a Statement AST node if the next tokens represent a statement.

+
source

fn parse_assert_statement(&mut self) -> Result<Statement>

Returns an AssertStatement AST node if the next tokens represent an assertion statement.

+
source

fn parse_assign_statement(&mut self) -> Result<Statement>

Returns an AssignStatement AST node if the next tokens represent an assignment, otherwise expects an expression statement.

+
source

pub(super) fn parse_block(&mut self) -> Result<Block>

Returns a Block AST node if the next tokens represent a block of statements.

+
source

fn parse_return_statement(&mut self) -> Result<ReturnStatement>

Returns a ReturnStatement AST node if the next tokens represent a return statement.

+
source

fn parse_conditional_statement(&mut self) -> Result<ConditionalStatement>

Returns a ConditionalStatement AST node if the next tokens represent a conditional statement.

+
source

fn parse_loop_statement(&mut self) -> Result<IterationStatement>

Returns an IterationStatement AST node if the next tokens represent an iteration statement.

+
source

fn parse_console_statement(&mut self) -> Result<ConsoleStatement>

Returns a ConsoleStatement AST node if the next tokens represent a console statement.

source

pub(super) fn parse_const_declaration_statement( &mut self, -) -> Result<ConstDeclaration>

Returns a ConstDeclaration AST node if the next tokens represent a const declaration statement.

+) -> Result<ConstDeclaration>

Returns a ConstDeclaration AST node if the next tokens represent a const declaration statement.

source

pub(super) fn parse_definition_statement( &mut self, -) -> Result<DefinitionStatement>

Returns a DefinitionStatement AST node if the next tokens represent a definition statement.

+) -> Result<DefinitionStatement>

Returns a DefinitionStatement AST node if the next tokens represent a definition statement.

source§

impl<N: Network> ParserContext<'_, N>

source

pub(super) fn token_to_int_type(token: &Token) -> Option<IntegerType>

Returns a IntegerType AST node if the given token is a supported integer type, or None.

-
source

pub fn parse_primitive_type(&mut self) -> Result<(Type, Span)>

Returns a [(Type, Span)] tuple of AST nodes if the next token represents a primitive type. +

source

pub fn parse_primitive_type(&mut self) -> Result<(Type, Span)>

Returns a [(Type, Span)] tuple of AST nodes if the next token represents a primitive type. Also returns the span of the parsed token.

These correspond to what the ABNF grammar calls ‘named primitive types’; the ‘primitive types’ according to the ABNF grammar include also the unit type.

-
source

pub fn parse_type(&mut self) -> Result<(Type, Span)>

Returns a [(Type, Span)] tuple of AST nodes if the next token represents a type. +

source

pub fn parse_type(&mut self) -> Result<(Type, Span)>

Returns a [(Type, Span)] tuple of AST nodes if the next token represents a type. Also returns the span of the parsed token.

Auto Trait Implementations§

§

impl<'a, N> Freeze for ParserContext<'a, N>

§

impl<'a, N> !RefUnwindSafe for ParserContext<'a, N>

§

impl<'a, N> !Send for ParserContext<'a, N>

§

impl<'a, N> !Sync for ParserContext<'a, N>

§

impl<'a, N> Unpin for ParserContext<'a, N>
where N: Unpin,

§

impl<'a, N> !UnwindSafe for ParserContext<'a, N>

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_parser/parser/expression/fn.assert_no_whitespace.html b/leo_parser/parser/expression/fn.assert_no_whitespace.html index 32281f7c19..1453a0af1f 100644 --- a/leo_parser/parser/expression/fn.assert_no_whitespace.html +++ b/leo_parser/parser/expression/fn.assert_no_whitespace.html @@ -1,6 +1,6 @@ assert_no_whitespace in leo_parser::parser::expression - Rust

Function leo_parser::parser::expression::assert_no_whitespace

source ·
fn assert_no_whitespace(
-    left_span: Span,
-    right_span: Span,
+    left_span: Span,
+    right_span: Span,
     left: &str,
     right: &str,
-) -> Result<()>
\ No newline at end of file +) -> Result<()>

\ No newline at end of file diff --git a/leo_parser/parser/fn.parse.html b/leo_parser/parser/fn.parse.html index 27583c7a8c..781758c012 100644 --- a/leo_parser/parser/fn.parse.html +++ b/leo_parser/parser/fn.parse.html @@ -1,7 +1,7 @@ parse in leo_parser::parser - Rust

Function leo_parser::parser::parse

source ·
pub fn parse<N: Network>(
-    handler: &Handler,
+    handler: &Handler,
     node_builder: &NodeBuilder,
     source: &str,
-    start_pos: BytePos,
-) -> Result<Program>
Expand description

Creates a new program from a given file path and source code text.

+ start_pos: BytePos, +) -> Result<Program>
Expand description

Creates a new program from a given file path and source code text.

\ No newline at end of file diff --git a/leo_parser/tokenizer/fn.tokenize.html b/leo_parser/tokenizer/fn.tokenize.html index 5e8a17afb4..9448601c50 100644 --- a/leo_parser/tokenizer/fn.tokenize.html +++ b/leo_parser/tokenizer/fn.tokenize.html @@ -1,5 +1,5 @@ tokenize in leo_parser::tokenizer - Rust

Function leo_parser::tokenizer::tokenize

source ·
pub(crate) fn tokenize(
     input: &str,
-    start_pos: BytePos,
-) -> Result<Vec<SpannedToken>>
Expand description

Creates a new vector of spanned tokens from a given file path and source code text.

+ start_pos: BytePos, +) -> Result<Vec<SpannedToken>>
Expand description

Creates a new vector of spanned tokens from a given file path and source code text.

\ No newline at end of file diff --git a/leo_parser/tokenizer/fn.tokenize_iter.html b/leo_parser/tokenizer/fn.tokenize_iter.html index 24dcc20636..416ec9a11f 100644 --- a/leo_parser/tokenizer/fn.tokenize_iter.html +++ b/leo_parser/tokenizer/fn.tokenize_iter.html @@ -1,6 +1,6 @@ tokenize_iter in leo_parser::tokenizer - Rust

Function leo_parser::tokenizer::tokenize_iter

source ·
pub(crate) fn tokenize_iter(
     input: &str,
-    lo: BytePos,
-) -> impl '_ + Iterator<Item = Result<SpannedToken>>
Expand description

Yields spanned tokens from the given source code text.

+ lo: BytePos, +) -> impl '_ + Iterator<Item = Result<SpannedToken>>
Expand description

Yields spanned tokens from the given source code text.

The lo byte position determines where spans will start.

\ No newline at end of file diff --git a/leo_parser/tokenizer/lexer/fn.ensure_no_bidi_override.html b/leo_parser/tokenizer/lexer/fn.ensure_no_bidi_override.html index f4c3dd3630..008d2a4cfa 100644 --- a/leo_parser/tokenizer/lexer/fn.ensure_no_bidi_override.html +++ b/leo_parser/tokenizer/lexer/fn.ensure_no_bidi_override.html @@ -1,2 +1,2 @@ -ensure_no_bidi_override in leo_parser::tokenizer::lexer - Rust

Function leo_parser::tokenizer::lexer::ensure_no_bidi_override

source ·
fn ensure_no_bidi_override(string: &str) -> Result<()>
Expand description

Ensure that string contains no Unicode Bidirectional Override code points.

+ensure_no_bidi_override in leo_parser::tokenizer::lexer - Rust

Function leo_parser::tokenizer::lexer::ensure_no_bidi_override

source ·
fn ensure_no_bidi_override(string: &str) -> Result<()>
Expand description

Ensure that string contains no Unicode Bidirectional Override code points.

\ No newline at end of file diff --git a/leo_parser/tokenizer/lexer/struct.SpannedToken.html b/leo_parser/tokenizer/lexer/struct.SpannedToken.html index a67779a280..8b8d4acfd0 100644 --- a/leo_parser/tokenizer/lexer/struct.SpannedToken.html +++ b/leo_parser/tokenizer/lexer/struct.SpannedToken.html @@ -1,7 +1,7 @@ SpannedToken in leo_parser::tokenizer::lexer - Rust

Struct leo_parser::tokenizer::lexer::SpannedToken

source ·
pub struct SpannedToken {
     pub token: Token,
-    pub span: Span,
-}

Fields§

§token: Token§span: Span

Implementations§

source§

impl SpannedToken

source

pub const fn dummy() -> Self

Returns a dummy token at a dummy span.

+ pub span: Span, +}

Fields§

§token: Token§span: Span

Implementations§

source§

impl SpannedToken

source

pub const fn dummy() -> Self

Returns a dummy token at a dummy span.

Trait Implementations§

source§

impl Clone for SpannedToken

source§

fn clone(&self) -> SpannedToken

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for SpannedToken

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for SpannedToken

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for SpannedToken

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Serialize for SpannedToken

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_parser/tokenizer/token/enum.Token.html b/leo_parser/tokenizer/token/enum.Token.html index 1740f32ca3..1089603057 100644 --- a/leo_parser/tokenizer/token/enum.Token.html +++ b/leo_parser/tokenizer/token/enum.Token.html @@ -7,7 +7,7 @@ Integer(String), AddressLit(String), StaticString(String), - Identifier(Symbol), + Identifier(Symbol), Not, And, AndAssign, @@ -113,11 +113,11 @@ since it includes comments and whitespace, it corresponds to the notion of ‘lexeme’ in the ABNF grammar. There are also a few other differences, noted in comments below.

-

Variants§

§

CommentLine(String)

§

CommentBlock(String)

§

WhiteSpace

§

True

§

False

§

Integer(String)

§

AddressLit(String)

§

StaticString(String)

§

Identifier(Symbol)

§

Not

§

And

§

AndAssign

§

Or

§

OrAssign

§

BitAnd

§

BitAndAssign

§

BitOr

§

BitOrAssign

§

BitXor

§

BitXorAssign

§

Eq

§

NotEq

§

Lt

§

LtEq

§

Gt

§

GtEq

§

Add

§

AddAssign

§

Sub

§

SubAssign

§

Mul

§

MulAssign

§

Div

§

DivAssign

§

Pow

§

PowAssign

§

Rem

§

RemAssign

§

Shl

§

ShlAssign

§

Shr

§

ShrAssign

§

Assign

§

LeftParen

§

RightParen

§

LeftSquare

§

RightSquare

§

LeftCurly

§

RightCurly

§

Comma

§

Dot

§

DotDot

§

Semicolon

§

Colon

§

DoubleColon

§

Question

§

Arrow

§

BigArrow

§

Underscore

§

At

§

Address

§

Bool

§

Field

§

Group

§

I8

§

I16

§

I32

§

I64

§

I128

§

Record

§

Scalar

§

Signature

§

String

§

Struct

§

U8

§

U16

§

U32

§

U64

§

U128

§

Aleo

§

As

§

Assert

§

AssertEq

§

AssertNeq

§

Async

§

Block

§

Console

§

Const

§

Constant

§

Else

§

Fn

§

For

§

Function

§

Future

§

If

§

Import

§

In

§

Inline

§

Let

§

Mapping

§

Network

§

Private

§

Program

§

Public

§

Return

§

SelfLower

§

Transition

§

Eof

§

Leo

Implementations§

source§

impl Token

source

pub fn is_keyword(&self) -> bool

Returns true if the self token equals a Leo keyword.

-
source

pub fn keyword_to_symbol(&self) -> Option<Symbol>

Converts self to the corresponding Symbol if it is_keyword.

+

Variants§

§

CommentLine(String)

§

CommentBlock(String)

§

WhiteSpace

§

True

§

False

§

Integer(String)

§

AddressLit(String)

§

StaticString(String)

§

Identifier(Symbol)

§

Not

§

And

§

AndAssign

§

Or

§

OrAssign

§

BitAnd

§

BitAndAssign

§

BitOr

§

BitOrAssign

§

BitXor

§

BitXorAssign

§

Eq

§

NotEq

§

Lt

§

LtEq

§

Gt

§

GtEq

§

Add

§

AddAssign

§

Sub

§

SubAssign

§

Mul

§

MulAssign

§

Div

§

DivAssign

§

Pow

§

PowAssign

§

Rem

§

RemAssign

§

Shl

§

ShlAssign

§

Shr

§

ShrAssign

§

Assign

§

LeftParen

§

RightParen

§

LeftSquare

§

RightSquare

§

LeftCurly

§

RightCurly

§

Comma

§

Dot

§

DotDot

§

Semicolon

§

Colon

§

DoubleColon

§

Question

§

Arrow

§

BigArrow

§

Underscore

§

At

§

Address

§

Bool

§

Field

§

Group

§

I8

§

I16

§

I32

§

I64

§

I128

§

Record

§

Scalar

§

Signature

§

String

§

Struct

§

U8

§

U16

§

U32

§

U64

§

U128

§

Aleo

§

As

§

Assert

§

AssertEq

§

AssertNeq

§

Async

§

Block

§

Console

§

Const

§

Constant

§

Else

§

Fn

§

For

§

Function

§

Future

§

If

§

Import

§

In

§

Inline

§

Let

§

Mapping

§

Network

§

Private

§

Program

§

Public

§

Return

§

SelfLower

§

Transition

§

Eof

§

Leo

Implementations§

source§

impl Token

source

pub fn is_keyword(&self) -> bool

Returns true if the self token equals a Leo keyword.

+
source

pub fn keyword_to_symbol(&self) -> Option<Symbol>

Converts self to the corresponding Symbol if it is_keyword.

source§

impl Token

source

fn eat_integer( input: &mut Peekable<impl Iterator<Item = char>>, -) -> Result<(usize, Token)>

Returns a tuple: [(integer length, integer token)] if an integer can be eaten. +) -> Result<(usize, Token)>

Returns a tuple: [(integer length, integer token)] if an integer can be eaten. An integer can be eaten if its characters are at the front of the given input string. If there is no input, this function returns an error. If there is input but no integer, this function returns the tuple consisting of @@ -126,7 +126,7 @@ This function eats a sequence of one or more digits and underscores (starting from a digit, as explained above, given when it is called), which corresponds to a numeral in the ABNF grammar.

-
source

pub(crate) fn eat(input: &str) -> Result<(usize, Token)>

Returns a tuple: [(token length, token)] if the next token can be eaten, otherwise returns an error. +

source

pub(crate) fn eat(input: &str) -> Result<(usize, Token)>

Returns a tuple: [(token length, token)] if the next token can be eaten, otherwise returns an error. The next token can be eaten if the characters at the front of the given input string can be scanned into a token.

Trait Implementations§

source§

impl Clone for Token

source§

fn clone(&self) -> Token

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Token

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Token

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for Token

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for Token

source§

fn eq(&self, other: &Token) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_passes/code_generation/generator/struct.CodeGenerator.html b/leo_passes/code_generation/generator/struct.CodeGenerator.html index 69191df037..e3ee7f467f 100644 --- a/leo_passes/code_generation/generator/struct.CodeGenerator.html +++ b/leo_passes/code_generation/generator/struct.CodeGenerator.html @@ -5,13 +5,13 @@ pub(crate) _call_graph: &'a CallGraph, pub(crate) next_register: u64, pub(crate) current_function: Option<&'a Function>, - pub(crate) variable_mapping: IndexMap<&'a Symbol, String>, - pub(crate) composite_mapping: IndexMap<&'a Symbol, (bool, String)>, - pub(crate) global_mapping: IndexMap<&'a Symbol, String>, + pub(crate) variable_mapping: IndexMap<&'a Symbol, String>, + pub(crate) composite_mapping: IndexMap<&'a Symbol, (bool, String)>, + pub(crate) global_mapping: IndexMap<&'a Symbol, String>, pub(crate) variant: Option<Variant>, pub(crate) program: &'a Program, pub(crate) program_id: Option<ProgramId>, - pub(crate) finalize_caller: Option<Symbol>, + pub(crate) finalize_caller: Option<Symbol>, pub(crate) next_label: u64, pub(crate) conditional_depth: u64,
}

Fields§

§symbol_table: &'a SymbolTable

The symbol table for the program.

@@ -20,15 +20,15 @@
§_call_graph: &'a CallGraph

The call graph for the program.

§next_register: u64

A counter to track the next available register.

§current_function: Option<&'a Function>

Reference to the current function.

-
§variable_mapping: IndexMap<&'a Symbol, String>

Mapping of variables to registers.

-
§composite_mapping: IndexMap<&'a Symbol, (bool, String)>

Mapping of composite names to a tuple containing metadata associated with the name. +

§variable_mapping: IndexMap<&'a Symbol, String>

Mapping of variables to registers.

+
§composite_mapping: IndexMap<&'a Symbol, (bool, String)>

Mapping of composite names to a tuple containing metadata associated with the name. The first element of the tuple indicate whether the composite is a record or not. The second element of the tuple is a string modifier used for code generation.

-
§global_mapping: IndexMap<&'a Symbol, String>

Mapping of global identifiers to their associated names.

+
§global_mapping: IndexMap<&'a Symbol, String>

Mapping of global identifiers to their associated names.

§variant: Option<Variant>

The variant of the function we are currently traversing.

§program: &'a Program

A reference to program. This is needed to look up external programs.

§program_id: Option<ProgramId>

The program ID of the current program.

-
§finalize_caller: Option<Symbol>

A reference to the finalize caller.

+
§finalize_caller: Option<Symbol>

A reference to the finalize caller.

§next_label: u64

A counter to track the next available label.

§conditional_depth: u64

The depth of the current conditional block.

Implementations§

source§

impl<'a> CodeGenerator<'a>

source

pub fn new( @@ -38,24 +38,24 @@ _call_graph: &'a CallGraph, program: &'a Program, ) -> Self

Initializes a new CodeGenerator.

-
source§

impl<'a> CodeGenerator<'a>

Implement the necessary methods to visit nodes in the AST.

+
source§

impl<'a> CodeGenerator<'a>

Implement the necessary methods to visit nodes in the AST.

source

pub(crate) fn visit_expression( &mut self, input: &'a Expression, -) -> (String, String)

source

fn visit_identifier(&mut self, input: &'a Identifier) -> (String, String)

source

fn visit_err(&mut self, _input: &'a ErrExpression) -> (String, String)

source

fn visit_value(&mut self, input: &'a Literal) -> (String, String)

source

fn visit_locator(&mut self, input: &'a LocatorExpression) -> (String, String)

source

fn visit_binary(&mut self, input: &'a BinaryExpression) -> (String, String)

source

fn visit_cast(&mut self, input: &'a CastExpression) -> (String, String)

source

fn visit_array(&mut self, input: &'a ArrayExpression) -> (String, String)

source

fn visit_unary(&mut self, input: &'a UnaryExpression) -> (String, String)

source

fn visit_ternary(&mut self, input: &'a TernaryExpression) -> (String, String)

source

fn visit_struct_init(&mut self, input: &'a StructExpression) -> (String, String)

source

fn visit_array_access(&mut self, input: &'a ArrayAccess) -> (String, String)

source

fn visit_member_access(&mut self, input: &'a MemberAccess) -> (String, String)

source

fn visit_associated_constant( +) -> (String, String)

source

fn visit_identifier(&mut self, input: &'a Identifier) -> (String, String)

source

fn visit_err(&mut self, _input: &'a ErrExpression) -> (String, String)

source

fn visit_value(&mut self, input: &'a Literal) -> (String, String)

source

fn visit_locator(&mut self, input: &'a LocatorExpression) -> (String, String)

source

fn visit_binary(&mut self, input: &'a BinaryExpression) -> (String, String)

source

fn visit_cast(&mut self, input: &'a CastExpression) -> (String, String)

source

fn visit_array(&mut self, input: &'a ArrayExpression) -> (String, String)

source

fn visit_unary(&mut self, input: &'a UnaryExpression) -> (String, String)

source

fn visit_ternary(&mut self, input: &'a TernaryExpression) -> (String, String)

source

fn visit_struct_init(&mut self, input: &'a StructExpression) -> (String, String)

source

fn visit_array_access(&mut self, input: &'a ArrayAccess) -> (String, String)

source

fn visit_member_access(&mut self, input: &'a MemberAccess) -> (String, String)

source

fn visit_associated_constant( &mut self, input: &'a AssociatedConstant, -) -> (String, String)

source

fn visit_associated_function( +) -> (String, String)

source

fn visit_associated_function( &mut self, input: &'a AssociatedFunction, -) -> (String, String)

source

fn visit_access(&mut self, input: &'a AccessExpression) -> (String, String)

source

fn visit_call(&mut self, input: &'a CallExpression) -> (String, String)

source

fn visit_tuple(&mut self, input: &'a TupleExpression) -> (String, String)

source

fn visit_unit(&mut self, _input: &'a UnitExpression) -> (String, String)

source§

impl<'a> CodeGenerator<'a>

source

pub(crate) fn visit_program(&mut self, input: &'a Program) -> String

source

fn visit_struct_or_record(&mut self, struct_: &'a Composite) -> String

source

fn visit_struct(&mut self, struct_: &'a Composite) -> String

source

fn visit_record(&mut self, record: &'a Composite) -> String

source

fn visit_function(&mut self, function: &'a Function) -> String

source

fn visit_mapping(&mut self, mapping: &'a Mapping) -> String

source§

impl<'a> CodeGenerator<'a>

source

fn visit_statement(&mut self, input: &'a Statement) -> String

source

fn visit_assert(&mut self, input: &'a AssertStatement) -> String

source

fn visit_return(&mut self, input: &'a ReturnStatement) -> String

source

fn visit_definition(&mut self, _input: &'a DefinitionStatement) -> String

source

fn visit_expression_statement( +) -> (String, String)

source

fn visit_access(&mut self, input: &'a AccessExpression) -> (String, String)

source

fn visit_call(&mut self, input: &'a CallExpression) -> (String, String)

source

fn visit_tuple(&mut self, input: &'a TupleExpression) -> (String, String)

source

fn visit_unit(&mut self, _input: &'a UnitExpression) -> (String, String)

source§

impl<'a> CodeGenerator<'a>

source

pub(crate) fn visit_program(&mut self, input: &'a Program) -> String

source

fn visit_struct_or_record(&mut self, struct_: &'a Composite) -> String

source

fn visit_struct(&mut self, struct_: &'a Composite) -> String

source

fn visit_record(&mut self, record: &'a Composite) -> String

source

fn visit_function(&mut self, function: &'a Function) -> String

source

fn visit_mapping(&mut self, mapping: &'a Mapping) -> String

source§

impl<'a> CodeGenerator<'a>

source

fn visit_statement(&mut self, input: &'a Statement) -> String

source

fn visit_assert(&mut self, input: &'a AssertStatement) -> String

source

fn visit_return(&mut self, input: &'a ReturnStatement) -> String

source

fn visit_definition(&mut self, _input: &'a DefinitionStatement) -> String

source

fn visit_expression_statement( &mut self, input: &'a ExpressionStatement, -) -> String

source

fn visit_assign(&mut self, input: &'a AssignStatement) -> String

source

fn visit_conditional(&mut self, _input: &'a ConditionalStatement) -> String

source

fn visit_iteration(&mut self, _input: &'a IterationStatement) -> String

source

fn visit_console(&mut self, _: &'a ConsoleStatement) -> String

source

pub(crate) fn visit_block(&mut self, input: &'a Block) -> String

source§

impl<'a> CodeGenerator<'a>

source

pub(crate) fn visit_type(input: &Type) -> String

source

pub(crate) fn visit_type_with_visibility( +) -> String

source

fn visit_assign(&mut self, input: &'a AssignStatement) -> String

source

fn visit_conditional(&mut self, _input: &'a ConditionalStatement) -> String

source

fn visit_iteration(&mut self, _input: &'a IterationStatement) -> String

source

fn visit_console(&mut self, _: &'a ConsoleStatement) -> String

source

pub(crate) fn visit_block(&mut self, input: &'a Block) -> String

source§

impl<'a> CodeGenerator<'a>

source

pub(crate) fn visit_type(input: &Type) -> String

source

pub(crate) fn visit_type_with_visibility( &self, type_: &'a Type, visibility: Mode, -) -> String

Trait Implementations§

source§

impl<'a> Pass for CodeGenerator<'a>

§

type Input = (&'a Ast, &'a SymbolTable, &'a TypeTable, &'a DiGraph<Symbol>, &'a DiGraph<Symbol>, &'a Program)

§

type Output = Result<String, LeoError>

source§

fn do_pass( +) -> String

Trait Implementations§

source§

impl<'a> Pass for CodeGenerator<'a>

§

type Input = (&'a Ast, &'a SymbolTable, &'a TypeTable, &'a DiGraph<Symbol>, &'a DiGraph<Symbol>, &'a Program)

§

type Output = Result<String, LeoError>

source§

fn do_pass( (ast, symbol_table, type_table, struct_graph, call_graph, program): Self::Input, ) -> Self::Output

Runs the compiler pass.

Auto Trait Implementations§

§

impl<'a> Freeze for CodeGenerator<'a>

§

impl<'a> !RefUnwindSafe for CodeGenerator<'a>

§

impl<'a> !Send for CodeGenerator<'a>

§

impl<'a> !Sync for CodeGenerator<'a>

§

impl<'a> Unpin for CodeGenerator<'a>

§

impl<'a> !UnwindSafe for CodeGenerator<'a>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_passes/code_generation/visit_expressions/index.html b/leo_passes/code_generation/visit_expressions/index.html index 9ac2911d3b..b8d33fe2e4 100644 --- a/leo_passes/code_generation/visit_expressions/index.html +++ b/leo_passes/code_generation/visit_expressions/index.html @@ -1 +1 @@ -leo_passes::code_generation::visit_expressions - Rust

Module leo_passes::code_generation::visit_expressions

source ·
\ No newline at end of file +leo_passes::code_generation::visit_expressions - Rust

Module leo_passes::code_generation::visit_expressions

source ·
\ No newline at end of file diff --git a/leo_passes/code_generation/visit_type/index.html b/leo_passes/code_generation/visit_type/index.html index 2f6e2f789a..065f69299d 100644 --- a/leo_passes/code_generation/visit_type/index.html +++ b/leo_passes/code_generation/visit_type/index.html @@ -1 +1 @@ -leo_passes::code_generation::visit_type - Rust

Module leo_passes::code_generation::visit_type

source ·
\ No newline at end of file +leo_passes::code_generation::visit_type - Rust

Module leo_passes::code_generation::visit_type

source ·
\ No newline at end of file diff --git a/leo_passes/common/assigner/struct.Assigner.html b/leo_passes/common/assigner/struct.Assigner.html index 0505889c31..0430247899 100644 --- a/leo_passes/common/assigner/struct.Assigner.html +++ b/leo_passes/common/assigner/struct.Assigner.html @@ -7,7 +7,7 @@ &self, arg: impl Display, separator: impl Display, -) -> Symbol

Return a new unique Symbol from a &str.

+) -> Symbol

Return a new unique Symbol from a &str.

source

pub fn simple_assign_statement( &self, identifier: Identifier, diff --git a/leo_passes/common/assigner/struct.AssignerInner.html b/leo_passes/common/assigner/struct.AssignerInner.html index 17215d7918..fc14a70a31 100644 --- a/leo_passes/common/assigner/struct.AssignerInner.html +++ b/leo_passes/common/assigner/struct.AssignerInner.html @@ -7,7 +7,7 @@ &mut self, arg: impl Display, separator: impl Display, -) -> Symbol

Return a new unique Symbol from a &str.

+) -> Symbol

Return a new unique Symbol from a &str.

source

fn simple_assign_statement( &mut self, identifier: Identifier, diff --git a/leo_passes/common/constant_propagation_table/struct.ConstantPropagationTable.html b/leo_passes/common/constant_propagation_table/struct.ConstantPropagationTable.html index 9590b81ff2..9935bf5023 100644 --- a/leo_passes/common/constant_propagation_table/struct.ConstantPropagationTable.html +++ b/leo_passes/common/constant_propagation_table/struct.ConstantPropagationTable.html @@ -1,11 +1,11 @@ ConstantPropagationTable in leo_passes::common::constant_propagation_table - Rust
pub struct ConstantPropagationTable {
     pub(crate) parent: Option<Box<ConstantPropagationTable>>,
-    pub(crate) constants: IndexMap<Symbol, Expression>,
+    pub(crate) constants: IndexMap<Symbol, Expression>,
     pub(crate) scope_index: usize,
     pub(crate) scopes: Vec<RefCell<ConstantPropagationTable>>,
 }

Fields§

§parent: Option<Box<ConstantPropagationTable>>

The parent scope if it exists. For example, the parent scope of a then-block is the scope containing the associated ConditionalStatement.

-
§constants: IndexMap<Symbol, Expression>

The known constants in the current scope +

§constants: IndexMap<Symbol, Expression>

The known constants in the current scope This field is populated as necessary.

§scope_index: usize

The index of the current scope.

§scopes: Vec<RefCell<ConstantPropagationTable>>

The sub-scopes of this scope.

@@ -13,13 +13,13 @@ Increments the scope index.

source

pub fn insert_constant( &mut self, - symbol: Symbol, + symbol: Symbol, expr: Expression, -) -> Result<()>

Inserts a constant into the constant propagation table.

+) -> Result<()>

Inserts a constant into the constant propagation table.

source

pub fn insert_block(&mut self) -> usize

Creates a new scope for the block and stores it in the constant propagation table.

-
source

pub fn lookup_constant(&self, symbol: Symbol) -> Option<&Expression>

Attempts to lookup a constant in the constant propagation table.

-
source

pub fn constant_in_local_scope(&self, symbol: Symbol) -> bool

Returns true if the constant exists in the local scope

-
source

pub fn constant_in_parent_scope(&self, symbol: Symbol) -> bool

Returns true if the constant exists in any parent scope

+
source

pub fn lookup_constant(&self, symbol: Symbol) -> Option<&Expression>

Attempts to lookup a constant in the constant propagation table.

+
source

pub fn constant_in_local_scope(&self, symbol: Symbol) -> bool

Returns true if the constant exists in the local scope

+
source

pub fn constant_in_parent_scope(&self, symbol: Symbol) -> bool

Returns true if the constant exists in any parent scope

source

pub fn lookup_scope_by_index(&self, index: usize) -> Option<&RefCell<Self>>

Returns the scope associated with index, if it exists in the constant propagation table

Trait Implementations§

source§

impl Clone for ConstantPropagationTable

source§

fn clone(&self) -> ConstantPropagationTable

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ConstantPropagationTable

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for ConstantPropagationTable

source§

fn default() -> ConstantPropagationTable

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

impl<'de> Deserialize<'de> for ConstantPropagationTable

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Serialize for ConstantPropagationTable

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where diff --git a/leo_passes/common/graph/trait.Node.html b/leo_passes/common/graph/trait.Node.html index 1bea87361e..a250195b61 100644 --- a/leo_passes/common/graph/trait.Node.html +++ b/leo_passes/common/graph/trait.Node.html @@ -1,2 +1,2 @@ Node in leo_passes::common::graph - Rust

Trait leo_passes::common::graph::Node

source ·
pub trait Node: Copy + 'static + Eq + PartialEq + Debug + Hash { }
Expand description

A node in a graph.

-

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl Node for Symbol

Implementors§

\ No newline at end of file +

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl Node for Symbol

Implementors§

\ No newline at end of file diff --git a/leo_passes/common/graph/type.CallGraph.html b/leo_passes/common/graph/type.CallGraph.html index b8ff37bae2..37ad06d1cc 100644 --- a/leo_passes/common/graph/type.CallGraph.html +++ b/leo_passes/common/graph/type.CallGraph.html @@ -1,8 +1,8 @@ -CallGraph in leo_passes::common::graph - Rust

Type Alias leo_passes::common::graph::CallGraph

source ·
pub type CallGraph = DiGraph<Symbol>;
Expand description

A call graph.

+CallGraph in leo_passes::common::graph - Rust

Type Alias leo_passes::common::graph::CallGraph

source ·
pub type CallGraph = DiGraph<Symbol>;
Expand description

A call graph.

Aliased Type§

struct CallGraph {
-    nodes: IndexSet<Symbol>,
-    edges: IndexMap<Symbol, IndexSet<Symbol>>,
-}

Fields§

§nodes: IndexSet<Symbol>

The set of nodes in the graph.

-
§edges: IndexMap<Symbol, IndexSet<Symbol>>

The directed edges in the graph. + nodes: IndexSet<Symbol>, + edges: IndexMap<Symbol, IndexSet<Symbol>>, +}

Fields§

§nodes: IndexSet<Symbol>

The set of nodes in the graph.

+
§edges: IndexMap<Symbol, IndexSet<Symbol>>

The directed edges in the graph. Each entry in the map is a node in the graph, and the set of nodes that it points to.

\ No newline at end of file diff --git a/leo_passes/common/graph/type.ImportGraph.html b/leo_passes/common/graph/type.ImportGraph.html index 150a479a3c..aac2d7aae7 100644 --- a/leo_passes/common/graph/type.ImportGraph.html +++ b/leo_passes/common/graph/type.ImportGraph.html @@ -1,8 +1,8 @@ -ImportGraph in leo_passes::common::graph - Rust

Type Alias leo_passes::common::graph::ImportGraph

source ·
pub type ImportGraph = DiGraph<Symbol>;
Expand description

An import dependency graph.

+ImportGraph in leo_passes::common::graph - Rust

Type Alias leo_passes::common::graph::ImportGraph

source ·
pub type ImportGraph = DiGraph<Symbol>;
Expand description

An import dependency graph.

Aliased Type§

struct ImportGraph {
-    nodes: IndexSet<Symbol>,
-    edges: IndexMap<Symbol, IndexSet<Symbol>>,
-}

Fields§

§nodes: IndexSet<Symbol>

The set of nodes in the graph.

-
§edges: IndexMap<Symbol, IndexSet<Symbol>>

The directed edges in the graph. + nodes: IndexSet<Symbol>, + edges: IndexMap<Symbol, IndexSet<Symbol>>, +}

Fields§

§nodes: IndexSet<Symbol>

The set of nodes in the graph.

+
§edges: IndexMap<Symbol, IndexSet<Symbol>>

The directed edges in the graph. Each entry in the map is a node in the graph, and the set of nodes that it points to.

\ No newline at end of file diff --git a/leo_passes/common/graph/type.StructGraph.html b/leo_passes/common/graph/type.StructGraph.html index 4e3a5eb813..c5d26f934d 100644 --- a/leo_passes/common/graph/type.StructGraph.html +++ b/leo_passes/common/graph/type.StructGraph.html @@ -1,8 +1,8 @@ -StructGraph in leo_passes::common::graph - Rust

Type Alias leo_passes::common::graph::StructGraph

source ·
pub type StructGraph = DiGraph<Symbol>;
Expand description

A struct dependency graph.

+StructGraph in leo_passes::common::graph - Rust

Type Alias leo_passes::common::graph::StructGraph

source ·
pub type StructGraph = DiGraph<Symbol>;
Expand description

A struct dependency graph.

Aliased Type§

struct StructGraph {
-    nodes: IndexSet<Symbol>,
-    edges: IndexMap<Symbol, IndexSet<Symbol>>,
-}

Fields§

§nodes: IndexSet<Symbol>

The set of nodes in the graph.

-
§edges: IndexMap<Symbol, IndexSet<Symbol>>

The directed edges in the graph. + nodes: IndexSet<Symbol>, + edges: IndexMap<Symbol, IndexSet<Symbol>>, +}

Fields§

§nodes: IndexSet<Symbol>

The set of nodes in the graph.

+
§edges: IndexMap<Symbol, IndexSet<Symbol>>

The directed edges in the graph. Each entry in the map is a node in the graph, and the set of nodes that it points to.

\ No newline at end of file diff --git a/leo_passes/common/rename_table/struct.RenameTable.html b/leo_passes/common/rename_table/struct.RenameTable.html index 6e686a5825..ea029ddfac 100644 --- a/leo_passes/common/rename_table/struct.RenameTable.html +++ b/leo_passes/common/rename_table/struct.RenameTable.html @@ -1,19 +1,19 @@ RenameTable in leo_passes::common::rename_table - Rust

Struct leo_passes::common::rename_table::RenameTable

source ·
pub struct RenameTable {
     pub(crate) parent: Option<Box<RenameTable>>,
-    names: IndexMap<Symbol, Symbol>,
-    ids: IndexMap<Symbol, NodeID>,
+    names: IndexMap<Symbol, Symbol>,
+    ids: IndexMap<Symbol, NodeID>,
 }
Expand description

RenameTable tracks the names assigned by static single assignment in a single scope.

Fields§

§parent: Option<Box<RenameTable>>

The RenameTable of the parent scope.

-
§names: IndexMap<Symbol, Symbol>

The mapping from names in the original AST to new names in the renamed AST.

-
§ids: IndexMap<Symbol, NodeID>

The mapping from symbols to node IDs. +

§names: IndexMap<Symbol, Symbol>

The mapping from names in the original AST to new names in the renamed AST.

+
§ids: IndexMap<Symbol, NodeID>

The mapping from symbols to node IDs. These are used to ensure that newly introduced symbols reference the appropriate information that has been previously indexed by node ID. e,g. TypeTable.

Implementations§

source§

impl RenameTable

source

pub(crate) fn new(parent: Option<Box<RenameTable>>) -> Self

Create a new RenameTable with the given parent.

-
source

pub(crate) fn local_names(&self) -> impl Iterator<Item = &Symbol>

Returns the symbols that were renamed in the current scope.

-
source

pub(crate) fn update(&mut self, symbol: Symbol, new_symbol: Symbol, id: NodeID)

Updates self.mapping with the desired entry. +

source

pub(crate) fn local_names(&self) -> impl Iterator<Item = &Symbol>

Returns the symbols that were renamed in the current scope.

+
source

pub(crate) fn update(&mut self, symbol: Symbol, new_symbol: Symbol, id: NodeID)

Updates self.mapping with the desired entry. Creates a new entry if symbol is not already in self.mapping.

-
source

pub(crate) fn lookup(&self, symbol: Symbol) -> Option<&Symbol>

Looks up the new name for symbol, recursively checking the parent if it is not found.

-
source

pub(crate) fn lookup_id(&self, symbol: &Symbol) -> Option<&NodeID>

Looks up the node ID for symbol, recursively checking the parent if it is not found.

+
source

pub(crate) fn lookup(&self, symbol: Symbol) -> Option<&Symbol>

Looks up the new name for symbol, recursively checking the parent if it is not found.

+
source

pub(crate) fn lookup_id(&self, symbol: &Symbol) -> Option<&NodeID>

Looks up the node ID for symbol, recursively checking the parent if it is not found.

Trait Implementations§

source§

impl Clone for RenameTable

source§

fn clone(&self) -> RenameTable

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RenameTable

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for RenameTable

source§

fn default() -> RenameTable

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

impl PartialEq for RenameTable

source§

fn eq(&self, other: &RenameTable) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for RenameTable

source§

impl StructuralPartialEq for RenameTable

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_passes/common/symbol_table/function_symbol/struct.FunctionSymbol.html b/leo_passes/common/symbol_table/function_symbol/struct.FunctionSymbol.html index 2917c84342..ba54c2f0f1 100644 --- a/leo_passes/common/symbol_table/function_symbol/struct.FunctionSymbol.html +++ b/leo_passes/common/symbol_table/function_symbol/struct.FunctionSymbol.html @@ -2,7 +2,7 @@ pub(crate) id: usize, pub(crate) output_type: Type, pub variant: Variant, - pub(crate) _span: Span, + pub(crate) _span: Span, pub(crate) input: Vec<Input>, pub(crate) future_inputs: Vec<Location>, pub(crate) finalize: Option<Location>, @@ -10,7 +10,7 @@

Fields§

§id: usize

The index associated with the scope in the parent symbol table.

§output_type: Type

The output type of the function.

§variant: Variant

Is this function a transition, inlined, or a regular function?.

-
§_span: Span

The Span associated with the function.

+
§_span: Span

The Span associated with the function.

§input: Vec<Input>

The inputs to the function.

§future_inputs: Vec<Location>

Future inputs.

§finalize: Option<Location>

The finalize block associated with the function.

diff --git a/leo_passes/common/symbol_table/struct.SymbolTable.html b/leo_passes/common/symbol_table/struct.SymbolTable.html index 636a224b31..9c68613b86 100644 --- a/leo_passes/common/symbol_table/struct.SymbolTable.html +++ b/leo_passes/common/symbol_table/struct.SymbolTable.html @@ -19,41 +19,41 @@ &self, location: &Location, is_struct: bool, - span: Span, -) -> Result<()>

Recursively checks if the symbol table contains an entry for the given symbol. + span: Span, +) -> Result<()>

Recursively checks if the symbol table contains an entry for the given symbol. Leo does not allow any variable shadowing or overlap between different symbols.

source

pub fn scope_index(&mut self) -> usize

Returns the current scope index. Increments the scope index.

-
source

pub fn insert_fn(&mut self, location: Location, insert: &Function) -> Result<()>

Inserts a function into the symbol table.

+
source

pub fn insert_fn(&mut self, location: Location, insert: &Function) -> Result<()>

Inserts a function into the symbol table.

source

pub fn insert_struct( &mut self, location: Location, insert: &Composite, -) -> Result<()>

Inserts a struct into the symbol table.

+) -> Result<()>

Inserts a struct into the symbol table.

source

fn check_eq_struct(&self, new: &Composite, old: &Composite) -> bool

Checks if two structs are equal.

source

pub fn attach_finalize( &mut self, caller: Location, callee: Location, -) -> Result<()>

Attach a finalize to a function.

+) -> Result<()>

Attach a finalize to a function.

source

pub fn insert_variable( &mut self, location: Location, insert: VariableSymbol, -) -> Result<()>

Inserts a variable into the symbol table.

+) -> Result<()>

Inserts a variable into the symbol table.

source

pub fn insert_futures( &mut self, - program: Symbol, - function: Symbol, + program: Symbol, + function: Symbol, futures: Vec<Location>, -) -> Result<()>

Inserts futures into the function definition.

+) -> Result<()>

Inserts futures into the function definition.

source

pub fn remove_variable_from_current_scope(&mut self, location: Location)

Removes a variable from the symbol table.

source

pub fn insert_block(&mut self) -> usize

Creates a new scope for the block and stores it in the symbol table.

source

pub fn lookup_fn_symbol(&self, location: Location) -> Option<&FunctionSymbol>

Attempts to lookup a function in the symbol table.

source

pub fn lookup_struct( &self, location: Location, - main_program: Option<Symbol>, + main_program: Option<Symbol>, ) -> Option<&Composite>

Attempts to lookup a struct in the symbol table.

source

pub fn lookup_variable(&self, location: Location) -> Option<&VariableSymbol>

Attempts to lookup a variable in the symbol table.

source

pub fn lookup_variable_in_current_scope( @@ -61,16 +61,16 @@ location: Location, ) -> Option<&VariableSymbol>

Attempts to lookup a variable in the current scope.

source

pub fn lookup_scope_by_index(&self, index: usize) -> Option<&RefCell<Self>>

Returns the scope associated with index, if it exists in the symbol table.

-
source

pub fn to_json_string(&self) -> Result<String>

Serializes the symbol table into a JSON string.

-
source

pub fn to_json_value(&self) -> Result<Value>

Converts the symbol table into a JSON value

-
source

pub fn to_json_file(&self, path: PathBuf, file_name: &str) -> Result<()>

source

pub fn to_json_file_without_keys( +

source

pub fn to_json_string(&self) -> Result<String>

Serializes the symbol table into a JSON string.

+
source

pub fn to_json_value(&self) -> Result<Value>

Converts the symbol table into a JSON value

+
source

pub fn to_json_file(&self, path: PathBuf, file_name: &str) -> Result<()>

source

pub fn to_json_file_without_keys( &self, path: PathBuf, file_name: &str, excluded_keys: &[&str], -) -> Result<()>

Serializes the symbol table into a JSON value and removes keys from object mappings before writing to a file.

-
source

pub fn from_json_string(json: &str) -> Result<Self>

Deserializes the JSON string into a symbol table.

-
source

pub fn from_json_file(path: PathBuf) -> Result<Self>

Deserializes the JSON string into a symbol table from a file.

+) -> Result<()>

Serializes the symbol table into a JSON value and removes keys from object mappings before writing to a file.

+
source

pub fn from_json_string(json: &str) -> Result<Self>

Deserializes the JSON string into a symbol table.

+
source

pub fn from_json_file(path: PathBuf) -> Result<Self>

Deserializes the JSON string into a symbol table from a file.

Trait Implementations§

source§

impl Clone for SymbolTable

source§

fn clone(&self) -> SymbolTable

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for SymbolTable

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for SymbolTable

source§

fn default() -> SymbolTable

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

impl<'de> Deserialize<'de> for SymbolTable

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for SymbolTable

source§

fn eq(&self, other: &SymbolTable) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always diff --git a/leo_passes/common/symbol_table/variable_symbol/struct.VariableSymbol.html b/leo_passes/common/symbol_table/variable_symbol/struct.VariableSymbol.html index 2a0799e296..923ff67b92 100644 --- a/leo_passes/common/symbol_table/variable_symbol/struct.VariableSymbol.html +++ b/leo_passes/common/symbol_table/variable_symbol/struct.VariableSymbol.html @@ -1,10 +1,10 @@ VariableSymbol in leo_passes::common::symbol_table::variable_symbol - Rust
pub struct VariableSymbol {
     pub type_: Type,
-    pub span: Span,
+    pub span: Span,
     pub declaration: VariableType,
 }
Expand description

An entry for a variable in the symbol table.

Fields§

§type_: Type

The Type of the variable.

-
§span: Span

The Span associated with the variable.

+
§span: Span

The Span associated with the variable.

§declaration: VariableType

The type of declaration for the variable.

Trait Implementations§

source§

impl Clone for VariableSymbol

source§

fn clone(&self) -> VariableSymbol

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for VariableSymbol

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for VariableSymbol

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for VariableSymbol

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for VariableSymbol

source§

fn eq(&self, other: &VariableSymbol) -> bool

This method tests for self and other values to be equal, and is used diff --git a/leo_passes/common/tree_node/trait.Node.html b/leo_passes/common/tree_node/trait.Node.html index 6de8e77131..8b3763f69f 100644 --- a/leo_passes/common/tree_node/trait.Node.html +++ b/leo_passes/common/tree_node/trait.Node.html @@ -1,2 +1,2 @@ Node in leo_passes::common::tree_node - Rust

Trait leo_passes::common::tree_node::Node

source ·
pub trait Node: Copy + 'static + Eq + PartialEq + Debug + Hash { }
Expand description

A node in a graph.

-

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl Node for Symbol

Implementors§

\ No newline at end of file +

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl Node for Symbol

Implementors§

\ No newline at end of file diff --git a/leo_passes/common/tree_node/type.ConditionalTreeNode.html b/leo_passes/common/tree_node/type.ConditionalTreeNode.html index 42decbe723..7461c4ab1d 100644 --- a/leo_passes/common/tree_node/type.ConditionalTreeNode.html +++ b/leo_passes/common/tree_node/type.ConditionalTreeNode.html @@ -1,9 +1,9 @@ -ConditionalTreeNode in leo_passes::common::tree_node - Rust

Type Alias leo_passes::common::tree_node::ConditionalTreeNode

source ·
pub type ConditionalTreeNode = TreeNode<Symbol>;
Expand description

A binary search tree to store all paths through nested conditional blocks.

+ConditionalTreeNode in leo_passes::common::tree_node - Rust

Type Alias leo_passes::common::tree_node::ConditionalTreeNode

source ·
pub type ConditionalTreeNode = TreeNode<Symbol>;
Expand description

A binary search tree to store all paths through nested conditional blocks.

Aliased Type§

struct ConditionalTreeNode {
     pub depth: usize,
-    pub elements: IndexSet<Symbol>,
+    pub elements: IndexSet<Symbol>,
     pub counter: usize,
 }

Fields§

§depth: usize

The current depth.

-
§elements: IndexSet<Symbol>

The current node.

+
§elements: IndexSet<Symbol>

The current node.

§counter: usize

A counter.

\ No newline at end of file diff --git a/leo_passes/dead_code_elimination/dead_code_eliminator/struct.DeadCodeEliminator.html b/leo_passes/dead_code_elimination/dead_code_eliminator/struct.DeadCodeEliminator.html index 35a0057cec..ab6bc0a0bd 100644 --- a/leo_passes/dead_code_elimination/dead_code_eliminator/struct.DeadCodeEliminator.html +++ b/leo_passes/dead_code_elimination/dead_code_eliminator/struct.DeadCodeEliminator.html @@ -1,10 +1,10 @@ DeadCodeEliminator in leo_passes::dead_code_elimination::dead_code_eliminator - Rust
pub struct DeadCodeEliminator<'a> {
     pub(crate) node_builder: &'a NodeBuilder,
-    pub(crate) used_variables: IndexSet<Symbol>,
+    pub(crate) used_variables: IndexSet<Symbol>,
     pub(crate) is_necessary: bool,
     pub(crate) is_async: bool,
 }

Fields§

§node_builder: &'a NodeBuilder

A counter to generate unique node IDs.

-
§used_variables: IndexSet<Symbol>

The set of used variables in the current function body.

+
§used_variables: IndexSet<Symbol>

The set of used variables in the current function body.

§is_necessary: bool

Whether or not the variables are necessary.

§is_async: bool

Whether or not we are currently traversing an async function.

Implementations§

source§

impl<'a> DeadCodeEliminator<'a>

source

pub fn new(node_builder: &'a NodeBuilder) -> Self

Initializes a new DeadCodeEliminator.

@@ -73,7 +73,7 @@ ) -> (Expression, Self::AdditionalOutput)
source§

fn reconstruct_unit( &mut self, input: UnitExpression, -) -> (Expression, Self::AdditionalOutput)

source§

impl<'a> Pass for DeadCodeEliminator<'a>

§

type Input = (Ast, &'a NodeBuilder)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass((ast, node_builder): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for DeadCodeEliminator<'_>

source§

impl StatementReconstructor for DeadCodeEliminator<'_>

source§

impl<'a> Pass for DeadCodeEliminator<'a>

§

type Input = (Ast, &'a NodeBuilder)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass((ast, node_builder): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for DeadCodeEliminator<'_>

source§

impl StatementReconstructor for DeadCodeEliminator<'_>

source§

fn reconstruct_assign( &mut self, input: AssignStatement, ) -> (Statement, Self::AdditionalOutput)

Reconstruct an assignment statement by eliminating any dead code.

diff --git a/leo_passes/destructuring/destructurer/struct.Destructurer.html b/leo_passes/destructuring/destructurer/struct.Destructurer.html index 098357981a..ebbe15791c 100644 --- a/leo_passes/destructuring/destructurer/struct.Destructurer.html +++ b/leo_passes/destructuring/destructurer/struct.Destructurer.html @@ -2,12 +2,12 @@ pub(crate) type_table: &'a TypeTable, pub(crate) node_builder: &'a NodeBuilder, pub(crate) assigner: &'a Assigner, - pub(crate) tuples: IndexMap<Symbol, TupleExpression>, + pub(crate) tuples: IndexMap<Symbol, TupleExpression>, pub(crate) is_async: bool, }

Fields§

§type_table: &'a TypeTable

A mapping between node IDs and their types.

§node_builder: &'a NodeBuilder

A counter used to generate unique node IDs.

§assigner: &'a Assigner

A struct used to construct (unique) assignment statements.

-
§tuples: IndexMap<Symbol, TupleExpression>

A mapping between variables and flattened tuple expressions.

+
§tuples: IndexMap<Symbol, TupleExpression>

A mapping between variables and flattened tuple expressions.

§is_async: bool

Whether or not we are currently traversing an async function block.

Implementations§

source§

impl<'a> Destructurer<'a>

source

pub(crate) fn new( type_table: &'a TypeTable, @@ -79,7 +79,7 @@ ) -> (Expression, Self::AdditionalOutput)

source§

fn reconstruct_unit( &mut self, input: UnitExpression, -) -> (Expression, Self::AdditionalOutput)

source§

impl<'a> Pass for Destructurer<'a>

§

type Input = (Ast, &'a TypeTable, &'a NodeBuilder, &'a Assigner)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass((ast, tt, node_builder, assigner): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for Destructurer<'_>

source§

impl StatementReconstructor for Destructurer<'_>

source§

impl<'a> Pass for Destructurer<'a>

§

type Input = (Ast, &'a TypeTable, &'a NodeBuilder, &'a Assigner)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass((ast, tt, node_builder, assigner): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for Destructurer<'_>

source§

impl StatementReconstructor for Destructurer<'_>

source§

fn reconstruct_assign( &mut self, assign: AssignStatement, ) -> (Statement, Self::AdditionalOutput)

Flattens an assign statement, if necessary. diff --git a/leo_passes/flattening/flattener/struct.Flattener.html b/leo_passes/flattening/flattener/struct.Flattener.html index c6498674c9..c2b9df05cf 100644 --- a/leo_passes/flattening/flattener/struct.Flattener.html +++ b/leo_passes/flattening/flattener/struct.Flattener.html @@ -5,7 +5,7 @@ pub(crate) assigner: &'a Assigner, pub(crate) condition_stack: Vec<Expression>, pub(crate) returns: Vec<(Option<Expression>, ReturnStatement)>, - pub(crate) program: Option<Symbol>, + pub(crate) program: Option<Symbol>, pub(crate) is_async: bool, }

Fields§

§symbol_table: &'a SymbolTable

The symbol table associated with the program.

§type_table: &'a TypeTable

A mapping between node IDs and their types.

@@ -16,7 +16,7 @@ A guard is an expression that evaluates to true on the execution path of the ReturnStatement. Note that returns are inserted in the order they are encountered during a pre-order traversal of the AST. Note that type checking guarantees that there is at most one return in a basic block.

-
§program: Option<Symbol>

The program name.

+
§program: Option<Symbol>

The program name.

§is_async: bool

Whether the function is an async function.

Implementations§

source§

impl<'a> Flattener<'a>

source

pub(crate) fn new( symbol_table: &'a SymbolTable, @@ -138,7 +138,7 @@ ) -> (Expression, Self::AdditionalOutput)

source§

fn reconstruct_unit( &mut self, input: UnitExpression, -) -> (Expression, Self::AdditionalOutput)

source§

impl<'a> Pass for Flattener<'a>

§

type Input = (Ast, &'a SymbolTable, &'a TypeTable, &'a NodeBuilder, &'a Assigner)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass((ast, st, tt, node_builder, assigner): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for Flattener<'_>

source§

fn reconstruct_program_scope(&mut self, input: ProgramScope) -> ProgramScope

Flattens a program scope.

+) -> (Expression, Self::AdditionalOutput)
source§

impl<'a> Pass for Flattener<'a>

§

type Input = (Ast, &'a SymbolTable, &'a TypeTable, &'a NodeBuilder, &'a Assigner)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass((ast, st, tt, node_builder, assigner): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for Flattener<'_>

source§

fn reconstruct_program_scope(&mut self, input: ProgramScope) -> ProgramScope

Flattens a program scope.

source§

fn reconstruct_function(&mut self, function: Function) -> Function

Flattens a function’s body

source§

fn reconstruct_program(&mut self, input: Program) -> Program

source§

fn reconstruct_stub(&mut self, input: Stub) -> Stub

source§

fn reconstruct_function_stub(&mut self, input: FunctionStub) -> FunctionStub

source§

fn reconstruct_struct(&mut self, input: Composite) -> Composite

source§

fn reconstruct_import(&mut self, input: Program) -> Program

source§

fn reconstruct_mapping(&mut self, input: Mapping) -> Mapping

source§

impl StatementReconstructor for Flattener<'_>

source§

fn reconstruct_assert( &mut self, diff --git a/leo_passes/function_inlining/assignment_renamer/struct.AssignmentRenamer.html b/leo_passes/function_inlining/assignment_renamer/struct.AssignmentRenamer.html index db586b7ac2..1deb62b323 100644 --- a/leo_passes/function_inlining/assignment_renamer/struct.AssignmentRenamer.html +++ b/leo_passes/function_inlining/assignment_renamer/struct.AssignmentRenamer.html @@ -5,7 +5,7 @@ }
Expand description

An AssignmentRenamer renames the left-hand side of all assignment statements in an AST node. The new names are propagated to all following identifiers.

Fields§

§assigner: &'a Assigner§rename_table: RenameTable§is_lhs: bool

Implementations§

source§

impl<'a> AssignmentRenamer<'a>

source

pub fn new(assigner: &'a Assigner) -> Self

Initialize a new AssignmentRenamer.

-
source

pub fn load(&mut self, entries: impl Iterator<Item = (Symbol, Symbol, NodeID)>)

Load the internal rename table with a set of entries.

+
source

pub fn load(&mut self, entries: impl Iterator<Item = (Symbol, Symbol, NodeID)>)

Load the internal rename table with a set of entries.

source

pub fn clear(&mut self)

Clear the internal rename table.

Trait Implementations§

source§

impl ExpressionReconstructor for AssignmentRenamer<'_>

source§

fn reconstruct_identifier( &mut self, diff --git a/leo_passes/function_inlining/function_inliner/struct.FunctionInliner.html b/leo_passes/function_inlining/function_inliner/struct.FunctionInliner.html index 76c961558c..a373114474 100644 --- a/leo_passes/function_inlining/function_inliner/struct.FunctionInliner.html +++ b/leo_passes/function_inlining/function_inliner/struct.FunctionInliner.html @@ -3,15 +3,15 @@ pub(crate) call_graph: &'a CallGraph, pub(crate) assignment_renamer: AssignmentRenamer<'a>, pub(crate) type_table: &'a TypeTable, - pub(crate) reconstructed_functions: Vec<(Symbol, Function)>, - pub(crate) program: Option<Symbol>, + pub(crate) reconstructed_functions: Vec<(Symbol, Function)>, + pub(crate) program: Option<Symbol>, pub(crate) is_async: bool, }

Fields§

§node_builder: &'a NodeBuilder

A counter used to create unique NodeIDs.

§call_graph: &'a CallGraph

The call graph for the program.

§assignment_renamer: AssignmentRenamer<'a>

A wrapper around an Assigner used to create unique variable assignments.

§type_table: &'a TypeTable

A mapping between node IDs and their types.

-
§reconstructed_functions: Vec<(Symbol, Function)>

A map of reconstructed functions in the current program scope.

-
§program: Option<Symbol>

The main program.

+
§reconstructed_functions: Vec<(Symbol, Function)>

A map of reconstructed functions in the current program scope.

+
§program: Option<Symbol>

The main program.

§is_async: bool

Whether or not we are currently traversing an async function block.

Implementations§

source§

impl<'a> FunctionInliner<'a>

source

pub fn new( node_builder: &'a NodeBuilder, @@ -79,7 +79,7 @@ ) -> (Expression, Self::AdditionalOutput)

source§

fn reconstruct_unit( &mut self, input: UnitExpression, -) -> (Expression, Self::AdditionalOutput)

source§

impl<'a> Pass for FunctionInliner<'a>

§

type Input = (Ast, &'a NodeBuilder, &'a DiGraph<Symbol>, &'a Assigner, &'a TypeTable)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass( +) -> (Expression, Self::AdditionalOutput)

source§

impl<'a> Pass for FunctionInliner<'a>

§

type Input = (Ast, &'a NodeBuilder, &'a DiGraph<Symbol>, &'a Assigner, &'a TypeTable)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass( (ast, node_builder, call_graph, assigner, tt): Self::Input, ) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for FunctionInliner<'_>

source§

impl StatementReconstructor for FunctionInliner<'_>

source§

fn reconstruct_assign( &mut self, diff --git a/leo_passes/loop_unrolling/range_iterator/trait.LoopBound.html b/leo_passes/loop_unrolling/range_iterator/trait.LoopBound.html index b092b8d628..956b47720e 100644 --- a/leo_passes/loop_unrolling/range_iterator/trait.LoopBound.html +++ b/leo_passes/loop_unrolling/range_iterator/trait.LoopBound.html @@ -1,2 +1,2 @@ -LoopBound in leo_passes::loop_unrolling::range_iterator - Rust
pub(crate) trait LoopBound: Add<Output = Self> + Copy + Display + One + PartialOrd + TryFrom<Value, Error = LeoError> { }
Expand description

A trait for whose implementors are concrete values for loop bounds.

+LoopBound in leo_passes::loop_unrolling::range_iterator - Rust
pub(crate) trait LoopBound: Add<Output = Self> + Copy + Display + One + PartialOrd + TryFrom<Value, Error = LeoError> { }
Expand description

A trait for whose implementors are concrete values for loop bounds.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl LoopBound for i128

source§

impl LoopBound for u128

Implementors§

\ No newline at end of file diff --git a/leo_passes/loop_unrolling/unroller/struct.Unroller.html b/leo_passes/loop_unrolling/unroller/struct.Unroller.html index d285594a7e..6ccffc4f6d 100644 --- a/leo_passes/loop_unrolling/unroller/struct.Unroller.html +++ b/leo_passes/loop_unrolling/unroller/struct.Unroller.html @@ -3,28 +3,28 @@ pub(crate) symbol_table: RefCell<SymbolTable>, pub(crate) type_table: &'a TypeTable, pub(crate) scope_index: usize, - pub(crate) handler: &'a Handler, + pub(crate) handler: &'a Handler, pub(crate) node_builder: &'a NodeBuilder, pub(crate) is_unrolling: bool, - pub(crate) current_program: Option<Symbol>, + pub(crate) current_program: Option<Symbol>, }

Fields§

§constant_propagation_table: RefCell<ConstantPropagationTable>

A table of constant variables.

§symbol_table: RefCell<SymbolTable>

The symbol table for the function being processed.

§type_table: &'a TypeTable

A mapping from node IDs to their types.

§scope_index: usize

The index of the current scope.

-
§handler: &'a Handler

An error handler used for any errors found during unrolling.

+
§handler: &'a Handler

An error handler used for any errors found during unrolling.

§node_builder: &'a NodeBuilder

A counter used to generate unique node IDs.

§is_unrolling: bool

Are we in the midst of unrolling a loop?

-
§current_program: Option<Symbol>

The current program name.

+
§current_program: Option<Symbol>

The current program name.

Implementations§

source§

impl<'a> Unroller<'a>

source

pub(crate) fn new( symbol_table: SymbolTable, type_table: &'a TypeTable, - handler: &'a Handler, + handler: &'a Handler, node_builder: &'a NodeBuilder, ) -> Self

source

pub(crate) fn current_scope_index(&mut self) -> usize

Returns the index of the current scope. Note that if we are in the midst of unrolling an IterationStatement, a new scope is created.

source

pub(crate) fn enter_scope(&mut self, index: usize) -> usize

Enters a child scope.

source

pub(crate) fn exit_scope(&mut self, index: usize)

Exits the current block scope.

-
source

pub(crate) fn emit_err(&self, err: LoopUnrollerError)

Emits a Loop Unrolling Error

+
source

pub(crate) fn emit_err(&self, err: LoopUnrollerError)

Emits a Loop Unrolling Error

source

pub(crate) fn unroll_iteration_statement<I: LoopBound>( &mut self, input: IterationStatement, @@ -94,7 +94,7 @@ ) -> (Expression, Self::AdditionalOutput)

source§

fn reconstruct_unit( &mut self, input: UnitExpression, -) -> (Expression, Self::AdditionalOutput)

source§

impl<'a> Pass for Unroller<'a>

§

type Input = (Ast, &'a Handler, &'a NodeBuilder, SymbolTable, &'a TypeTable)

§

type Output = Result<(Ast, SymbolTable), LeoError>

source§

fn do_pass((ast, handler, node_builder, st, tt): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for Unroller<'_>

source§

impl StatementReconstructor for Unroller<'_>

source§

impl<'a> Pass for Unroller<'a>

§

type Input = (Ast, &'a Handler, &'a NodeBuilder, SymbolTable, &'a TypeTable)

§

type Output = Result<(Ast, SymbolTable), LeoError>

source§

fn do_pass((ast, handler, node_builder, st, tt): Self::Input) -> Self::Output

Runs the compiler pass.
source§

impl ProgramReconstructor for Unroller<'_>

source§

impl StatementReconstructor for Unroller<'_>

source§

fn reconstruct_block(&mut self, input: Block) -> (Block, Self::AdditionalOutput)

source§

fn reconstruct_const( &mut self, input: ConstDeclaration, ) -> (Statement, Self::AdditionalOutput)

source§

fn reconstruct_definition( diff --git a/leo_passes/pass/trait.Pass.html b/leo_passes/pass/trait.Pass.html index 6d863812fb..f41a8fcf9d 100644 --- a/leo_passes/pass/trait.Pass.html +++ b/leo_passes/pass/trait.Pass.html @@ -6,4 +6,4 @@ fn do_pass(input: Self::Input) -> Self::Output; }
Expand description

A compiler pass consuming Self::Input and returning Self::Output.

Required Associated Types§

Required Methods§

source

fn do_pass(input: Self::Input) -> Self::Output

Runs the compiler pass.

-

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<'a> Pass for CodeGenerator<'a>

§

type Input = (&'a Ast, &'a SymbolTable, &'a TypeTable, &'a DiGraph<Symbol>, &'a DiGraph<Symbol>, &'a Program)

§

type Output = Result<String, LeoError>

source§

impl<'a> Pass for DeadCodeEliminator<'a>

§

type Input = (Ast, &'a NodeBuilder)

§

type Output = Result<Ast, LeoError>

source§

impl<'a> Pass for Destructurer<'a>

§

type Input = (Ast, &'a TypeTable, &'a NodeBuilder, &'a Assigner)

§

type Output = Result<Ast, LeoError>

source§

impl<'a> Pass for Flattener<'a>

§

type Input = (Ast, &'a SymbolTable, &'a TypeTable, &'a NodeBuilder, &'a Assigner)

§

type Output = Result<Ast, LeoError>

source§

impl<'a> Pass for FunctionInliner<'a>

§

type Input = (Ast, &'a NodeBuilder, &'a DiGraph<Symbol>, &'a Assigner, &'a TypeTable)

§

type Output = Result<Ast, LeoError>

source§

impl<'a> Pass for Unroller<'a>

§

type Input = (Ast, &'a Handler, &'a NodeBuilder, SymbolTable, &'a TypeTable)

§

type Output = Result<(Ast, SymbolTable), LeoError>

source§

impl<'a> Pass for StaticSingleAssigner<'a>

§

type Input = (Ast, &'a NodeBuilder, &'a Assigner, &'a SymbolTable, &'a TypeTable)

§

type Output = Result<Ast, LeoError>

source§

impl<'a> Pass for SymbolTableCreator<'a>

§

type Input = (&'a Ast, &'a Handler)

§

type Output = Result<SymbolTable, LeoError>

source§

impl<'a, N: Network> Pass for TypeChecker<'a, N>

§

type Input = (&'a Ast, &'a Handler, SymbolTable, &'a TypeTable, usize, bool)

§

type Output = Result<(SymbolTable, DiGraph<Symbol>, DiGraph<Symbol>), LeoError>

\ No newline at end of file +

Object Safety§

This trait is not object safe.

Implementors§

\ No newline at end of file diff --git a/leo_passes/static_single_assignment/static_single_assigner/struct.StaticSingleAssigner.html b/leo_passes/static_single_assignment/static_single_assigner/struct.StaticSingleAssigner.html index fc94ceb58f..dad4e57d65 100644 --- a/leo_passes/static_single_assignment/static_single_assigner/struct.StaticSingleAssigner.html +++ b/leo_passes/static_single_assignment/static_single_assigner/struct.StaticSingleAssigner.html @@ -5,14 +5,14 @@ pub(crate) rename_table: RenameTable, pub(crate) is_lhs: bool, pub(crate) assigner: &'a Assigner, - pub(crate) program: Option<Symbol>, + pub(crate) program: Option<Symbol>, }

Fields§

§node_builder: &'a NodeBuilder

A counter used to generate unique node IDs.

§symbol_table: &'a SymbolTable

The SymbolTable of the program.

§type_table: &'a TypeTable

A mapping from node IDs to their types.

§rename_table: RenameTable

The RenameTable for the current basic block in the AST

§is_lhs: bool

A flag to determine whether or not the traversal is on the left-hand side of a definition or an assignment.

§assigner: &'a Assigner

A struct used to construct (unique) assignment statements.

-
§program: Option<Symbol>

The main program name.

+
§program: Option<Symbol>

The main program name.

Implementations§

source§

impl<'a> StaticSingleAssigner<'a>

source

pub(crate) fn new( node_builder: &'a NodeBuilder, symbol_table: &'a SymbolTable, @@ -44,7 +44,7 @@

source§

fn consume_tuple(&mut self, input: TupleExpression) -> Self::Output

Consumes a tuple expression, accumulating any statements that are generated

source§

fn consume_unary(&mut self, input: UnaryExpression) -> Self::Output

Consumes a unary expression, accumulating any statements that are generated.

§

type Output = (Expression, Vec<Statement>)

source§

fn consume_unit(&mut self, input: UnitExpression) -> Self::Output

source§

fn consume_expression(&mut self, input: Expression) -> Self::Output

source§

fn consume_err(&mut self, _input: ErrExpression) -> Self::Output

source§

impl FunctionConsumer for StaticSingleAssigner<'_>

source§

fn consume_function(&mut self, function: Function) -> Self::Output

Reconstructs the Functions in the Program, while allocating the appropriate RenameTables.

-
§

type Output = Function

source§

impl<'a> Pass for StaticSingleAssigner<'a>

§

type Input = (Ast, &'a NodeBuilder, &'a Assigner, &'a SymbolTable, &'a TypeTable)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass( +

§

type Output = Function

source§

impl<'a> Pass for StaticSingleAssigner<'a>

§

type Input = (Ast, &'a NodeBuilder, &'a Assigner, &'a SymbolTable, &'a TypeTable)

§

type Output = Result<Ast, LeoError>

source§

fn do_pass( (ast, node_builder, assigner, symbol_table, type_table): Self::Input, ) -> Self::Output

Runs the compiler pass.
source§

impl ProgramConsumer for StaticSingleAssigner<'_>

§

type Output = Program

source§

fn consume_program(&mut self, input: Program) -> Self::Output

source§

impl ProgramScopeConsumer for StaticSingleAssigner<'_>

source§

impl StatementConsumer for StaticSingleAssigner<'_>

source§

fn consume_assert(&mut self, input: AssertStatement) -> Self::Output

Consumes the expressions in an AssertStatement, returning the list of simplified statements.

source§

fn consume_assign(&mut self, assign: AssignStatement) -> Self::Output

Consume all AssignStatements, renaming as necessary.

diff --git a/leo_passes/symbol_table_creation/creator/struct.SymbolTableCreator.html b/leo_passes/symbol_table_creation/creator/struct.SymbolTableCreator.html index 185d2e1734..f6e7a5859d 100644 --- a/leo_passes/symbol_table_creation/creator/struct.SymbolTableCreator.html +++ b/leo_passes/symbol_table_creation/creator/struct.SymbolTableCreator.html @@ -1,18 +1,18 @@ SymbolTableCreator in leo_passes::symbol_table_creation::creator - Rust
pub struct SymbolTableCreator<'a> {
     pub(crate) symbol_table: SymbolTable,
-    handler: &'a Handler,
-    program_name: Option<Symbol>,
+    handler: &'a Handler,
+    program_name: Option<Symbol>,
     is_stub: bool,
-    structs: IndexSet<Symbol>,
+    structs: IndexSet<Symbol>,
 }
Expand description

A compiler pass during which the SymbolTable is created. Note that this pass only creates the initial entries for functions, structs, and records. The table is populated further during the type checking pass.

Fields§

§symbol_table: SymbolTable

The SymbolTable constructed by this compiler pass.

-
§handler: &'a Handler

The error handler.

-
§program_name: Option<Symbol>

The current program name.

+
§handler: &'a Handler

The error handler.

+
§program_name: Option<Symbol>

The current program name.

§is_stub: bool

Whether or not traversing stub.

-
§structs: IndexSet<Symbol>

The set of local structs that have been successfully visited.

-

Implementations§

source§

impl<'a> SymbolTableCreator<'a>

source

pub fn new(handler: &'a Handler) -> Self

Trait Implementations§

source§

impl<'a> ExpressionVisitor<'a> for SymbolTableCreator<'a>

§structs: IndexSet<Symbol>

The set of local structs that have been successfully visited.

+

Implementations§

source§

impl<'a> SymbolTableCreator<'a>

source

pub fn new(handler: &'a Handler) -> Self

Trait Implementations§

source§

impl<'a> ExpressionVisitor<'a> for SymbolTableCreator<'a>

§

type AdditionalInput = ()

§

type Output = ()

source§

fn visit_expression( &mut self, input: &'a Expression, additional: &Self::AdditionalInput, @@ -73,7 +73,7 @@ _input: &'a UnitExpression, _additional: &Self::AdditionalInput, ) -> Self::Output

source§

impl<'a> Pass for SymbolTableCreator<'a>

source§

fn do_pass((ast, handler): Self::Input) -> Self::Output

Runs the compiler pass.

-
§

type Input = (&'a Ast, &'a Handler)

§

type Output = Result<SymbolTable, LeoError>

source§

impl<'a> ProgramVisitor<'a> for SymbolTableCreator<'a>

source§

fn visit_program_scope(&mut self, input: &'a ProgramScope)

source§

fn visit_import(&mut self, input: &'a Program)

source§

fn visit_struct(&mut self, input: &'a Composite)

source§

fn visit_mapping(&mut self, input: &'a Mapping)

source§

fn visit_function(&mut self, input: &'a Function)

source§

fn visit_stub(&mut self, input: &'a Stub)

source§

fn visit_function_stub(&mut self, input: &'a FunctionStub)

source§

fn visit_struct_stub(&mut self, input: &'a Composite)

source§

fn visit_program(&mut self, input: &'a Program)

source§

impl<'a> StatementVisitor<'a> for SymbolTableCreator<'a>

source§

fn visit_statement(&mut self, input: &'a Statement)

source§

fn visit_assert(&mut self, input: &'a AssertStatement)

source§

fn visit_assign(&mut self, input: &'a AssignStatement)

source§

fn visit_block(&mut self, input: &'a Block)

source§

fn visit_conditional(&mut self, input: &'a ConditionalStatement)

source§

fn visit_console(&mut self, input: &'a ConsoleStatement)

source§

fn visit_const(&mut self, input: &'a ConstDeclaration)

source§

fn visit_definition(&mut self, input: &'a DefinitionStatement)

source§

fn visit_expression_statement(&mut self, input: &'a ExpressionStatement)

source§

fn visit_iteration(&mut self, input: &'a IterationStatement)

source§

fn visit_return(&mut self, input: &'a ReturnStatement)

Auto Trait Implementations§

§

impl<'a> Freeze for SymbolTableCreator<'a>

§

impl<'a> !RefUnwindSafe for SymbolTableCreator<'a>

§

impl<'a> !Send for SymbolTableCreator<'a>

§

impl<'a> !Sync for SymbolTableCreator<'a>

§

impl<'a> Unpin for SymbolTableCreator<'a>

§

impl<'a> !UnwindSafe for SymbolTableCreator<'a>

Blanket Implementations§

source§

impl<T> Any for T
where +

§

type Input = (&'a Ast, &'a Handler)

§

type Output = Result<SymbolTable, LeoError>

source§

impl<'a> ProgramVisitor<'a> for SymbolTableCreator<'a>

source§

fn visit_program_scope(&mut self, input: &'a ProgramScope)

source§

fn visit_import(&mut self, input: &'a Program)

source§

fn visit_struct(&mut self, input: &'a Composite)

source§

fn visit_mapping(&mut self, input: &'a Mapping)

source§

fn visit_function(&mut self, input: &'a Function)

source§

fn visit_stub(&mut self, input: &'a Stub)

source§

fn visit_function_stub(&mut self, input: &'a FunctionStub)

source§

fn visit_struct_stub(&mut self, input: &'a Composite)

source§

fn visit_program(&mut self, input: &'a Program)

source§

impl<'a> StatementVisitor<'a> for SymbolTableCreator<'a>

source§

fn visit_statement(&mut self, input: &'a Statement)

source§

fn visit_assert(&mut self, input: &'a AssertStatement)

source§

fn visit_assign(&mut self, input: &'a AssignStatement)

source§

fn visit_block(&mut self, input: &'a Block)

source§

fn visit_conditional(&mut self, input: &'a ConditionalStatement)

source§

fn visit_console(&mut self, input: &'a ConsoleStatement)

source§

fn visit_const(&mut self, input: &'a ConstDeclaration)

source§

fn visit_definition(&mut self, input: &'a DefinitionStatement)

source§

fn visit_expression_statement(&mut self, input: &'a ExpressionStatement)

source§

fn visit_iteration(&mut self, input: &'a IterationStatement)

source§

fn visit_return(&mut self, input: &'a ReturnStatement)

Auto Trait Implementations§

§

impl<'a> Freeze for SymbolTableCreator<'a>

§

impl<'a> !RefUnwindSafe for SymbolTableCreator<'a>

§

impl<'a> !Send for SymbolTableCreator<'a>

§

impl<'a> !Sync for SymbolTableCreator<'a>

§

impl<'a> Unpin for SymbolTableCreator<'a>

§

impl<'a> !UnwindSafe for SymbolTableCreator<'a>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

diff --git a/leo_passes/type_checking/await_checker/struct.AwaitChecker.html b/leo_passes/type_checking/await_checker/struct.AwaitChecker.html index d102da9821..d95cac3590 100644 --- a/leo_passes/type_checking/await_checker/struct.AwaitChecker.html +++ b/leo_passes/type_checking/await_checker/struct.AwaitChecker.html @@ -1,20 +1,20 @@ AwaitChecker in leo_passes::type_checking::await_checker - Rust

Struct leo_passes::type_checking::await_checker::AwaitChecker

source ·
pub struct AwaitChecker {
     pub(crate) to_await: Vec<ConditionalTreeNode>,
-    pub(crate) static_to_await: IndexSet<Symbol>,
+    pub(crate) static_to_await: IndexSet<Symbol>,
     pub(crate) enabled: bool,
     pub(crate) max_depth: usize,
 }

Fields§

§to_await: Vec<ConditionalTreeNode>

All possible subsets of futures that must be awaited.

-
§static_to_await: IndexSet<Symbol>

Statically updated set of futures to await.

+
§static_to_await: IndexSet<Symbol>

Statically updated set of futures to await.

§enabled: bool

Whether or not to do full tree search for await checking.

§max_depth: usize

Maximum nesting depth to search for await checking.

Implementations§

source§

impl AwaitChecker

source

pub fn new(max_depth: usize, enabled: bool) -> Self

Initializes a new AwaitChecker.

source

pub fn remove(&mut self, id: &Identifier)

Remove from list.

-
source

pub fn set_futures(&mut self, futures: IndexSet<Symbol>)

Initialize futures.

+
source

pub fn set_futures(&mut self, futures: IndexSet<Symbol>)

Initialize futures.

source

pub fn create_then_scope( &mut self, is_finalize: bool, - input: Span, -) -> Result<Vec<ConditionalTreeNode>, TypeCheckerWarning>

Enter scope for then branch of conditional.

+ input: Span, +) -> Result<Vec<ConditionalTreeNode>, TypeCheckerWarning>

Enter scope for then branch of conditional.

source

pub fn exit_then_scope( &mut self, is_finalize: bool, diff --git a/leo_passes/type_checking/checker/struct.TypeChecker.html b/leo_passes/type_checking/checker/struct.TypeChecker.html index ecc7d9c60a..462b0c51c9 100644 --- a/leo_passes/type_checking/checker/struct.TypeChecker.html +++ b/leo_passes/type_checking/checker/struct.TypeChecker.html @@ -3,93 +3,93 @@ pub(crate) type_table: &'a TypeTable, pub(crate) struct_graph: StructGraph, pub(crate) call_graph: CallGraph, - pub(crate) handler: &'a Handler, + pub(crate) handler: &'a Handler, pub(crate) scope_state: ScopeState, pub(crate) await_checker: AwaitChecker, pub(crate) async_function_input_types: IndexMap<Location, Vec<Type>>, - pub(crate) used_structs: IndexSet<Symbol>, + pub(crate) used_structs: IndexSet<Symbol>, phantom: PhantomData<N>, }

Fields§

§symbol_table: RefCell<SymbolTable>

The symbol table for the program.

§type_table: &'a TypeTable

A mapping from node IDs to their types.

§struct_graph: StructGraph

A dependency graph of the structs in program.

§call_graph: CallGraph

The call graph for the program.

-
§handler: &'a Handler

The error handler.

+
§handler: &'a Handler

The error handler.

§scope_state: ScopeState

The state of the current scope being traversed.

§await_checker: AwaitChecker

Struct to store the state relevant to checking all futures are awaited.

§async_function_input_types: IndexMap<Location, Vec<Type>>

Mapping from async function name to the inferred input types.

-
§used_structs: IndexSet<Symbol>

The set of used composites.

+
§used_structs: IndexSet<Symbol>

The set of used composites.

§phantom: PhantomData<N>

Implementations§

source§

impl<'a, N: Network> TypeChecker<'a, N>

source

pub fn new( symbol_table: SymbolTable, type_table: &'a TypeTable, - handler: &'a Handler, + handler: &'a Handler, max_depth: usize, disabled: bool, ) -> Self

Returns a new type checker given a symbol table and error handler.

source

pub(crate) fn enter_scope(&mut self, index: usize)

Enters a child scope.

source

pub(crate) fn create_child_scope(&mut self) -> usize

Creates a new child scope.

source

pub(crate) fn exit_scope(&mut self, index: usize)

Exits the current scope.

-
source

pub(crate) fn emit_err(&self, err: TypeCheckerError)

Emits a type checker error.

-
source

pub fn emit_warning(&self, warning: TypeCheckerWarning)

Emits a type checker warning

+
source

pub(crate) fn emit_err(&self, err: TypeCheckerError)

Emits a type checker error.

+
source

pub fn emit_warning(&self, warning: TypeCheckerWarning)

Emits a type checker warning

source

fn check_type( &self, is_valid: impl Fn(&Type) -> bool, error_string: String, type_: &Option<Type>, - span: Span, + span: Span, )

Emits an error to the handler if the given type is invalid.

source

pub(crate) fn check_eq_types( &self, t1: &Option<Type>, t2: &Option<Type>, - span: Span, + span: Span, )

Emits an error if the two given types are not equal.

source

pub(crate) fn assert_and_return_type( &mut self, actual: Type, expected: &Option<Type>, - span: Span, + span: Span, ) -> Type

Use this method when you know the actual type. Emits an error to the handler if the actual type is not equal to the expected type.

source

pub(crate) fn assert_type( &mut self, actual: &Option<Type>, expected: &Type, - span: Span, + span: Span, )

Emits an error to the error handler if the actual type is not equal to the expected type.

-
source

pub(crate) fn assert_address_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the error handler if the given type is not an address.

-
source

pub(crate) fn assert_bool_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a boolean.

-
source

pub(crate) fn assert_field_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field.

-
source

pub(crate) fn assert_group_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a group.

-
source

pub(crate) fn assert_scalar_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a scalar.

-
source

pub(crate) fn assert_signature_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a signature.

-
source

pub(crate) fn assert_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not an integer.

-
source

pub(crate) fn assert_signed_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a signed integer.

-
source

pub(crate) fn assert_unsigned_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not an unsigned integer.

-
source

pub(crate) fn assert_magnitude_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a magnitude (u8, u16, u32).

-
source

pub(crate) fn assert_bool_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a boolean or an integer.

-
source

pub(crate) fn assert_field_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field or integer.

-
source

pub(crate) fn assert_field_group_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field or group.

+
source

pub(crate) fn assert_address_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the error handler if the given type is not an address.

+
source

pub(crate) fn assert_bool_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a boolean.

+
source

pub(crate) fn assert_field_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field.

+
source

pub(crate) fn assert_group_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a group.

+
source

pub(crate) fn assert_scalar_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a scalar.

+
source

pub(crate) fn assert_signature_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a signature.

+
source

pub(crate) fn assert_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not an integer.

+
source

pub(crate) fn assert_signed_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a signed integer.

+
source

pub(crate) fn assert_unsigned_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not an unsigned integer.

+
source

pub(crate) fn assert_magnitude_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a magnitude (u8, u16, u32).

+
source

pub(crate) fn assert_bool_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a boolean or an integer.

+
source

pub(crate) fn assert_field_int_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field or integer.

+
source

pub(crate) fn assert_field_group_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field or group.

source

pub(crate) fn assert_field_group_int_type( &self, type_: &Option<Type>, - span: Span, + span: Span, )

Emits an error to the handler if the given type is not a field, group, or integer.

source

pub(crate) fn assert_field_group_signed_int_type( &self, type_: &Option<Type>, - span: Span, + span: Span, )

Emits an error to the handler if the given type is not a field, group, or signed integer.

source

pub(crate) fn assert_field_scalar_int_type( &self, type_: &Option<Type>, - span: Span, + span: Span, )

Emits an error to the handler if the given type is not a field, scalar, or integer.

source

pub(crate) fn assert_field_group_scalar_int_type( &self, type_: &Option<Type>, - span: Span, + span: Span, )

Emits an error to the handler if the given type is not a field, group, scalar, integer, or boolean.

-
source

pub(crate) fn assert_castable_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field, group, scalar, integer, boolean, or address.

+
source

pub(crate) fn assert_castable_type(&self, type_: &Option<Type>, span: Span)

Emits an error to the handler if the given type is not a field, group, scalar, integer, boolean, or address.

source

pub(crate) fn get_core_constant( &self, type_: &Type, @@ -104,8 +104,8 @@

source

pub(crate) fn check_core_function_call( &mut self, core_function: CoreFunction, - arguments: &[(Option<Type>, Span)], - function_span: Span, + arguments: &[(Option<Type>, Span)], + function_span: Span, ) -> Option<Type>

Type checks the inputs to a core function call and returns the expected output type. Emits an error if the correct number of arguments are not provided. Emits an error if the arguments are not of the correct type.

@@ -113,31 +113,31 @@ &mut self, struct_: &Composite, expected: &Option<Type>, - span: Span, + span: Span, ) -> Type

Returns the struct type and emits an error if the expected type does not match.

source

pub(crate) fn assert_member_is_not_record( &mut self, - span: Span, - parent: Symbol, + span: Span, + parent: Symbol, type_: &Type, )

Emits an error if the struct member is a record type.

-
source

pub(crate) fn assert_type_is_valid(&mut self, type_: &Type, span: Span) -> bool

Emits an error if the type or its constituent types is not valid.

+
source

pub(crate) fn assert_type_is_valid(&mut self, type_: &Type, span: Span) -> bool

Emits an error if the type or its constituent types is not valid.

source

pub(crate) fn assert_mapping_type( &self, type_: &Option<Type>, - span: Span, + span: Span, ) -> Option<MappingType>

Emits an error if the type is not a mapping.

-
source

pub(crate) fn assert_array_type(&self, type_: &Option<Type>, span: Span)

Emits an error if the type is not an array.

+
source

pub(crate) fn assert_array_type(&self, type_: &Option<Type>, span: Span)

Emits an error if the type is not an array.

source

pub(crate) fn check_function_signature(&mut self, function: &Function)

Helper function to check that the input and output of function are valid

source

pub(crate) fn lookup_struct( &mut self, - program: Option<Symbol>, - name: Symbol, + program: Option<Symbol>, + name: Symbol, ) -> Option<Composite>

Wrapper around lookup_struct that additionally records all structs that are used in the program.

source

pub(crate) fn assert_future_await( &mut self, future: &Option<&Expression>, - span: Span, + span: Span, )

Type checks the awaiting of a future.

source

pub(crate) fn insert_variable( &mut self, @@ -145,13 +145,13 @@ name: &Identifier, type_: Type, index: usize, - span: Span, + span: Span, )

Inserts variable to symbol table.

source

pub(crate) fn check_access_allowed( &mut self, name: &str, finalize_op: bool, - span: Span, + span: Span, )

Trait Implementations§

source§

impl<'a, N: Network> ExpressionVisitor<'a> for TypeChecker<'a, N>

§

type AdditionalInput = Option<Type>

§

type Output = Option<Type>

source§

fn visit_expression( &mut self, input: &'a Expression, @@ -212,7 +212,7 @@ &mut self, input: &'a UnitExpression, _additional: &Self::AdditionalInput, -) -> Self::Output

source§

impl<'a, N: Network> Pass for TypeChecker<'a, N>

§

type Input = (&'a Ast, &'a Handler, SymbolTable, &'a TypeTable, usize, bool)

§

type Output = Result<(SymbolTable, DiGraph<Symbol>, DiGraph<Symbol>), LeoError>

source§

fn do_pass( +) -> Self::Output

source§

impl<'a, N: Network> Pass for TypeChecker<'a, N>

§

type Input = (&'a Ast, &'a Handler, SymbolTable, &'a TypeTable, usize, bool)

§

type Output = Result<(SymbolTable, DiGraph<Symbol>, DiGraph<Symbol>), LeoError>

source§

fn do_pass( (ast, handler, st, tt, max_depth, await_checking): Self::Input, ) -> Self::Output

Runs the compiler pass.
source§

impl<'a, N: Network> ProgramVisitor<'a> for TypeChecker<'a, N>

source§

fn visit_program(&mut self, input: &'a Program)

source§

fn visit_program_scope(&mut self, input: &'a ProgramScope)

source§

fn visit_stub(&mut self, input: &'a Stub)

source§

fn visit_struct(&mut self, input: &'a Composite)

source§

fn visit_mapping(&mut self, input: &'a Mapping)

source§

fn visit_function(&mut self, function: &'a Function)

source§

fn visit_function_stub(&mut self, input: &'a FunctionStub)

source§

fn visit_struct_stub(&mut self, input: &'a Composite)

source§

fn visit_import(&mut self, input: &'a Program)

source§

impl<'a, N: Network> StatementVisitor<'a> for TypeChecker<'a, N>

source§

fn visit_statement(&mut self, input: &'a Statement)

source§

fn visit_assert(&mut self, input: &'a AssertStatement)

source§

fn visit_assign(&mut self, input: &'a AssignStatement)

source§

fn visit_block(&mut self, input: &'a Block)

source§

fn visit_conditional(&mut self, input: &'a ConditionalStatement)

source§

fn visit_console(&mut self, _: &'a ConsoleStatement)

source§

fn visit_const(&mut self, input: &'a ConstDeclaration)

source§

fn visit_definition(&mut self, input: &'a DefinitionStatement)

source§

fn visit_expression_statement(&mut self, input: &'a ExpressionStatement)

source§

fn visit_iteration(&mut self, input: &'a IterationStatement)

source§

fn visit_return(&mut self, input: &'a ReturnStatement)

Auto Trait Implementations§

§

impl<'a, N> !Freeze for TypeChecker<'a, N>

§

impl<'a, N> !RefUnwindSafe for TypeChecker<'a, N>

§

impl<'a, N> !Send for TypeChecker<'a, N>

§

impl<'a, N> !Sync for TypeChecker<'a, N>

§

impl<'a, N> Unpin for TypeChecker<'a, N>
where N: Unpin,

§

impl<'a, N> !UnwindSafe for TypeChecker<'a, N>

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/leo_passes/type_checking/scope_state/struct.ScopeState.html b/leo_passes/type_checking/scope_state/struct.ScopeState.html index 2a1680e407..426115c331 100644 --- a/leo_passes/type_checking/scope_state/struct.ScopeState.html +++ b/leo_passes/type_checking/scope_state/struct.ScopeState.html @@ -1,22 +1,22 @@ ScopeState in leo_passes::type_checking::scope_state - Rust

Struct leo_passes::type_checking::scope_state::ScopeState

source ·
pub struct ScopeState {
-    pub(crate) function: Option<Symbol>,
+    pub(crate) function: Option<Symbol>,
     pub(crate) variant: Option<Variant>,
     pub(crate) has_return: bool,
     pub(crate) is_return: bool,
-    pub(crate) program_name: Option<Symbol>,
+    pub(crate) program_name: Option<Symbol>,
     pub(crate) is_stub: bool,
-    pub(crate) futures: IndexMap<Symbol, Location>,
+    pub(crate) futures: IndexMap<Symbol, Location>,
     pub(crate) has_called_finalize: bool,
     pub(crate) is_conditional: bool,
     pub(crate) is_call: bool,
     pub(crate) call_location: Option<Location>,
-}

Fields§

§function: Option<Symbol>

The name of the function that we are currently traversing.

+}

Fields§

§function: Option<Symbol>

The name of the function that we are currently traversing.

§variant: Option<Variant>

The variant of the function that we are currently traversing.

§has_return: bool

Whether or not the function that we are currently traversing has a return statement.

§is_return: bool

Whether or not we are currently traversing a return statement.

-
§program_name: Option<Symbol>

Current program name.

+
§program_name: Option<Symbol>

Current program name.

§is_stub: bool

Whether or not we are currently traversing a stub.

-
§futures: IndexMap<Symbol, Location>

The futures that must be propagated to an async function.

+
§futures: IndexMap<Symbol, Location>

The futures that must be propagated to an async function.

§has_called_finalize: bool

Whether the finalize caller has called the finalize function.

§is_conditional: bool

Whether currently traversing a conditional statement.

§is_call: bool

Whether the current function is a call.

diff --git a/leo_retriever/program_context/dependency/struct.Dependency.html b/leo_retriever/program_context/dependency/struct.Dependency.html index b4f5a500e7..9d56afa67c 100644 --- a/leo_retriever/program_context/dependency/struct.Dependency.html +++ b/leo_retriever/program_context/dependency/struct.Dependency.html @@ -9,7 +9,7 @@ network: Option<NetworkName>, path: Option<PathBuf>, ) -> Self

source

pub fn name(&self) -> &String

source

pub fn location(&self) -> &Location

source

pub fn network(&self) -> &Option<NetworkName>

source

pub fn path(&self) -> &Option<PathBuf>

Trait Implementations§

source§

impl Clone for Dependency

source§

fn clone(&self) -> Dependency

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Dependency

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Dependency

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where - __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl From<&Dependency> for Symbol

source§

fn from(context: &Dependency) -> Self

Converts to this type from the input type.
source§

impl From<Dependency> for ProgramContext

source§

fn from(dependency: Dependency) -> Self

Converts to this type from the input type.
source§

impl Hash for Dependency

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where + __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl From<&Dependency> for Symbol

source§

fn from(context: &Dependency) -> Self

Converts to this type from the input type.
source§

impl From<Dependency> for ProgramContext

source§

fn from(dependency: Dependency) -> Self

Converts to this type from the input type.
source§

impl Hash for Dependency

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq for Dependency

source§

fn eq(&self, other: &Dependency) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always diff --git a/leo_retriever/program_context/manifest/struct.Manifest.html b/leo_retriever/program_context/manifest/struct.Manifest.html index e7589727bd..26a15a016a 100644 --- a/leo_retriever/program_context/manifest/struct.Manifest.html +++ b/leo_retriever/program_context/manifest/struct.Manifest.html @@ -10,7 +10,7 @@ description: &str, license: &str, dependencies: Option<Vec<Dependency>>, -) -> Self
source

pub fn default(program: &str) -> Self

source

pub fn program(&self) -> &String

source

pub fn version(&self) -> &String

source

pub fn description(&self) -> &String

source

pub fn license(&self) -> &String

source

pub fn dependencies(&self) -> &Option<Vec<Dependency>>

source

pub fn write_to_dir(&self, path: &Path) -> Result<(), PackageError>

source

pub fn read_from_dir(path: &Path) -> Result<Self, PackageError>

Trait Implementations§

source§

impl Clone for Manifest

source§

fn clone(&self) -> Manifest

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Manifest

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Manifest

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where +) -> Self

source

pub fn default(program: &str) -> Self

source

pub fn program(&self) -> &String

source

pub fn version(&self) -> &String

source

pub fn description(&self) -> &String

source

pub fn license(&self) -> &String

source

pub fn dependencies(&self) -> &Option<Vec<Dependency>>

source

pub fn write_to_dir(&self, path: &Path) -> Result<(), PackageError>

source

pub fn read_from_dir(path: &Path) -> Result<Self, PackageError>

Trait Implementations§

source§

impl Clone for Manifest

source§

fn clone(&self) -> Manifest

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Manifest

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Manifest

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Serialize for Manifest

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where diff --git a/leo_retriever/program_context/network_name/enum.NetworkName.html b/leo_retriever/program_context/network_name/enum.NetworkName.html index 187194b72a..6ad57ef28a 100644 --- a/leo_retriever/program_context/network_name/enum.NetworkName.html +++ b/leo_retriever/program_context/network_name/enum.NetworkName.html @@ -8,7 +8,7 @@ Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq for NetworkName

source§

fn eq(&self, other: &NetworkName) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for NetworkName

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where - __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&str> for NetworkName

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(network: &str) -> Result<Self, LeoError>

Performs the conversion.
source§

impl TryFrom<String> for NetworkName

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(network: String) -> Result<Self, LeoError>

Performs the conversion.
source§

impl Copy for NetworkName

source§

impl Eq for NetworkName

source§

impl StructuralPartialEq for NetworkName

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where + __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl TryFrom<&str> for NetworkName

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(network: &str) -> Result<Self, LeoError>

Performs the conversion.
source§

impl TryFrom<String> for NetworkName

§

type Error = LeoError

The type returned in the event of a conversion error.
source§

fn try_from(network: String) -> Result<Self, LeoError>

Performs the conversion.
source§

impl Copy for NetworkName

source§

impl Eq for NetworkName

source§

impl StructuralPartialEq for NetworkName

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where diff --git a/leo_retriever/program_context/struct.ProgramContext.html b/leo_retriever/program_context/struct.ProgramContext.html index 2c6845987c..0c775bb53a 100644 --- a/leo_retriever/program_context/struct.ProgramContext.html +++ b/leo_retriever/program_context/struct.ProgramContext.html @@ -1,20 +1,20 @@ ProgramContext in leo_retriever::program_context - Rust

Struct leo_retriever::program_context::ProgramContext

source ·
pub struct ProgramContext {
-    name: Symbol,
+    name: Symbol,
     full_name: String,
     location: Location,
     network: Option<NetworkName>,
     path: Option<PathBuf>,
     full_path: Option<PathBuf>,
     compiled_file_path: Option<PathBuf>,
-    dependencies: Option<Vec<Symbol>>,
+    dependencies: Option<Vec<Symbol>>,
     checksum: Option<String>,
     stub: Option<Stub>,
-    post_order: Option<IndexSet<Symbol>>,
-}

Fields§

§name: Symbol§full_name: String§location: Location§network: Option<NetworkName>§path: Option<PathBuf>§full_path: Option<PathBuf>§compiled_file_path: Option<PathBuf>§dependencies: Option<Vec<Symbol>>§checksum: Option<String>§stub: Option<Stub>§post_order: Option<IndexSet<Symbol>>

Implementations§

source§

impl ProgramContext

source

pub fn new_main( - name: Symbol, + post_order: Option<IndexSet<Symbol>>, +}

Fields§

§name: Symbol§full_name: String§location: Location§network: Option<NetworkName>§path: Option<PathBuf>§full_path: Option<PathBuf>§compiled_file_path: Option<PathBuf>§dependencies: Option<Vec<Symbol>>§checksum: Option<String>§stub: Option<Stub>§post_order: Option<IndexSet<Symbol>>

Implementations§

source§

impl ProgramContext

source

pub fn new_main( + name: Symbol, path: PathBuf, dependencies: Vec<Dependency>, -) -> Self

source

pub fn name(&self) -> &Symbol

source

pub fn full_name(&self) -> &String

source

pub fn network(&self) -> &NetworkName

source

pub fn location(&self) -> &Location

source

pub fn path(&self) -> &PathBuf

source

pub fn full_path(&self) -> &PathBuf

source

pub fn add_full_path(&mut self, full_path: &Path)

source

pub fn compiled_file_path(&self) -> &PathBuf

source

pub fn add_compiled_file_path(&mut self, path: &Path)

source

pub fn checksum(&self) -> &String

source

pub fn add_checksum(&mut self)

source

pub fn add_stub(&mut self, stub: Stub) -> bool

source

pub fn stub(&self) -> &Stub

source

pub fn dependencies(&self) -> Vec<Symbol>

source

pub fn add_dependencies(&mut self, dependencies: Vec<Symbol>)

source

pub fn post_order(&self) -> &IndexSet<Symbol>

source

pub fn add_post_order(&mut self, post_order: IndexSet<Symbol>)

Trait Implementations§

source§

impl Clone for ProgramContext

source§

fn clone(&self) -> ProgramContext

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ProgramContext

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<&ProgramContext> for LockFileEntry

source§

fn from(context: &ProgramContext) -> Self

Converts to this type from the input type.
source§

impl From<Dependency> for ProgramContext

source§

fn from(dependency: Dependency) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Self

source

pub fn name(&self) -> &Symbol

source

pub fn full_name(&self) -> &String

source

pub fn network(&self) -> &NetworkName

source

pub fn location(&self) -> &Location

source

pub fn path(&self) -> &PathBuf

source

pub fn full_path(&self) -> &PathBuf

source

pub fn add_full_path(&mut self, full_path: &Path)

source

pub fn compiled_file_path(&self) -> &PathBuf

source

pub fn add_compiled_file_path(&mut self, path: &Path)

source

pub fn checksum(&self) -> &String

source

pub fn add_checksum(&mut self)

source

pub fn add_stub(&mut self, stub: Stub) -> bool

source

pub fn stub(&self) -> &Stub

source

pub fn dependencies(&self) -> Vec<Symbol>

source

pub fn add_dependencies(&mut self, dependencies: Vec<Symbol>)

source

pub fn post_order(&self) -> &IndexSet<Symbol>

source

pub fn add_post_order(&mut self, post_order: IndexSet<Symbol>)

Trait Implementations§

source§

impl Clone for ProgramContext

source§

fn clone(&self) -> ProgramContext

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ProgramContext

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<&ProgramContext> for LockFileEntry

source§

fn from(context: &ProgramContext) -> Self

Converts to this type from the input type.
source§

impl From<Dependency> for ProgramContext

source§

fn from(dependency: Dependency) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where diff --git a/leo_retriever/retriever/fn.fetch_from_network.html b/leo_retriever/retriever/fn.fetch_from_network.html index 3baf1e7eb3..7c433fd32c 100644 --- a/leo_retriever/retriever/fn.fetch_from_network.html +++ b/leo_retriever/retriever/fn.fetch_from_network.html @@ -1 +1 @@ -fetch_from_network in leo_retriever::retriever - Rust

Function leo_retriever::retriever::fetch_from_network

source ·
pub fn fetch_from_network(url: &str) -> Result<String, UtilError>
\ No newline at end of file +fetch_from_network in leo_retriever::retriever - Rust

Function leo_retriever::retriever::fetch_from_network

source ·
pub fn fetch_from_network(url: &str) -> Result<String, UtilError>
\ No newline at end of file diff --git a/leo_retriever/retriever/fn.retrieve_from_network.html b/leo_retriever/retriever/fn.retrieve_from_network.html index 8d1a0e1458..f435bb9d98 100644 --- a/leo_retriever/retriever/fn.retrieve_from_network.html +++ b/leo_retriever/retriever/fn.retrieve_from_network.html @@ -3,4 +3,4 @@ home_path: &Path, name: &String, endpoint: &String, -) -> Result<(Stub, Vec<Dependency>), UtilError>

\ No newline at end of file +) -> Result<(Stub, Vec<Dependency>), UtilError>

\ No newline at end of file diff --git a/leo_retriever/retriever/fn.retrieve_local.html b/leo_retriever/retriever/fn.retrieve_local.html index 6b8fb6842c..3a2502f284 100644 --- a/leo_retriever/retriever/fn.retrieve_local.html +++ b/leo_retriever/retriever/fn.retrieve_local.html @@ -1,4 +1,4 @@ retrieve_local in leo_retriever::retriever - Rust

Function leo_retriever::retriever::retrieve_local

source ·
fn retrieve_local(
     name: &String,
     path: &PathBuf,
-) -> Result<Vec<Dependency>, UtilError>
\ No newline at end of file +) -> Result<Vec<Dependency>, UtilError>
\ No newline at end of file diff --git a/leo_retriever/retriever/fn.verify_valid_program.html b/leo_retriever/retriever/fn.verify_valid_program.html index 41586a88c7..6fd364274e 100644 --- a/leo_retriever/retriever/fn.verify_valid_program.html +++ b/leo_retriever/retriever/fn.verify_valid_program.html @@ -1,4 +1,4 @@ verify_valid_program in leo_retriever::retriever - Rust

Function leo_retriever::retriever::verify_valid_program

source ·
pub fn verify_valid_program<N: Network>(
     name: &str,
     program: &str,
-) -> Result<(), UtilError>
\ No newline at end of file +) -> Result<(), UtilError>
\ No newline at end of file diff --git a/leo_retriever/retriever/struct.Retriever.html b/leo_retriever/retriever/struct.Retriever.html index 362d8c5d0f..f7c40c4338 100644 --- a/leo_retriever/retriever/struct.Retriever.html +++ b/leo_retriever/retriever/struct.Retriever.html @@ -1,23 +1,23 @@ Retriever in leo_retriever::retriever - Rust

Struct leo_retriever::retriever::Retriever

source ·
pub struct Retriever<N: Network> {
-    name: Symbol,
-    contexts: IndexMap<Symbol, ProgramContext>,
+    name: Symbol,
+    contexts: IndexMap<Symbol, ProgramContext>,
     project_path: PathBuf,
     registry_path: PathBuf,
     endpoint: String,
     phantom: PhantomData<N>,
-}

Fields§

§name: Symbol§contexts: IndexMap<Symbol, ProgramContext>§project_path: PathBuf§registry_path: PathBuf§endpoint: String§phantom: PhantomData<N>

Implementations§

source§

impl<N: Network> Retriever<N>

source

pub fn new( - name: Symbol, +}

Fields§

§name: Symbol§contexts: IndexMap<Symbol, ProgramContext>§project_path: PathBuf§registry_path: PathBuf§endpoint: String§phantom: PhantomData<N>

Implementations§

source§

impl<N: Network> Retriever<N>

source

pub fn new( + name: Symbol, path: &PathBuf, home: &Path, endpoint: String, -) -> Result<Self, UtilError>

source

pub fn get_context(&self, name: &Symbol) -> &ProgramContext

source

pub fn retrieve(&mut self) -> Result<Vec<Symbol>, UtilError>

source

pub fn prepare_local( +) -> Result<Self, UtilError>

source

pub fn get_context(&self, name: &Symbol) -> &ProgramContext

source

pub fn retrieve(&mut self) -> Result<Vec<Symbol>, UtilError>

source

pub fn prepare_local( &mut self, - name: Symbol, -) -> Result<(PathBuf, IndexMap<Symbol, Stub>), UtilError>

source

pub fn process_local( + name: Symbol, +) -> Result<(PathBuf, IndexMap<Symbol, Stub>), UtilError>

source

pub fn process_local( &mut self, - name: Symbol, + name: Symbol, recursive: bool, -) -> Result<(), UtilError>

source

fn write_lock_file(&self, name: &Symbol) -> Result<(), UtilError>

Auto Trait Implementations§

§

impl<N> Freeze for Retriever<N>

§

impl<N> RefUnwindSafe for Retriever<N>
where +) -> Result<(), UtilError>

source

fn write_lock_file(&self, name: &Symbol) -> Result<(), UtilError>

Auto Trait Implementations§

§

impl<N> Freeze for Retriever<N>

§

impl<N> RefUnwindSafe for Retriever<N>
where N: RefUnwindSafe,

§

impl<N> Send for Retriever<N>

§

impl<N> Sync for Retriever<N>

§

impl<N> Unpin for Retriever<N>
where N: Unpin,

§

impl<N> UnwindSafe for Retriever<N>
where N: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where diff --git a/settings.html b/settings.html index 9473591eed..9b4a3d3e00 100644 --- a/settings.html +++ b/settings.html @@ -1 +1 @@ -Settings

Rustdoc settings

Back
\ No newline at end of file +Settings

Rustdoc settings

Back
\ No newline at end of file diff --git a/src/leo_ast/types/type_.rs.html b/src/leo_ast/types/type_.rs.html index e0d6f2a9a4..f182207c3d 100644 --- a/src/leo_ast/types/type_.rs.html +++ b/src/leo_ast/types/type_.rs.html @@ -387,7 +387,7 @@ match *self { Type::Address => write!(f, "address"), Type::Array(ref array_type) => write!(f, "{array_type}"), - Type::Boolean => write!(f, "boolean"), + Type::Boolean => write!(f, "bool"), Type::Field => write!(f, "field"), Type::Future(ref future_type) => write!(f, "{future_type}"), Type::Group => write!(f, "group"), diff --git a/src/leo_passes/code_generation/visit_expressions.rs.html b/src/leo_passes/code_generation/visit_expressions.rs.html index b8b88d8cc0..a58e3b8e9e 100644 --- a/src/leo_passes/code_generation/visit_expressions.rs.html +++ b/src/leo_passes/code_generation/visit_expressions.rs.html @@ -613,6 +613,8 @@ 613 614 615 +616 +617
// Copyright (C) 2019-2024 Aleo Systems Inc.
 // This file is part of the Leo library.
 
@@ -763,8 +765,10 @@
         // Increment the register counter.
         self.next_register += 1;
 
-        let cast_instruction =
-            format!("    cast {expression_operand} into {destination_register} as {};\n", input.type_);
+        let cast_instruction = format!(
+            "    cast {expression_operand} into {destination_register} as {};\n",
+            Self::visit_type(&input.type_)
+        );
 
         // Concatenate the instructions.
         instructions.push_str(&cast_instruction);
diff --git a/src/leo_passes/code_generation/visit_type.rs.html b/src/leo_passes/code_generation/visit_type.rs.html
index c850529804..5acf1ca3e7 100644
--- a/src/leo_passes/code_generation/visit_type.rs.html
+++ b/src/leo_passes/code_generation/visit_type.rs.html
@@ -70,6 +70,9 @@
 70
 71
 72
+73
+74
+75
 

// Copyright (C) 2019-2024 Aleo Systems Inc.
 // This file is part of the Leo library.
 
@@ -94,7 +97,6 @@
     pub(crate) fn visit_type(input: &Type) -> String {
         match input {
             Type::Address
-            | Type::Boolean
             | Type::Field
             | Type::Group
             | Type::Scalar
@@ -104,6 +106,10 @@
             | Type::Composite(..)
             | Type::Identifier(..)
             | Type::Integer(..) => format!("{input}"),
+            Type::Boolean => {
+                // Leo calls this just `bool`, which isn't what we need.
+                "boolean".into()
+            }
             Type::Array(array_type) => {
                 format!("[{}; {}u32]", Self::visit_type(array_type.element_type()), array_type.length())
             }
diff --git a/trait.impl/core/convert/trait.From.js b/trait.impl/core/convert/trait.From.js
index 767a2dc31c..e686fd15f7 100644
--- a/trait.impl/core/convert/trait.From.js
+++ b/trait.impl/core/convert/trait.From.js
@@ -2,5 +2,5 @@
 "leo_ast":[["impl From<&Value> for Type"],["impl From<&CompositeType> for Location"],["impl From<Value> for Type"],["impl From<usize> for NonNegativeNumber"],["impl From<String> for NonNegativeNumber"],["impl From<Identifier> for ProgramId"],["impl From<Function> for FunctionStub"],["impl From<FunctionStub> for Function"],["impl From<Stub> for ProgramScope"],["impl<N: Network> From<&Identifier<N>> for Identifier"],["impl<N: Network> From<&ProgramID<N>> for ProgramId"]],
 "leo_errors":[["impl From<AstError> for LeoError"],["impl From<CliError> for LeoError"],["impl From<CompilerError> for LeoError"],["impl From<FlattenError> for LeoError"],["impl From<LoopUnrollerError> for LeoError"],["impl From<PackageError> for LeoError"],["impl From<ParserError> for LeoError"],["impl From<ParserWarning> for LeoWarning"],["impl From<TypeCheckerError> for LeoError"],["impl From<TypeCheckerWarning> for LeoWarning"],["impl From<UtilError> for LeoError"],["impl From<Error> for LeoError"],["impl From<Backtraced> for AstError"],["impl From<Backtraced> for CliError"],["impl From<Backtraced> for CompilerError"],["impl From<Backtraced> for FlattenError"],["impl From<Backtraced> for LoopUnrollerError"],["impl From<Backtraced> for PackageError"],["impl From<Backtraced> for ParserError"],["impl From<Backtraced> for ParserWarning"],["impl From<Backtraced> for TypeCheckerError"],["impl From<Backtraced> for TypeCheckerWarning"],["impl From<Backtraced> for UtilError"],["impl From<Formatted> for AstError"],["impl From<Formatted> for CliError"],["impl From<Formatted> for CompilerError"],["impl From<Formatted> for FlattenError"],["impl From<Formatted> for LoopUnrollerError"],["impl From<Formatted> for PackageError"],["impl From<Formatted> for ParserError"],["impl From<Formatted> for ParserWarning"],["impl From<Formatted> for TypeCheckerError"],["impl From<Formatted> for TypeCheckerWarning"],["impl From<Formatted> for UtilError"]],
 "leo_lang":[["impl From<BuildOptions> for CompilerOptions"]],
-"leo_retriever":[["impl From<&Dependency> for Symbol"],["impl From<&ProgramContext> for LockFileEntry"],["impl From<Dependency> for ProgramContext"]]
+"leo_retriever":[["impl From<&Dependency> for Symbol"],["impl From<&ProgramContext> for LockFileEntry"],["impl From<Dependency> for ProgramContext"]]
 };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})()
\ No newline at end of file