AP_HAL: removed AVR special case

no longer needed
This commit is contained in:
Andrew Tridgell 2015-05-26 14:34:13 +10:00
parent 964b8ed2f3
commit 1a2b02a563
1 changed files with 0 additions and 10 deletions

View File

@ -7,18 +7,8 @@
#include "string.h"
#include "utility/FastDelegate.h"
#if defined(__AVR__)
/*
gcc on AVR doesn't allow for delegates in progmem. It gives a
warning that the progmem area is uninitialised, and fills the area
with zeros. This is a workaround.
*/
#define DELEGATE_FUNCTION_VOID_TYPEDEF(type) typedef void (*type)(const void *)
#define AP_HAL_CLASSPROC_VOID(classptr, func) (void (*)(const void*))func
#else
#define DELEGATE_FUNCTION_VOID_TYPEDEF(type) typedef fastdelegate::FastDelegate0<void> type
#define AP_HAL_CLASSPROC_VOID(classptr, func) fastdelegate::MakeDelegate(classptr, func)
#endif
// macros to hide the details of delegate functions using FastDelegate
#define AP_HAL_CLASSPROC(classptr, func) fastdelegate::MakeDelegate(classptr, func)