Developer forums (C::B DEVELOPMENT STRICTLY!) > Plugins development

modify codecompletion plugin to macro parser

<< < (2/5) > >>

visualfc:
I already changes the template<> class for browse. the code update for top download

Make new GetRealArgs to supper class member method parser

   example OnAbout(wxCommandEvent& event) == OnAbout(wxCommandEvent& WXUNUSED(event))

The macro parser:
First test the name is all upper then parser to macro. while there are some global function , but the most of the remaining is correct

blueshake:
hi,visualfc
in this statement,
--- Code: ---static wxString GetRealArgs(const wxChar * args
--- End code ---
why not use statement like this
--- Code: ---static wxString GetRealArgs(const wxString& args)
--- End code ---

I just have a quick review on the codes.I don't understand why doing this.
--- Code: --- newToken = TokenExists(newname+realArgs, localParent);
--- End code ---
the reason is just as ollydbg said above,
--- Quote ---1, it seems you just let the template argument appending to the "Token name", in my opinion, that is not a good idea, because it will disorder the Token tree, because the Token name is the tree's search key.
--- End quote ---
since you have save the template args in m_RealArgs.

I think it is better to do this
--- Code: ---newToken->m_Type = readType + m_RealArgs;
--- End code ---
for better token hover tip.

blueshake:
hi,it seems the template has not worked.

--- Code: ---struct qq
{
    int x;
    int y;
};
template<typename aa>
class xx
{
    aa tt;
};

xx<qq> oo;

oo.tt.-------not tip
--- End code ---

did I miss something?

visualfc:
@blueshake

I‘m sorry, I'm not English,can only guess what you mean, Similarly, do not know whether the right to write.

The code GetRealArgs is portable code, keep compatibility. I would like to improve the quality of the code。

The code tokenExists(newname+realArgs,...) to ensure that function name unique.The reason is to search class method name.
I will try to the code newToken->m_Type = readType + m_RealArgs;


@blueshake
the template<> already parser, but don't visible on browser tree. only on code search can be find.

blueshake:

--- Quote ---@blueshake
the template<> already parser, but don't visible on browser tree. only on code search can be find.
--- End quote ---

hi,Can you provide the codes.For me ,the code suggestion list don't show me the "x" and "y" in the class "qq"body but visual assist worked.
see the screen shot below.

see the screen shot.this is codeblock's tip.

this is visual assist's tip.


see,visual assist can find the right type for oo.tt. I think this is why visual assist can work and codeblock didn't.


Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version