Fork of the official mbed C/C++ SDK provides the software platform and libraries to build your applications. The fork has the documentation converted to Doxygen format

Dependents:   NervousPuppySprintOne NervousPuppySprint2602 Robot WarehouseBot1 ... more

Fork of mbed by mbed official

Revision:
4:5d1359a283bc
Parent:
1:6b7f447ca868
Child:
5:62573be585e9
--- a/Debug.h	Fri Nov 14 15:25:20 2008 +0000
+++ b/Debug.h	Thu Nov 27 16:23:24 2008 +0000
@@ -5,8 +5,6 @@
 #ifndef MBED_DEBUG_H
 #define MBED_DEBUG_H
 
-#include "DebugTracer.h"
-
 namespace mbed {
 
 /* Section: debug
@@ -25,11 +23,11 @@
 void ERROR(const char* format, ...);
 #endif 
 
-#define ERROR(...) mbed_error(__FILE__, __LINE__, __VA_ARGS__) 
-void mbed_error(const char* file, int line, const char* fmt, ...);
+#define ERROR(FMT, ...) mbed_error(__FILE__, __LINE__, FMT, ##__VA_ARGS__) 
+void mbed_error(const char* file, int line, const char* fmt=0, ...) __attribute__((noreturn));
 
 // Internal use for "official" errors
-void mbed_error(const char* file, int line, int code, const char* fmt, ...);
+void mbed_error(const char* file, int line, int code, const char* fmt=0, ...) __attribute__((noreturn));
 
 // As seen by user, for documentation purposes only
 #if 0
@@ -46,11 +44,7 @@
 void ASSERT(int condition, const char* fmt = 0, ...);
 #endif
 
-#define ASSERT(...) mbed_assert(__FILE__, __LINE__, __VA_ARGS__)
-void mbed_assert(const char* file, int line, int condition, const char* fmt = 0, ...);
-
-// Internal use for "official" errors
-void mbed_assert(const char* file, int line, int condition, int code, const char* fmt = 0, ...);
+#define ASSERT(COND, ...) (COND ? (void)0 : mbed_error(__FILE__, __LINE__, ##__VA_ARGS__))
 
 // As seen by user, for documentation purposes only
 #if 0