I just found myself in execScan.c. I noticed that tlist_matches_tupdesc() is a bit wasteful in some cases as it goes to the trouble of matching the tlist to the TupleDesc item by item until it runs out of tlist items or finds a non-match. Once the loop completes it ensures that all tlist items were consumed, so basically in other words, it checks the lengths match.
I think likely this was just not made optimal originally in d0b4399 when the length property etc were added to List
The attached patch adds a fast path so that no list items are compared if the lengths don't match.