Skip to content

Commit

Permalink
fixing codepage extraction issue, fixed square brackets
Browse files Browse the repository at this point in the history
  • Loading branch information
mainframed committed Apr 25, 2024
1 parent bfb7790 commit 99e7925
Show file tree
Hide file tree
Showing 92 changed files with 1,847 additions and 1,847 deletions.
4 changes: 2 additions & 2 deletions inc/compile.h
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,10 @@ enum mnemonic_type {
,OP_PUSH /* push lstring */
,OP_PUSHTMP /* push a temporary lstring */
,OP_POP /* pop lstring */
,OP_DUP /* DUP Ýrelative¨ duplicates something from stack */
,OP_DUP /* DUP [relative] duplicates something from stack */
,OP_COPY /* COPY to previous (Lstrcpy)*/
,OP_COPY2TMP /* COPY a value to temporary */
,OP_PATCH /* PATCH Ýrelative¨ Ýbyte¨ in code */
,OP_PATCH /* PATCH [relative] [byte] in code */
,OP_RAISE /* raise a condition error */

,OP_LOADARG /* load argument */
Expand Down
6 changes: 3 additions & 3 deletions inc/dbginfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
typedef struct T_DebugInfo_st {
dword magic_eye;
char *message;
dword pointerÝMAX_POINTER_ELEMENTS¨;
dword pointer[MAX_POINTER_ELEMENTS];
} DebugInfo;

typedef DebugInfo *P_DebugInfo;
Expand All @@ -39,12 +39,12 @@ static void updateDebugInfo (char *message, int num, ...)

/* zero out all old values */
for (ii=0; ii < MAX_POINTER_ELEMENTS; ii++) {
debugInfo->pointerÝii¨ = 0;
debugInfo->pointer[ii] = 0;
}

/* set new values */
for (jj=0; jj < MIN(num,MAX_POINTER_ELEMENTS); jj++) {
debugInfo->pointerÝjj¨ = va_arg(args,dword);
debugInfo->pointer[jj] = va_arg(args,dword);
}

/* clean up */
Expand Down
20 changes: 10 additions & 10 deletions inc/dynit.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,29 @@ typedef struct __DYNstruct {
char *__ddname; /* DDNAME */
char *__dsname; /* DSNAME, dataset name */
char __sysout; /* system output dataset */
char __01__Ý7¨;
char __01__[7];
char *__sysoutname; /* program name for sysout */
char *__member; /* member of a PDS */
char __status; /* dataset status */
char __normdisp; /* dataset's normal disp */
char __conddisp; /* dataset's cond disp */
char __02__Ý5¨;
char __02__[5];
char *__unit; /* unit name of dataset */
char *__volser; /* volume serial number */
short __dsorg; /* dataset organization */
char __alcunit; /* unit of space allocation */
char __03__Ý1¨;
char __03__[1];
int __primary; /* primary space allocation */
int __secondary; /* secondary space alloc'n */
short __recfm; /* the record format */
short __blksize; /* the block size */
unsigned short __lrecl; /* record length */
char __04__Ý6¨;
char __04__[6];
char *__volrefds; /* volume serial reference */
char *__dcbrefds; /* dsname for DCB reference */
char *__dcbrefdd; /* ddname for DCB reference */
unsigned char __misc_flags; /* attribute flags */
char __05__Ý7¨;
char __05__[7];
char *__password; /* password */
char **__miscitems; /* all remaining text units */
short __infocode; /* SVC 99 info code */
Expand All @@ -43,17 +43,17 @@ typedef struct __DYNstruct {
char *__mgntclass; /* SMS management class */
char *__dataclass; /* SMS data class */
unsigned char __recorg; /* Vsam dataset organization */
char __06__Ý1¨;
char __06__[1];
short __keylength; /* Vsam key length */
short __keyoffset; /* Vsam key offset */
char __07__Ý2¨;
char __07__[2];
char *__refdd; /* copy attributes of ref. dd*/
char *__like; /* copy attributes of like dsn */
unsigned char __dsntype; /* type att. of pds or pdse */
char __08__Ý7¨;
char __09__Ý4¨;
char __08__[7];
char __09__[4];
struct __S99rbx * __rbx; /* to the req. block extension */
char __10__Ý4¨;
char __10__[4];
struct __S99emparms * __emsgparmlist; /* @ of error msg parms*/
} __DYNstruct, __dyn_t;

Expand Down
220 changes: 110 additions & 110 deletions inc/irx.h

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion inc/ldefs.h
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ typedef unsigned int uintptr_t;

#define SWAP(a,b) a ¬= b ¬= a ¬= b;

#define DIMENSION(p) (sizeof(p) / sizeof(pÝ0¨))
#define DIMENSION(p) (sizeof(p) / sizeof(p[0]))
#define ABS(a) (((a)<0)?-(a):(a))

#ifndef MAX
Expand Down
10 changes: 5 additions & 5 deletions inc/lstring.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ typedef Lstr *PLstr;
#define LUNSETOPT(L,O) ((L).options &= ~(O))

/* --- string --- */
#define LASCIIZ(s) {LSTR(s)ÝLLEN(s)¨ = '\0';}
#define LASCIIZ(s) {LSTR(s)[LLEN(s)] = '\0';}
#define LZEROSTR(s) {(s).len=0; (s).type=LSTRING_TY;}
#define LISNULL(s) (!(s).pstr)

Expand Down Expand Up @@ -147,8 +147,8 @@ typedef Lstr *PLstr;
#define LWSCPY Lscpy

/* --- word --- */
#define LSKIPBLANKS(S,P) {while (((P)<LLEN(S)) && ISSPACE(LSTR(S)ÝP¨)) (P)++;}
#define LSKIPWORD(S,P) {while (((P)<LLEN(S)) && !ISSPACE(LSTR(S)ÝP¨)) (P)++;}
#define LSKIPBLANKS(S,P) {while (((P)<LLEN(S)) && ISSPACE(LSTR(S)[P])) (P)++;}
#define LSKIPWORD(S,P) {while (((P)<LLEN(S)) && !ISSPACE(LSTR(S)[P])) (P)++;}

/* --- transform --- */
#define L2INT(s) if (LTYPE(*(s))!=LINTEGER_TY) L2int((s))
Expand Down Expand Up @@ -387,7 +387,7 @@ DECLMATH( tanh );
double lLastScannedNumber=0.0;
int lNumericDigits = LMAXNUMERICDIGITS;
/* int form */
byte l2uÝ256¨, u2lÝ256¨;
byte l2u[256], u2l[256];
LerrorFunc Lerror;
#else
extern char
Expand All @@ -398,7 +398,7 @@ DECLMATH( tanh );
*crxsymb;
extern double lLastScannedNumber;
extern int lNumericDigits;
extern byte l2uݨ, u2lݨ;
extern byte l2u[], u2l[];
extern LerrorFunc Lerror;
#endif

Expand Down
2 changes: 1 addition & 1 deletion inc/metal.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

#ifndef _METAL_TYPES_
#define _METAL_TYPES_
typedef char char8Ý8¨;
typedef char char8[8];
typedef int bool;
typedef unsigned char byte;
typedef unsigned short hword;
Expand Down
42 changes: 21 additions & 21 deletions inc/netdata.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,28 +42,28 @@ typedef enum {
} ND_CTRL_RECORD_FORMAT;

typedef struct {
char year Ý4¨;
char month Ý2¨;
char day Ý2¨;
char hour Ý2¨;
char minute Ý2¨;
char second Ý2¨;
char year [4];
char month [2];
char day [2];
char hour [2];
char minute [2];
char second [2];
} ND_DATE_TIME, *P_ND_DATE_TIME;

/* INMR01 */
typedef struct {
/* mandatory fields*/
char INMFNODE Ý8¨; /* Origin node name */
char INMFNODE [8]; /* Origin node name */
ND_DATE_TIME INMFTIME ; /* Origin timestamp */
char INMFUID Ý8¨; /* Origin user ID */
char INMFUID [8]; /* Origin user ID */
unsigned int INMLRECL ; /* Length of physical control record segments */
char INMTNODE Ý8¨; /* Target node name */
char INMTUID Ý8¨; /* Target user ID */
char INMTNODE [8]; /* Target node name */
char INMTUID [8]; /* Target user ID */
/* optional fields*/
char INMFACK Ý64¨; /* Receipt notification requested */
char INMFACK [64]; /* Receipt notification requested */
unsigned int INMFVERS ; /* Origin version number */
unsigned int INMNUMF ; /* Number of files in this transmission */
char INMUSERP Ý251¨; /* User parameter string */
char INMUSERP [251]; /* User parameter string */
} ND_HEADER_RECORD, *P_ND_HEADER_RECORD;

/* INMR02 */
Expand All @@ -73,20 +73,20 @@ typedef struct {
unsigned int INMLRECL ; /* Logical record length */
ND_RECFM INMRECFM ; /* Record format */
unsigned int INMSIZE ; /* Approximate size of file in bytes */
char INMUTILN Ý8¨; /* Utility program name */
char INMUTILN [8]; /* Utility program name */
/* optional fields */
int INMBLKSZ ; /* File block size */
ND_DATE_TIME INMCREAT ; /* Creation date */
unsigned int INMDIR ; /* Number of directory blocks */
char INMDSNAM Ý44¨; /* File name */
char INMDSNAM [44]; /* File name */
ND_DATE_TIME INMEXPDT ; /* Expiration date */
int INMFFM ; /* Filemode number */
ND_DATE_TIME INMLCHG ; /* Last change date */
ND_DATE_TIME INMLREF ; /* Last reference date */
unsigned int INMTERM ; /* Mail file */
char INMUSERP Ý251¨; /* User parameter string */
char INMUSERP [251]; /* User parameter string */
unsigned int INMMEMBRN ; /* Member name number */
char INMMEMBRÝ1¨Ý8¨ ; /* Member name list */
char INMMEMBR[1][8] ; /* Member name list */
} ND_FILE_UTIL_CTRL_RECORD, *P_ND_FILE_UTIL_CTRL_RECORD;

/* INMR03 */
Expand All @@ -102,12 +102,12 @@ typedef struct {
unsigned int length;
short first;
short last;
BYTE dataÝ253¨;
BYTE data[253];
} ND_DATA_RECORD, *P_ND_DATA_RECORD;

typedef struct {
short length;
BYTE dataÝ1¨;
BYTE data[1];
} ND_TEXT_UNIT_VALUE, *P_ND_TEXT_UNIT_VALUE;

typedef struct {
Expand All @@ -117,14 +117,14 @@ typedef struct {
} ND_TEXT_UNIT, *P_ND_TEXT_UNIT;

typedef struct {
BYTE identifierÝ6¨;
BYTE dataÝ247¨;
BYTE identifier[6];
BYTE data[247];
} ND_CTRL_RECORD, *P_ND_CTRL_RECORD;

typedef struct {
BYTE length;
BYTE flags;
BYTE dataÝ253¨;
BYTE data[253];
} ND_SEGMENT, *P_ND_SEGMENT;

/* SEGMENT DESCRIPTOR FLAGS */
Expand Down
4 changes: 2 additions & 2 deletions inc/nextsymb.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ enum symboltype {
,function_sy /* ident with a paren */
,literal_sy /* literal symbol */
,le_parent /* ( */ /* the order */
,le_bracket /* Ý */ /* until */
,le_bracket /* [ */ /* until */
,le_curlbracket /* { */ /* not_ty */
,plus_sy /* + */ /* is important */
,inc_sy /* ++ */ /* for expr.c */
Expand All @@ -56,7 +56,7 @@ enum symboltype {
,intdiv_sy /* // */ /* --------------- */

,ri_parent /* ) */
,ri_bracket /* ¨ */
,ri_bracket /* ] */
,ri_curlbracket /* } */
,dot_sy /* . */
,tidle_sy /* ~ */
Expand Down
12 changes: 6 additions & 6 deletions inc/rexx.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ struct trxfile {
Lstr name; /* complete file path */
char *filename; /* filename in name */
char *filetype; /* filetype in name */
char ddnÝ9¨; /* ddname */
char dsnÝ45¨; /* dsname */
char memberÝ9¨; /* member name */
char ddn[9]; /* ddname */
char dsn[45]; /* dsname */
char member[9]; /* member name */
void *libHandle; /* Shared library handle */
Lstr file; /* actual file */
FILE *fp; /* file pointer */
Expand All @@ -107,7 +107,7 @@ typedef
struct tidentinfo {
int id; /* the last prg that set leaf value */
int stem; /* if it is a stem */
PBinLeaf leafÝ1¨; /* Variable array of leafs */
PBinLeaf leaf[1]; /* Variable array of leafs */
/* Variable value if stem=0 OR */
/* pointers to litterals */
} IdentInfo;
Expand All @@ -117,7 +117,7 @@ typedef
struct targs {
int n; /* number of args */
PLstr r; /* return data */
PLstr aÝMAXARGS¨; /* argument pointers */
PLstr a[MAXARGS]; /* argument pointers */
} Args;

/* ------------ internal rexxfunctions ------------ */
Expand Down Expand Up @@ -160,7 +160,7 @@ struct trxproc {
EXTERN int __debug__;
#endif

EXTERN char *_prgname; /* point to argvÝ0¨ */
EXTERN char *_prgname; /* point to argv[0] */
EXTERN jmp_buf _error_trap; /* error trap for compile */
EXTERN jmp_buf _exit_trap; /* exit from prg */

Expand Down
22 changes: 11 additions & 11 deletions inc/rxdefs.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,16 @@

#define ARGN (rxArg.n)
#define ARGR (rxArg.r)
#define ARG1 (rxArg.aÝ0¨)
#define ARG2 (rxArg.aÝ1¨)
#define ARG3 (rxArg.aÝ2¨)
#define ARG4 (rxArg.aÝ3¨)
#define ARG5 (rxArg.aÝ4¨)
#define ARG6 (rxArg.aÝ5¨)
#define ARG7 (rxArg.aÝ6¨)
#define ARG8 (rxArg.aÝ7¨)
#define ARG9 (rxArg.aÝ8¨)
#define ARG10 (rxArg.aÝ9¨)
#define ARG1 (rxArg.a[0])
#define ARG2 (rxArg.a[1])
#define ARG3 (rxArg.a[2])
#define ARG4 (rxArg.a[3])
#define ARG5 (rxArg.a[4])
#define ARG6 (rxArg.a[5])
#define ARG7 (rxArg.a[6])
#define ARG8 (rxArg.a[7])
#define ARG9 (rxArg.a[8])
#define ARG10 (rxArg.a[9])

#define must_exist(I) if (ARG##I == NULL) \
Lerror(ERR_INCORRECT_CALL,0)
Expand Down Expand Up @@ -82,7 +82,7 @@
#define get_pad(I,pad) { if (exist(I)) \
{ L2STR(ARG##I); \
if (LLEN(*ARG##I)!=1) Lerror(ERR_INCORRECT_CALL,0); \
pad = LSTR(*ARG##I)Ý0¨; \
pad = LSTR(*ARG##I)[0]; \
} else pad = ' '; }

enum functions {
Expand Down
Loading

0 comments on commit 99e7925

Please sign in to comment.