I have a function that works with string passed to it. The string should be defined as "a to b" rather than "a downto b". I have the following questions:
- How to find out if the string passed is defined in ascending or descending order?
- Why do strings not have index 0? The minimum index is 1.
I have string p is 1 to 10, while string q is 10 downto 1, assigning one to the other generates error:
Fatal: (vsim-3607) Slice range direction (downto) does not match slice prefix direction (to).
Why?
How do I assign p to q or q to p in this case?