RE: [xsl] RE: xslt and bitwise operations

Subject: RE: [xsl] RE: xslt and bitwise operations
From: "Clapham, Paul" <pclapham@xxxxxxxxxxxxx>
Date: Wed, 10 Jan 2001 15:48:56 -0800
Not directly, but it does support the arithmetic operations "div" and "mod"
that you can use to simulate bitwise calculations.  For example, to extract
the low-order bit from x you could use "x mod 2", and to extract the bit to
the left of that you could use "floor(x div 2) mod 2" and like that.

Extracting more than one bit at a time using a mask (e.g. "x and 17") is
Left As An Exercise For The Student.


-----Original Message-----
From: Hahn, Kimberly [mailto:Kim.Hahn@xxxxxxxxxx]

Does anyone know if XSLT supports bitwise calculations (ex. '2 and 34'
evaluates to 2 or True)?  From what I have been able to tell 'and' and 'or'
expressions do not apply bitwise operations.  Are there other functions
available that do this?

 XSL-List info and archive:

Current Thread