Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/concurrency/exception.cfa

    r1c01c58 rc960331  
    1010// Created On       : Mon Aug 17 10:41:00 2020
    1111// Last Modified By : Andrew Beach
    12 // Last Modified On : Tue Aug 25 14:41:00 2020
    13 // Update Count     : 0
     12// Last Modified On : Wed Oct 28 14:34:00 2020
     13// Update Count     : 1
    1414//
    1515
    16 extern "C" {
    17 // use this define to make unwind.h play nice, definitely a hack
    18 #define HIDE_EXPORTS
    19 #include <unwind.h>
    20 #undef HIDE_EXPORTS
    21 }
     16#define __cforall_thread__
    2217
    23 #include "invoke.h"
    2418#include "exception.hfa"
     19
    2520#include "coroutine.hfa"
    2621
    2722extern struct $thread * mainThread;
     23extern "C" {
     24extern void __cfactx_thrd_leave();
     25}
    2826
    2927// Common pattern for all the stop functions, wait until the end then act.
     
    5250
    5351STOP_AT_END_FUNCTION(thread_cancelstop,
    54         // TODO: Instead pass information to the joiner.
    55         abort();
     52        __cfactx_thrd_leave();
     53        __cabi_abort( "Resumed cancelled thread" );
    5654)
    5755
     
    8583                stop_param = (void *)0x22;
    8684        } else {
     85                this_thread->self_cor.cancellation = unwind_exception;
     86
    8787                stop_func = thread_cancelstop;
    8888                stop_param = this_thread;
Note: See TracChangeset for help on using the changeset viewer.