GCC Debugging/Draft

New content \ idea test page

Posssible Book Guidelines
About the book \ What is "GCC Debugging"


 * Goals:
 * verbose, easy to understand, manual
 * cover troubleshooting with GCC
 * make removing bugs a less painful \ time consuming process


 * Intended audience:
 * new gcc users with some experience in programming language being used


 * Style:
 * common language (not overly technical)


 * Book Scope:
 * gcc
 * g++
 * gdb
 * other compilers?

Error and Warning pages should include:
 * Verbose explanation of error message
 * GCC Version(s) found in
 * Earlier Versions of messages?
 * Sample code that would cause the message to be displayed
 * Fixes to get rid of trouble message (depending on cause)

Error Page Layout 1
Notes on bottom, error causes are level 3 headings under level 2, "causes"

Page Title...


 Solutions

What to change...

Arguments in a function call do not match those in any function declaration
For example, a function, "foo", is called from inside main with an argument that is not a perfect match for any of the currently existing implementations of "foo".

 Solutions

Cast the argument to match a declaration

Create a new, overloaded version of the called function to match the arguments

The same function is defined more then once

 * Look for a misspelled or duplicate function definition/declaration

Error Page Layout 2
Notes on top, causes are level 2 headings instead of 3

Page Title...

example of error message

Found in: gcc versions x.x.x to x.x.x

Past Versions: example of error message Found in: gcc versions x.x.x to x.x.x

See Also: similar error messages?

Causes:


Solutions

What to change...

example:

Page Title...

foo.cpp:23:12 call of overloaded 'foo' is ambiguous


 * Found in: gcc versions x.x.x to 4.5.1
 * Causes:

Arguments in a function call do not match those in any function declaration
For example, a function, "foo", is called from inside main with an argument that is not a perfect match for any of the currently existing implementations of "foo".

 Solutions

Cast the argument to match a declaration

Create a new, overloaded version of the called function to match the arguments

The same function is defined more then once

 * Look for a misspelled or duplicate function definition/declaration