I created issue #742 to fix this. Maybe the TODO could be more specific, but I'm basically trying to point out that the above code should *never* be used as a reference point :).