rm-hull / byok

A bare-metal x86 Forth interpreter & compiler
MIT License
56 stars 11 forks source link

Dump return stack trace #14

Open rm-hull opened 9 years ago

rm-hull commented 9 years ago

In stack_abort() something a bit more fancy than:

    printf("RS: ");
    dlist_elem_t *element = dlist_tail(ctx->rs);
    while (element != NULL)
    {
        int *num = dlist_data(element);

        printnum(*num, ctx->base);
        element = dlist_prev(element);
    }
    printf("\n");