Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Template parameters of functions.

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
tailsu Posted - Sep 11 2007 : 03:54:27 AM
Template functions in C++ have a nice feature that lets them figure out their template arguments automatically. However it's not always possible, and some functions aren't even meant to do so.

However VA doesn't know and respect this.

Take boost::fusion::at_c() for example, it's used as follows:
at_c<0>(fusionSeq);
0 must always be passed explicitly.

It would be nice for VA to know about this and insert <>() (or something like this, instead of just () when auto-completing..
2   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Sep 11 2007 : 08:19:52 AM
We are considering having VA automatically insert the angle brackets along with the round brackets when it knows you are calling a template function:

case=460

I am a little wary of special casing the angle brackets as you describe in your second post, although off hand I cannot think of anything this would break.
tailsu Posted - Sep 11 2007 : 04:07:24 AM
It seems to me that the most intuitive way would be when being at
at_c(*cursor*)

pressing '<' takes us to

at_c<*cursor*>()

This way VA doesn't even need to understand about deducible template parameters and whatnot, just an editing aid.

How about it?

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000