Go Back   Velocity Reviews > Newsgroups > VHDL
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

VHDL - near LIBRARY :Syntax error

 
Thread Tools Search this Thread
Old 11-14-2008, 08:08 PM   #1
Default near LIBRARY :Syntax error


I have following code:

library IEEE;
use IEEE.STD_LOGIC_1164.all;

package my_pkg is

COMPONENT my_comp
PORT(
clk : IN STD_LOGIC;
a : IN STD_LOGIC;
b : OUT STD_LOGIC;
c : IN STD_LOGIC;
d : INOUT STD_LOGIC;
);
END my_comp;
END my_pkg;

During compilation, I'm getting error:
near "library": syntax error

What am I missing here?

thanks,
Anand



AnandA
  Reply With Quote
Old 11-14-2008, 08:57 PM   #2
Mike Treseler
 
Posts: n/a
Default Re: near LIBRARY :Syntax error
AnandA wrote:

> During compilation, I'm getting error:
> near "library": syntax error
>
> What am I missing here?


-- Proper syntax

library ieee;
use ieee.std_logic_1164.all;
package my_pkg is
component my_comp is
port(
clk : in std_logic;
a : in std_logic;
b : out std_logic;
c : in std_logic;
d : inout std_logic);
end component my_comp;
end my_pkg;


consider:

1. A vhdl-aware editor
2. direct instances instead of components
3. not using inout ports


Mike Treseler
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Python, syntax error for nothing darkie Software 0 01-18-2009 11:36 AM
error: java.lang.UnsatisfiedLinkError: Can't load library: /home/nalgo01/libcImpl.so gopinath511 Software 0 01-07-2009 09:13 AM
Need help on Modelsim VHDL syntax? ASAP:) kaji General Help Related Topics 0 03-14-2007 10:43 PM
Need help on a Modelsim VHDL Syntax? ASAP:) kaji Software 0 03-14-2007 10:43 PM
Need Help on a Modelsim VHDL Syntax....ASAP:) kaji Hardware 0 03-14-2007 10:41 PM




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46