Changeset d6566c1 for tests/manipulatorsOutput3.cfa
 Timestamp:
 May 6, 2020, 8:54:28 PM (4 years ago)
 Branches:
 ADT, armeh, astexperimental, enum, forallpointerdecay, jacob/cs343translation, master, newast, newastuniqueexpr, pthreademulation, qualifiedEnum
 Children:
 e68d092
 Parents:
 1488f94
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

tests/manipulatorsOutput3.cfa
r1488f94 rd6566c1 52 52 sout  left(wd( 10,40, oct(y) ))  'X'; 53 53 54 y = 123456789;54 y = 01234567; 55 55 sout  left(wd( 45, 49, oct(y) ))  'X'; 56 y = y; 57 sout  wd(0, oct(y))  'Y'; 58 sout  left(wd(0, oct(y)))  'Y'; 56 59 sout  nl; 57 60 … … 66 69 sout  left(wd( 45,49, upcase(hex(x)) ))  'X'; 67 70 68 sout  nl  nl;71 sout  nl; 69 72 70 73 int128 divisor = 0x4b3b4ca85a86c47a; 71 74 divisor <<= 16; 72 75 divisor += 0x98a224000000000; 76 77 // base 2 78 sout  "base 2"; 79 sout  bin(divisor); 80 sout  upcase(bin(divisor)); 81 sout  wd(38, upcase(bin(divisor))); 82 sout  wd(40, upcase(bin(divisor))); 83 sout  wd(40, 38, upcase(bin(divisor))); 84 sout  wd(40, 30, upcase(bin(divisor))); 85 sout  pad0(sign(wd(40, 38, upcase(bin(divisor))))); 86 sout  nl; 87 88 // oct 89 sout  "base 8"; 90 sout  upcase(oct(divisor)); 91 sout  wd(38, upcase(oct(divisor))); 92 sout  wd(40, upcase(oct(divisor))); 93 sout  wd(40, 38, upcase(oct(divisor))); 94 sout  wd(40, 30, upcase(oct(divisor))); 95 sout  pad0(sign(wd(40, 38, upcase(oct(divisor))))); 96 sout  nl; 73 97 74 // base 10 98 // decimal 99 sout  "base 10"; 75 100 sout  divisor; 76 101 sout  wd(2, divisor); … … 87 112 sout  pad0(wd(40, divisor)); 88 113 sout  pad0(sign(wd(40,divisor))); 89 90 // base 2 91 sout  upcase(bin(divisor)); 92 sout  wd(38, upcase(bin(divisor))); 93 sout  wd(40, upcase(bin(divisor))); 94 sout  wd(40, 38, upcase(bin(divisor))); 95 sout  wd(40, 30, upcase(bin(divisor))); 96 sout  pad0(sign(wd(40, 38, upcase(bin(divisor))))); 97 98 // oct 99 sout  upcase(oct(divisor)); 100 sout  wd(38, upcase(oct(divisor))); 101 sout  wd(40, upcase(oct(divisor))); 102 sout  wd(40, 38, upcase(oct(divisor))); 103 sout  wd(40, 30, upcase(oct(divisor))); 104 sout  pad0(sign(wd(40, 38, upcase(oct(divisor))))); 114 sout  nl; 105 115 106 116 // hex 117 sout  "base 16"; 107 118 sout  upcase(hex(divisor)); 108 119 sout  wd(38, upcase(hex(divisor))); … … 111 122 sout  wd(40, 30, upcase(hex(divisor))); 112 123 sout  pad0(sign(wd(40, 38, upcase(hex(divisor))))); 124 sout  nl; 113 125 114 126
Note: See TracChangeset
for help on using the changeset viewer.