Changes in src/examples/iostream.h [cf16f94:e56cfdb0]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/examples/iostream.h
rcf16f94 re56cfdb0 10 10 // Created On : Wed May 27 17:56:53 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Mon Nov 23 14:15:25201513 // Update Count : 1712 // Last Modified On : Thu Nov 19 17:56:51 2015 13 // Update Count : 5 14 14 // 15 15 … … 27 27 28 28 context writeable( type T ) { 29 forall( dtype ostype | ostream( ostype ) ) ostype * ? |?( ostype *, T );29 forall( dtype ostype | ostream( ostype ) ) ostype * ?<<?( ostype *, T ); 30 30 }; 31 31 32 32 // implement writable for some intrinsic types 33 33 34 forall( dtype ostype | ostream( ostype ) ) ostype * ?|?( ostype *, char ); 35 forall( dtype ostype | ostream( ostype ) ) ostype * ?|?( ostype *, int ); 36 forall( dtype ostype | ostream( ostype ) ) ostype * ?|?( ostype *, double ); 37 forall( dtype ostype | ostream( ostype ) ) ostype * ?|?( ostype *, const char * ); 38 forall( dtype ostype | ostream( ostype ) ) ostype * ?|?( ostype *, const void * ); 39 40 forall( dtype ostype, dtype retostype | ostream( ostype ) | ostream( retostype ) ) retostype * ?|?( ostype *os, retostype * (* manip)(ostype*) ); 41 forall( dtype ostype | ostream( ostype ) ) ostype * endl( ostype * ); 34 forall( dtype ostype | ostream( ostype ) ) ostype * ?<<?( ostype *, char ); 35 forall( dtype ostype | ostream( ostype ) ) ostype * ?<<?( ostype *, int ); 36 forall( dtype ostype | ostream( ostype ) ) ostype * ?<<?( ostype *, double ); 37 forall( dtype ostype | ostream( ostype ) ) ostype * ?<<?( ostype *, const char * ); 38 forall( dtype ostype | ostream( ostype ) ) ostype * ?<<?( ostype *, void * ); 42 39 43 40 // writes the range [begin, end) to the given stream … … 52 49 void write_reverse( iterator_type begin, iterator_type end, os_type *os ); 53 50 54 //******************************************************************************55 51 56 52 context istream( dtype istype ) { … … 62 58 63 59 context readable( type T ) { 64 forall( dtype istype | istream( istype ) ) istype * ? |?( istype *, T );60 forall( dtype istype | istream( istype ) ) istype * ?<<?( istype *, T ); 65 61 }; 66 62 67 63 forall( dtype istype | istream( istype ) ) 68 istype * ? |?( istype *, char * );64 istype * ?>>?( istype *, char * ); 69 65 70 66 forall( dtype istype | istream( istype ) ) 71 istype * ? |?( istype *, int * );67 istype * ?>>?( istype *, int * ); 72 68 73 69 #endif // IOSTREAM_H
Note:
See TracChangeset
for help on using the changeset viewer.