snobol4logic - Man Page

bitwise logic and conversions for SNOBOL4

Synopsys

-INCLUDE 'logic.sno'

Description

For binary operations, either argument can be INTEGER or STRING (if both string, must be of same length).

NOT(arg)

returns bitwise not (complement) of integer argument.

AND(arg1,arg2)

bitwise intersection.

OR(arg1,arg2)

bitwise union.

XOR(arg1,arg2)

bitwise exclusive or (equivalence).

NAND(arg1,arg2)

bitwise intersection (first argument complemented).

NOR(arg1,arg2)

bitwise union (first argument complemented).

UPLUS(arg1,arg2)

unsigned addition.

UMINUS(arg1,arg2)

unsigned subtraction.

UMUL(arg1,arg2)

unsigned multiplication.

UDIV(arg1,arg2)

unsigned division.

SHL(arg1,arg2)

shift left.

SHR(arg1,arg2)

shift right.

SAR(arg1,arg2)

arithmetic (signed) shift right.

ROL(arg1,arg2)

rotate left.

ROR(arg1,arg2)

rotate right.

HI(str)

convert base 16 string to integer.

IH(int)

convert integer to base16 string.

DIB(str,n)

convert base n string to integer.

IDB(int,n)

convert integer to base n string.

Compatibility

compatible with Catspaw SPITBOL LOGIC function.

See Also

snobol4(1)

Author

Philip L. Budne

Referenced By

snobol4(1), snolib(3).

March 31, 2022 CSNOBOL4B 2.3.1 CSNOBOL4 Manual