mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-12-26 11:45:00 +03:00
Remove occurences of 'call_type'
This commit is contained in:
parent
4e8cd3ce52
commit
b5c22e23ee
@ -77,7 +77,7 @@ impl Function {
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
pub fn new(
|
||||
annotations: Vec<Annotation>,
|
||||
call_type: Variant,
|
||||
variant: Variant,
|
||||
identifier: Identifier,
|
||||
input: Vec<Input>,
|
||||
output: Vec<Output>,
|
||||
@ -99,7 +99,7 @@ impl Function {
|
||||
|
||||
Function {
|
||||
annotations,
|
||||
variant: call_type,
|
||||
variant,
|
||||
identifier,
|
||||
input,
|
||||
output,
|
||||
|
@ -36,7 +36,7 @@ pub struct FunctionSymbol {
|
||||
/// The output type of the function.
|
||||
pub(crate) output_type: Type,
|
||||
/// Is this function a transition, inlined, or a regular function?.
|
||||
pub call_type: Variant,
|
||||
pub variant: Variant,
|
||||
/// The `Span` associated with the function.
|
||||
pub(crate) _span: Span,
|
||||
/// The inputs to the function.
|
||||
@ -50,7 +50,7 @@ impl SymbolTable {
|
||||
FunctionSymbol {
|
||||
id,
|
||||
output_type: func.output_type.clone(),
|
||||
call_type: func.variant,
|
||||
variant: func.variant,
|
||||
_span: func.span,
|
||||
input: func.input.clone(),
|
||||
finalize: func.finalize.as_ref().map(|finalize| FinalizeData {
|
||||
|
@ -454,7 +454,7 @@ impl<'a> ExpressionVisitor<'a> for TypeChecker<'a> {
|
||||
}
|
||||
// If the function is a transition function, then check that the call is not to another local transition function.
|
||||
true => {
|
||||
if matches!(func.call_type, Variant::Transition) && input.external.is_none() {
|
||||
if matches!(func.variant, Variant::Transition) && input.external.is_none() {
|
||||
self.emit_err(TypeCheckerError::cannot_invoke_call_to_local_transition_function(
|
||||
input.span,
|
||||
));
|
||||
|
Loading…
Reference in New Issue
Block a user