Author Topic: how to activate Jump to error/warning  (Read 8796 times)

Offline eb

  • Multiple posting newcomer
  • *
  • Posts: 46
how to activate Jump to error/warning
« on: January 28, 2012, 02:38:41 am »
All of a sudden CodeBlocks no longer jumps the the proper file/line when I click the error in the message box.  How do i turn it back on?

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: how to activate Jump to error/warning
« Reply #1 on: January 28, 2012, 02:58:51 am »
Make sure the program is done compiling.
Make sure you are in the "Build Messages" tab.

Those are the two causes that make it not work for me.

"View" -> "Perspective" controls the "Log & other" tabs that show up on start up.
Right clicking on an existing tab should give you options to toggle tabs that show up.

Tim S.
« Last Edit: January 28, 2012, 03:01:10 am by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: how to activate Jump to error/warning
« Reply #2 on: January 28, 2012, 08:55:02 am »
All of a sudden CodeBlocks no longer jumps the the proper file/line when I click the error in the message box.  How do i turn it back on?

If you have non-ascii characters or spaces in the filename (including the path), it can cause this, at least in older revisions.

Offline eb

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: how to activate Jump to error/warning
« Reply #3 on: January 30, 2012, 07:44:48 pm »
It's done compiling.  I'm on the 'Build Messages' window.  There are no spaces or special characters in the path.  It compiled fine with this setup for a couple of week.

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: how to activate Jump to error/warning
« Reply #4 on: January 30, 2012, 08:09:14 pm »
It has nothing to do with compiling.
Can you (copy and) post the relevant parts of the "Build log" and the "Build messages" tab ?

And please tell us which version of C::B, which OS and which compiler (and version) you use !

Offline eb

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: how to activate Jump to error/warning
« Reply #5 on: January 30, 2012, 10:25:14 pm »
I don't think it has anything to do with compiling either.  And I'm not sure if the logs help but here goes:

BUILD MESSAGES:
||=== rap00, Release ===|
\usr\include\sys\types.h|26|bits/types.h: No such file or directory|
\usr\include\rpc\xdr.h|114|error: parse error before "bool_t"|
\usr\include\rpc\xdr.h|117|error: parse error before '*' token|
\usr\include\rpc\xdr.h|117|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|120|error: parse error before '*' token|
\usr\include\rpc\xdr.h|120|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|123|error: parse error before '*' token|
\usr\include\rpc\xdr.h|123|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|129|error: parse error before '*' token|
\usr\include\rpc\xdr.h|129|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|138|error: parse error before '*' token|
\usr\include\rpc\xdr.h|138|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|141|error: parse error before '*' token|
\usr\include\rpc\xdr.h|141|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|143|error: parse error before '}' token|
\usr\include\rpc\xdr.h|148|error: parse error before '}' token|
\usr\include\rpc\xdr.h|159|error: parse error before '*' token|
\usr\include\rpc\xdr.h|159|error: parse error before '*' token|
\usr\include\rpc\xdr.h|159|error: `bool_t' declared as function returning a function|
\usr\include\rpc\xdr.h|159|error: 'bool_t' redeclared as different kind of symbol|
\usr\include\rpc\xdr.h|141|error: previous declaration of 'bool_t' was here|
\usr\include\rpc\xdr.h|159|error: 'bool_t' redeclared as different kind of symbol|
\usr\include\rpc\xdr.h|141|error: previous declaration of 'bool_t' was here|
\usr\include\rpc\xdr.h|250|error: parse error before "xdrproc_t"|
\usr\include\rpc\xdr.h|295|error: `xdr_void' declared as function returning a function|
\usr\include\rpc\xdr.h|296|error: parse error before '*' token|
\usr\include\rpc\xdr.h|296|error: `xdr_short' declared as function returning a function|
\usr\include\rpc\xdr.h|297|error: parse error before '*' token|
\usr\include\rpc\xdr.h|297|error: `xdr_u_short' declared as function returning a function|
\usr\include\rpc\xdr.h|298|error: parse error before '*' token|
\usr\include\rpc\xdr.h|298|error: `xdr_int' declared as function returning a function|
\usr\include\rpc\xdr.h|299|error: parse error before '*' token|
\usr\include\rpc\xdr.h|299|error: `xdr_u_int' declared as function returning a function|
\usr\include\rpc\xdr.h|300|error: parse error before '*' token|
\usr\include\rpc\xdr.h|300|error: `xdr_long' declared as function returning a function|
\usr\include\rpc\xdr.h|301|error: parse error before '*' token|
\usr\include\rpc\xdr.h|301|error: `xdr_u_long' declared as function returning a function|
\usr\include\rpc\xdr.h|302|error: parse error before '*' token|
\usr\include\rpc\xdr.h|302|error: `xdr_int8_t' declared as function returning a function|
\usr\include\rpc\xdr.h|303|error: parse error before '*' token|
\usr\include\rpc\xdr.h|303|error: `xdr_uint8_t' declared as function returning a function|
\usr\include\rpc\xdr.h|304|error: parse error before '*' token|
\usr\include\rpc\xdr.h|304|error: `xdr_u_int8_t' declared as function returning a function|
\usr\include\rpc\xdr.h|305|error: parse error before '*' token|
\usr\include\rpc\xdr.h|305|error: `xdr_int16_t' declared as function returning a function|
\usr\include\rpc\xdr.h|306|error: parse error before '*' token|
\usr\include\rpc\xdr.h|306|error: `xdr_uint16_t' declared as function returning a function|
\usr\include\rpc\xdr.h|307|error: parse error before '*' token|
\usr\include\rpc\xdr.h|307|error: `xdr_u_int16_t' declared as function returning a function|
\usr\include\rpc\xdr.h|308|error: parse error before '*' token|
||More errors follow but not being shown.|
||Edit the max errors limit in compiler options...|
||=== Build finished: 50 errors, 0 warnings ===|

