Changeset d96f7c4 for tests


Ignore:
Timestamp:
Jan 17, 2025, 3:46:34 PM (2 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
df56e25
Parents:
3b340d68
Message:

expunge fallthru keyword and replace its usages with fallthrough

Location:
tests
Files:
15 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified tests/concurrency/actors/dynamic.cfa

    r3b340d68 rd96f7c4  
    3737                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    3838                        Times = ato( argv[1] );
    39                         if ( Times < 1 ) fallthru default;
     39                        if ( Times < 1 ) fallthrough default;
    4040                } // if
    4141          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/actors/executor.cfa

    r3b340d68 rd96f7c4  
    4141                if ( strcmp( argv[6], "d" ) != 0 ) {                    // default ?
    4242                        BufSize = ato( argv[6] );
    43                         if ( BufSize < 0 ) fallthru default;
     43                        if ( BufSize < 0 ) fallthrough default;
    4444                } // if
    4545          case 6:
    4646                if ( strcmp( argv[5], "d" ) != 0 ) {                    // default ?
    4747                        Batch = ato( argv[5] );
    48                         if ( Batch < 1 ) fallthru default;
     48                        if ( Batch < 1 ) fallthrough default;
    4949                } // if
    5050          case 5:
    5151                if ( strcmp( argv[4], "d" ) != 0 ) {                    // default ?
    5252                        Processors = ato( argv[4] );
    53                         if ( Processors < 1 ) fallthru default;
     53                        if ( Processors < 1 ) fallthrough default;
    5454                } // if
    5555          case 4:
    5656                if ( strcmp( argv[3], "d" ) != 0 ) {                    // default ?
    5757                        Rounds = ato( argv[3] );
    58                         if ( Rounds < 1 ) fallthru default;
     58                        if ( Rounds < 1 ) fallthrough default;
    5959                } // if
    6060          case 3:
    6161                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    6262                        Set = ato( argv[2] );
    63                         if ( Set < 1 ) fallthru default;
     63                        if ( Set < 1 ) fallthrough default;
    6464                } // if
    6565          case 2:
    6666                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    6767                        Actors = ato( argv[1] );
    68                         if ( Actors < 1 || Actors <= Set || Actors % Set != 0 ) fallthru default;
     68                        if ( Actors < 1 || Actors <= Set || Actors % Set != 0 ) fallthrough default;
    6969                } // if
    7070          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/actors/matrixMultiply.cfa

    r3b340d68 rd96f7c4  
    3939                if ( strcmp( argv[4], "d" ) != 0 ) {                    // default ?
    4040                        Processors = ato( argv[4] );
    41                         if ( Processors < 1 ) fallthru default;
     41                        if ( Processors < 1 ) fallthrough default;
    4242                } // if
    4343          case 4:
    4444                if ( strcmp( argv[3], "d" ) != 0 ) {                    // default ?
    4545                        xr = ato( argv[3] );
    46                         if ( xr < 1 ) fallthru default;
     46                        if ( xr < 1 ) fallthrough default;
    4747                } // if
    4848          case 3:
    4949                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    5050                        xc = ato( argv[2] );
    51                         if ( xc < 1 ) fallthru default;
     51                        if ( xc < 1 ) fallthrough default;
    5252                } // if
    5353          case 2:
    5454                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    5555                        yc = ato( argv[1] );
    56                         if ( yc < 1 ) fallthru default;
     56                        if ( yc < 1 ) fallthrough default;
    5757                } // if
    5858          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/actors/static.cfa

    r3b340d68 rd96f7c4  
    3434                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    3535                        Times = ato( argv[1] );
    36                         if ( Times < 1 ) fallthru default;
     36                        if ( Times < 1 ) fallthrough default;
    3737                } // if
    3838          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/channels/barrier.cfa

    r3b340d68 rd96f7c4  
    6666                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    6767                        BarrierSize = ato( argv[2] );
    68             if ( Processors < 1 ) fallthru default;
     68            if ( Processors < 1 ) fallthrough default;
    6969                } // if
    7070          case 2:
    7171                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    7272                        Processors = ato( argv[1] );
    73                         if ( Processors < 1 ) fallthru default;
     73                        if ( Processors < 1 ) fallthrough default;
    7474                } // if
    7575          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/channels/churn.cfa

    r3b340d68 rd96f7c4  
    9191                if ( strcmp( argv[3], "d" ) != 0 ) {                    // default ?
    9292                        ChannelSize = ato( argv[3] );
    93                         if ( ChannelSize < 1 ) fallthru default;
     93                        if ( ChannelSize < 1 ) fallthrough default;
    9494                } // if
    9595      case 3:
    9696                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    9797                        Channels = ato( argv[2] );
    98                         if ( Channels < 1 ) fallthru default;
     98                        if ( Channels < 1 ) fallthrough default;
    9999                } // if
    100100      case 2:
    101101                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    102102                        Processors = ato( argv[1] );
    103                         if ( Processors < 1 ) fallthru default;
     103                        if ( Processors < 1 ) fallthrough default;
    104104                } // if
    105105          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/channels/contend.cfa

    r3b340d68 rd96f7c4  
    128128                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    129129                        ChannelSize = ato( argv[2] );
    130                         if ( ChannelSize < 1 ) fallthru default;
     130                        if ( ChannelSize < 1 ) fallthrough default;
    131131                } // if
    132132          case 2:
    133133                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    134134                        Processors = ato( argv[1] );
    135                         if ( Processors < 1 ) fallthru default;
     135                        if ( Processors < 1 ) fallthrough default;
    136136                } // if
    137137          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/channels/daisy_chain.cfa

    r3b340d68 rd96f7c4  
    3838                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    3939                        Tasks = ato( argv[2] );
    40             if ( Tasks < 1 ) fallthru default;
     40            if ( Tasks < 1 ) fallthrough default;
    4141                } // if
    4242          case 2:
    4343                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    4444                        Processors = ato( argv[1] );
    45                         if ( Processors < 1 ) fallthru default;
     45                        if ( Processors < 1 ) fallthrough default;
    4646                } // if
    4747          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/channels/hot_potato.cfa

    r3b340d68 rd96f7c4  
    4343                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    4444                        Tasks = ato( argv[2] );
    45             if ( Tasks < 1 ) fallthru default;
     45            if ( Tasks < 1 ) fallthrough default;
    4646                } // if
    4747          case 2:
    4848                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    4949                        Processors = ato( argv[1] );
    50                         if ( Processors < 1 ) fallthru default;
     50                        if ( Processors < 1 ) fallthrough default;
    5151                } // if
    5252          case 1:                                                                                       // use defaults
  • TabularUnified tests/concurrency/channels/pub_sub.cfa

    r3b340d68 rd96f7c4  
    8888                if ( strcmp( argv[2], "d" ) != 0 ) {                    // default ?
    8989                        Tasks = ato( argv[2] );
    90             if ( Tasks < 1 ) fallthru default;
     90            if ( Tasks < 1 ) fallthrough default;
    9191                } // if
    9292          case 2:
    9393                if ( strcmp( argv[1], "d" ) != 0 ) {                    // default ?
    9494                        Processors = ato( argv[1] );
    95                         if ( Processors < 1 ) fallthru default;
     95                        if ( Processors < 1 ) fallthrough default;
    9696                } // if
    9797          case 1:                                                                                       // use defaults
  • TabularUnified tests/ctrl-flow/fallthrough.cfa

    r3b340d68 rd96f7c4  
    1010// Created On       : Wed Mar 14 10:06:25 2018
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Mon Dec 24 11:24:35 2018
    13 // Update Count     : 22
     12// Last Modified On : Fri Jan 17 14:09:49 2025
     13// Update Count     : 23
    1414//
    1515
     
    2020          case 1:
    2121                sout | "case 1";
    22                 fallthru;
     22                fallthrough;
    2323          case 2:
    2424                sout | "case 2";
    25                 fallthru;
    26                 sout | "did not fallthru";
    27                 if ( 7 ) fallthru common2;
    28                 fallthru common1;
     25                fallthrough;
     26                sout | "did not fallthrough";
     27                if ( 7 ) fallthrough common2;
     28                fallthrough common1;
    2929          case 3:
    3030                sout | "case 3";
    31                 fallthru default;
    32                 fallthru common1;
     31                fallthrough default;
     32                fallthrough common1;
    3333          common1:
    3434                sout | "common1";
     
    3636          case 4:
    3737                sout | "case 4";
    38                 fallthru common2;
     38                fallthrough common2;
    3939          case 5:
    4040                sout | "case 5";
    41                 fallthru common2;
    42                 fallthru default;
     41                fallthrough common2;
     42                fallthrough default;
    4343          case 6:
    4444                sout | "case 6";
    45                 fallthru common2;
     45                fallthrough common2;
    4646          common2:
    4747                sout | "common2";
     
    4949          default:
    5050                sout | "default";
    51                 fallthru;
     51                fallthrough;
    5252        } // choose
    5353
     
    6262                        for ( int i = 0; i < 4; i += 1 ) {
    6363                                sout | i;
    64                                 if ( i == 2 ) fallthru common;
     64                                if ( i == 2 ) fallthrough common;
    6565                        } // for
    6666                } // switch
     
    7373                        } else {
    7474                                sout | "check";
    75                                 fallthru common;
     75                                fallthrough common;
    7676                        } // if
    7777                } // if
    7878          common:
    7979                sout | "common";
    80                 fallthru;
     80                fallthrough;
    8181                break;
    8282          default:
    8383                sout | "default";
    84                 fallthru;
     84                fallthrough;
    8585        } // switch
    8686
    8787#if ERR1
    8888        // ERROR: fallthrough must be enclosed in switch or choose
    89         fallthru;
     89        fallthrough;
    9090        // ERROR: fallthrough must be enclosed in switch or choose
    91         fallthru common4;
     91        fallthrough common4;
    9292        // ERROR: fallthrough must be enclosed in switch or choose
    93         fallthru default;
     93        fallthrough default;
    9494        choose ( 3 ) {
    9595          case 2:
     
    9898                          case 1:
    9999                                // ERROR: default is later, but in a different switch
    100                                 fallthru default;
     100                                fallthrough default;
    101101                                // ERROR: common3 is later, but not at the same level as a case clause
    102                                 fallthru common3;
     102                                fallthrough common3;
    103103                        }
    104104                  common3: ;
     
    108108          common4:
    109109                // ERROR: attempt to jump up with fallthrough
    110                 if ( 7 ) fallthru common4;
     110                if ( 7 ) fallthrough common4;
    111111                // ERROR: attempt to jump up with fallthrough
    112                 fallthru default;
     112                fallthrough default;
    113113        } // choose
    114114#endif
  • TabularUnified tests/ctrl-flow/labelledExit.cfa

    r3b340d68 rd96f7c4  
    1010// Created On       : Wed Aug 10 07:29:39 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Jun  5 10:07:34 2021
    13 // Update Count     : 13
     12// Last Modified On : Fri Jan 17 14:18:15 2025
     13// Update Count     : 14
    1414//
    1515
     
    131131                        break Choose;
    132132                }
    133                 fallthru;
     133                fallthrough;
    134134          case 2:
    135135                i += 1;
  • TabularUnified tests/exceptions/try-ctrl-flow.cfa

    r3b340d68 rd96f7c4  
    8181}
    8282
    83 void choose_fallthru_in_finally() {
     83void choose_fallthrough_in_finally() {
    8484        choose (1) {
    8585        case 1:
    8686                try {} finally {
    87                         fallthru;
     87                        fallthrough;
    8888                }
    8989        default:
     
    105105}
    106106
    107 void labelled_choose_fallthru_in_finally() {
     107void labelled_choose_fallthrough_in_finally() {
    108108        mainBlock: choose (1) {
    109109        case 1:
    110110                try {} finally {
    111                         fallthru mainBlock;
     111                        fallthrough mainBlock;
    112112                }
    113113        case 2:
     
    118118}
    119119
    120 void choose_fallthru_default_in_finally() {
     120void choose_fallthrough_default_in_finally() {
    121121        choose (1) {
    122122        case 1:
    123123                try {} finally {
    124                         fallthru default;
     124                        fallthrough default;
    125125                }
    126126        default:
  • TabularUnified tests/quotedKeyword.cfa

    r3b340d68 rd96f7c4  
    1010// Created On       : Wed May 27 17:56:53 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Feb 23 20:31:05 2023
    13 // Update Count     : 26
     12// Last Modified On : Fri Jan 17 14:10:32 2025
     13// Update Count     : 27
    1414//
    1515
     
    2929        ``__attribute__, ``auto, ``_Bool, ``break, ``case, ``catch, ``catchResume, ``char, ``choose, ``_Complex, ``__complex,
    3030        ``__complex__, ``const, ``__const, ``__const__, ``continue, ``default, ``disable, ``do, ``double, ``dtype, ``else,
    31         ``enable, ``enum, ``__extension__, ``extern, ``fallthru, ``finally, ``float, ``__float128, ``for, ``forall, ``fortran,
     31        ``enable, ``enum, ``__extension__, ``extern, ``fallthrough, ``finally, ``float, ``__float128, ``for, ``forall, ``fortran,
    3232        ``ftype, ``_Generic, ``goto, ``if, ``_Imaginary, ``__imag, ``__imag__, ``inline, ``__inline, ``__inline__, ``int,
    3333        ``__int128, ``__label__, ``long, ``lvalue, ``_Noreturn, ``__builtin_offsetof, ``otype, ``register, ``restrict,
  • TabularUnified tests/switch.cfa

    r3b340d68 rd96f7c4  
    1010// Created On       : Tue Jul 12 06:50:22 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Jun  5 10:08:20 2021
    13 // Update Count     : 44
     12// Last Modified On : Fri Jan 17 14:10:12 2025
     13// Update Count     : 45
    1414//
    1515
     
    9696          case 8~10:
    9797                f( 3 );
    98                 fallthru;
     98                fallthrough;
    9999          case 'd':
    100100                j = 5;
Note: See TracChangeset for help on using the changeset viewer.