[myhdl-list] Top level method conversion
Brought to you by:
jandecaluwe
From: Henry G. <he...@ca...> - 2015-01-23 22:08:39
|
MEP 108 describes the conversion of top-level methods. Please forgive me for being stupid here, but I have a few questions: "top-level" in the nomenclature means the outer most collection of instances, is this correct? It is the most broad view of the design. Given the hierarchy is flattened, is this simply a conceptual convenience, or is there more to it than that? (i.e. could one manually flatten the hierarchy and end up with much the same thing, so top level would be just "all the instances"?). Or does it only convey meaning in the conversion process - It is the outer most factory function? Is there a clear use case example of when the mep 108 work would be useful? In my mind, the main benefit of classes is they retain and modify state at run-time, which seems to be of little value when creating instances (at least in the convertible case), but perhaps I'm missing something? As I understand it, for convertible code one should not really be modifying attributes on self inside an instance (and given all my previous comments, I imagine accessing attributes on self would cause conversion problems). Cheers, Henry |