112855Sgabeblack@google.com// Bug 70 - Problems with part selections on sc_biguint. 212855Sgabeblack@google.com 312855Sgabeblack@google.com#include "systemc.h" 412855Sgabeblack@google.com//#include "iomanip.h" 512855Sgabeblack@google.com 612855Sgabeblack@google.comint sc_main(int argc, char* argv[]) 712855Sgabeblack@google.com{ 812855Sgabeblack@google.com sc_biguint< 16 > a, b, c; 912855Sgabeblack@google.com //sc_uint< 16 > a, b ; 1012855Sgabeblack@google.com 1112855Sgabeblack@google.com a = 0x5A6C ; 1212855Sgabeblack@google.com b = 0 ; 1312855Sgabeblack@google.com c = 0 ; 1412855Sgabeblack@google.com 1512855Sgabeblack@google.com cout << "a: " << a.to_string(SC_HEX) << endl ; 1612855Sgabeblack@google.com cout << "b: " << b.to_string(SC_HEX) << " - So far so good" << endl ; 1712855Sgabeblack@google.com cout << "c: " << c.to_string(SC_HEX) << " - So far so good" << endl ; 1812855Sgabeblack@google.com 1912855Sgabeblack@google.com b(7,0) = a(15,8) ; // Now b should be "0x005A" or ??? 2012855Sgabeblack@google.com c = a(15,8) ; // Now c should be "0x005A" or ??? 2112855Sgabeblack@google.com 2212855Sgabeblack@google.com cout << "a: " << a.to_string(SC_HEX) << endl ; 2312855Sgabeblack@google.com cout << "b: " << b.to_string(SC_HEX) << endl ; 2412855Sgabeblack@google.com cout << "c: " << c.to_string(SC_HEX) << endl ; 2512855Sgabeblack@google.com 2612855Sgabeblack@google.com sc_stop() ; 2712855Sgabeblack@google.com return 0; 2812855Sgabeblack@google.com} 2912855Sgabeblack@google.com 30