Ignore:
Timestamp:
Jan 8, 2016, 10:37:10 PM (9 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, string, with_gc
Children:
61f9356
Parents:
1cced28
Message:

fix recursive include bug in shadow includes, major clean of examples, add several long long routines to prelude

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/examples/swap.c

    r1cced28 r784deab  
    1010// Created On       : Wed May 27 17:56:53 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Wed May 27 18:34:47 2015
    13 // Update Count     : 1
     12// Last Modified On : Mon Jan  4 11:32:25 2016
     13// Update Count     : 5
    1414//
    1515
    16 extern "C" {
    17         int printf( const char *, ... );
    18 }
     16#include "fstream.h"
    1917
    2018forall( type T )
     
    2523}
    2624
    27 int main() {
     25int main( void ) {
    2826        int x = 1, y = 2;
    29         printf( "%d %d\n", x, y );
     27        ofstream *sout = ofstream_stdout();
     28        sout | x | ' ' | y | endl;
    3029        swap( &x, &y );
    31         printf( "%d %d\n", x, y );
     30        sout | x | ' ' | y | endl;
    3231}
    3332
    3433// Local Variables: //
    3534// tab-width: 4 //
    36 // compile-command: "cfa swap.c" //
     35// compile-command: "cfa swap.c fstream.o iostream.o iterator.o" //
    3736// End: //
Note: See TracChangeset for help on using the changeset viewer.