Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/examples/it_out.c

    rb63e376 r86bd7c1f  
    1010// Created On       : Wed May 27 17:56:53 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Tue Mar  8 22:14:39 2016
    13 // Update Count     : 8
     12// Last Modified On : Wed May 27 18:41:23 2015
     13// Update Count     : 4
    1414//
    1515
    1616typedef unsigned long streamsize_type;
    1717
    18 trait ostream( dtype os_type ) {
     18context ostream( dtype os_type ) {
    1919        os_type *write( os_type *, const char *, streamsize_type );
    2020        int fail( os_type * );
    2121};
    2222
    23 trait writeable( otype T ) {
     23context writeable( type T ) {
    2424        forall( dtype os_type | ostream( os_type ) ) os_type * ?<<?( os_type *, T );
    2525};
     
    2929forall( dtype os_type | ostream( os_type ) ) os_type * ?<<?( os_type *, const char * );
    3030
    31 trait istream( dtype is_type ) {
     31context istream( dtype is_type ) {
    3232        is_type *read( is_type *, char *, streamsize_type );
    3333        is_type *unread( is_type *, char );
     
    3636};
    3737
    38 trait readable( otype T ) {
     38context readable( type T ) {
    3939        forall( dtype is_type | istream( is_type ) ) is_type * ?<<?( is_type *, T );
    4040};
     
    4343forall( dtype is_type | istream( is_type ) ) is_type * ?>>?( is_type *, int* );
    4444
    45 trait iterator( otype iterator_type, otype elt_type ) {
     45context iterator( type iterator_type, type elt_type ) {
    4646        iterator_type ?++( iterator_type* );
    4747        iterator_type ++?( iterator_type* );
     
    5252};
    5353
    54 forall( otype elt_type | writeable( elt_type ),
    55                 otype iterator_type | iterator( iterator_type, elt_type ),
     54forall( type elt_type | writeable( elt_type ),
     55                type iterator_type | iterator( iterator_type, elt_type ),
    5656                dtype os_type | ostream( os_type ) )
    5757void write_all( iterator_type begin, iterator_type end, os_type *os );
    5858
    59 forall( otype elt_type | writeable( elt_type ),
    60                 otype iterator_type | iterator( iterator_type, elt_type ),
     59forall( type elt_type | writeable( elt_type ),
     60                type iterator_type | iterator( iterator_type, elt_type ),
    6161                dtype os_type | ostream( os_type ) )
    6262void write_all( elt_type begin, iterator_type end, os_type *os ) {
Note: See TracChangeset for help on using the changeset viewer.