Changeset 839ccbb for src/examples/fstream.c
- Timestamp:
- Nov 20, 2015, 4:19:13 PM (9 years ago)
- 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:
- 5189888
- Parents:
- 05587c2 (diff), ed94eac (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - git-author:
- Peter A. Buhr <pabuhr@…> (11/20/15 12:51:58)
- git-committer:
- Peter A. Buhr <pabuhr@…> (11/20/15 16:19:13)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/examples/fstream.c
r05587c2 r839ccbb 10 10 // Created On : Wed May 27 17:56:53 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Wed May 27 18:12:33201513 // Update Count : 212 // Last Modified On : Thu Nov 19 22:43:31 2015 13 // Update Count : 4 14 14 // 15 15 … … 30 30 fwrite( data, size, 1, os->file ); 31 31 os->fail = ferror( os->file ); 32 } 32 } // if 33 33 return os; 34 } 34 } // write 35 35 36 36 int fail( ofstream *os ) { 37 37 return os->fail; 38 } 38 } // fail 39 39 40 40 static ofstream *make_ofstream() { … … 42 42 new_stream->fail = 0; 43 43 return new_stream; 44 } 44 } // make_ofstream 45 45 46 46 ofstream *ofstream_stdout() { … … 48 48 stdout_stream->file = stdout; 49 49 return stdout_stream; 50 } 50 } // ofstream_stdout 51 51 52 52 ofstream *ofstream_stderr() { … … 54 54 stderr_stream->file = stderr; 55 55 return stderr_stream; 56 } 56 } // ofstream_stderr 57 57 58 58 ofstream *ofstream_fromfile( const char *name ) {
Note: See TracChangeset
for help on using the changeset viewer.