Ignore:
Timestamp:
Jun 10, 2019, 9:36:03 PM (3 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
arm-eh, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr
Children:
b326277
Parents:
558d13b
Message:

not wd with char type, and update test appropriately

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/iostream.cfa

    r558d13b r86a8be5  
    1010// Created On       : Wed May 27 17:56:53 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sun Jun  9 20:54:05 2019
    13 // Update Count     : 804
     12// Last Modified On : Mon Jun 10 18:06:16 2019
     13// Update Count     : 809
    1414//
    1515
     
    797797} // ?|?
    798798
     799forall( dtype istype | istream( istype ) )
     800istype & ?|?( istype & is, _Istream_Char f ) {
     801        fmt( is, "%*c" );                                                                       // argument variable unused
     802        return is;
     803} // ?|?
     804
    799805#define InputFMTImpl( T, CODE ) \
    800806forall( dtype istype | istream( istype ) ) \
     
    802808        enum { size = 16 }; \
    803809        char fmtstr[size]; \
    804         if ( f.wd == -1 || strcmp( CODE, "c" ) == 0 ) { /* ignore width with "c" */     \
     810        if ( f.wd == -1 ) { \
    805811                snprintf( fmtstr, size, "%%%s%s", f.ignore ? "*" : "", CODE ); \
    806812        } else { \
     
    812818} // ?|?
    813819
    814 InputFMTImpl( char, "c" )
    815820InputFMTImpl( signed char, "hhi" )
    816821InputFMTImpl( unsigned char, "hhi" )
Note: See TracChangeset for help on using the changeset viewer.