Use app provided panic handler if it exists (#209)

wch-ch32v003
Matthias 3 months ago committed by GitHub
parent 0c3293fe36
commit bb8888944f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -3,12 +3,7 @@ const microzig = @import("microzig");
const app = @import("app"); const app = @import("app");
// Use microzig panic handler if not defined by an application // Use microzig panic handler if not defined by an application
pub usingnamespace if (!@hasDecl(app, "panic")) pub const panic = if (!@hasDecl(app, "panic")) microzig.panic else app.panic;
struct {
pub const panic = microzig.panic;
}
else
struct {};
pub const VectorTableOptions = if (@hasDecl(microzig.chip, "VectorTable")) pub const VectorTableOptions = if (@hasDecl(microzig.chip, "VectorTable"))
blk: { blk: {

Loading…
Cancel
Save