"Carl Gundel" <ca...@psychesystems.com> writes: > “If there are contradictions in the design, the program shouldn't > compile.” > > > > How can a compiler know how to make sense of domain specific > contradictions? I can only imagine the challenges we would face if > compilers operated in this way.
Contradictions are often not really contradictions. It's a question of representation, that is, of mapping of the "domain", to some other "domain", usually a formal system. Now we know that a given formal system cannot be at the same time complete and consistent, but nothing prevents an automatic system to work with an incomplete system or an inconsistent system (or even a system that's both incomplete and inconsistent). The only thing, is that sometimes you may reach conclusions such as 1=2, but if you expect them, you can deal with them. We do everyday. Notably, by modifying the mapping between the domain and the formal system: for different parts of the domain, you can use different formal systems, or avoid some axioms or theorems leading to a contradiction, to find some usable conclusion. Daily, we use formal rules, that are valid just in some context. The conclusions we reach can easily be invalidated, if the context is wrong for the application of those rules. If we tried to take into account all the possible rules, we'd get soon enough inconsistencies. But by restricting the mapping of the domain to some contextual rules, we can read usable conclusions (most of the time). When the conclusion doesn't match the domain, we may ask where the error is, and often it's just the context that was wrong, not the rules. We will have to embrace Artifical Intelligence, even in compilers, eventually. -- __Pascal Bourguignon__ http://www.informatimago.com/ A bad day in () is better than a good day in {}. _______________________________________________ fonc mailing list fonc@vpri.org http://vpri.org/mailman/listinfo/fonc