Remove pub in macros (#1027)

* use :vis in macro_rules!

* use :vis in meta
This commit is contained in:
guanqun authored and Bastian Köcher committed 2018-10-27 12:15:15 +02:00
1 parent 55e53a9898
commit c0f7021427
2 files changed
+110 -908

No files matched your search

@@ -196,13 +196,9 @@ impl<D: NativeExecutionDispatch> CodeExecutor<Blake2Hasher> for NativeExecutor<D
#[macro_export]
macro_rules! native_executor_instance {
(pub $name:ident, $dispatcher:path, $version:path, $code:expr) => {
pub struct $name;
native_executor_instance!(IMPL $name, $dispatcher, $version, $code);
};
($name:ident, $dispatcher:path, $version:path, $code:expr) => {
( $pub:vis $name:ident, $dispatcher:path, $version:path, $code:expr) => {
/// A unit struct which implements `NativeExecutionDispatch` feeding in the hard-coded runtime.
struct $name;
$pub struct $name;
native_executor_instance!(IMPL $name, $dispatcher, $version, $code);
};
(IMPL $name:ident, $dispatcher:path, $version:path, $code:expr) => {