Changeset 17a1b21
- Timestamp:
- Mar 5, 2019, 8:45:24 AM (6 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, persistent-indexer, pthread-emulation, qualifiedEnum
- Children:
- ca0f061f
- Parents:
- 0050a5f
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/iostream.cfa
r0050a5f r17a1b21 10 10 // Created On : Wed May 27 17:56:53 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Mon Dec 24 18:33:40 201813 // Update Count : 5 8912 // Last Modified On : Mon Mar 4 20:57:24 2019 13 // Update Count : 593 14 14 // 15 15 … … 27 27 28 28 forall( dtype ostype | ostream( ostype ) ) { 29 ostype & ?|?( ostype & os, zero_t ) { 30 if ( sepPrt( os ) ) fmt( os, "%s", sepGetCur( os ) ); 31 fmt( os, "%d", 0n ); 32 return os; 33 } // ?|? 34 void ?|?( ostype & os, zero_t z ) { 35 (ostype &)(os | z); nl( os ); 36 } // ?|? 37 38 ostype & ?|?( ostype & os, one_t ) { 39 if ( sepPrt( os ) ) fmt( os, "%s", sepGetCur( os ) ); 40 fmt( os, "%d", 1n ); 41 return os; 42 } // ?|? 43 void ?|?( ostype & os, one_t o ) { 44 (ostype &)(os | o); nl( os ); 45 } // ?|? 46 29 47 ostype & ?|?( ostype & os, bool b ) { 30 48 if ( sepPrt( os ) ) fmt( os, "%s", sepGetCur( os ) ); -
libcfa/src/iostream.hfa
r0050a5f r17a1b21 10 10 // Created On : Wed May 27 17:56:53 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Mon Dec 24 18:33:40 201813 // Update Count : 22 012 // Last Modified On : Tue Feb 26 16:57:22 2019 13 // Update Count : 221 14 14 // 15 15 … … 62 62 63 63 forall( dtype ostype | ostream( ostype ) ) { 64 ostype & ?|?( ostype &, zero_t ); 65 void ?|?( ostype &, zero_t ); 66 ostype & ?|?( ostype &, one_t ); 67 void ?|?( ostype &, one_t ); 68 64 69 ostype & ?|?( ostype &, bool ); 65 70 void ?|?( ostype &, bool ); -
tests/.expect/io1.txt
r0050a5f r17a1b21 1 1 9 6 28 0 7 1 2 2 1 2 33 1234 1232 0 1 2 3 3 0123 4 0123 5 5 6 6 opening delimiters -
tests/io1.cfa
r0050a5f r17a1b21 10 10 // Created On : Wed Mar 2 16:56:02 2016 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Fri Dec 21 16:02:55 201813 // Update Count : 11 412 // Last Modified On : Mon Mar 4 21:42:47 2019 13 // Update Count : 115 14 14 // 15 15 … … 19 19 int x = 3, y = 5, z = 7; 20 20 sout | x * 3 | y + 1 | z << 2 | x == y | (x | y) | (x || y) | (x > z ? 1 : 2); 21 sout | 1 | 2 | 3;22 sout | ' 1' | '2' | '3';23 sout | 1 | "" | 2 | "" | 3;21 sout | 0 | 1 | 2 | 3; 22 sout | '0' | '1' | '2' | '3'; 23 sout | 0 | "" | 1 | "" | 2 | "" | 3; 24 24 sout | nl; 25 25
Note: See TracChangeset
for help on using the changeset viewer.