Re: [myhdl-list] MEP : Signal Containers
Brought to you by:
jandecaluwe
From: Jan D. <ja...@ja...> - 2012-05-21 07:16:20
|
On 05/19/2012 04:05 PM, Christopher Felton wrote: > On 5/19/12 4:02 AM, Jan Decaluwe wrote: >> On 05/18/2012 09:57 PM, Christopher Felton wrote: >> >>> The advantage of a class method over a function ... no advantage per se. >>> They both achieve the same thing in the similar manner. But it gives >>> the ability to use a method versus a function if someone wanted. >> >> I think there has to be a much better reason than this to warrant >> the effort to support this in conversion. There should be some feature >> that many people find useful and that cannot reasonably done in >> a different way. Conversion is complex enough as it is! > > Oh oh, I setup this enhancement up poorly here, doh. In the context of > describing hardware behavior using a class method (as proposed) or a > python function, they will do the same thing. So what is the benefit to > justify the changes in the conversion code? > > My opinion, the benefit is that it helps organize larger more complex > designs (yes, complex can be subjective, what is complex?). To me this > benefit is worth the inclusion. In the past couple years this topic has > surfaced a couple times. Others do intuitively want to use a class > method instead of a function in some cases. > > The changes can be diffed here (viewed), > https://bitbucket.org/cfelton/myhdl_0.8dev_work/changeset/d61bf91023b7 . > > The changes are localized in two spots. The enhancement doesn't touch a > lot of the conversion code. Hopefully, minimizing additional complexity > in the conversion code. > > Is the concern that it will add unneeded complexity to the conversion > code or be confusing for users? The latter is an often overlooked, but important concern. If something is supported it should be "all the way", otherwise it may just raise new expectations and increase confusion. However, it looks like this case is indeed simple and clean. -- Jan Decaluwe - Resources bvba - http://www.jandecaluwe.com Python as a HDL: http://www.myhdl.org VHDL development, the modern way: http://www.sigasi.com World-class digital design: http://www.easics.com |