-
Notifications
You must be signed in to change notification settings - Fork 188
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix selector functions for models and contracts (#2156)
- Loading branch information
Showing
87 changed files
with
1,763 additions
and
1,052 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 |
---|---|---|
@@ -1,15 +1,10 @@ | ||
#[starknet::interface] | ||
trait IContract<T> { | ||
fn contract_name(self: @T) -> ByteArray; | ||
fn selector(self: @T) -> felt252; | ||
|
||
/// Returns the namespace of a contract. | ||
fn namespace(self: @T) -> ByteArray; | ||
|
||
// Returns the namespace selector built from its name. | ||
/// namespace_selector = hash(namespace_name) | ||
fn namespace_selector(self: @T) -> felt252; | ||
|
||
// Returns the contract tag | ||
fn tag(self: @T) -> ByteArray; | ||
|
||
fn name_hash(self: @T) -> felt252; | ||
fn namespace_hash(self: @T) -> felt252; | ||
fn selector(self: @T) -> felt252; | ||
} |
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
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
4 changes: 2 additions & 2 deletions
4
crates/dojo-lang/src/manifest_test_data/compiler_cairo/manifests/dev/base/dojo-world.toml
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,6 +1,6 @@ | ||
kind = "Class" | ||
class_hash = "0x21341ba6e0d96f909f15c4ed865188afc716563d34593fb443d56cb97ff7b92" | ||
original_class_hash = "0x21341ba6e0d96f909f15c4ed865188afc716563d34593fb443d56cb97ff7b92" | ||
class_hash = "0x210dd8e484e5555dc74a4a600b17878fc108911719b04139309acc874160c51" | ||
original_class_hash = "0x210dd8e484e5555dc74a4a600b17878fc108911719b04139309acc874160c51" | ||
abi = "manifests/dev/base/abis/dojo-world.json" | ||
tag = "dojo-world" | ||
manifest_name = "dojo-world" |
Oops, something went wrong.