Re: Remarks on SWI 7
Alan Baljeu <[email protected]>
| Newsgroups | gmane.comp.ai.prolog.swi |
|---|---|
| Message-ID | <[email protected]> |
Ulrich: >Jan Wielemaker: >>A standard that _prescribes_ that length(2,0) should fail silently is >>something I refuse to take seriously. So yes, it is another issue. > >On the other hand you leave out many list checks in many places - not >even consistently - and sometimes add errors not described in the >standard. Your main argument being (against checks), that these tests >are so costly. So people cannot anticipate what will happen without >trying SWI or studying its source code. Or they just od the right >thing without ever getting errors. To the working programmer this 100% isn't an issue, because I won't write code with anything other than length(List, Int). If I accidentally do I spot the error and rewrite. So adding a 3rd clause to length as "length(_,_) :- throw" is merely helpful and never harmful because *nobody* wants to use length on integers. So yes it's non-compliant, but focus your efforts where it has an impact.