Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   VHDL (http://www.velocityreviews.com/forums/f18-vhdl.html)
-   -   Specifying vector length in the function output (http://www.velocityreviews.com/forums/t23785-specifying-vector-length-in-the-function-output.html)

valentin tihomirov 06-28-2005 03:13 PM

Specifying vector length in the function output
 
it seems that the following code will not work

function F() return std_logic_vector (1 to 10) -- error

while the following is compiled

function F() return std_logic_vector

So, I would like to highlight the length to the user looking at package
interface part.



Colin Marquardt 06-28-2005 06:52 PM

Re: Specifying vector length in the function output
 
"valentin tihomirov" <spam@abelectron.com> writes:

> it seems that the following code will not work
>
> function F() return std_logic_vector (1 to 10) -- error

[...]
> So, I would like to highlight the length to the user looking at package
> interface part.


Just define a subtype.

HTH,
Colin


All times are GMT. The time now is 08:30 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.