News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

C::B 13.12 Can't work with big project which have more than 100 files.

Started by tyysoft, February 24, 2014, 03:05:59 PM

Previous topic - Next topic

ollydbg

Quote from: tyysoft on February 28, 2014, 02:40:37 PM
Here it is, my whole project files.
https://www.dropbox.com/s/f0lhi9e1y9lvh6q/wxFB_Prj.zip
Works fine here (I'm using the latest svn trunk rev9665), except there are some duplicated DecBy() functions in the suggestion list.
See image shot below:

If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

MortenMacFly

Quote from: ollydbg on February 28, 2014, 04:04:54 PMWorks fine here (I'm using the latest svn trunk rev9665), except there are some duplicated DecBy() functions [...]
Works fine here, too. The DecBy duplicates might be even OK, if these have different parameters... sure there is potential for an optimisation here.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

tyysoft


tyysoft

find the issue of rev9660!
code completion setting, if choose "Auto-select, if only one math", then the suggest list is "too many result", otherwise, the suggest list work well.


tyysoft

And a little suggestion about the code completion
wxSize* szPtr = this.GetSize();

I think the code completion thread is know the "this" is a pointer, and when I typing the ".", it should be better to change the "." to "->", is it?

oBFusCATed

Quote from: MortenMacFly on February 28, 2014, 04:56:32 PM
The DecBy duplicates might be even OK....
Looking at the screenshot they aren't OK, they are just duplicates.
Ollydbg can you check why they happen, because I've seen it on my own code.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

ollydbg

Quote from: oBFusCATed on March 01, 2014, 10:26:19 AM
Quote from: MortenMacFly on February 28, 2014, 04:56:32 PM
The DecBy duplicates might be even OK....
Looking at the screenshot they aren't OK, they are just duplicates.
Ollydbg can you check why they happen, because I've seen it on my own code.
Using the CC debug tool(dialog), I just lookup the keyword "DecBy", and I get four entries, I found that they are all overload functions.
See image shot below:

So, if they have different documents, those document will shown in the right side of the suggestion list. While we move the caret in the suggestion list, the document will change accordingly.

My suggest would be: Merge the same entry in the suggestion list, but we need also merge the document. :)
Or, we can just leave it as it is.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

ollydbg

Quote from: tyysoft on March 01, 2014, 02:26:47 AM
And a little suggestion about the code completion
wxSize* szPtr = this.GetSize();

I think the code completion thread is know the "this" is a pointer, and when I typing the ".", it should be better to change the "." to "->", is it?
We have such discussion already, but some people will complain such automatic change. Also, such change may be wrong (not the "this" case, but a pointer variable). Another case is when you are editing a C source file, then "this" is not a C language keyword.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

oBFusCATed

ollydbg: So the problem with the duplicates is that the list of parameters is not displayed for every entry?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

ollydbg

Quote from: oBFusCATed on March 01, 2014, 12:47:29 PM
ollydbg: So the problem with the duplicates is that the list of parameters is not displayed for every entry?
You can enable this code completion option: Show token's details even it hasn't documentation.
(see image shot below)


You will see their function prototypes even they don't have doxygen style document, see image shot below:
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

oBFusCATed

Okay, so they are different, but to me they look the same so we have to do one of these (or do both with an option) :
1. merge them together (the doc popup must show info for all versions in this case)
2. display the parameters, so the user know they are different
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

MortenMacFly

Quote from: oBFusCATed on March 01, 2014, 01:17:37 PM
2. display the parameters, so the user know they are different
We had removed this because the parameter list might get that large, that the CC windows won't fit on the screen.

If you want to try, in codecompletion.cpp, method CodeCompletion::CodeComplete() replace:
tmp << _T("(): ") << token->m_FullType;
...with:
tmp << token->GetFormattedArgs() << _T(": ") << token->m_FullType;

...the documentation is responsible for the details and should always be shown in the short version.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

oBFusCATed

Have you tried some string length limiting?
If yes then option 1 should be implemented. There is no point in having multiple copies of the same string in this list.
Probably this merging should be done in the CCManager in the cc_branch and not by the CC plugin.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

MortenMacFly

The idea was to have a scrollable list of methods on the left and if you scroll through them the docs window always shows the details on the right. This is as minimalistic as it gets and if you take them as a combined information then thats already option 1.

In the past (w/o docs windows) we only had the plain CC window that showed the (formatted) args as well.
Whats missing IMHO is the use case, if the docs are disabled in the CC options. Then the CC windows should return to its old behaviour and show the args as well.

I think this would be most simple and clear.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

MortenMacFly

Quote from: MortenMacFly on March 01, 2014, 01:37:54 PM
Whats missing IMHO is the use case, if the docs are disabled in the CC options. Then the CC windows should return to its old behaviour and show the args as well.
I've comitted this to trunk. Play with it.

There should only be 2 cases:
1.) A short list of methods and always the docs on the right
2.) A long list of methods including args if the docs are disabled.

Every other state is invalid and we need to dig into it.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]