Subject: Re: [OT] Any sources for PDP-11 spares?
To: None <port-vax@netbsd.org, port-pdp10@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: port-pdp10
Date: 06/11/2002 15:46:43
>> Hmm? I think it's an excellent way to smoke out those hidden
>> assumptions about word size.
> Those assumptions are not especially well hidden, things like:
> char c[4];
> int32_t b;
> b = c[0] << 24 | c[1] << 16 | c[2] << 8 | c[3];
Eh. Yes, "hidden" was not the right word. "Depressingly pervasive",
maybe. Or perhaps "hidden in plain sight", by not being easy to find
mechanically. (Grepping for int32_t is easy to automate. Telling
which ones should be int_least32_t is not. And finding all the places
where you have (say) 17 where you mean (2*CHAR_BIT)+1, that is
difficult enough even for a human.)
/~\ The ASCII der Mouse
\ / Ribbon Campaign
X Against HTML mouse@rodents.montreal.qc.ca
/ \ Email! 7D C8 61 52 5D E7 2D 39 4E F1 31 3E E8 B3 27 4B