Author Topic: C::B 13.12 Can't work with big project which have more than 100 files.  (Read 40856 times)

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 6034
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #15 on: February 28, 2014, 04:04:54 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:

« Last Edit: February 28, 2014, 04:10:47 pm by ollydbg »
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.

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9693
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #16 on: February 28, 2014, 04:56:32 pm »
Works 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: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline tyysoft

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #17 on: March 01, 2014, 01:43:06 am »
How about the release 13.12? no response somewhere?

Offline tyysoft

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #18 on: March 01, 2014, 01:52:28 am »
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.


Offline tyysoft

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #19 on: March 01, 2014, 02:26:47 am »
And a little suggestion about the code completion
Code
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?

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #20 on: March 01, 2014, 10:26:19 am »
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!]

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 6034
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #21 on: March 01, 2014, 12:40:06 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.

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 6034
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #22 on: March 01, 2014, 12:44:47 pm »
And a little suggestion about the code completion
Code
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.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #23 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?
(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!]

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 6034
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #24 on: March 01, 2014, 01:01:21 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.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #25 on: March 01, 2014, 01:17:37 pm »
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!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9693
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #26 on: March 01, 2014, 01:25:43 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.
« Last Edit: March 01, 2014, 01:29:20 pm by MortenMacFly »
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #27 on: March 01, 2014, 01:31:11 pm »
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!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9693
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #28 on: March 01, 2014, 01:37:54 pm »
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: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9693
Re: C::B 13.12 Can't work with big project which have more than 100 files.
« Reply #29 on: March 01, 2014, 01:45:32 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: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