BUILD LOG:



-------------- Clean: Release in rap00 ---------------

Cleaned "rap00 - Release"

-------------- Build: Release in rap00 ---------------

gcc-3.exe -Wall  -O2    -IC:/cygwin/usr/include/tirpc  -c C:/cygwin/home/eb/rap00/main.c -o obj/Release/main.o
In file included from /usr/include/stdio.h:46,
                 from C:/cygwin/home/eb/rap00/main.c:1:
/usr/include/sys/types.h:26:24: bits/types.h: No such file or directory
In file included from /usr/include/tirpc/rpc/rpc.h:43,
                 from C:/cygwin/home/eb/rap00/rap.h:16,
                 from C:/cygwin/home/eb/rap00/main.c:10:
/usr/include/rpc/xdr.h:114: error: parse error before "bool_t"
/usr/include/rpc/xdr.h:117: error: parse error before '*' token
/usr/include/rpc/xdr.h:117: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:120: error: parse error before '*' token
/usr/include/rpc/xdr.h:120: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:123: error: parse error before '*' token
/usr/include/rpc/xdr.h:123: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:129: error: parse error before '*' token
/usr/include/rpc/xdr.h:129: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:138: error: parse error before '*' token
/usr/include/rpc/xdr.h:138: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:141: error: parse error before '*' token
/usr/include/rpc/xdr.h:141: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:143: error: parse error before '}' token
/usr/include/rpc/xdr.h:148: error: parse error before '}' token
/usr/include/rpc/xdr.h:159: error: parse error before '*' token
/usr/include/rpc/xdr.h:159: error: parse error before '*' token
/usr/include/rpc/xdr.h:159: error: `bool_t' declared as function returning a function
/usr/include/rpc/xdr.h:159: error: 'bool_t' redeclared as different kind of symbol
/usr/include/rpc/xdr.h:141: error: previous declaration of 'bool_t' was here
/usr/include/rpc/xdr.h:159: error: 'bool_t' redeclared as different kind of symbol
/usr/include/rpc/xdr.h:141: error: previous declaration of 'bool_t' was here
/usr/include/rpc/xdr.h:250: error: parse error before "xdrproc_t"
/usr/include/rpc/xdr.h:295: error: `xdr_void' declared as function returning a function
/usr/include/rpc/xdr.h:296: error: parse error before '*' token
/usr/include/rpc/xdr.h:296: error: `xdr_short' declared as function returning a function
/usr/include/rpc/xdr.h:297: error: parse error before '*' token
/usr/include/rpc/xdr.h:297: error: `xdr_u_short' declared as function returning a function
/usr/include/rpc/xdr.h:298: error: parse error before '*' token
/usr/include/rpc/xdr.h:298: error: `xdr_int' declared as function returning a function
/usr/include/rpc/xdr.h:299: error: parse error before '*' token
/usr/include/rpc/xdr.h:299: error: `xdr_u_int' declared as function returning a function
/usr/include/rpc/xdr.h:300: error: parse error before '*' token
/usr/include/rpc/xdr.h:300: error: `xdr_long' declared as function returning a function
/usr/include/rpc/xdr.h:301: error: parse error before '*' token
/usr/include/rpc/xdr.h:301: error: `xdr_u_long' declared as function returning a function
/usr/include/rpc/xdr.h:302: error: parse error before '*' token
/usr/include/rpc/xdr.h:302: error: `xdr_int8_t' declared as function returning a function
/usr/include/rpc/xdr.h:303: error: parse error before '*' token
/usr/include/rpc/xdr.h:303: error: `xdr_uint8_t' declared as function returning a function
/usr/include/rpc/xdr.h:304: error: parse error before '*' token
/usr/include/rpc/xdr.h:304: error: `xdr_u_int8_t' declared as function returning a function
/usr/include/rpc/xdr.h:305: error: parse error before '*' token
/usr/include/rpc/xdr.h:305: error: `xdr_int16_t' declared as function returning a function
/usr/include/rpc/xdr.h:306: error: parse error before '*' token
/usr/include/rpc/xdr.h:306: error: `xdr_uint16_t' declared as function returning a function
/usr/include/rpc/xdr.h:307: error: parse error before '*' token
/usr/include/rpc/xdr.h:307: error: `xdr_u_int16_t' declared as function returning a function
/usr/include/rpc/xdr.h:308: error: parse error before '*' token
Process terminated with status 1 (0 minutes, 2 seconds)
50 errors, 0 warnings
 

