Ignore:
Timestamp:
Aug 25, 2022, 10:43:36 PM (20 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, ast-experimental, master, pthread-emulation
Children:
51fbba5
Parents:
d2f09e4
Message:

change C loop control to CFA loop control

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/rational.cfa

    rd2f09e4 rf6a4917  
    1010// Created On       : Wed Apr  6 17:54:28 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Tue Jul 20 16:30:06 2021
    13 // Update Count     : 193
     12// Last Modified On : Thu Aug 25 18:09:58 2022
     13// Update Count     : 194
    1414//
    1515
     
    2626        // rationals.  alternative: https://en.wikipedia.org/wiki/Binary_GCD_algorithm
    2727        static T gcd( T a, T b ) {
    28                 for ( ;; ) {                                                                    // Euclid's algorithm
     28                for () {                                                                                // Euclid's algorithm
    2929                        T r = a % b;
    3030                  if ( r == (T){0} ) break;
     
    246246
    247247        // find terms until denom gets too big
    248         for ( ;; ) {
     248        for () {
    249249                ai = convert( f );
    250250          if ( ! (m10 * ai + m11 <= md) ) break;
Note: See TracChangeset for help on using the changeset viewer.