#include <luna/Attributes.h>
#include <luna/SourceLocation.h>

#include <stdio.h>
#include <stdlib.h>

_weak [[noreturn]] bool __check_failed(SourceLocation location, const char* expr)
{
    // FIXME: Output to standard error instead of standard output.
    printf("Check failed at %s:%d in %s: %s\n", location.file(), location.line(), location.function(), expr);
    abort();
}