Commit Graph

13 Commits

Author SHA1 Message Date
Thomas Haller
bcce368e55
clang-format: mark FOR_EACH_DELAYED_ACTION() as a ForEachMacro 2022-01-13 15:25:17 +01:00
Thomas Haller
9c99c948fd
platform: add nmp_cache_iter_for_each_reverse() helper 2021-08-17 19:56:38 +02:00
Thomas Haller
4e109bacab
clang-format: use "IndentPPDirectives:None" instead of "BeforeHash"
Subjectively, I think this looks better.
2021-07-09 08:49:06 +02:00
Thomas Haller
75a64dd199
core: add nm_l3_config_data_iter_ip_{address,route}_for_each() helpers 2021-05-18 09:41:55 +02:00
Thomas Haller
757443d0c5
core: add nm_ip_config_iter_ip_address_for_each() macro 2020-11-24 08:52:59 +01:00
Beniamino Galvani
dc6ec6ce7b core: reverse the order of active connections in the manager
When a new active connection is created, it gets added at the
beginning of manager's list. This means that the list contains most
recently activated connections first. Since the list is doubly-linked,
it is possible to efficiently iterate in both directions, so the order
of the list is mostly a matter of convention.

I think it is preferable to have oldest active connections at the
beginning of the list; let's reverse the order.

In most places where the list is iterated, the order doesn't
matter. Where it does, use the *_prev() variant to maintain the old
iteration order.
2020-11-16 16:43:39 +01:00
Beniamino Galvani
dfd2fcde0f shared: add c-list macros to iterate backwards 2020-11-16 16:43:39 +01:00
Thomas Haller
7d5ec103df
format: mark json_{object,array}_foreach() macors as ForEachMacros for clang-format 2020-11-09 17:53:15 +01:00
Thomas Haller
6807774b7d
clang-format: mark "nm_platform_iter_obj_for_each()"/"nm_l3_config_data_iter_*()" as ForEachMacros 2020-10-13 12:56:25 +02:00
Antonio Cardace
76bb1f91a5
clang-format: add clang-format proposed code-style file
Signed-off-by: Antonio Cardace <acardace@redhat.com>
2020-09-28 15:08:41 +02:00
Antonio Cardace
41147c4d17
clang-format: proposed style 2020-09-23 09:07:10 +02:00
Thomas Haller
0d65b24b93
format: some adjustments to the style and mark ForEachMacros
"ForEachMacros" requires us to maintain a list of for each macros.
However, that seems doable, as we only seldom add such macros.
2020-07-10 10:59:36 +02:00
Antonio Cardace
8a5e664e5d
format: add .clang-format file to source tree 2020-07-09 18:07:16 +02:00