/* This C language subroutine returns non-zero if the input is a space character, zero otherwise. The Run Time Library for the C Language. Gordon A. Sterling (617) 461 - 3076 DSP Development Tools Engineering Updated on 5/94 by AS #include
int isspace(int c); */ #include "lib_glob.h" #include "cty_glob.h" .SEGMENT/CODE Code_Space_Name; .FILE RTL_FILENAME; .GLOBAL _isspace; _isspace: R2=32; /*ASC(' ')*/ COMP(R4,R2), R0=dm_1; /*Test for space */ IF EQ JUMP (PC, restore_state) (DB); R2=13; /*13 = ASC('\n')*/ COMP(R4,R2), FETCH_RETURN IF GT R0=R0-R0; /*Set return to false*/ R2=9; /*9 = ASC('\r')*/ COMP(R4,R2); IF LT R0=R0-R0; /*Set return to false*/ restore_state: RETURN (DB); RESTORE_STACK RESTORE_FRAME .ENDSEG;