kendall@talcott.UUCP (Sam Kendall) (07/22/85)
> Since code written on one machine is > very often taken to others, and the word "register" isn't very hard to > type, you should declare almost everything a register. Even data types > you don may not think fit in registers, like strucutures, enums, > doubles, and unions. > > Ken Arnol Conceptually nice, but register structs and unions will fail with pcc-based compilers due to a compiler bug. The compiler treats `s.member' as `(&s)->member'; i.e., in the compiler, `->' rather than `.' is the primitive. Martin Minow ran into this problem porting his cpp to UNIX. Sam Kendall Delft Consulting Corp. {allegra, cmcl2, ihnp4}!delftcc!sam
chris@umcp-cs.UUCP (Chris Torek) (07/23/85)
> ... register structs and unions will fail with pcc-based > compilers due to a compiler bug. The compiler treats `s.member' as > `(&s)->member'; i.e., in the compiler, `->' rather than `.' is the > primitive. (There's a good reason for it doing so, but that's beside the point here). This has been ``fixed'' in later compilers by ignoring the register keyword; however, lint still gets indigestion on these. -- In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 4251) UUCP: seismo!umcp-cs!chris CSNet: chris@umcp-cs ARPA: chris@maryland