-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #348 from 0xPolygonMiden/greenhat/i314-note-script…
…-compilation [3/x] Add note script compilation test
- Loading branch information
Showing
33 changed files
with
4,458 additions
and
2,123 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -64,12 +64,11 @@ fn inline( | |
|
||
#[cfg(test)] | ||
mod tests { | ||
use miden_core::crypto::hash::RpoDigest; | ||
use midenc_hir::{FunctionType, Ident, InterfaceFunctionIdent, InterfaceIdent, Symbol}; | ||
use midenc_hir_type::Type; | ||
|
||
use super::*; | ||
use crate::{component::StaticModuleIndex, config::ImportMetadata, test_utils::test_context}; | ||
use crate::{component::StaticModuleIndex, test_utils::test_context}; | ||
|
||
#[test] | ||
fn translate_simple() { | ||
|
@@ -182,19 +181,8 @@ mod tests { | |
interface: InterfaceIdent::from_full_ident("miden:add/[email protected]"), | ||
function: Symbol::intern("add"), | ||
}; | ||
let import_metadata = [( | ||
interface_function_ident, | ||
ImportMetadata { | ||
digest: RpoDigest::default(), | ||
}, | ||
)] | ||
.into_iter() | ||
.collect(); | ||
|
||
let config = WasmTranslationConfig { | ||
import_metadata, | ||
..Default::default() | ||
}; | ||
let config = WasmTranslationConfig::default(); | ||
let (mut component_types_builder, parsed_component) = | ||
parse(&config, &wasm, &context.session).unwrap(); | ||
let component_translation = | ||
|
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
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
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 |
---|---|---|
|
@@ -3,6 +3,8 @@ use alloc::vec::Vec; | |
|
||
use miden_stdlib_sys::Felt; | ||
|
||
use super::CoreAsset; | ||
|
||
#[link(wasm_import_module = "miden:core-import/[email protected]")] | ||
extern "C" { | ||
#[link_name = "get-inputs"] | ||
|
@@ -39,3 +41,7 @@ pub fn get_inputs() -> Vec<Felt> { | |
} | ||
inputs | ||
} | ||
|
||
pub fn get_assets() -> Vec<CoreAsset> { | ||
todo!() | ||
} |
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
Oops, something went wrong.