kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #11548
Re: Function prototypes
On Fri, Nov 01, 2013 at 01:22:12AM +0100, Tomasz Wlostowski wrote:
> application. IMHO a fixed enum type is probably not the best solution
> here...
Yes, I have seen that, there functions/macro to generate them
(offsetting the value IIRC). Maybe the best way to handle it would be
a different type and an (eventually implicit and/or validating)
conversion operator.
There is a whole set of stuff which assumes (in fact, requires,
segfault is the penalty:P) that a LAYER_NUM has a valid value (example:
the color translation). Overusing it (especially if it has to be shared
with eeschema later!) doesn't seem a good idea to me.
--
Lorenzo Marcantonio
Logos Srl
References