From: pneyz Newsgroups: comp.os.msdos.djgpp Subject: Re: Bytes and words Date: Sat, 07 Feb 1998 22:04:33 -0800 Organization: Smoof Team Lines: 21 Message-ID: <34DD4AF1.E35F1A26@bethany.edu> References: <34DD3806 DOT 92C44AF4 AT ea DOT oac DOT uci DOT edu> NNTP-Posting-Host: scz-ca19-20.ix.netcom.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk > If I try to include this in a simple program, gcc complains about the > use of semicolons in a structure and (it seems) about the use of > 'BYTE'. Is the above just meant to be a very formal looking piece of > pseudocode, or can one actually declare bytes and words (2 bytes?) in > this manner? BYTE and WORD are not defined be default, so most coders put something like: typedef unsigned char byte; typedef unsigned int word; In their code for gfx routines. However, in DJGPP, an int is 4 bytes by default, so you should change the int to a short. byte and word are not C identifiers, but are holdovers from asm (I think). -- /* pneyz / Smoof Team pneyz AT bethany DOT edu "Fine Malt Coding" http://ns.bethany.edu/pneyz/ */