Changes in libcfa/src/iostream.cfa [e7a8f65:ff7f6d07]
- File:
-
- 1 edited
-
libcfa/src/iostream.cfa (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/iostream.cfa
re7a8f65 rff7f6d07 10 10 // Created On : Wed May 27 17:56:53 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Wed Aug 9 10:10:56202313 // Update Count : 14 3212 // Last Modified On : Mon Aug 7 08:59:29 2023 13 // Update Count : 1407 14 14 // 15 15 … … 271 271 OSTYPE_VOID_IMPL( const char * ) 272 272 273 // ostype & ?|?( ostype & os, const char16_t s[]) {273 // ostype & ?|?( ostype & os, const char16_t * s ) { 274 274 // if ( sepPrt$( os ) ) fmt( os, "%s", sepGetCur$( os ) ); 275 275 // fmt( os, "%ls", s ); … … 278 278 279 279 // #if ! ( __ARM_ARCH_ISA_ARM == 1 && __ARM_32BIT_STATE == 1 ) // char32_t == wchar_t => ambiguous 280 // ostype & ?|?( ostype & os, const char32_t s[]) {280 // ostype & ?|?( ostype & os, const char32_t * s ) { 281 281 // if ( sepPrt$( os ) ) fmt( os, "%s", sepGetCur$( os ) ); 282 282 // fmt( os, "%ls", s ); … … 285 285 // #endif // ! ( __ARM_ARCH_ISA_ARM == 1 && __ARM_32BIT_STATE == 1 ) 286 286 287 // ostype & ?|?( ostype & os, const wchar_t s[]) {287 // ostype & ?|?( ostype & os, const wchar_t * s ) { 288 288 // if ( sepPrt$( os ) ) fmt( os, "%s", sepGetCur$( os ) ); 289 289 // fmt( os, "%ls", s ); … … 917 917 // } // ?|? 918 918 919 //istype & ?|?( istype & is, char s[] ) {920 //fmt( is, "%s", s );921 //return is;922 //} // ?|?923 //ISTYPE_VOID_IMPL( char * )919 istype & ?|?( istype & is, char s[] ) { 920 fmt( is, "%s", s ); 921 return is; 922 } // ?|? 923 ISTYPE_VOID_IMPL( char * ) 924 924 925 925 // manipulators … … 934 934 istype & nl( istype & is ) { 935 935 fmt( is, "%*[^\n]" ); // ignore characters to newline 936 if ( ! eof( is ) && getANL$( is ) ) fmt( is, "%*c" ); // read newline937 936 return is; 938 937 } // nl … … 953 952 forall( istype & | basic_istream( istype ) ) { 954 953 istype & ?|?( istype & is, _Istream_Cstr f ) { 955 // skip 954 // skip xxx 956 955 if ( ! f.s ) { 957 956 // printf( "skip %s %d\n", f.scanset, f.wd ); 958 if ( f.wd == -1 ) fmt( is, f.scanset, "" ); // no input arguments957 if ( f.wd == -1 ) fmt( is, f.scanset, "" ); // no input arguments 959 958 else for ( f.wd ) fmt( is, "%*c" ); 960 959 return is; 961 960 } // if 962 963 // getline964 if ( f.flags.delimit ) {965 char fmtstr[] = "%[^ ]s"; // delimit inserted into space966 fmtstr[3] = f.delimit;967 fmt( is, fmtstr, f.s ); // read upto delimiter968 fmt( is, "%*c" ); // ignore delimiter969 return is;970 } // if971 972 // incl/excl973 961 size_t len = 0; 974 962 if ( f.scanset ) len = strlen( f.scanset ); … … 989 977 fmtstr[start] = '['; start += 1; 990 978 if ( f.flags.inex ) { fmtstr[start] = '^'; start += 1; } 991 strcpy( &fmtstr[start], f.scanset ); // copy includes '\0'979 strcpy( &fmtstr[start], f.scanset ); // copy includes '\0' 992 980 len += start; 993 981 fmtstr[len] = ']'; fmtstr[len + 1] = '\0'; … … 999 987 1000 988 istype & ?|?( istype & is, _Istream_Char f ) { 1001 fmt( is, "%*c" ); // argument variable unused989 fmt( is, "%*c" ); // argument variable unused 1002 990 return is; 1003 991 } // ?|?
Note:
See TracChangeset
for help on using the changeset viewer.