metaeducation / rebol-issues

6 stars 1 forks source link

Bitset set operations ignore negation state #2365

Open hostilefork opened 5 years ago

hostilefork commented 5 years ago
>> one: make bitset! [1]
== make bitset! #{40}

>> two: make bitset! [2]
== make bitset! #{20}

>> union one two
== make bitset! #{60}

Negation is not taken into account, it acts as if the sets involved were not negated:

>> union one negate two
== make bitset! #{60}

Red says:

red>> union one negate two
== make bitset! [not #{20}]

red>> union negate one negate two
== make bitset! #{FF}