diff options
Diffstat (limited to 'font/src/ft/fc/char_set.rs')
-rw-r--r-- | font/src/ft/fc/char_set.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/font/src/ft/fc/char_set.rs b/font/src/ft/fc/char_set.rs index e6fe027a..151d14a3 100644 --- a/font/src/ft/fc/char_set.rs +++ b/font/src/ft/fc/char_set.rs @@ -24,7 +24,13 @@ foreign_type! { } impl CharSet { - pub fn new() -> CharSet { + pub fn new() -> Self { + Self::default() + } +} + +impl Default for CharSet { + fn default() -> Self { CharSet(unsafe { FcCharSetCreate() }) } } |