-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
simplify init and post upgrade mod and build files
- Loading branch information
Showing
7 changed files
with
81 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
kybra/compiler/kybra_generate/src/canister_method/init_method/mod.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
pub mod build; | ||
mod rust; | ||
pub mod rust; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 0 additions & 15 deletions
15
kybra/compiler/kybra_generate/src/canister_method/post_upgrade_method/mod.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,2 @@ | ||
use proc_macro2::TokenStream; | ||
use quote::quote; | ||
use rustpython_parser::ast::{Located, StmtKind}; | ||
|
||
use crate::{source_map::SourceMapped, Error}; | ||
|
||
pub mod build; | ||
pub mod rust; | ||
|
||
pub fn generate_call( | ||
function_def_option: &Option<&SourceMapped<&Located<StmtKind>>>, | ||
) -> Result<TokenStream, Vec<Error>> { | ||
match &function_def_option { | ||
Some(function_def) => function_def.generate_call_to_py_function(), | ||
None => Ok(quote!()), | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters