Wiki Page Content

Revision 1 as of 2011-04-01 21:38:12

Clear message

DRAFT

SDL_GetAssertionReport

Use this function to get a list of all assertion failures.

Syntax

const SDL_assert_data* SDL_GetAssertionReport(void)

Return Value

Returns a list of all failed??? assertions. This never returns NULL, even if there are no items.

Code Examples

You can add your code example here

Remarks

This function gets all assertions triggered since the last call to SDL_ResetAssertionReport(), or the start of the program.

green

The proper way to examine this data looks something like this:

  • const SDL_assert_data *item = SDL_GetAssertionReport();
    while (item->condition) {
         printf("'%s', %s (%s:%d), triggered %u times, always ignore: %s.\n",
              item->condition, item->function, item->filename,
              item->linenum, item->trigger_count,
              item->always_ignore ? "yes" : "no");
         item = item->next;
    }


CategoryAPI, CategoryAssertions

(Page Info.)
Feedback
Please include your contact information if you'd like to receive a reply.
Submit