Skip to content

Commit b866fd3

Browse files
ur4tburgerrg
authored andcommitted
Update remaining K&R function declarations to modern style (#683)
1 parent 9df56e7 commit b866fd3

File tree

7 files changed

+7
-10
lines changed

7 files changed

+7
-10
lines changed

c/fasl.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1553,8 +1553,7 @@ static uptr sparc64_get_literal(void *address) {
15531553
return item;
15541554
}
15551555

1556-
static U32 adjust_delay_inst(delay_inst, old_call_addr, new_call_addr)
1557-
U32 delay_inst; U32 *old_call_addr, *new_call_addr; {
1556+
static U32 adjust_delay_inst(U32 delay_inst, U32 *old_call_addr, U32 *new_call_addr) {
15581557
INT offset;
15591558

15601559
offset = sizeof(U32) * (old_call_addr - new_call_addr);

c/foreign.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ void S_foreign_entry(void) {
270270
AC0(tc) = x;
271271
}
272272

273-
static void *lookup_foreign_entry(s) const char *s; {
273+
static void *lookup_foreign_entry(const char *s) {
274274
return ptr_to_addr(lookup(s));
275275
}
276276

c/number.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -778,8 +778,7 @@ static void big_short_trunc(ptr tc, ptr x, bigit s, iptr xl, IBOOL qs, IBOOL rs,
778778
if (r != (ptr *)NULL) *r = copy_normalize(tc, &k,1,rs);
779779
}
780780

781-
static void big_trunc(tc, x, y, xl, yl, qs, rs, q, r)
782-
ptr tc, x, y; iptr xl, yl; IBOOL qs, rs; ptr *q, *r; {
781+
static void big_trunc(ptr tc, ptr x, ptr y, iptr xl, iptr yl, IBOOL qs, IBOOL rs, ptr *q, ptr *r) {
783782
iptr i;
784783
bigit *p, *xp, *yp;
785784
iptr m = xl-yl+1;

c/prim5.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -872,8 +872,7 @@ static ptr s_flush_instruction_cache(void) {
872872
return Svoid;
873873
}
874874

875-
static ptr s_make_code(flags, free, name, arity_mark, n, info, pinfos)
876-
iptr flags, free, n; ptr name, arity_mark, info, pinfos; {
875+
static ptr s_make_code(iptr flags, iptr free, ptr name, ptr arity_mark, iptr n, ptr info, ptr pinfos) {
877876
ptr co;
878877

879878
tc_mutex_acquire()

c/scheme.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@ static IBOOL next_path(char *path, const char *name, const char *ext, const char
420420
static const char *path_last(const char *path);
421421
static char *get_defaultheapdirs(void);
422422

423-
static const char *path_last(p) const char *p; {
423+
static const char *path_last(const char *p) {
424424
const char *s;
425425
#ifdef WIN32
426426
char c;

c/segment.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ iptr S_find_segments(ISPC s, IGEN g, iptr n) {
325325
* allocates a group of n contiguous fresh segments, returning the
326326
* segment number of the first segment of the group.
327327
*/
328-
static seginfo *allocate_segments(nreq) uptr nreq; {
328+
static seginfo *allocate_segments(uptr nreq) {
329329
uptr nact, bytes, base; void *addr;
330330
iptr i;
331331
chunkinfo *chunk; seginfo *si;

c/thread.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ ptr S_fork_thread(ptr thunk) {
259259
return thread;
260260
}
261261

262-
static s_thread_rv_t start_thread(p) void *p; {
262+
static s_thread_rv_t start_thread(void *p) {
263263
ptr tc = (ptr)p; ptr cp;
264264

265265
s_thread_setspecific(S_tc_key, tc);

0 commit comments

Comments
 (0)