Remove separate GCC4 versions of add_debug_command()/remove_debug_command() and
add the const in any case. As Axel points out these are C functions and we do not affect binary compatibility by changing their signature. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29124 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -174,16 +174,10 @@ extern void panic(const char *format, ...) _PRINTFLIKE(1, 2);
|
|||||||
extern void kernel_debugger(const char *message);
|
extern void kernel_debugger(const char *message);
|
||||||
extern uint64 parse_expression(const char *string);
|
extern uint64 parse_expression(const char *string);
|
||||||
|
|
||||||
#if __GNUC__ > 2
|
|
||||||
extern int add_debugger_command(const char *name,
|
extern int add_debugger_command(const char *name,
|
||||||
debugger_command_hook hook, const char *help);
|
debugger_command_hook hook, const char *help);
|
||||||
extern int remove_debugger_command(const char *name,
|
extern int remove_debugger_command(const char *name,
|
||||||
debugger_command_hook hook);
|
debugger_command_hook hook);
|
||||||
#else
|
|
||||||
extern int add_debugger_command(char *name, debugger_command_hook hook, char *help);
|
|
||||||
extern int remove_debugger_command(char *name,
|
|
||||||
debugger_command_hook hook);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Miscellaneous */
|
/* Miscellaneous */
|
||||||
extern void spin(bigtime_t microseconds);
|
extern void spin(bigtime_t microseconds);
|
||||||
|
|||||||
@@ -499,23 +499,15 @@ print_debugger_command_usage(const char* commandName)
|
|||||||
// #pragma mark - public API
|
// #pragma mark - public API
|
||||||
|
|
||||||
int
|
int
|
||||||
#if __GNUC__ > 2
|
|
||||||
add_debugger_command(const char *name, int (*func)(int, char **),
|
add_debugger_command(const char *name, int (*func)(int, char **),
|
||||||
const char *desc)
|
const char *desc)
|
||||||
#else
|
|
||||||
add_debugger_command(char *name, int (*func)(int, char **), char *desc)
|
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
return add_debugger_command_etc(name, func, desc, NULL, 0);
|
return add_debugger_command_etc(name, func, desc, NULL, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
#if __GNUC__ > 2
|
|
||||||
remove_debugger_command(const char * name, int (*func)(int, char **))
|
remove_debugger_command(const char * name, int (*func)(int, char **))
|
||||||
#else
|
|
||||||
remove_debugger_command(char * name, int (*func)(int, char **))
|
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
struct debugger_command *cmd = sCommands;
|
struct debugger_command *cmd = sCommands;
|
||||||
struct debugger_command *prev = NULL;
|
struct debugger_command *prev = NULL;
|
||||||
|
|||||||
Reference in New Issue
Block a user