From 17b6982f49db5441d48878bb3c43ca5bae93811c Mon Sep 17 00:00:00 2001 From: Ben Frankel Date: Sun, 28 Jun 2020 14:23:23 -0700 Subject: [PATCH] Allow trailing comma in vertex_attr_array! --- src/macros.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/macros.rs b/src/macros.rs index 3cf649ed1..17bb4e8fd 100644 --- a/src/macros.rs +++ b/src/macros.rs @@ -12,7 +12,7 @@ /// Offsets are calculated automatically. #[macro_export] macro_rules! vertex_attr_array { - ($($loc:expr => $fmt:ident),*) => { + ($($loc:expr => $fmt:ident),* $(,)?) => { $crate::vertex_attr_array!([] ; 0; $($loc => $fmt ,)*) }; ([$($t:expr,)*] ; $off:expr ;) => { [$($t,)*] };