In article <[EMAIL PROTECTED]>,
Alfred Perlstein  <[EMAIL PROTECTED]> wrote:
> 
> If you're worried about such things happening then you can use
> the pre-processor to catch things that may make your structures
> too large.
> 
> > I wonder how too "big" can be detected. The code in question is perfectly
> > valid syntactically and semantically correct C-code.
> 
> There's code that #error (maybe #warning?) when it can detect that the
> size of a struct has been unreasonably grown, it's done via the
> pre-processor.

I doubt if it's possible to implement that at compile time.  Remember,
the preprocessor doesn't understand "sizeof".  It doesn't recognize
keywords in expressions at all.

John
-- 
  John Polstra                                               [EMAIL PROTECTED]
  John D. Polstra & Co., Inc.                        Seattle, Washington USA
  "Disappointment is a good sign of basic intelligence."  -- Chögyam Trungpa



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to