1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-02-09 01:31:11 +00:00

Remove extra semicolons, convert #define x() {...} to do {...} while (0) style (#444)

* Remove extra semicolons, convert #define x() {...} to do {...} while (0) style

* Fix missing brace in INIT-specific definition of init_kbd_startup
This commit is contained in:
Nick Briggs
2022-10-05 09:07:17 -07:00
committed by GitHub
parent f5b17b0e63
commit cdffa541ef
57 changed files with 413 additions and 400 deletions

View File

@@ -65,21 +65,21 @@ static const char il_string[] = "INTERLISP";
#define CLASSP(obj) (LC_TYPEP((obj), atom_class))
#define INSTANCE_OR_PUNT(obj, fn, argnum) \
{ \
do { \
if (!LC_TYPEP((obj), atom_instance)) RETCALL(fn, argnum); \
}
} while (0)
#define INSTANCE_CLASS_OR_PUNT(obj, fn, argnum) \
{ \
do { \
LispPTR tmp = DTD_FROM_LADDR(obj); \
if (tmp != atom_instance && tmp != atom_class) RETCALL(fn, argnum); \
}
} while (0)
#define LC_INIT \
if (atom_instance == 0) LCinit()
#define GET_IV_INDEX(objptr, iv, dest, otherwise) \
{ \
do { \
struct LCIVCacheEntry *ce; \
LispPTR iNames = (objptr)->iNames; \
\
@@ -105,7 +105,7 @@ static const char il_string[] = "INTERLISP";
} \
} \
} \
}
} while (0)
struct LCClass { /* class datatype */
LispPTR metaClass, ivNames, ivDescrs, classUnitRec, localIVs, cvNames, cvDescrs, className,
@@ -206,7 +206,7 @@ LispPTR LCFetchMethodOrHelp(LispPTR object, LispPTR selector) {
ce->selector = selector;
return (ce->method_fn = ((LispPTR *)NativeAligned4FromLAddr(classptr->methods))[i - 1]);
}
};
}
next_class:
if ((cur_class = car(supers)) == NIL_PTR) break;
@@ -255,7 +255,7 @@ LispPTR LCFetchMethod(LispPTR class, LispPTR selector) {
ce->selector = selector;
return (ce->method_fn = ((LispPTR *)NativeAligned4FromLAddr(classptr->methods))[i - 1]);
}
};
}
next_class:
if ((cur_class = car(supers)) == NIL_PTR) break;