Connecting Tech Pros Worldwide Help | Site Map

Any package for printing out type information for debugging programs using templates?

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 8th, 2005, 01:05 AM
PengYu.UT@gmail.com
Guest
 
Posts: n/a
Default Any package for printing out type information for debugging programs using templates?

I found that it is extremely unproductive to debug programs using
templates a lot. Although I could manually define some types to help
printing out type informations, it is still tedious for me. Are there
any package available for this purpose?

Thanks,
Peng


  #2  
Old November 8th, 2005, 05:25 PM
mlimber
Guest
 
Posts: n/a
Default Re: Any package for printing out type information for debugging programs using templates?

PengYu.UT@gmail.com wrote:[color=blue]
> I found that it is extremely unproductive to debug programs using
> templates a lot. Although I could manually define some types to help
> printing out type informations, it is still tedious for me. Are there
> any package available for this purpose?
>
> Thanks,
> Peng[/color]

You could use the typeid operator and std::cout. The content returned
by type_info::name() is implementation-defined, but it might be
sufficient for your needs.

Also, you might consider using the script mentioned in response to one
of your previous questions on templates:

http://groups.google.com/group/comp....fce0636fea3f16

It generates classes from template definitions so you can see the final
product, though it won't work with all modern template features.

Cheers! --M

 

Bookmarks

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

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

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,989 network members.