swarm-derive/: Make event_process = false the default (#2214)

Co-authored-by: Max Inden <mail@max-inden.de>
This commit is contained in:
Thomas Eizinger
2021-09-14 23:28:08 +10:00
committed by GitHub
parent b79fd02f0b
commit e83e1b3d0b
10 changed files with 72 additions and 39 deletions

View File

@ -71,7 +71,7 @@ fn build_struct(ast: &DeriveInput, data_struct: &DataStruct) -> TokenStream {
// Whether or not we require the `NetworkBehaviourEventProcess` trait to be implemented.
let event_process = {
let mut event_process = true; // Default to true for backwards compatibility
let mut event_process = false;
for meta_items in ast.attrs.iter().filter_map(get_meta_items) {
for meta_item in meta_items {