Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.

Remove impl_outer_ macros - #9307

Merged
2 commits merged into
masterfrom
gui-remove-impl_outer
Jul 12, 2021
Merged

2 commits merged into
masterfrom
gui-remove-impl_outer

Conversation

@gui1117

@gui1117 gui1117 commented Jul 8, 2021

Copy link
Copy Markdown
Contributor

Those macro are no longer used, people should rather use construct_runtime, it is some code debt when implementing new functionality in substrate (e.g. metadata changes).

@gui1117 gui1117 added A3-in_progress Pull request is in progress. No review needed at this stage. B3-apinoteworthy C1-low PR touches the given topic and has a low impact on builders. D2-notlive 💤 PR contains changes in a runtime directory that is not deployed to a chain that requires an audit. labels Jul 8, 2021
@github-actions github-actions Bot added A0-please_review Pull request needs code review. and removed A3-in_progress Pull request is in progress. No review needed at this stage. labels Jul 8, 2021
);

assert_eq!(Runtime::ensure_inherents_are_first(&block).err().unwrap(), 2);
}

@gui1117 gui1117 Jul 8, 2021 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: those tests are in frame/support/test/tests/pallets.rs

origin_without_generic::Origin
);
assert_eq!(without_generic_variant.encode()[0], 1);
}

@gui1117 gui1117 Jul 8, 2021 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

origin tests are in frame/support/test/tests/construct_runtime.rs

}

#[test]
fn test_codec() {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

codec test is in frame/support/test/tests/construct_runtime.rs

fn get_module_names() {
let module_names = OuterCall::get_module_names();
assert_eq!(["Test"], module_names);
}

@gui1117 gui1117 Jul 8, 2021 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

those tests are in frame/support/test/tests/construct_runtime.rs

@gui1117 gui1117 added A3-in_progress Pull request is in progress. No review needed at this stage. and removed A0-please_review Pull request needs code review. labels Jul 8, 2021
@gui1117
gui1117 force-pushed the gui-remove-impl_outer branch from 1614d0d to a26531c Compare July 8, 2021 11:09
Comment thread frame/support/src/lib.rs
#[doc(hidden)]
pub use crate::sp_runtime::transaction_validity::{
TransactionValidity, UnknownTransaction, TransactionValidityError, TransactionSource,
};

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all those reexport were already hidden, some are used by construct_runtime, some are used by some pallet.

@gui1117 gui1117 added A0-please_review Pull request needs code review. and removed A3-in_progress Pull request is in progress. No review needed at this stage. labels Jul 8, 2021
@gui1117 gui1117 mentioned this pull request Jul 8, 2021
16 of 19 tasks
@gui1117

gui1117 commented Jul 12, 2021

Copy link
Copy Markdown
Contributor Author

farewell macro rules

@gui1117

gui1117 commented Jul 12, 2021

Copy link
Copy Markdown
Contributor Author

bot merge

@ghost

ghost commented Jul 12, 2021

Copy link
Copy Markdown

Trying merge.

@ghost
ghost merged commit 6be513d into master Jul 12, 2021
@ghost
ghost deleted the gui-remove-impl_outer branch July 12, 2021 08:50
This pull request was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

A0-please_review Pull request needs code review. C1-low PR touches the given topic and has a low impact on builders. D2-notlive 💤 PR contains changes in a runtime directory that is not deployed to a chain that requires an audit.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants