Changes in libcfa/src/iostream.hfa [200fcb3:58b6d1b]
- File:
-
- 1 edited
-
libcfa/src/iostream.hfa (modified) (8 diffs)
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/iostream.hfa
r200fcb3 r58b6d1b 10 10 // Created On : Wed May 27 17:56:53 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Tue Dec 11 22:01:31201813 // Update Count : 21312 // Last Modified On : Sun Jul 1 12:12:22 2018 13 // Update Count : 155 14 14 // 15 15 … … 20 20 trait ostream( dtype ostype ) { 21 21 // private 22 bool sepPrt( ostype & ); // return separator state (on/off)22 _Bool sepPrt( ostype & ); // return separator state (on/off) 23 23 void sepReset( ostype & ); // set separator state to default state 24 void sepReset( ostype &, bool ); // set separator and default state24 void sepReset( ostype &, _Bool ); // set separator and default state 25 25 const char * sepGetCur( ostype & ); // get current separator string 26 26 void sepSetCur( ostype &, const char * ); // set current separator string 27 bool getNL( ostype & ); // check newline 28 void setNL( ostype &, bool ); // saw newline 29 bool getANL( ostype & ); // check auto newline 30 bool getNonl( ostype & ); // check nonnl manipulator 31 void setNonl( ostype &, bool ); // set nonnl manipulator 27 _Bool getNL( ostype & ); // check newline 28 void setNL( ostype &, _Bool ); // saw newline 32 29 // public 33 30 void sepOn( ostype & ); // turn separator state on 34 31 void sepOff( ostype & ); // turn separator state off 35 bool sepDisable( ostype & ); // set default state to off, and return previous state 36 bool sepEnable( ostype & ); // set default state to on, and return previous state 37 void nlOn( ostype & ); // turn auto-newline state on 38 void nlOff( ostype & ); // turn auto-newline state off 32 _Bool sepDisable( ostype & ); // set default state to off, and return previous state 33 _Bool sepEnable( ostype & ); // set default state to on, and return previous state 39 34 40 35 const char * sepGet( ostype & ); // get separator string … … 62 57 63 58 forall( dtype ostype | ostream( ostype ) ) { 64 ostype & ?|?( ostype &, bool ); 65 void & ?|?( ostype &, bool ); 59 ostype & ?|?( ostype &, _Bool ); 66 60 67 61 ostype & ?|?( ostype &, char ); 68 void & ?|?( ostype &, char );69 62 ostype & ?|?( ostype &, signed char ); 70 void & ?|?( ostype &, signed char );71 63 ostype & ?|?( ostype &, unsigned char ); 72 void & ?|?( ostype &, unsigned char );73 64 74 65 ostype & ?|?( ostype &, short int ); 75 void & ?|?( ostype &, short int );76 66 ostype & ?|?( ostype &, unsigned short int ); 77 void & ?|?( ostype &, unsigned short int );78 67 ostype & ?|?( ostype &, int ); 79 void & ?|?( ostype &, int );80 68 ostype & ?|?( ostype &, unsigned int ); 81 void & ?|?( ostype &, unsigned int );82 69 ostype & ?|?( ostype &, long int ); 83 void & ?|?( ostype &, long int );84 70 ostype & ?|?( ostype &, long long int ); 85 void & ?|?( ostype &, long long int );86 71 ostype & ?|?( ostype &, unsigned long int ); 87 void & ?|?( ostype &, unsigned long int );88 72 ostype & ?|?( ostype &, unsigned long long int ); 89 void & ?|?( ostype &, unsigned long long int );90 73 91 74 ostype & ?|?( ostype &, float ); // FIX ME: should not be required 92 void & ?|?( ostype &, float ); // FIX ME: should not be required93 75 ostype & ?|?( ostype &, double ); 94 void & ?|?( ostype &, double );95 76 ostype & ?|?( ostype &, long double ); 96 void & ?|?( ostype &, long double );97 77 98 78 ostype & ?|?( ostype &, float _Complex ); 99 void & ?|?( ostype &, float _Complex );100 79 ostype & ?|?( ostype &, double _Complex ); 101 void & ?|?( ostype &, double _Complex );102 80 ostype & ?|?( ostype &, long double _Complex ); 103 void & ?|?( ostype &, long double _Complex );104 81 105 82 ostype & ?|?( ostype &, const char * ); 106 void & ?|?( ostype &, const char * );107 83 // ostype & ?|?( ostype &, const char16_t * ); 108 84 #if ! ( __ARM_ARCH_ISA_ARM == 1 && __ARM_32BIT_STATE == 1 ) // char32_t == wchar_t => ambiguous … … 111 87 // ostype & ?|?( ostype &, const wchar_t * ); 112 88 ostype & ?|?( ostype &, const void * ); 113 void & ?|?( ostype &, const void * );114 89 115 90 // manipulators 116 91 ostype & ?|?( ostype &, ostype & (*)( ostype & ) ); 117 void ?|?( ostype &, ostype & (*)( ostype & ) ); 118 ostype & nl( ostype & ); 119 ostype & nonl( ostype & ); 92 ostype & endl( ostype & ); 120 93 ostype & sep( ostype & ); 121 94 ostype & sepTuple( ostype & ); … … 124 97 ostype & sepDisable( ostype & ); 125 98 ostype & sepEnable( ostype & ); 126 ostype & nlOn( ostype & );127 ostype & nlOff( ostype & );128 99 } // distribution 129 100 130 101 // tuples 131 forall( dtype ostype, otype T, ttype Params | writeable( T, ostype ) | { ostype & ?|?( ostype &, Params ); } ) { 132 ostype & ?|?( ostype & os, T arg, Params rest ); 133 void ?|?( ostype & os, T arg, Params rest ); 134 } // distribution 102 forall( dtype ostype, otype T, ttype Params | writeable( T, ostype ) | { ostype & ?|?( ostype &, Params ); } ) 103 ostype & ?|?( ostype & os, T arg, Params rest ); 135 104 136 105 // writes the range [begin, end) to the given stream 137 forall( dtype ostype, otype elt_type | writeable( elt_type, ostype ), otype iterator_type | iterator( iterator_type, elt_type ) ) { 138 void write( iterator_type begin, iterator_type end, ostype & os ); 139 void write_reverse( iterator_type begin, iterator_type end, ostype & os ); 140 } // distribution 106 forall( dtype ostype, otype elt_type | writeable( elt_type, ostype ), otype iterator_type | iterator( iterator_type, elt_type ) ) 107 void write( iterator_type begin, iterator_type end, ostype & os ); 108 109 forall( dtype ostype, otype elt_type | writeable( elt_type, ostype ), otype iterator_type | iterator( iterator_type, elt_type ) ) 110 void write_reverse( iterator_type begin, iterator_type end, ostype & os ); 141 111 142 112 //--------------------------------------- … … 157 127 158 128 forall( dtype istype | istream( istype ) ) { 159 istype & ?|?( istype &, bool & );129 istype & ?|?( istype &, _Bool & ); 160 130 161 131 istype & ?|?( istype &, char & ); … … 182 152 // manipulators 183 153 istype & ?|?( istype &, istype & (*)( istype & ) ); 184 istype & nl( istype & is );154 istype & endl( istype & is ); 185 155 } // distribution 186 156 … … 194 164 195 165 196 #include <time_t.hfa> // Duration (constructors) / Time (constructors)166 #include <time_t.hfa> // Duration (constructors) / Time (constructors) 197 167 198 forall( dtype ostype | ostream( ostype ) ) { 199 ostype & ?|?( ostype & os, Duration dur ); 200 void ?|?( ostype & os, Duration dur ); 201 ostype & ?|?( ostype & os, Time time ); 202 void ?|?( ostype & os, Time time ); 203 } // distribution 168 forall( dtype ostype | ostream( ostype ) ) ostype & ?|?( ostype & os, Duration dur ); 169 forall( dtype ostype | ostream( ostype ) ) ostype & ?|?( ostype & os, Time time ); 170 204 171 205 172 // Local Variables: //
Note:
See TracChangeset
for help on using the changeset viewer.