Changeset d9f6d80 for tests


Ignore:
Timestamp:
Dec 20, 2024, 3:35:35 PM (11 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
9dc05782
Parents:
77148b0 (diff), 5251c6b (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

Location:
tests
Files:
17 edited

Legend:

Unmodified
Added
Removed
  • tests/Makefile.am

    r77148b0 rd9f6d80  
    5050# Indented list entries are finer-grained targets under the test.
    5151# Making this association implicit would be ideal, but requires learning more automake than is affordable.
    52 WFLGAS_OPT_LAX =  \
     52WFLGAS_OPT_LAX = \
    5353        alloc \
    5454        alloc2 \
     
    5656        array-collections/array-raii-c \
    5757        array-collections/array-raii-cfa \
    58         array-collections/array-sbscr-types \
    5958        array-collections/boxed \
    6059                array-collections/boxed% \
     
    6968        cast \
    7069        collections/atomic_mpsc \
     70        collections/multi_list \
    7171        collections/queue \
    7272        collections/sequence \
    7373        collections/stack \
    74         collections/string-api-coverage \
    75         collections/string-api-coverage-noshare \
    7674        collections/vector-demo \
    7775        concurrency/actors/dynamic \
     
    10098        concurrency/examples/boundedBufferEXT \
    10199        concurrency/examples/boundedBufferINT \
    102         concurrency/examples/datingService \
    103         concurrency/examples/gortn \
    104         concurrency/examples/matrixSum \
    105         concurrency/examples/quickSort \
    106100        concurrency/futures/abandon \
    107         concurrency/futures/basic \
    108101        concurrency/futures/multi \
    109102        concurrency/futures/select_future \
     
    119112        concurrency/mutexstmt/tuple \
    120113        concurrency/once \
    121         concurrency/park/contention \
    122         concurrency/park/force_preempt \
    123         concurrency/park/start_parked \
    124114        concurrency/preempt \
    125         concurrency/preempt2 \
    126115        concurrency/pthread/bounded_buffer \
    127116        concurrency/pthread/pthread_attr_test \
     
    131120        concurrency/pthread/pthread_key_test \
    132121        concurrency/pthread/pthread_once_test \
    133         concurrency/readyQ/barrier_sleeper \
    134122        concurrency/readyQ/leader_spin \
    135123        concurrency/signal/block \
     
    152140        concurrency/unified_locking/timeout_lock \
    153141        concurrency/waitfor/barge \
    154         concurrency/waitfor/dtor \
    155142        concurrency/waitfor/parse \
    156         concurrency/waitfor/recurse \
    157143        concurrency/waitfor/statment \
    158144        concurrency/waitfor/when \
     
    170156        configs/parsenums \
    171157        configs/usage \
    172         coroutine/devicedriver \
    173         coroutine/fibonacci \
    174         coroutine/fmtLines \
    175         coroutine/pingpong \
    176         coroutine/prodcons \
    177158        coroutine/raii \
    178         coroutine/runningTotal \
    179159        ctrl-flow/goto \
    180160        ctrl-flow/ifwhileCtl \
     
    186166        enum_tests/planet \
    187167        enum_tests/structEnum \
    188         exceptions/cancel/coroutine \
    189         exceptions/cancel/thread \
    190168        exceptions/cardgame \
    191         exceptions/conditional \
    192         exceptions/conditional-threads \
    193         exceptions/cor_resumer \
    194         exceptions/data-except \
    195169        exceptions/defaults \
    196170        exceptions/defaults-threads \
    197         exceptions/fibonacci_nonlocal \
    198         exceptions/finally \
    199         exceptions/finally-threads \
    200171        exceptions/hotpotato \
    201172        exceptions/hotpotato_checked \
    202         exceptions/interact \
    203173        exceptions/pingpong_nonlocal \
    204174        exceptions/polymorphic \
    205         exceptions/resume \
    206         exceptions/resume-threads \
    207         exceptions/terminate \
    208         exceptions/terminate-threads \
    209         exceptions/trash \
    210175        exceptions/try-leave-catch \
    211         exceptions/virtual-cast \
    212176        exceptions/virtual-poly \
    213177        expression \
     
    241205                linking/mangling/lib.o \
    242206                linking/mangling/main.o \
    243         linking/withthreads \
    244207        linkonce \
    245208                link-once/% \
     
    249212        maybe \
    250213        minmax \
    251         nested_function \
    252214        nested-types \
    253215        nested-types-ERR1 \
     
    268230        raii/init_once \
    269231        raii/partial \
    270         rational \
    271232        references \
    272233        result \
     
    284245        typedefRedef-ERR1 \
    285246        typeof \
     247        userLiterals \
    286248        variableDeclarator \
    287249        vector \
  • tests/collections/string-api-coverage.cfa

    r77148b0 rd9f6d80  
    11#include <collections/string.hfa>
    22#include <string_sharectx.hfa>
    3 
    4 void assertWellFormedHandleList( int maxLen ) { // with(HeapArea)
    5     // HandleNode *n;
    6     // int limit1 = maxLen;
    7     // for ( n = Header.flink; (limit1-- > 0) && n != &Header; n = n->flink ) {}
    8     // assert (n == &Header);
    9     // int limit2 = maxLen;
    10     // for ( n = Header.blink; (limit2-- > 0) && n != &Header; n = n->blink ) {}
    11     // assert (n == &Header);
    12     // assert (limit1 == limit2);
    13 }
    14 
    15 // The given string is reachable.
    16 void assertOnHandleList( string & q ) { // with(HeapArea)
    17     // HandleNode *n;
    18     // for ( n = Header.flink; n != &Header; n = n->flink ) {
    19     //     if ( n == & q.inner->Handle ) return;
    20     // }
    21     // assert( false );
    22 }
    233
    244
     
    6141
    6242
    63                                             assertWellFormedHandleList( 10 );
    6443    //
    6544    // breadth Constructors
     
    11695        sout | b11; // 5.5+3.4i
    11796    }
    118                                             assertWellFormedHandleList( 10 );
     97
    11998    //
    12099    // Assignments
     
    176155        sout | b; // 5.5+3.4i
    177156    }
    178                                             assertWellFormedHandleList( 10 );
     157
    179158
    180159
     
    187166
    188167    string sx = s + s3;
    189                                             assertWellFormedHandleList( 10 );
    190168    sout | sx; // helloworld
    191                                             assertWellFormedHandleList( 10 );
    192169    sx = "xx";
    193                                             assertWellFormedHandleList( 10 );
    194170    sx = s + s3;
    195                                             assertWellFormedHandleList( 10 );
    196171    sout | sx; // helloworld
    197                                             assertWellFormedHandleList( 10 );
    198172
    199173    sx += '!';
     
    205179    sx += s;
    206180    sout | sx; // hellohello
    207                                             assertWellFormedHandleList( 10 );
    208181    sx += ", friend";   
    209182    sout | sx; // hellohello, friend
  • tests/exceptions/cancel/coroutine.cfa

    r77148b0 rd9f6d80  
    99coroutine WillCancel {};
    1010
    11 const char * msg(CoroutineCancelled(WillCancel) * this) {
     11const char * msg(CoroutineCancelled(WillCancel) *) {
    1212        return "CoroutineCancelled(WillCancel)";
    1313}
    1414
    15 void main(WillCancel & wc) {
     15void main(WillCancel &) {
    1616        sout | '1';
    1717        cancel_stack((internal_error){&internal_vt});
     
    1919}
    2020
    21 int main(int argc, char * argv[]) {
     21int main() {
    2222        sout | nlOff;
    2323        WillCancel cancel;
  • tests/exceptions/cancel/thread.cfa

    r77148b0 rd9f6d80  
    99thread WillCancel {};
    1010
    11 const char * msg(ThreadCancelled(WillCancel) * this) {
     11const char * msg(ThreadCancelled(WillCancel) *) {
    1212        return "ThreadCancelled(WillCancel)";
    1313}
     
    5252}
    5353
    54 int main(int argc, char * argv[]) {
     54int main() {
    5555        sout | nlOff;
    5656        explicit();
  • tests/exceptions/conditional.cfa

    r77148b0 rd9f6d80  
    1616}
    1717
    18 int main(int argc, char * argv[]) {
     18int main() {
    1919        num_error exc = {&num_error_vt, 2};
    2020
  • tests/exceptions/data-except.cfa

    r77148b0 rd9f6d80  
    1414}
    1515
    16 int main(int argc, char * argv[]) {
     16int main() {
    1717        paired except = {&paired_vt, 3, 13};
    1818
  • tests/exceptions/defaults.cfa

    r77148b0 rd9f6d80  
    106106}
    107107
    108 int main(int argc, char * argv[]) {
     108int main() {
    109109        log_test();
    110110        jump_test();
  • tests/exceptions/except-io.hfa

    r77148b0 rd9f6d80  
    99};
    1010
    11 inline void ?{}(loud_exit & this, const char * area) {
     11static inline void ?{}(loud_exit & this, const char * area) {
    1212    this.area = area;
    1313}
    1414
    15 inline void ^?{}(loud_exit & this) {
     15static inline void ^?{}(loud_exit & this) {
    1616    sout | "Exiting: " | this.area;
    1717}
     
    2121};
    2222
    23 inline void ?{}(loud_region & this, const char * region) {
     23static inline void ?{}(loud_region & this, const char * region) {
    2424        this.region = region;
    2525        sout | "Entering: " | region;
    2626}
    2727
    28 inline void ^?{}(loud_region & this) {
     28static inline void ^?{}(loud_region & this) {
    2929        sout | "Exiting: " | this.region;
    3030}
  • tests/exceptions/finally.cfa

    r77148b0 rd9f6d80  
    88vtable(myth) myth_vt;
    99
    10 int main(int argc, char * argv[]) {
     10int main() {
    1111        myth exc = {&myth_vt};
    1212
  • tests/exceptions/interact.cfa

    r77148b0 rd9f6d80  
    1010vtable(moon) moon_vt;
    1111
    12 int main(int argc, char * argv[]) {
     12int main() {
    1313        // Resume falls back to terminate.
    1414        try {
  • tests/exceptions/polymorphic.cfa

    r77148b0 rd9f6d80  
    5959}
    6060
    61 int main(int argc, char * argv[]) {
     61int main() {
    6262        proxy_test();
    6363        sout | nl;
  • tests/exceptions/resume.cfa

    r77148b0 rd9f6d80  
    1414void in_void(void);
    1515
    16 int main(int argc, char * argv[]) {
     16int main() {
    1717        yin a_yin = {&yin_vt};
    1818        yang a_yang = {&yang_vt};
  • tests/exceptions/terminate.cfa

    r77148b0 rd9f6d80  
    1414void in_void(void);
    1515
    16 int main(int argc, char * argv[]) {
     16int main() {
    1717        yin a_yin = {&yin_vt};
    1818        yang a_yang = {&yang_vt};
  • tests/exceptions/trash.cfa

    r77148b0 rd9f6d80  
    99vtable(yang) yang_vt;
    1010
    11 int main(int argc, char * argv[]) {
     11int main() {
    1212        try {
    1313                try {
  • tests/exceptions/try-ctrl-flow.cfa

    r77148b0 rd9f6d80  
    189189}
    190190
    191 void main() {
     191int main() {
    192192        // Should not compile.
    193193        return 1;
  • tests/exceptions/try-leave-catch.cfa

    r77148b0 rd9f6d80  
    5353}
    5454
    55 int main(int argc, char * argv[]) {
     55int main() {
    5656        test_loop();
    5757        test_switch();
  • tests/exceptions/virtual-cast.cfa

    r77148b0 rd9f6d80  
    9393}
    9494
    95 int main (int argc, char * argv[]) {
    96 
     95int main() {
    9796        gamma * tri = malloc(); tri->virtual_table = &_gamma_vtable_instance;
    9897        beta * mid = (virtual beta *)tri;
Note: See TracChangeset for help on using the changeset viewer.