To add to this I created builds with and without MICROPY_PY_REVERSE_SPECIAL_METHODS
for Pyboard D SF6W and for ESP8266. On each platform I verified that the reverse special methods only work with the appropriate build. I then tried to figure out exactly what resource is being conserved by disabling them.
On the SF6W the dfu files were exactly the same size, 1_063_685 bytes. Of more interest is free ram, so I issued
Code: Select all
The outcome was 385_488 bytes free with special methods, 385_632 without. A saving of 144 bytes.
Oddly on ESP8266 the free RAM was 36_488 bytes in both cases.
Incidentally my unit test would not run on ESP8266 because math.isclose
doesn't exist on that platform, another undocumented feature