Your brilliant AI calls another low level function to get the file size on the file name. (also did worse stuff but let's not go into details).
Do you call reading the file size from the in memory structure that you already have a speed optimization? I call it common sense.
It's so funny how these AI bros make excuse after excuse for glaring issues rather than just accept AI doesn't actually understand what it's doing (not even considering it's faster to just write good quality code on the first try).
Stuff that google search from 10 years ago would have done without pretending it's "AI". But not google search from this year.
* it wasn't able to simply list the fields of the returned structure that contained a directory entry. But since it gave me the name, i was able to look it up via plain search.
Its less funny when you realize how few of these people even have experience reading and writing code.
They just see code on screen, trust the machine and proclaim victory.
because that is what the market is trying to sell?