Merge pull request #52591 from timothyqiu/error-macros

[3.x] Remove do{ } while(0) wrapper around error macros
This commit is contained in:
Rémi Verschelde 2021-09-21 10:38:34 +02:00 committed by GitHub
commit b37776fa2f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 209 additions and 230 deletions

View file

@ -869,7 +869,7 @@ Error OS_JavaScript::initialize(const VideoMode &p_desired, int p_video_driver,
EMSCRIPTEN_RESULT result;
#define EM_CHECK(ev) \
if (result != EMSCRIPTEN_RESULT_SUCCESS) \
ERR_PRINT("Error while setting " #ev " callback: Code " + itos(result))
ERR_PRINT("Error while setting " #ev " callback: Code " + itos(result));
#define SET_EM_CALLBACK(target, ev, cb) \
result = emscripten_set_##ev##_callback(target, NULL, true, &cb); \
EM_CHECK(ev)