Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: nick name on September 08, 2017, 11:10:29 am

Title: headers suggestions
Post by: nick name on September 08, 2017, 11:10:29 am
I decieded to update my old version of codeblocks (11.12) to the last one I could find, 16.01. I noted that when I type "#include <", the standard headers are'nt displayed. The only suggesions are in the header's search directories I added to the project. I searched in the Editor's parameters and did not find any solutions. Is it possible to display them without adding a search directory of the main header's directory for each projects ?
Title: Re: headers suggestions
Post by: BlueHazzard on September 08, 2017, 01:48:42 pm
Have you started to type more characters? The completion should kick in after 3 letters.
Title: Re: headers suggestions
Post by: oBFusCATed on September 08, 2017, 09:05:50 pm
State your OS and compiler versions, please.
Title: Re: headers suggestions
Post by: nick name on September 09, 2017, 03:34:12 pm
Have you started to type more characters? The completion should kick in after 3 letters.
Of course, and even with the ctrl+space, it just suggest the headers in the added directories.
I have Code::Blocks 16.01, and MinGW with gcc 6.3.0, and my os is windows 10 wow64
Title: Re: headers suggestions
Post by: oBFusCATed on September 09, 2017, 04:45:34 pm
@ollydbg: Is there a way to see the folders that the CC plugin detects by calling GCC? On linux this is possible by using the -v --debug-log flags when starting C::B in terminal. But I don't have an idea if this works similarly on windows.
Title: Re: headers suggestions
Post by: ollydbg on September 09, 2017, 05:02:27 pm
@ollydbg: Is there a way to see the folders that the CC plugin detects by calling GCC? On linux this is possible by using the -v --debug-log flags when starting C::B in terminal. But I don't have an idea if this works similarly on windows.
yes, the same thing under Windows, the log messages are shown in "debug log" panel.
Title: Re: headers suggestions
Post by: oBFusCATed on September 09, 2017, 05:14:22 pm
@nick name:
Can you start codeblocks from a cmd.exe window and can you pass these two arguments "-v --debug-log" (without the quotes)?
Then try to reproduce the problem and paste the contents of the "Debug log" window here using code or quote tags.
Title: Re: headers suggestions
Post by: nick name on September 09, 2017, 05:41:47 pm
I started CB with arguments -v --debug-log, and it worked! the output when loading headers is

"ClassBrowser::OnThreadEvent(): Updating class browser...
ClassBrowser::OnThreadEvent(): Class browser updated.
SystemHeadersThread: C:\MinGW\lib\gcc\mingw32\6.3.0\include\c++\ , 656
SystemHeadersThread: C:\MinGW\lib\gcc\mingw32\6.3.0\include\c++\mingw32\ , 23
SystemHeadersThread: C:\MinGW\lib\gcc\mingw32\6.3.0\include\c++\backward\ , 8
SystemHeadersThread: C:\MinGW\lib\gcc\mingw32\6.3.0\include\ , 90
SystemHeadersThread: C:\MinGW\include\ , 2346
SystemHeadersThread: C:\MinGW\lib\gcc\mingw32\6.3.0\include-fixed\ , 3
SystemHeadersThread: C:\MinGW\mingw32\include\ , 5
SystemHeadersThread: Total number of paths: 7"
and it resolved my problem because when I rebooted my CB, the suggestions were rights. Thank you for help!
Title: Re: headers suggestions
Post by: oBFusCATed on September 09, 2017, 06:01:44 pm
This is strange. Anyway good to know that the problem is no resolved.

Can you tell me if it works when you start codeblock without passing these two parameters?
Title: Re: headers suggestions
Post by: nick name on September 10, 2017, 07:59:54 pm
Since I started cb in debug mode, suggestions are alwayse rights. I don't know if the problem was resolved thanks to the debug mdoe or by itself, but it works  ;D