xref: /csrg-svn/share/man/man3f/bit.3 (revision 20480)
Copyright (c) 1983 Regents of the University of California.
All rights reserved. The Berkeley software License Agreement
specifies the terms and conditions for redistribution.

@(#)bit.3 5.1 (Berkeley) 05/15/85

BIT 3F "13 June 1983"
C 5
NAME
bit - and, or, xor, not, rshift, lshift bitwise functions
SYNOPSIS
(intrinsic) function and (word1, word2) (intrinsic) function or (word1, word2) (intrinsic) function xor (word1, word2) (intrinsic) function not (word) (intrinsic) function rshift (word, nbits) (intrinsic) function lshift (word, nbits)
DESCRIPTION
These bitwise functions are built into the compiler and return the data type of their argument(s). It is recommended that their arguments be integer values; inappropriate manipulation of real objects may cause unexpected results.

The bitwise combinatorial functions return the bitwise ``and'' (and), ``or'' (or), or ``exclusive or'' (xor) of two operands. Not returns the bitwise complement of its operand.

Lshift , or rshift with a negative nbits , is a logical left shift with no end around carry. Rshift , or lshift with a negative nbits , is an arithmatic right shift with sign extension. No test is made for a reasonable value of nbits.

FILES
These functions are generated in-line by the f77 compiler.