AI does not understand JS's shitty Infinity constant. In most languages ÷0 is an error, but in JS 100/0 === 1/0, and sorts higher than any number, and isNaN(1/0) is false; it's stupid. But LLMs don't get this at all, and keep autocorrecting it in even dumber ways.
Today's AI coding gripe: why does it insist (over and over, in languages that don't coerce types) that "'!(A > B)' can be simplified to 'A <= B'" when A and/or B is nullable? It keeps trying to make this change in C# and breaking code (further down, when calling A.Value but !A.HasValue)
0 reposts0 likes