Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!hc!lll-winken!uunet!mcvax!hp4nl!botter!star.cs.vu.nl!maart From: maart@cs.vu.nl (Maarten Litmaath) Newsgroups: comp.unix.questions Subject: Re^2: Bit Switching - How? Keywords: bits, flip Message-ID: <2255@solo5.cs.vu.nl> Date: 6 Apr 89 17:59:58 GMT References: <1138@uvm-gen.UUCP> <9977@smoke.BRL.MIL> <2345@van-bc.UUCP> Organization: V.U. Informatica, Amsterdam, the Netherlands Lines: 9 sl@van-bc.UUCP (pri=-10 Stuart Lynne) writes: \For fast generic swapping I use: \#define swap(a,b) {a^=b;b^=a;a^= b;} Generic? How about floats? -- "If it isn't aesthetically pleasing, |Maarten Litmaath @ VU Amsterdam: it's probably wrong." (jim@bilpin). |maart@cs.vu.nl, mcvax!botter!maart