Ignore:
Timestamp:
Mar 10, 2024, 11:21:18 AM (6 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
9398177
Parents:
b64d0f4
Message:

more switch to tabs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • doc/theses/mike_brooks_MMath/programs/hello-accordion.cfa

    rb64d0f4 r5546f50b  
    1111forall( T, [Nclients], [Ncosts] )
    1212struct request {
    13     unsigned int requestor_id;
    14     array( T, Nclients ) impacted_client_ids; // nested VLA
    15     array( float, Ncosts ) cost_contribs; // nested VLA
    16     float total_cost;
     13        unsigned int requestor_id;
     14        array( T, Nclients ) impacted_client_ids; // nested VLA
     15        array( float, Ncosts ) cost_contribs; // nested VLA
     16        float total_cost;
    1717};
    1818
     
    4141forall( T, [Nclients], [Ncosts] )
    4242void summarize( request( T, Nclients, Ncosts ) & r ) {
    43     r.total_cost = 0;
    44     for( i; Ncosts )
    45         r.total_cost += r.cost_contribs[i];
    46     // say the cost is per-client, to make output vary
    47     r.total_cost *= Nclients;
     43        r.total_cost = 0;
     44        for( i; Ncosts )
     45                r.total_cost += r.cost_contribs[i];
     46        // say the cost is per-client, to make output vary
     47        r.total_cost *= Nclients;
    4848}
    4949
Note: See TracChangeset for help on using the changeset viewer.