The #define SWAP() is in the mbedtls and mbeddes crypto libraries, so not in your code.
#define SWAP()