aboutsummaryrefslogtreecommitdiff
path: root/src/os/signal.h
diff options
context:
space:
mode:
authorFelipe Oliveira Carvalho <felipekde@gmail.com>2014-04-05 23:37:39 -0300
committerThiago de Arruda <tpadilha84@gmail.com>2014-04-07 00:22:01 -0300
commit967fb1aca6ea9c3d3046ccd6b9fcf0f88d6999ac (patch)
tree886a553c1f5ea139fec7600803562aa11edcfe2a /src/os/signal.h
parentfac85c17248ab8c371fb311c1dd4bc1b2a7520cf (diff)
downloadrneovim-967fb1aca6ea9c3d3046ccd6b9fcf0f88d6999ac.tar.gz
rneovim-967fb1aca6ea9c3d3046ccd6b9fcf0f88d6999ac.tar.bz2
rneovim-967fb1aca6ea9c3d3046ccd6b9fcf0f88d6999ac.zip
Reimplement the event queue in event.c using klist.h
- Add a new macro to klist.h: kl_empty() The whole point of abstract data structures is to avoid reimplementing common actions. The emptiness test seems to be such an action. - Add a new function attribute to func_attr.h: FUNC_ATTR_UNUSED Some of the many functions created by the macros in klist.h may end up not being used. Unused functions cause compilation errors as we compile with -Werror. To mark those functions as possibly unused we can use the FUNC_ATTR_UNUSED now. - Pass `Event` by value `Event` is such a small struct that I don't think we should allocate heap space and pass it by reference. Let's use the stack and memory cache in our favor passing it by value.
Diffstat (limited to 'src/os/signal.h')
-rw-r--r--src/os/signal.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/os/signal.h b/src/os/signal.h
index a5247742db..4507bea26b 100644
--- a/src/os/signal.h
+++ b/src/os/signal.h
@@ -7,7 +7,7 @@ void signal_init(void);
void signal_stop(void);
void signal_accept_deadly(void);
void signal_reject_deadly(void);
-void signal_handle(Event *event);
+void signal_handle(Event event);
#endif