|
Hey guys,
I'm not finding this question on this forum or on Google. Do chips have "return values"? In other words, can you use a function as a parameter?
Eg.
Something like this is typical and works:
Not(in=b, out=notb);
And(a=a, b=notb, out=o1);
Is it possible to consolidate in this form?
And(a=a, b=Not(in=b, out=notb), out=o1);
The Hardware Simulator doesn't seem to like this notation. I see on Page 15 of Chapter 1 that the sample Xor implementation can be Xor(a, b) = Or(And(a, Not(b)), And(Not(a),(b)) but I think the authors are just describing it conceptually, rather than implying a similar structure can be used in their HDL.
Thanks
|