Re: [myhdl-list] List Of Constants
Brought to you by:
jandecaluwe
From: Josy B. <jos...@gm...> - 2015-03-18 16:23:05
|
> > while you're at it, can you put the 'constants' in upper-case? A PEP8 > > recommendation ;) > > > > I disagree, we have a reference to a `tuple` not a > module level constant. > > # module level constant > from myhdl import * > MAX_LEVELS = 4 > > # reference to a tuple > coef = (1,2,3,4) > > Module-level constants are fairly rare. The python > documentation [1] does not use cap names for references > to tuples (can't say I have seen other that does) > > Regards, > Chris > > [1] > https://docs.python.org/2/tutorial/datastructures.html#tuples-and- sequences Chris, I see your point. But I like to stress the fact that some arguments are *constant* (and I always use UPPER_CASE names for generic parameters in VHDL which is what I mimic in my MyHDL code). I'll let it digest. Regards, Josy |