modules: update documentation examples so they compile under ccanlint.
[ccan] / ccan / build_assert / build_assert.h
index 4b0d75e4bf29ade83fe741440d56532e3c8ffdfe..c6ee362f2299933160a552484434f911c713a290 100644 (file)
@@ -9,7 +9,9 @@
  * by the compiler.  This can only be used within a function.
  *
  * Example:
- *     char *foo_to_char(struct foo *foo)
+ *     #include <stddef.h>
+ *     ...
+ *     static char *foo_to_char(struct foo *foo)
  *     {
  *             // This code needs string to be at start of foo.
  *             BUILD_ASSERT(offsetof(struct foo, string) == 0);