On 24 Jul 2014, at 4:21 pm, Jim Lewis <Jim@synthworks.com> wrote: > Hi David, >> And I'll put my opinion out there succinctly. >> >> If you can't have a 'image attribute that won't operate error free for valid VHDL expressions it doesn't belong in the language. VHDL has no error recovery mechanisms. > > Why is generating an error message that says that the bounds are out of range of the base type? > It does not seem much different from the code below. You should really ask what is there in VHDL that's predefined that can give you an analogous error. The only thing that comes to mind is division by zero, with the ordinary mathematical meaning. ("/", "mod", "rem"). So there's only one value (0) that can cause an error. Well, dawgies, there's a regular plethora of potential type declarations that can cause a return string to be too long for this composite imaging attribute. I can hear it now - "How to I tell what will cause 'image to generate and error and abort my simulation?" "Uh, well the only way we have to tell is the subtype image string representation would exceed the string index range." Contrast with division by zero. The answer is easy, check your right operand isn't 0. (And the way to deal with determinism is to test the subtype with another attribute that returns a boolean instead generating an error.) -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.Received on Thu Jul 24 02:24:56 2014
This archive was generated by hypermail 2.1.8 : Thu Jul 24 2014 - 02:24:57 PDT