This should pass review because there are comments?

We indeed don't know why the code:
- Disables the interrupt upon entry and re-enables it at the end (most MCUs I've ever seen can't retrigger the *same* interrupt while being serviced anyway). Might be an odd MCU, or useless code.
- Indeed setting up the interrupt on change inside the handler doesn't seem to make sense either, unless it's maybe set up differently before the handler is called, but at least one of the edge would be enabled anyway, so it's useless to configure both in the handler.
- Doesn't do anything useful except clear the interrupt flags. (Looks like the only thing actually useful there.) We can assume that's an interrupt handler as it does clear the interrupt flags in there. But maybe it's not.
I wonder where the OP got that piece of code from. Could be fun to know. Might be fully made up to have a laugh. Or maybe code from a coworker.
