STATIC_ASSERT for sizeof(struct ListMenu)
This commit is contained in:
committed by
Philipp AUER
parent
f8e7a2db5f
commit
c5bbaeab5d
@@ -13,6 +13,10 @@
|
||||
#include "sound.h"
|
||||
#include "constants/songs.h"
|
||||
|
||||
// GF cast Task data to ListMenu in many places, which effectively puts
|
||||
// an upper bound on sizeof(struct ListMenu).
|
||||
STATIC_ASSERT(sizeof(struct ListMenu) <= sizeof(((struct Task *)NULL)->data), ListMenuTooLargeForTaskData);
|
||||
|
||||
// Cursors after this point are created using a sprite with their own task.
|
||||
// This allows them to have idle animations. Cursors prior to this are simply printed text.
|
||||
#define CURSOR_OBJECT_START CURSOR_RED_OUTLINE
|
||||
|
||||
Reference in New Issue
Block a user