summaryrefslogtreecommitdiff
path: root/doc/developer
diff options
context:
space:
mode:
Diffstat (limited to 'doc/developer')
-rw-r--r--doc/developer/hooks.rst10
-rw-r--r--doc/developer/lists.rst10
-rw-r--r--doc/developer/memtypes.rst10
-rw-r--r--doc/developer/modules.rst2
4 files changed, 16 insertions, 16 deletions
diff --git a/doc/developer/hooks.rst b/doc/developer/hooks.rst
index 10fe6b9c43..b37a4aeea7 100644
--- a/doc/developer/hooks.rst
+++ b/doc/developer/hooks.rst
@@ -15,13 +15,13 @@ Example:
:caption: mydaemon.h
#include "hook.h"
- DECLARE_HOOK(some_update_event, (struct eventinfo *info), (info))
+ DECLARE_HOOK(some_update_event, (struct eventinfo *info), (info));
.. code-block:: c
:caption: mydaemon.c
#include "mydaemon.h"
- DEFINE_HOOK(some_update_event, (struct eventinfo *info), (info))
+ DEFINE_HOOK(some_update_event, (struct eventinfo *info), (info));
...
hook_call(some_update_event, info);
@@ -110,9 +110,9 @@ Definition
.. code-block:: c
- DECLARE_HOOK(foo, (), ())
- DECLARE_HOOK(bar, (int arg), (arg))
- DECLARE_HOOK(baz, (const void *x, in_addr_t y), (x, y))
+ DECLARE_HOOK(foo, (), ());
+ DECLARE_HOOK(bar, (int arg), (arg));
+ DECLARE_HOOK(baz, (const void *x, in_addr_t y), (x, y));
.. c:macro:: DEFINE_HOOK(name, arglist, passlist)
diff --git a/doc/developer/lists.rst b/doc/developer/lists.rst
index 28b21533c0..86db788c0e 100644
--- a/doc/developer/lists.rst
+++ b/doc/developer/lists.rst
@@ -140,7 +140,7 @@ The common setup pattern will look like this:
#include <typesafe.h>
- PREDECL_XXX(Z)
+ PREDECL_XXX(Z);
struct item {
int otherdata;
struct Z_item mylistitem;
@@ -149,20 +149,20 @@ The common setup pattern will look like this:
struct Z_head mylisthead;
/* unsorted: */
- DECLARE_XXX(Z, struct item, mylistitem)
+ DECLARE_XXX(Z, struct item, mylistitem);
/* sorted, items that compare as equal cannot be added to list */
int compare_func(const struct item *a, const struct item *b);
- DECLARE_XXX_UNIQ(Z, struct item, mylistitem, compare_func)
+ DECLARE_XXX_UNIQ(Z, struct item, mylistitem, compare_func);
/* sorted, items that compare as equal can be added to list */
int compare_func(const struct item *a, const struct item *b);
- DECLARE_XXX_NONUNIQ(Z, struct item, mylistitem, compare_func)
+ DECLARE_XXX_NONUNIQ(Z, struct item, mylistitem, compare_func);
/* hash tables: */
int compare_func(const struct item *a, const struct item *b);
uint32_t hash_func(const struct item *a);
- DECLARE_XXX(Z, struct item, mylistitem, compare_func, hash_func)
+ DECLARE_XXX(Z, struct item, mylistitem, compare_func, hash_func);
``XXX`` is replaced with the name of the data structure, e.g. ``SKIPLIST``
or ``ATOMLIST``. The ``DECLARE_XXX`` invocation can either occur in a `.h`
diff --git a/doc/developer/memtypes.rst b/doc/developer/memtypes.rst
index 952b316ea0..08dad7fb68 100644
--- a/doc/developer/memtypes.rst
+++ b/doc/developer/memtypes.rst
@@ -15,15 +15,15 @@ Example:
.. code-block:: c
:caption: mydaemon.h
- DECLARE_MGROUP(MYDAEMON)
- DECLARE_MTYPE(MYNEIGHBOR)
+ DECLARE_MGROUP(MYDAEMON);
+ DECLARE_MTYPE(MYNEIGHBOR);
.. code-block:: c
:caption: mydaemon.c
- DEFINE_MGROUP( MYDAEMON, "My daemon's memory")
- DEFINE_MTYPE( MYDAEMON, MYNEIGHBOR, "Neighbor entry")
- DEFINE_MTYPE_STATIC(MYDAEMON, MYNEIGHBORNAME, "Neighbor name")
+ DEFINE_MGROUP( MYDAEMON, "My daemon's memory");
+ DEFINE_MTYPE( MYDAEMON, MYNEIGHBOR, "Neighbor entry");
+ DEFINE_MTYPE_STATIC(MYDAEMON, MYNEIGHBORNAME, "Neighbor name");
struct neigh *neighbor_new(const char *name)
{
diff --git a/doc/developer/modules.rst b/doc/developer/modules.rst
index 02330ddfe4..e95f8a1b4a 100644
--- a/doc/developer/modules.rst
+++ b/doc/developer/modules.rst
@@ -76,7 +76,7 @@ Basic boilerplate:
.version = "0.0",
.description = "my module",
.init = module_init,
- )
+ );
The ``frr_late_init`` hook will be called after the daemon has finished
its other startup and is about to enter the main event loop; this is the