Issue #14105 has been updated by gotoken (Kentaro Goto). knu (Akinori MUSHA) wrote: > I'm afraid aliasing `^` to `xor` is not like aliasing `&` to `intersection` and `|` to `union`, because the latter two are the terms defined in the set theory whereas `xor` is (apparently) not. Yep, that is usually called the symmetric difference in elementary set theory. Even so, some text books introduce the relation between them as a¢¤b = {x | x¢ºa x¢ºb} where ¢¤ and stand for symmetric difference and XOR respectively. By the way I recently wrote this set theoretical operation to find all uncommon files in two file collections then I reminded this feature request :) ---------------------------------------- Feature #14105: Introduce xor as alias for Set#^ https://bugs.ruby-lang.org/issues/14105#change-72112 * Author: ana06 (Ana Maria Martinez Gomez) * Status: Assigned * Priority: Normal * Assignee: knu (Akinori MUSHA) * Target version: ---------------------------------------- Not sure if I should also add feautures for the `Set` class here or if I should do it somewhere else. I would like to add a more readable method for the exclusive or, currently as `^` in set. It is in both mathematics, hardware and many other programming languages known as `xor`, so I think this will help to use it. ---Files-------------------------------- firefox.desktop (528 Bytes) -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>