Skip to content

Commit 6517a72

Browse files
committed
Fix make check error when add native simulator
1 parent 0c25da1 commit 6517a72

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

native-simulator/src/contract-lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#![cfg_attr(not(feature = "simulator"), no_std)]
22
#![allow(special_module_name)]
3+
#![allow(unused_attributes)]
34
#[cfg(feature = "simulator")]
45
mod main;
56
#[cfg(feature = "simulator")]

workspace/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,6 @@ generate-native-simulator:
149149
fi; \
150150
FILE=contracts/$(CRATE)/src/main.rs; \
151151
sed -i 's/#!\[no_std\]/#!\[cfg_attr(not(feature = "simulator"), no_std)\]/' $$FILE; \
152-
sed -i 's/#!\[cfg_attr(not(test), no_main)\]/#!\[cfg_attr(not(any(feature = "simulator", test)), no_main)\]/' $$FILE; \
153152
sed -i 's/#\[cfg(test)\]/#\[cfg(any(feature = "simulator", test))\]/' $$FILE; \
154153
sed -i 's/#\[cfg(not(test))\]/#\[cfg(not(any(feature = "simulator", test)))\]/' $$FILE; \
155154
sed '/@@INSERTION_POINT@@/s/$$/\n "native-simulators\/$(CRATE)-sim",/' Cargo.toml > Cargo.toml.new; \

0 commit comments

Comments
 (0)