Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Template for STDMETHOD create impl?

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
peterchen Posted - Jan 29 2019 : 06:36:02 AM
When I have a COM class declaration containing


struct CoClass
{
  STDMETHOD(MemFn)();
};


and I choose "create implementation" for MemFn, I get


STDMETHODIMP CoClass::MemFn()
{
   return S_OK;
}


This seems to be a custom body for this type of method (it is not the "Create From Usage Method Body" snippet), but I can't find where I can customize this.

Independent of making it customizable, consider making "return E_NOTIMPL" the default. his wpuld be the equivalent of throwing a not-implemented-exception.

Thank you!

(edit: fixed formatting)
1   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Jan 29 2019 : 07:18:16 AM
A good point, I cannot see any way to control this default body either, I have put in a feature request for this, we really should have control here:

case=135767

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