]> git.lizzy.rs Git - linenoise.git/blobdiff - example.c
Clear some warnings and errors with GCC and MSVC.
[linenoise.git] / example.c
index 971ac31def48e6ba975537360217f32cf795626b..ea3a9937e1acc9418009ff3323497bc5eaecc0ca 100644 (file)
--- a/example.c
+++ b/example.c
@@ -5,6 +5,7 @@
 
 #ifndef NO_COMPLETION
 void completion(const char *buf, linenoiseCompletions *lc, void *userdata) {
+    (void)userdata;
     if (buf[0] == 'h') {
         linenoiseAddCompletion(lc,"hello");
         linenoiseAddCompletion(lc,"hello there");
@@ -12,6 +13,7 @@ void completion(const char *buf, linenoiseCompletions *lc, void *userdata) {
 }
 
 char *hints(const char *buf, int *color, int *bold, void *userdata) {
+    (void)userdata;
     if (!strcasecmp(buf,"hello")) {
         *color = 35;
         *bold = 0;