Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8714533
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T05:37:13+00:00 2026-06-13T05:37:13+00:00

I have recently started using exuberant ctags and emacs for verilog & system verilog

  • 0

I have recently started using exuberant ctags and emacs for verilog & system verilog coding and code browsing. I currently generate the tags using the command

ctags -e -R --tag-relative=yes --langmap=verilog:.v.vh.sv.svh 

My code contains a lot of `define macros which are all specified in certain header files with extension “.vh” & “.svh”. For e.g. a header file named foo.vh has the following code

`define WIDTH_ADDRESS 32;

and a file top.v invokes the macro as follows

input [`WIDTH_ADDRESS - 1 : 0] InAddress;

While browsing the top.v file using emacs, is there any way by which I can jump directly to to the macro definition in the foo.vh file?

I have been using M-x tags-search <RET> WIDTH_ADDRESS <RET> for sometime now but it jumps to quite a few other instances of `WIDTH_ADDRESS in other files before reaching the foo.vh file.

After some research I did see an option to specify header files using -h option with ctags during tags generation. However I could not get it to work and I guess there was some syntactical error from my part.

First of all are there any notable benefits of specifying a header file using -h option? If so, what is the correct syntax to specify header files? Also can I specify emacs to look into these header files first (files with extension “.vh” &”.svh”) before parsing other files (with extension “.v” & “.sv”)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T05:37:14+00:00Added an answer on June 13, 2026 at 5:37 am

    The syntax for the -h option is -h .vh.svh

    I’m not sure why ctags is picking up `WIDTH_ADDRESS macro invocations. If WIDTH_ADDRESS is `defined multiple times it should pick up all the definitions, but not the invocations. Maybe it’s an issue with the Verilog plugin. You can always edit the tags file and delete entries you don’t want. This should be easy to do with a sed or perl script.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have recently started using DocCheck for checking the validity of JavaDoc's in code
We have recently started using FxCop on our code base and I am in
I have recently started using doc-view in Emacs, but I am having quite a
I have recently started a tutorial to learn how to code GUI using Windows
Currently I am creating VBA Macros for Excel and recently have started using UserForms.
I have recently started using Vim as my text editor and am currently working
I use git as my primary version control system, and have recently started using
I have recently started using Web-Harvest as a web scraping tool. Currently, I am
I have recently started using Netbeans with following stack Liferay, icefaces with jBoss. Is
I have recently started using RSpec for Integration testing in my Rails application, to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.