Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > default arguments in class member template functions

Reply
Thread Tools

default arguments in class member template functions

 
 
Hicham Mouline
Guest
Posts: n/a
 
      09-15-2009
Hello,
I am debugging (vs200 the following code:
http://codepad.org/zy3WFbe7

From user code, I call:

const Curve1D<Trait> curve(/* ctor arguments*/);
double y = curve.Get<Something, Linear1D>( x );

when I get in the implementation of the Get() member function, the e that is
supposed to be constructed
with Linear1D() default ctor, isn't properly set.

introspecting e shows that
mfPrimebegin=NaN
mfPrimeend= 7.737463760456e-317#DEN
mfboundary= 3.6492352064455326e-307while they should all be NaNThis is in
debug.Is there a problem defining the Get function outside of its
encapsulating class?especially that it is a template member
function?regards,


 
Reply With Quote
 
 
 
Reply

Thread Tools

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
default arguments for class member template function Hicham Mouline C++ 3 09-16-2009 12:13 PM
overloading non-template member functions with template member functions Hicham Mouline C++ 1 04-24-2009 07:47 AM
overloading non-template member functions with template member functions Hicham Mouline C++ 0 04-23-2009 11:42 AM
Member function pointers to member functions with default arguments Hamish C++ 3 01-25-2008 06:46 AM
parse error in gcc but success in vc.net, call a non_template class's template member function from a template class's member function! ken C++ 2 06-28-2005 06:57 AM



Advertisments
 



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 47 48 49 50 51 52 53 54 55 56 57