Connecting Tech Pros Worldwide Help | Site Map

Help on template specialization

 
LinkBack Thread Tools Search this Thread
  #1  
Old July 19th, 2005, 04:17 PM
Virendra Verma
Guest
 
Posts: n/a
Default Help on template specialization

Hi all,

Is second definition a specialization of the first as per Stroustrup?
Visual C++ thinks it is not (error C2912 ). Thanks for help.

template< class T, class Cmp >
bool BinSearch( int& nMid, const T * pVec, int nSize, Cmp& cmp );

template<>
bool BinSearch( int& nMid, const char ** pVec, int nSize,
Comparator<const char *>& cmp );

  #2  
Old July 19th, 2005, 04:20 PM
Virendra Verma
Guest
 
Posts: n/a
Default Re: Help on template specialization

Thanks, Victor.
 

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,840 network members.