Path: utzoo!attcan!uunet!convex!convex.COM From: macphee@convex.COM (Scott C. Mac Phee) Newsgroups: comp.lang.c Subject: Re: IsUnsigned() function? Message-ID: <104086@convex.convex.com> Date: 19 Jul 90 13:18:47 GMT References: <1990Jul16.214155.5087@Neon.Stanford.EDU> <3539@sactoh0.UUCP> Sender: news@convex.com Reply-To: macphee@convex.COM (Scott C. Mac Phee) Organization: Convex Computer Corporation; Richardson, TX Lines: 16 I would think what we are really looking for is : o Assume (always) that the type we are checking is of type int. int IsUnsigned(x) unsigned x ; { return(x&(1<<(sizeof(int)-1))) ; } Scott Convex Computer Corporation ...uunet!convex!macphee (214) 497-4772