Offline eb

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: how to activate Jump to error/warning
« Reply #6 on: January 31, 2012, 07:43:39 pm »
I re-installed Code Blocks (did not uninstall first).  Still doesn't work.  Is this a known bug?

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: how to activate Jump to error/warning
« Reply #7 on: January 31, 2012, 08:09:46 pm »
I re-installed Code Blocks (did not uninstall first).  Still doesn't work.  Is this a known bug?
It is not a known bug but how do you believe shall Windows guess on what path a Unix folder name resides?

If you look at the errors, they are in Unix format and you are on a Windows platform. Without tricks this cannot work. Use a native Windows compiler (not Cygwin) if possible and it will work.
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 eb

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: how to activate Jump to error/warning
« Reply #8 on: January 31, 2012, 08:51:32 pm »
I have to use Cygwin because it is the Cygwin library that contains the clnt_create function that will be required to execute the BSD socket based RPC call to the server.
(I am also attempting this project using the Microsoft Services for Unix library but that is for another thread.)

Also Code Blocks seems to understand that "/usr/include/sys/types.h" is the same as "c:\cygwin\usr\include\sys\types.h" as I have my search directories set up properly.

Offline eb

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: how to activate Jump to error/warning
« Reply #9 on: January 31, 2012, 08:53:17 pm »
Another bit of info:
  It seems that when I open the file that contains the error Code Blocks places the marker (the red rectangle in the margin to the left) in the proper line, or in this case: there is only one error and code blocks places the marker whether I highlight the error message or not.

Also, I've made progrees regard the code itself so now my Build log looks like this:



-------------- Clean: Release in rap00 ---------------

Cleaned "rap00 - Release"

-------------- Build: Release in rap00 ---------------

gcc-3.exe -Wall  -O2    -IC:/cygwin/usr/include/tirpc -IC:/cygwin/usr/include  -c C:/cygwin/home/eb/rap00/main.c -o obj/Release/main.o
In file included from C:/cygwin/usr/include/tirpc/rpc/rpc.h:46,
                 from C:/cygwin/home/eb/rap00/rap.h:13,
                 from C:/cygwin/home/eb/rap00/main.c:10:
C:/cygwin/usr/include/tirpc/rpc/auth.h:83: error: redefinition of `struct netbuf'
C:/cygwin/home/eb/rap00/main.c: In function `rapvar_read_name_1':
C:/cygwin/home/eb/rap00/main.c:41: warning: function returns address of local variable
C:/cygwin/home/eb/rap00/main.c: In function `main':
C:/cygwin/home/eb/rap00/main.c:94: warning: passing arg 4 of `rpcb_getaddr' from incompatible pointer type
C:/cygwin/home/eb/rap00/main.c:48: warning: unused variable `Pclient'
Process terminated with status 1 (0 minutes, 0 seconds)
1 errors, 3 warnings
 
But it still won't jump to the error...PLUS if you'll notice it ALSO it no longer tells me where the original definition of `struct netbuf' occurs.
« Last Edit: January 31, 2012, 08:58:42 pm by eb »