@@ -29,7 +29,7 @@ struct FloatTraits<T, 8 /*64bits*/> {
2929 using exponent_type = int16_t ;
3030 static const exponent_type exponent_max = 308 ;
3131
32- static pgm_ptr<T > positiveBinaryPowersOfTen () {
32+ static pgm_array<T, 9 > positiveBinaryPowersOfTen () {
3333 ARDUINOJSON_DEFINE_PROGMEM_ARRAY ( //
3434 uint64_t , factors,
3535 {
@@ -43,10 +43,10 @@ struct FloatTraits<T, 8 /*64bits*/> {
4343 0x5A827748F9301D32 , // 1e128
4444 0x75154FDD7F73BF3C , // 1e256
4545 });
46- return pgm_ptr<T >(reinterpret_cast <const T*>(factors));
46+ return pgm_array<T, 9 >(reinterpret_cast <const T*>(factors));
4747 }
4848
49- static pgm_ptr<T > negativeBinaryPowersOfTen () {
49+ static pgm_array<T, 9 > negativeBinaryPowersOfTen () {
5050 ARDUINOJSON_DEFINE_PROGMEM_ARRAY ( //
5151 uint64_t , factors,
5252 {
@@ -60,7 +60,7 @@ struct FloatTraits<T, 8 /*64bits*/> {
6060 0x255BBA08CF8C979D , // 1e-128
6161 0x0AC8062864AC6F43 // 1e-256
6262 });
63- return pgm_ptr<T >(reinterpret_cast <const T*>(factors));
63+ return pgm_array<T, 9 >(reinterpret_cast <const T*>(factors));
6464 }
6565
6666 static T nan () {
@@ -113,7 +113,7 @@ struct FloatTraits<T, 4 /*32bits*/> {
113113 using exponent_type = int8_t ;
114114 static const exponent_type exponent_max = 38 ;
115115
116- static pgm_ptr<T > positiveBinaryPowersOfTen () {
116+ static pgm_array<T, 6 > positiveBinaryPowersOfTen () {
117117 ARDUINOJSON_DEFINE_PROGMEM_ARRAY (uint32_t , factors,
118118 {
119119 0x41200000 , // 1e1f
@@ -123,10 +123,10 @@ struct FloatTraits<T, 4 /*32bits*/> {
123123 0x5a0e1bca , // 1e16f
124124 0x749dc5ae // 1e32f
125125 });
126- return pgm_ptr<T >(reinterpret_cast <const T*>(factors));
126+ return pgm_array<T, 6 >(reinterpret_cast <const T*>(factors));
127127 }
128128
129- static pgm_ptr<T > negativeBinaryPowersOfTen () {
129+ static pgm_array<T, 6 > negativeBinaryPowersOfTen () {
130130 ARDUINOJSON_DEFINE_PROGMEM_ARRAY (uint32_t , factors,
131131 {
132132 0x3dcccccd , // 1e-1f
@@ -136,7 +136,7 @@ struct FloatTraits<T, 4 /*32bits*/> {
136136 0x24e69595 , // 1e-16f
137137 0x0a4fb11f // 1e-32f
138138 });
139- return pgm_ptr<T >(reinterpret_cast <const T*>(factors));
139+ return pgm_array<T, 6 >(reinterpret_cast <const T*>(factors));
140140 }
141141
142142 static T forge (uint32_t bits) {
0 commit comments