Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 1 addition & 15 deletions apollo-router/src/plugin/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -793,21 +793,7 @@ macro_rules! register_plugin {
};
};

($group: literal, $name: literal, $plugin_type: ident) => {
// Artificial scope to avoid naming collisions
const _: () = {
use $crate::_private::once_cell::sync::Lazy;
use $crate::_private::PluginFactory;
use $crate::_private::PLUGINS;

#[$crate::_private::linkme::distributed_slice(PLUGINS)]
#[linkme(crate = $crate::_private::linkme)]
static REGISTER_PLUGIN: Lazy<PluginFactory> =
Lazy::new(|| $crate::plugin::PluginFactory::new::<$plugin_type>($group, $name));
};
};

($group: literal, $name: ident, $plugin_type: ident) => {
($group: literal, $name: expr, $plugin_type: ident) => {
// Artificial scope to avoid naming collisions
const _: () = {
use $crate::_private::once_cell::sync::Lazy;
Expand Down