Systemd/src/locale
Lennart Poettering ae2a15bc14 macro: introduce TAKE_PTR() macro
This macro will read a pointer of any type, return it, and set the
pointer to NULL. This is useful as an explicit concept of passing
ownership of a memory area between pointers.

This takes inspiration from Rust:

https://doc.rust-lang.org/std/option/enum.Option.html#method.take

and was suggested by Alan Jenkins (@sourcejedi).

It drops ~160 lines of code from our codebase, which makes me like it.
Also, I think it clarifies passing of ownership, and thus helps
readability a bit (at least for the initiated who know the new macro)
2018-03-22 20:21:42 +01:00
..
kbd-model-map kbd-model-map: add more mappings for Slovak, Lithuanian, and Khmer 2015-01-22 01:14:54 -05:00
keymap-util.c macro: introduce TAKE_PTR() macro 2018-03-22 20:21:42 +01:00
keymap-util.h Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00
language-fallback-map locale: Language fallbacks for fr_(BE|CA|CH|LU) to fr_FR (#3178) 2016-05-02 19:43:37 -04:00
localectl.c bus-util: make bus_map_all_properties() not copy string 2018-03-20 00:42:48 +09:00
localed.c tree-wide: make name requesting asynchronous in all our services 2018-01-05 13:58:32 +01:00
meson.build meson: drop unnecessary "transformation" of policy files 2018-02-16 13:01:12 +01:00
org.freedesktop.locale1.conf Add SPDX license headers to various assorted files 2017-11-19 19:08:15 +01:00
org.freedesktop.locale1.policy meson: drop unnecessary "transformation" of policy files 2018-02-16 13:01:12 +01:00
org.freedesktop.locale1.service Add SPDX license headers to various assorted files 2017-11-19 19:08:15 +01:00
test-keymap-util.c Add SPDX license identifiers to source files under the LGPL 2017-11-19 19:08:15 +01:00