source: translator/examples/hello.c @ c8ffe20b

ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsctordeferred_resndemanglerenumforall-pointer-decaygc_noraiijacob/cs343-translationjenkins-sandboxmemorynew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newstringwith_gc
Last change on this file since c8ffe20b was 134b86a, checked in by Peter A. Buhr <pabuhr@…>, 10 years ago

add compiler flag to driver, update examples, fix unnamed bit fields

  • Property mode set to 100644
File size: 429 bytes
Line 
1// "cfa hello.c fstream.c iostream.o"
2// "cfa -CFA hello.c > hello.i"
3// "cfa hello.i fstream.i iostream.o"
4
5#include "fstream.h"
6
7int main() {
8    ofstream *sout = ofstream_stdout();
9    ifstream *sin = ifstream_stdin();
10    sout << "Bonjour au monde!\n";
11    sout << 3 << " " << 3.5 << " " << 'a' << " " << "abc" << "\n";
12    int i, j, k;
13    sin >> &i >> &j >> &k;
14    sout << "i:" << i << " j:" << j << " k:" << k << "\n";
15}
Note: See TracBrowser for help on using the repository browser.