OLD | NEW |
| (Empty) |
1 /// Contains encoding, decoding and detection functionality for the | |
2 /// representation of program data at runtime. | |
3 /// | |
4 /// This library is shared between the compiler and the runtime system. | |
5 library dart2js.runtime_data; | |
6 | |
7 | |
8 String encodeTypedefFieldDescriptor(int typeIndex) { | |
9 return ":$typeIndex;"; | |
10 } | |
11 | |
12 bool isTypedefDescriptor(String descriptor) { | |
13 return descriptor.startsWith(':'); | |
14 } | |
15 | |
16 int getTypeFromTypedef(String descriptor) { | |
17 return int.parse(descriptor.substring(1, descriptor.length - 1)); | |
18 } | |
OLD | NEW |