Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
* errno.h problems in DEC 'C'
@ 1995-08-02  4:00 Greg Thomas
  1995-08-02  4:00 ` Dan Pop
                   ` (4 more replies)
  0 siblings, 5 replies; 9+ messages in thread
From: Greg Thomas @ 1995-08-02  4:00 UTC (permalink / raw)


Hi,

I'm trying to porting some code to Alpha/DEC 'C' from VAX/VAX 'C'. We have, 
however, hit a problem with the <errno.h> include file. It #defines it to be 
(*cma$tis_errno_get_addr()). The trouble is, we have number of structures that 
have an errno as an element. Of course, this gets expanded to the above 
function, and so it won't compile. ie ...

#include <errno.h>

/* Which then does the following define ... 
#define errno (*cma$tis_errno_get_addr())
*/

struct test 
{
	long errno;
/* which gets expanded to 
	long (*cma$tis_errno_get_addr());
   which of course will not compile 
*/
};

Now whilst I can change all our code to not refer to errno in this structure, 
I feel that the DEC 'C' errno.h does not have correct behaviour in it. Is the 
DEC 'C' compiler in error (my K&R 2nd Ed does refer to errno as an integer, 
but that's all), or am I not allowed to do this?

Thanks for any help,


Greg Thomas
---
Tel (01473) 224832
Fax (01473) 233319



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~1995-08-04  4:00 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1995-08-02  4:00 errno.h problems in DEC 'C' Greg Thomas
1995-08-02  4:00 ` Dan Pop
1995-08-03  4:00   ` halasz
1995-08-04  4:00     ` David Claude Brown
1995-08-04  4:00     ` Dan Pop
1995-08-02  4:00 ` Lawrence Kirby
1995-08-02  4:00 ` J. Daniel Smith
1995-08-03  4:00 ` David Claude Brown
1995-08-03  4:00 ` Derick J.R. Qua-Gonzalez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox