I don't think that makes mkstemp obsolete as it may be important to have named temp files.
(and of course though there is a slight race you can unlink the file you get through mkstemp while keeping it open, that seems to be the strategy used by python's tempfile.TemporaryFile)