Kauê Hunnicutt Bazilli
Kauê Hunnicutt Bazilli
Version without operators: ```prolog ?- Z = a(b(Z,Z), Z), Z =.. X, X = [a, b(Z,Z), Z]. Z = a(b(Z,Z),Z), X = [a,b(a(Z,a(b(Z,Z),Z)),b(a(b(Z,Z),Z),a(b(Z,Z),Z))),a(b(Z,Z),Z)]. ?- [a,b(a(Z,a(b(Z,Z),Z)),b(a(b(Z,Z),Z),a(b(Z,Z),Z))),a(b(Z,Z),Z)] = [a,b(Z,Z),Z]. false. ``` "Pretty...
``` ?- Z = a(b(Z,Z), Z), Z =.. X, X = [a, b(A,B), Z]. Z = a(b(Z,Z),Z), % X is still equivalent to [a, b(a(Z,Z),b(Z,Z)), Z] here, unexpected. X =...
Yeah, I also think that rational numbers being simply a special composite term is a more friendly extension to the ISO Standard than inventing a new literal like `1r2` that...
Well, this is also problematic, because the intent of `write_canonical/1` (at least as I understand it) is to make a representation that can always be read back with the same...
Let me give examples of how my two suggestions would look like. # 1: Rational numbers as composite terms This is the one that makes the most sense to me....
> I wasn't addressing write_canonical output, just the top-level results display. Makes sense, and that is a very good way to represent the "internal state" that I talked about that...
But can this canonical representation be faithfully read back? ``` ?- X is 1 rdiv 3, X = 0r1/3. true. ``` That would be the kind of thing I was...
Is there any way of making a test in `machine::compiler` or other appropriate place that is smaller, self contained (in the sense that it doesn't need to have the whole...
I was going to ask exactly for this feature actually! This works specially nice with warnings as comments, and I think it may also make the experience with ediprolog and...
> The issue here is that one or more answer descriptions can follow a query [...] Oh, so it's support also for things like this and not only actual outputs...