({1,2,3,4,1,2}) ^ ({1,2})
gives
({3,4,1,2})
I was expecting ({3,4}), I guess there is a good reason behind it but I can't figure it out :)
It operates on arrays, not sets.
/ Johan Sundström (a hugging punishment!)
Previous text:
2003-02-04 12:46: Subject: Xor
({1,2,3,4,1,2}) ^ ({1,2})
gives
({3,4,1,2})
I was expecting ({3,4}), I guess there is a good reason behind it but I can't figure it out :)
/ Peta, jo det är jag
This has been discussed earlier, and I distinctly remember that it was actually fixed to be equivalent, but apparantly it has been de-fixed sometime since then. :-)
/ Per Hedbor ()
Previous text:
2003-02-04 13:51: Subject: Xor
But `- removes all matching elements - why not `^?
I would have expected a^b to be similar to (a-b)+(b-a).
/ Mirar
Also known as the penalty for not solidifying a fix in the testsuite.
/ Johan Sundström (a hugging punishment!)
Previous text:
2003-02-04 13:56: Subject: Xor
This has been discussed earlier, and I distinctly remember that it was actually fixed to be equivalent, but apparantly it has been de-fixed sometime since then. :-)
/ Per Hedbor ()
Will anything break if the behaviour changed now? Or is the behaviour wanted in some way? Or is it hard to implement? Else, I'll add that to the testsuite for mappings, arrays and multisets, and check around what can be done about it.
/ Mirar
Previous text:
2003-02-04 13:51: Subject: Xor
But `- removes all matching elements - why not `^?
I would have expected a^b to be similar to (a-b)+(b-a).
/ Mirar
For multisets, I'd say that the current behaviour is correct,
(<1,1,2>) ^ (<1>);
(2) Result: (< /* 2 elements */ 1, 2 >)
Let #X denote the number of occurances of a given element in X, then it makes sense to have
#(A ^ B) == #A + #B (mod 2)
just like above. But I don't know whether or not it's desirable to have arrays behave as multisets for this operation.
/ Niels Möller ()
Previous text:
2003-02-05 15:15: Subject: Xor
Will anything break if the behaviour changed now? Or is the behaviour wanted in some way? Or is it hard to implement? Else, I'll add that to the testsuite for mappings, arrays and multisets, and check around what can be done about it.
/ Mirar
If that is correct, wouldn't
(<1,1,2>) - (<1>) = (<1,2>)
Let #X denote the number of occurances of a given element in X, then it makes sense to have
#(A ^ B) == #A + #B (mod 2)
( #A + #B ) mod 2, you mean? I think can agree to that. However, that would mean that (<1,1>)^(<2,2>) = (<>), and (<1,1,1>)^(<>) = (<1>), which might be confusing.
I just think that a^b should equal (a-b)+(b-a). If a-b removes one element in a per element in b (fixing - instead of ^), this becomes true with the above behaviour (again). Possibly could multisets and arrays behave differently here, arrays removing all matching while multisets remove one element for each matching element.
/ Mirar
Previous text:
2003-02-05 15:29: Subject: Xor
For multisets, I'd say that the current behaviour is correct,
(<1,1,2>) ^ (<1>);
(2) Result: (< /* 2 elements */ 1, 2 >)
Let #X denote the number of occurances of a given element in X, then it makes sense to have
#(A ^ B) == #A + #B (mod 2)
just like above. But I don't know whether or not it's desirable to have arrays behave as multisets for this operation.
/ Niels Möller ()
Depends on what `- is used for. I guess the common use is to clear out all elements.
Having (<1,1,2>) - (<1>) = (<1,2>) would be kind of nice, but then one would need some other operation for deleteing all the ones. m - (<1,1,1,1,1,1,1,1,1>) or m - sizeof(m) * (<1>) isn't particularly pretty.
BTW, why doesn't int * multiset work?
/ Niels Möller ()
Previous text:
2003-02-05 16:33: Subject: Xor
If that is correct, wouldn't
(<1,1,2>) - (<1>) = (<1,2>)
Let #X denote the number of occurances of a given element in X, then it makes sense to have
#(A ^ B) == #A + #B (mod 2)
( #A + #B ) mod 2, you mean? I think can agree to that. However, that would mean that (<1,1>)^(<2,2>) = (<>), and (<1,1,1>)^(<>) = (<1>), which might be confusing.
I just think that a^b should equal (a-b)+(b-a). If a-b removes one element in a per element in b (fixing - instead of ^), this becomes true with the above behaviour (again). Possibly could multisets and arrays behave differently here, arrays removing all matching while multisets remove one element for each matching element.
/ Mirar
What is `^ used for? Maybe we should drop it until the use can define how it should work. :)
/ Mirar
Previous text:
2003-02-05 17:16: Subject: Xor
Depends on what `- is used for. I guess the common use is to clear out all elements.
Having (<1,1,2>) - (<1>) = (<1,2>) would be kind of nice, but then one would need some other operation for deleteing all the ones. m - (<1,1,1,1,1,1,1,1,1>) or m - sizeof(m) * (<1>) isn't particularly pretty.
BTW, why doesn't int * multiset work?
/ Niels Möller ()
I have been wondering why the index operations on multisets work like they do:
| > multiset v=(<1,1,1>); | > v[1]; | Result: 1 | > v[1]=0; | Result: 0 | > v; | Result: (<1,1>)
This could of course be used to do a `- that removes one for one:
multiset res=copy_value(v); foreach (v;mixed elem;) res[elem]=0; // remove one
But why doesn't v[1] return 3 above, and remove all the elements with v[1]=0?
It would also be much more useful to do v[1]=17 to get 17 of element 1. You can't, however, even add elements using that method now:
| > v[1]=17; | Result: 17 | > v; | Result: (<1,1>) | > v[1]=1; | Result: 1 | > v; | Result: (<1,1>)
How much would break if we fixed this behaviour, so that
multiset v=(<1,1,1>); v[1] == 3 v[1]=0 => v==(<>) v[1]=17 => v==(<1,1,1,1...1,1>) /* 17 elements */
Sidenote: This code works for the above `- for both the current and my suggestion:
multiset res=copy_value(v); foreach (v;mixed elem;int n) res[elem]-=n; // remove n
/ Mirar
Previous text:
2003-02-05 17:16: Subject: Xor
Depends on what `- is used for. I guess the common use is to clear out all elements.
Having (<1,1,2>) - (<1>) = (<1,2>) would be kind of nice, but then one would need some other operation for deleteing all the ones. m - (<1,1,1,1,1,1,1,1,1>) or m - sizeof(m) * (<1>) isn't particularly pretty.
BTW, why doesn't int * multiset work?
/ Niels Möller ()
Personally, I don't quite understood why we have multisets at all. In principle, a multiset is the same thing as a mixed:int(0,...) mapping.
/ Niels Möller ()
Previous text:
2003-02-06 10:12: Subject: Xor
I have been wondering why the index operations on multisets work like they do:
| > multiset v=(<1,1,1>); | > v[1]; | Result: 1 | > v[1]=0; | Result: 0 | > v; | Result: (<1,1>)
This could of course be used to do a `- that removes one for one:
multiset res=copy_value(v); foreach (v;mixed elem;) res[elem]=0; // remove one
But why doesn't v[1] return 3 above, and remove all the elements with v[1]=0?
It would also be much more useful to do v[1]=17 to get 17 of element 1. You can't, however, even add elements using that method now:
| > v[1]=17; | Result: 17 | > v; | Result: (<1,1>) | > v[1]=1; | Result: 1 | > v; | Result: (<1,1>)
How much would break if we fixed this behaviour, so that
multiset v=(<1,1,1>); v[1] == 3 v[1]=0 => v==(<>) v[1]=17 => v==(<1,1,1,1...1,1>) /* 17 elements */
Sidenote: This code works for the above `- for both the current and my suggestion:
multiset res=copy_value(v); foreach (v;mixed elem;int n) res[elem]-=n; // remove n
/ Mirar
That's what I thought too, but I don't know if we have that, since there currently is no way to look up the "value".
Only when looping over multisets you can see that they are a multiset,
| > v=(<1,1,1,2,2,3>); | > foreach (v;int i;) werror("%d\n",i); | 1 | 1 | 1 | 2 | 2 | 3
as far as I can see. Using the index operator, it's not very multi.
And +, -, |, & and ^ doesn't all give that logical results:
(<1,1,1,2,2,3>)+(<1,3>) gives (<1,1,1,1,2,2,3,3>), (<1,1,1,2,2,3>)-(<1,3>) gives (<2,2>), (<1,1,1,2,2,3>)|(<1,3>) gives (<1,1,1,2,2,3>), (<1,1,1,2,2,3>)&(<1,3>) gives (<1,3>), (<1,1,1,2,2,3>)^(<1,3>) gives (<1,1,2,2>)
/ Mirar
Previous text:
2003-02-06 11:00: Subject: Xor
Personally, I don't quite understood why we have multisets at all. In principle, a multiset is the same thing as a mixed:int(0,...) mapping.
/ Niels Möller ()
Of those operators, I think +, | and & make the most sense. If you think about the multisets as mappings with integer values, they are simply addition, max and min of corresponding values. ^ and - are a lot more questionable.
/ Niels Möller ()
Previous text:
2003-02-06 12:34: Subject: Xor
That's what I thought too, but I don't know if we have that, since there currently is no way to look up the "value".
Only when looping over multisets you can see that they are a multiset,
| > v=(<1,1,1,2,2,3>); | > foreach (v;int i;) werror("%d\n",i); | 1 | 1 | 1 | 2 | 2 | 3
as far as I can see. Using the index operator, it's not very multi.
And +, -, |, & and ^ doesn't all give that logical results:
(<1,1,1,2,2,3>)+(<1,3>) gives (<1,1,1,1,2,2,3,3>), (<1,1,1,2,2,3>)-(<1,3>) gives (<2,2>), (<1,1,1,2,2,3>)|(<1,3>) gives (<1,1,1,2,2,3>), (<1,1,1,2,2,3>)&(<1,3>) gives (<1,3>), (<1,1,1,2,2,3>)^(<1,3>) gives (<1,1,2,2>)
/ Mirar
Yes, I agree on that. Those operators make sense.
`^ uses PIKE_ARRAY_OP_XOR which is "PIKE_MINTERM(PIKE_ARRAY_OP_TAKE_A,PIKE_ARRAY_OP_SKIP_A | PIKE_ARRAY_OP_SKIP_B,PIKE_ARRAY_OP_TAKE_B)", (PIKE_MINTERM defining a bitfield), which I can't see that clearly what it does.
`- on multisets ought to fill these criteria, I think: (a+b)-b == a a^b=(a-b)+(b-a)
And since `+ makes sense, `- ought to remove one element for every matching element in the multiset. Then the current behaviour of `^ makes sense:
(<1,1,1,2,2,3>)^(<1,3>);
(5) Result: (< 1, 1, 2, 2 >)
where (<1,1,1,2,2,3>)^(<1,3>) == (<1,1,2,2>)+(<>).
/ Mirar
Previous text:
2003-02-06 12:43: Subject: Xor
Of those operators, I think +, | and & make the most sense. If you think about the multisets as mappings with integer values, they are simply addition, max and min of corresponding values. ^ and - are a lot more questionable.
/ Niels Möller ()
That's a convincing argument. One misght still want a way to delete selected elements completely. Something like a = a & ~(<1,2>) to delete all 1s and 2s.
/ Niels Möller ()
Previous text:
2003-02-06 13:09: Subject: Xor
Yes, I agree on that. Those operators make sense.
`^ uses PIKE_ARRAY_OP_XOR which is "PIKE_MINTERM(PIKE_ARRAY_OP_TAKE_A,PIKE_ARRAY_OP_SKIP_A | PIKE_ARRAY_OP_SKIP_B,PIKE_ARRAY_OP_TAKE_B)", (PIKE_MINTERM defining a bitfield), which I can't see that clearly what it does.
`- on multisets ought to fill these criteria, I think: (a+b)-b == a a^b=(a-b)+(b-a)
And since `+ makes sense, `- ought to remove one element for every matching element in the multiset. Then the current behaviour of `^ makes sense:
(<1,1,1,2,2,3>)^(<1,3>);
(5) Result: (< 1, 1, 2, 2 >)
where (<1,1,1,2,2,3>)^(<1,3>) == (<1,1,2,2>)+(<>).
/ Mirar
Hm. Inverted sets. That would actually be useful, and not all that hard to implement either. :-)
/ Per Hedbor ()
Previous text:
2003-02-06 13:33: Subject: Xor
That's a convincing argument. One misght still want a way to delete selected elements completely. Something like a = a & ~(<1,2>) to delete all 1s and 2s.
/ Niels Möller ()
As said before, an ordinary multiset can be viewed as a mapping that assigns a non-negative integer to each object, and which assigns the value zero to all but a finite number of objects (i.e. zero is the default value).
An inverted multiset can be viewed as a mapping that assigns a non-negative number, or the special value +infinity, and with +infinity as the default value. I.e. there are only a finite number of objects with a value less than +infinity. Note that *both* zero and +infinity can occur, so one can't just change the meaning of zero.
/ Niels Möller ()
Previous text:
2003-02-06 13:36: Subject: Xor
Hm. Inverted sets. That would actually be useful, and not all that hard to implement either. :-)
/ Per Hedbor ()
Would ~(< 1 >)[1] return (infinity-1) or 0? And ~(< 1,1 >)[1] (infinity-2)?
It would probably be more useful to view multisets as sets when negating them. I think. That is, (~(< 1 >))[1] is 0.
/ Per Hedbor ()
Previous text:
2003-02-06 14:00: Subject: Xor
As said before, an ordinary multiset can be viewed as a mapping that assigns a non-negative integer to each object, and which assigns the value zero to all but a finite number of objects (i.e. zero is the default value).
An inverted multiset can be viewed as a mapping that assigns a non-negative number, or the special value +infinity, and with +infinity as the default value. I.e. there are only a finite number of objects with a value less than +infinity. Note that *both* zero and +infinity can occur, so one can't just change the meaning of zero.
/ Niels Möller ()
How about if (~(<1>))[1] == ~((<1>)[1])? :)
/ Mirar
Previous text:
2003-02-06 14:04: Subject: Xor
Would ~(< 1 >)[1] return (infinity-1) or 0? And ~(< 1,1 >)[1] (infinity-2)?
It would probably be more useful to view multisets as sets when negating them. I think. That is, (~(< 1 >))[1] is 0.
/ Per Hedbor ()
Then you treat it like a set, the easy way. :)
I guess doing it any other way would need multisets to store the values rather then repeating the elements.
/ Mirar
Previous text:
2003-02-06 14:13: Subject: Xor
It's more like
(~(<1>))[1] == !((<1>)[1])
To bad we can't use ! instead of ~ for this inversion operation.
/ Niels Möller ()
To me it would make sense to have multisets like "a occurs once, b occurs five times, c zero times, all other +infinity times". You could construct that as
m = ~(<a,b,c>) + (<a, b, b, b, b, b>)
m is an inverted multiset (ie. the default value is +infinity, not zero), but it has elements of multiplicity 0, 1, 5 and +infinity. So you need something similar to a multiset to implement it.
/ Niels Möller ()
Previous text:
2003-02-06 14:17: Subject: Xor
Then you treat it like a set, the easy way. :)
I guess doing it any other way would need multisets to store the values rather then repeating the elements.
/ Mirar
Negation should probably work such that
(~(<1>))[1] = 0 (~(<1>))[2] = infinity
So ~ transforms the element counts as 0 --> infty, x --> 0 if x != 0.
You'd also have
m = ~(<1>) & (<1, 2, 2, 3>); m[1] == 0 m[2] == 1 // Really the count is 2 m[3] == 1 m[4] == +infinity
m & ~~(<1,2,3>) == (<2,2,3>)
/ Niels Möller ()
Previous text:
2003-02-06 14:04: Subject: Xor
Would ~(< 1 >)[1] return (infinity-1) or 0? And ~(< 1,1 >)[1] (infinity-2)?
It would probably be more useful to view multisets as sets when negating them. I think. That is, (~(< 1 >))[1] is 0.
/ Per Hedbor ()
Considering the current results from `[] on multisets, they would return 0 or 1, regardless on how many times the element is repeated.
What would
foreach ( ~(<1>); int i; ) ...
do?
/ Mirar
Previous text:
2003-02-06 14:04: Subject: Xor
Would ~(< 1 >)[1] return (infinity-1) or 0? And ~(< 1,1 >)[1] (infinity-2)?
It would probably be more useful to view multisets as sets when negating them. I think. That is, (~(< 1 >))[1] is 0.
/ Per Hedbor ()
Set i to 0 2 3 4 ... <to infinity>
/ Per Hedbor ()
Previous text:
2003-02-06 14:19: Subject: Xor
Considering the current results from `[] on multisets, they would return 0 or 1, regardless on how many times the element is repeated.
What would
foreach ( ~(<1>); int i; ) ...
do?
/ Mirar
First all positive integers, then all negative integers, then floats, then strings, and then the objects, mappings arrays and multisets.
If we just define that order, my version is correct. :-)
/ Per Hedbor ()
Previous text:
2003-02-06 14:43: Subject: Xor
First we iterate over all integers, then all floats, then all strings.
/ Martin Nilsson (Åskblod)
And programs and types...
/ Martin Nilsson (Åskblod)
Previous text:
2003-02-06 14:44: Subject: Xor
First all positive integers, then all negative integers, then floats, then strings, and then the objects, mappings arrays and multisets.
If we just define that order, my version is correct. :-)
/ Per Hedbor ()
On Thu, 6 Feb 2003, Per Hedbor () @ Pike (-) developers forum wrote:
Hmm, didn't get the start of that thread, but if it is the discussion about creating a test case ... make it so.
First all positive integers, then all negative integers, then floats, then strings, and then the objects, mappings arrays and multisets.
If we just define that order, my version is correct. :-)
/ Per Hedbor ()
Previous text:
2003-02-06 14:43: Subject: Xor
First we iterate over all integers, then all floats, then all strings.
/ Martin Nilsson (Åskblod)
They are just pulling each others legs about how to iterate over an infinite set. :-)
/ Johan Sundström (a hugging punishment!)
Previous text:
2003-02-06 15:03: Subject: Re: Xor
On Thu, 6 Feb 2003, Per Hedbor () @ Pike (-) developers forum wrote:
Hmm, didn't get the start of that thread, but if it is the discussion about creating a test case ... make it so.
First all positive integers, then all negative integers, then floats, then strings, and then the objects, mappings arrays and multisets.
If we just define that order, my version is correct. :-)
/ Per Hedbor ()
Previous text:
2003-02-06 14:43: Subject: Xor
First we iterate over all integers, then all floats, then all strings.
/ Martin Nilsson (Åskblod)
/ Brevbäraren
You have to use some triangularization to make sure that you get all values. Perhaps this is a reasonable ;-) method:
First write an iterator code that generates all strings, starting with the empty string, all one-character strings, all two-character strings, and so on.
Then stack another iterator that runs decode_value on all these strings, if decode_value succeeds, the value is generated as a part of the enumeration.
Try this,
#! /usr/local/bin/pike
int increment(array a) { for (int i = sizeof(a); i; ) { i--; if (++a[i] < 0x100) return 1; a[i] = 0; } return 0; }
int main(int argc, array(string) argv) { for (int l = 0; ;l++) { array a = allocate(l); do { object o; if (!catch (o = decode_value((string)a))) write("%O\n", o); } while (increment(a)); } }
Seems to generate some values, like 0, 0.0, and empty strings, arrays and multisets multiple times, though.
/ Niels Möller ()
Previous text:
2003-02-06 14:44: Subject: Xor
First all positive integers, then all negative integers, then floats, then strings, and then the objects, mappings arrays and multisets.
If we just define that order, my version is correct. :-)
/ Per Hedbor ()
On Thu, Feb 06, 2003 at 03:10:03PM +0100, Niels Möller () @ Pike (-) developers forum wrote:
First write an iterator code that generates all strings, starting with the empty string, all one-character strings, all two-character strings, and so on.
i'd just do sort(indices(~(<1>)) and iterate over that.
greetings, martin.
The point here is that the hypothetical ~(<1>) construction is an *infinite* set. It represents the set of all things that can ever exist, except for the integer 1. (In fact it might be even worse: The multiset that contains an infinite number of each thing that can ever exist, except for the integer 1).
/ Niels Möller ()
Previous text:
2003-02-06 16:48: Subject: Re: Xor
On Thu, Feb 06, 2003 at 03:10:03PM +0100, Niels Möller () @ Pike (-) developers forum wrote:
First write an iterator code that generates all strings, starting with the empty string, all one-character strings, all two-character strings, and so on.
i'd just do sort(indices(~(<1>)) and iterate over that.
greetings, martin.
/ Brevbäraren
I think it would be correct to keep looping over all indices - after all, it's just the values that has changed, not which indices that doesn't have the default value.
Thus, foreach ((<1,2,3>);int i;int v) ... would give i:v 1:1, 2:1, 3:1, and foreach (~(<1,2,3>);int i;int v) ... would give 1:0, 2:0, 3:0.
/ Mirar
Previous text:
2003-02-06 14:42: Subject: Xor
Who's to say? :-) The order of the set is not defined, is it?
/ Per Hedbor ()
Now that you mention it, it does seem like the obvious choice. At the very least, it's the most useful suggestion so far.
/ Johan Sundström (a hugging punishment!)
Previous text:
2003-02-06 17:30: Subject: Xor
I think it would be correct to keep looping over all indices - after all, it's just the values that has changed, not which indices that doesn't have the default value.
Thus, foreach ((<1,2,3>);int i;int v) ... would give i:v 1:1, 2:1, 3:1, and foreach (~(<1,2,3>);int i;int v) ... would give 1:0, 2:0, 3:0.
/ Mirar
I'm more pragmatic and don't think nice mathematical relations per se carry much weight compared to operations that has shown to be useful in practice, such as the current behavior of `-.
The only possible practical use of (a+b)-b == a that I can think of is to perform optimizations, but that's not a good idea partly since it would be applicable extremely seldom and partly because it probably would rule out various custom `+ and `- implementations that are otherwise reasonable.
Whether the current `^ is useful or not I don't know; I've never used it in any case I can remember. Does anyone know a real world example of it? Maybe Peta, who apparently had a case that surprised him?
/ Martin Stjernholm, Roxen IS
Previous text:
2003-02-06 13:33: Subject: Xor
That's a convincing argument. One misght still want a way to delete selected elements completely. Something like a = a & ~(<1,2>) to delete all 1s and 2s.
/ Niels Möller ()
I'm glad that the index operator on multisets only accesses one element even if there are several with the same index. That makes it easier to extend it to hold real values.
In the new implementation (which has a well defined order), the indexing operations (including m_delete) always operate on the last element with the given index. I thought that to be most useful since += can be used to add elements which might be duplicates and the normal indexing operations will default to the last of them. (There will of course also be other utility functions to set and get all values that share the same index.)
See the comment blurbs in rbtree.h and multiset.h for more details of how I've intended the operations. Opinions are welcome; now is a good time to affect it.
/ Martin Stjernholm, Roxen IS
Previous text:
2003-02-06 10:12: Subject: Xor
I have been wondering why the index operations on multisets work like they do:
| > multiset v=(<1,1,1>); | > v[1]; | Result: 1 | > v[1]=0; | Result: 0 | > v; | Result: (<1,1>)
This could of course be used to do a `- that removes one for one:
multiset res=copy_value(v); foreach (v;mixed elem;) res[elem]=0; // remove one
But why doesn't v[1] return 3 above, and remove all the elements with v[1]=0?
It would also be much more useful to do v[1]=17 to get 17 of element 1. You can't, however, even add elements using that method now:
| > v[1]=17; | Result: 17 | > v; | Result: (<1,1>) | > v[1]=1; | Result: 1 | > v; | Result: (<1,1>)
How much would break if we fixed this behaviour, so that
multiset v=(<1,1,1>); v[1] == 3 v[1]=0 => v==(<>) v[1]=17 => v==(<1,1,1,1...1,1>) /* 17 elements */
Sidenote: This code works for the above `- for both the current and my suggestion:
multiset res=copy_value(v); foreach (v;mixed elem;int n) res[elem]-=n; // remove n
/ Mirar
With real values, do you mean like each index has a value of it's own, and thus for instance (<1:3,1:17>) would be possible?
how I've intended the operations. Opinions are welcome; now is a good time to affect it.
That's what I thought. Or rather, the sooner things are determined and fixed, the better. :)
/ Mirar
Previous text:
2003-02-06 16:07: Subject: Xor
I'm glad that the index operator on multisets only accesses one element even if there are several with the same index. That makes it easier to extend it to hold real values.
In the new implementation (which has a well defined order), the indexing operations (including m_delete) always operate on the last element with the given index. I thought that to be most useful since += can be used to add elements which might be duplicates and the normal indexing operations will default to the last of them. (There will of course also be other utility functions to set and get all values that share the same index.)
See the comment blurbs in rbtree.h and multiset.h for more details of how I've intended the operations. Opinions are welcome; now is a good time to affect it.
/ Martin Stjernholm, Roxen IS
Yes, they will have values just like mappings. The difference from mappings is that they got an order and that multiple indices are handled. (The name "multiset" won't be that good anymore but I doubt it's worth the hassle to try to change it. Haven't come up with one that's much better anyway.)
/ Martin Stjernholm, Roxen IS
Previous text:
2003-02-06 17:34: Subject: Xor
With real values, do you mean like each index has a value of it's own, and thus for instance (<1:3,1:17>) would be possible?
how I've intended the operations. Opinions are welcome; now is a good time to affect it.
That's what I thought. Or rather, the sooner things are determined and fixed, the better. :)
/ Mirar
pike-devel@lists.lysator.liu.se