Skip to content

Commit

Permalink
Simplify define_resource_id
Browse files Browse the repository at this point in the history
  • Loading branch information
nox committed Nov 16, 2018
1 parent 1c89ac9 commit 3f8a3b2
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions components/canvas_traits/webgl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ pub enum WebGLCommand {
},
}

macro_rules! define_resource_id_struct {
macro_rules! define_resource_id {
($name:ident) => {
#[derive(Clone, Copy, Eq, Hash, PartialEq)]
pub struct $name(NonZeroU32);
Expand All @@ -384,12 +384,6 @@ macro_rules! define_resource_id_struct {
self.0.get()
}
}
};
}

macro_rules! define_resource_id {
($name:ident) => {
define_resource_id_struct!($name);

#[allow(unsafe_code)]
impl<'de> ::serde::Deserialize<'de> for $name {
Expand Down

0 comments on commit 3f8a3b2

Please sign in to comment.