| 
      
      
      From: Stephen W. <st...@ic...> - 2008-04-09 02:15:06
      
     | 
| -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Cary R. wrote: > I'm working on the implementation for assign/deassign of bit and part > selects and decided to see what the standard had to say. Very interesting! > > For reference this is what it says about assign (section 9.3 page 125 > 1364-2001): > > The left-hand side of the assignment in the assign statement shall be a > variable reference or a concatenation of variables. It shall not be a > memory word (array reference) or a bit-select or a part-select of a > variable. It says the same thing. I understand why they disallow memory words, and we should stick with that. I'm surprised about the bit/part select exclusion, but given the trouble *we* are having with it, I can understand why it is there;-) > The way I read this is that an assign only works on a register/etc. type > not a wire (net). The standard say we shouldn't allow an assign to an > array word, but we don't distinguish between individual array words and a > normal variable. Bit and part selects are not allowed, but I'm working on > implementing them. > > It says basically the same think for force except it allows force to work > on either variables or nets. Though it is missing the array word > exclusion. The 2005 spec is explicit that it should not allow memory words or array references. I think we *can* allow array references if the address expression is constant. I think that would be more interesting then adding assign/deassign to bit/part selects. As for accepting assign/deassign of bit/part select, I guess we can add support to them if it is not too hard. We may want to think about adding a warning type "extensions" that would flag this sort of thing so that people can vet their code for portability. - -- Steve Williams "The woods are lovely, dark and deep. steve at icarus.com But I have promises to keep, http://www.icarus.com and lines to code before I sleep, http://www.picturel.com And lines to code before I sleep." -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iD8DBQFH/CaprPt1Sc2b3ikRAju5AJ4poCfp3mj7FFxyzU83+SGQ5iXocQCg3RbX 5SCuAEaBGCqvoXiv4PS2dgQ= =fTt+ -----END PGP SIGNATURE----- |