diff options
author | Antonio Borneo <borneo.antonio@gmail.com> | 2010-06-19 23:34:05 +0800 |
---|---|---|
committer | Antonio Borneo <borneo.antonio@gmail.com> | 2010-06-21 22:14:08 +0800 |
commit | ec073e89435785375dece2fb7c4664002c22859c (patch) | |
tree | b200207fd406be8758dd7f45d0672f1fdae54b47 /src/helper | |
parent | 2fbb0b5972b04e10090e39137817e9f359fb6105 (diff) | |
download | openocd+libswd-ec073e89435785375dece2fb7c4664002c22859c.tar.gz openocd+libswd-ec073e89435785375dece2fb7c4664002c22859c.tar.bz2 openocd+libswd-ec073e89435785375dece2fb7c4664002c22859c.tar.xz openocd+libswd-ec073e89435785375dece2fb7c4664002c22859c.zip |
helper/jim-eventloop: review scope of symbols
Add "static" qualifier to private functions.
Remove private prototypes from include file.
Remove empty definition of JIM_STATIC.
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Diffstat (limited to 'src/helper')
-rw-r--r-- | src/helper/jim-eventloop.c | 14 | ||||
-rw-r--r-- | src/helper/jim-eventloop.h | 17 |
2 files changed, 9 insertions, 22 deletions
diff --git a/src/helper/jim-eventloop.c b/src/helper/jim-eventloop.c index fae46e89..23115fe6 100644 --- a/src/helper/jim-eventloop.c +++ b/src/helper/jim-eventloop.c @@ -90,7 +90,7 @@ typedef struct Jim_EventLoop { Jim_TimeEvent *timeEventHead; } Jim_EventLoop; -void Jim_CreateFileHandler(Jim_Interp *interp, void *handle, int mask, +static void Jim_CreateFileHandler(Jim_Interp *interp, void *handle, int mask, Jim_FileProc *proc, void *clientData, Jim_EventFinalizerProc *finalizerProc) { @@ -109,7 +109,7 @@ void Jim_CreateFileHandler(Jim_Interp *interp, void *handle, int mask, // fprintf(stderr,"raus\n"); } -void Jim_DeleteFileHandler(Jim_Interp *interp, void *handle) +static void Jim_DeleteFileHandler(Jim_Interp *interp, void *handle) { Jim_FileEvent *fe, *prev = NULL; Jim_EventLoop *eventLoop = Jim_GetAssocData(interp, "eventloop"); @@ -152,7 +152,7 @@ static void JimGetTime(long *seconds, long *milliseconds) *milliseconds = tv.tv_usec/1000; } -jim_wide Jim_CreateTimeHandler(Jim_Interp *interp, jim_wide milliseconds, +static jim_wide Jim_CreateTimeHandler(Jim_Interp *interp, jim_wide milliseconds, Jim_TimeProc *proc, void *clientData, Jim_EventFinalizerProc *finalizerProc) { @@ -181,7 +181,7 @@ jim_wide Jim_CreateTimeHandler(Jim_Interp *interp, jim_wide milliseconds, return id; } -jim_wide Jim_DeleteTimeHandler(Jim_Interp *interp, jim_wide id) +static jim_wide Jim_DeleteTimeHandler(Jim_Interp *interp, jim_wide id) { Jim_TimeEvent *te, *prev = NULL; Jim_EventLoop *eventLoop = Jim_GetAssocData(interp, "eventloop"); @@ -391,7 +391,7 @@ int Jim_ProcessEvents(Jim_Interp *interp, int flags) } /* ---------------------------------------------------------------------- */ -void JimELAssocDataDeleProc(Jim_Interp *interp, void *data) +static void JimELAssocDataDeleProc(Jim_Interp *interp, void *data) { void *next; Jim_FileEvent *fe; @@ -446,14 +446,14 @@ static int JimELVwaitCommand(Jim_Interp *interp, int argc, return JIM_OK; } -void JimAfterTimeHandler(Jim_Interp *interp, void *clientData) +static void JimAfterTimeHandler(Jim_Interp *interp, void *clientData) { Jim_Obj *objPtr = clientData; Jim_EvalObjBackground(interp, objPtr); } -void JimAfterTimeEventFinalizer(Jim_Interp *interp, void *clientData) +static void JimAfterTimeEventFinalizer(Jim_Interp *interp, void *clientData) { Jim_Obj *objPtr = clientData; diff --git a/src/helper/jim-eventloop.h b/src/helper/jim-eventloop.h index ddb6fc98..77ee8fec 100644 --- a/src/helper/jim-eventloop.h +++ b/src/helper/jim-eventloop.h @@ -64,9 +64,8 @@ typedef void Jim_EventFinalizerProc(Jim_Interp *interp, void *clientData); #define JIM_EVENT_FEOF 8 #define JIM_API(x) x -#define JIM_STATIC -JIM_STATIC int Jim_EventLoopOnLoad(Jim_Interp *interp); +int Jim_EventLoopOnLoad(Jim_Interp *interp); /* --- POSIX version of Jim_ProcessEvents, for now the only available --- */ #define JIM_FILE_EVENTS 1 @@ -74,20 +73,8 @@ JIM_STATIC int Jim_EventLoopOnLoad(Jim_Interp *interp); #define JIM_ALL_EVENTS (JIM_FILE_EVENTS | JIM_TIME_EVENTS) #define JIM_DONT_WAIT 4 -JIM_STATIC void JIM_API(Jim_CreateFileHandler) (Jim_Interp *interp, - void *handle, int mask, - Jim_FileProc *proc, void *clientData, - Jim_EventFinalizerProc *finalizerProc); -JIM_STATIC void JIM_API(Jim_DeleteFileHandler) (Jim_Interp *interp, - void *handle); -JIM_STATIC jim_wide JIM_API(Jim_CreateTimeHandler) (Jim_Interp *interp, - jim_wide milliseconds, - Jim_TimeProc *proc, void *clientData, - Jim_EventFinalizerProc *finalizerProc); -JIM_STATIC jim_wide JIM_API(Jim_DeleteTimeHandler) (Jim_Interp *interp, jim_wide id); -JIM_STATIC int JIM_API(Jim_ProcessEvents) (Jim_Interp *interp, int flags); +int JIM_API(Jim_ProcessEvents) (Jim_Interp *interp, int flags); -#undef JIM_STATIC #undef JIM_API #ifndef __JIM_EVENTLOOP_CORE__ |