Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 1724: no suggestion in semi-obvious case

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
tandr Posted - May 05 2009 : 4:14:26 PM
VS2008, SP1 + hotfixes to compiler.

the code


#include <string>
#include <vector>

class Dset
{
private:
    std::vector<std::string> m_strings;
    
    int func(const std::string& str)
    {
        for (int i = 0; i < m_strings.size(); ++i)
            if (m_strings[i]. compare(str) == 0)
            //               ^ put caret here
                return i;
    
        return -1;
    }
};



If you place caret after m_strings[i]. -- member functions are listed, but compare is not in the list!!! Alt-G does not know about it either. Am I missing something here?

BTW, if I replace it with
if (str.compare(m_strings[i])==0)
it does work -- compare is in the list, Alt-G pops bunch of possibilities from <xstring>

VA_X.dll file version 10.5.1724.0 built 2009.05.01
Licensed to:
VA X: <[email protected]> (1-user license) Support ends 2010.02.04
DevEnv.exe version 9.0.30729.1
msenv.dll version 9.0.30729.1
Font: Consolas 11(Pixels)
Comctl32.dll version 6.0.2900.5512
Windows XP 5.1 Build 2600 S
2 processors (x86)

Platform: Win32
Stable Includes:
D:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\include;
D:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\atlmfc\\include;
D:\\Program Files\\Microsoft SDKs\\Windows\\v6.1\\include;
D:\\Program Files\\Microsoft SDKs\\Windows\\v6.1\\include;
E:\\svn\\repos\\3rd\\boost\\tags\\Boost_1_39_0;

Other Includes:

Stable Source Directories:
D:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\atlmfc\\src\\mfc;
D:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\atlmfc\\src\\mfcm;
D:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\atlmfc\\src\\atl;
D:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\crt\\src;



1   L A T E S T    R E P L I E S    (Newest First)
accord Posted - May 05 2009 : 6:14:04 PM
I am seeing the same effect here. Thank you for the clear description.

case=26666

For now, turn on

VA Options -> Advanced -> Listboxes -> Get content from default Intellisense

This will help to produce correct completion list for std::string.

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