xkcd #3204: Dinosaurs And Non-Dinosaurs
Title text:
Staplers are actually in Pseudosuchia, making them more closely related to crocodiles than to dinosaurs.
Transcript:
Transcript will show once it’s been added to explainxkcd.com
Source: https://xkcd.com/3204/


That one I’m not entirely sure about, but it seems that, in the same way being a mammal (from a bone perspective) is all about the teeth and inner ear, being a dinosaur is all about the hips (dinosaurs have an upright stance, with the legs under their bodies; even with the quadruped ones you can see how they’re really something evolved to walk on its hind legs walking on its hands and feet), and pterosaurs and their non-dinosaur ancestors just don’t have the right kind of hip.
It’s a bit muddy, though. Once you get into archosaurs and before you get into more specialised things like crocodiles, dinosaurs, or pterosaurs it’s mostly “this thing seems to be more closely related to this group than to this other group, so we’ll throw it in with them even if it doesn’t really look anything like them”.
There’s a small bipedal reptile, for instance, scleromuchlus, that’s been bundled up with pterosaurs because it apparently seems more related to them, even though if you look at an artist’s representation you’d assume it must be a dinosaur, but might in fact not fit in either group and be instead just a basal avemetatarsalian (or maybe even lower in the tree) with no other identified close relatives.