avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] timer.h


From: Theodore A. Roth
Subject: Re: [avr-libc-dev] timer.h
Date: Mon, 30 Sep 2002 10:03:38 -0700 (PDT)

On Mon, 30 Sep 2002, E. Weddington wrote:

:) > IMHO, it's hard to even make it `complete', since the notion of
:) > completeness might vary much between different environments.  Also,
:) > newer ATmegas use different names for the bit descriptions.
:) >
:) That's what conditional compilation is for. ;-)

Be careful there. Conditional compilation can be dangerous. For instance,
how to you guarantee that you've tested all the various permutations of
the conditions? Then there's the fact that it can make the code incredibly
difficult to read (look at all the confusion lately with the _SFR_*
macros). Kernighan and Pike's "The Practice of Programming" has a good
discussion on this (among many excellent discussions).

Ted Roth





reply via email to

[Prev in Thread] Current Thread [Next in Thread]