[librsvg/wip/css-crate] repr(C) the enums created by the make_property macro



commit b03526aa41d3e479ef839ae769e30e6c3ac4296d
Author: Federico Mena Quintero <federico gnome org>
Date:   Mon Jan 13 19:13:50 2020 -0600

    repr(C) the enums created by the make_property macro
    
    This is so they can be exported to C code in gnome-shell.

 rsvg_internals/src/property_macros.rs | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/rsvg_internals/src/property_macros.rs b/rsvg_internals/src/property_macros.rs
index 99149e86..b8e09372 100644
--- a/rsvg_internals/src/property_macros.rs
+++ b/rsvg_internals/src/property_macros.rs
@@ -38,6 +38,7 @@ macro_rules! make_property {
      $($str_prop: expr => $variant: ident,)+
     ) => {
         #[derive(Debug, Copy, Clone, PartialEq)]
+        #[repr(C)]
         pub enum $name {
             $($variant),+
         }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]