Raymond Toy pushed to branch master at cmucl / cmucl
Commits:
-
a3a3fbd9
by Raymond Toy at 2024-05-30T14:38:30+00:00
-
7e7f3f0f
by Raymond Toy at 2024-05-30T14:38:41+00:00
3 changed files:
Changes:
... | ... | @@ -265,10 +265,10 @@ void message_write_color(message_t m,XColor *color,int tag) |
265 | 265 | message_put_word(m,color->blue);
|
266 | 266 | }
|
267 | 267 | |
268 | -void message_write_float(message_t m,float f,int tag)
|
|
268 | +void message_write_float(message_t m,void *f,int tag)
|
|
269 | 269 | {
|
270 | 270 | message_put_dblword(m,combine_type_and_data(tag,0));
|
271 | - message_put_dblword(m,f);
|
|
271 | + message_put_dblword(m,*(long *) f);
|
|
272 | 272 | }
|
273 | 273 | |
274 | 274 |
|
... | ... | @@ -524,8 +524,8 @@ void message_read_color(message_t m,XColor *color,int tag, int red) |
524 | 524 | |
525 | 525 | void message_read_float(message_t m,float *f,int tag,int data)
|
526 | 526 | {
|
527 | - fprintf(stderr,">>>>> Warning:message_read_float: Not implemented.\n");
|
|
528 | - fflush(stderr);
|
|
527 | + long d = message_get_dblword(m);
|
|
528 | + memcpy(f, &d, sizeof(*f));
|
|
529 | 529 | }
|
530 | 530 | |
531 | 531 |
|
... | ... | @@ -38,7 +38,7 @@ extern void message_write_int_list(); |
38 | 38 | extern void message_write_event();
|
39 | 39 | extern void message_write_color();
|
40 | 40 | /* GCC complains without the full prototype */
|
41 | -extern void message_write_float(message_t,float,int);
|
|
41 | +extern void message_write_float(message_t,void *,int);
|
|
42 | 42 | |
43 | 43 |
|
44 | 44 |
... | ... | @@ -10,8 +10,8 @@ |
10 | 10 | #ifndef TABLES_H
|
11 | 11 | #define TABLES_H
|
12 | 12 | |
13 | -typedef void (*type_writer)(message_t out,caddr_t src,int type_tag);
|
|
14 | -typedef void (*type_reader)(message_t in,caddr_t dest,int type_tag,int data);
|
|
13 | +typedef void (*type_writer)(message_t out,void *src,int type_tag);
|
|
14 | +typedef void (*type_reader)(message_t in,void *dest,int type_tag,int data);
|
|
15 | 15 | |
16 | 16 | typedef struct {
|
17 | 17 | String type;
|