| <html> |
| <head> |
| <title> |
| CDT's Code Analysis (Codan) |
| </title> |
| <link rel="stylesheet" type="text/css" href="help.css"> |
| <script type="text/javascript" src="thumb.js"> </script> |
| </head> |
| <body> |
| <h1 id="top">CDT's Code Analysis (Codan)</h1> |
| |
| <p>CDT's <b>Code Analysis</b> (Codan) feature assists the user by flagging possible syntax errors and |
| other issues as problems, warnings, or not at all. By default many of these |
| are flagged as errors and can be confused with compile errors. |
| <ul><li>The most frequent cause of Codan errors with PTP Synchronized projects is that the include files are located |
| on the remote machine and local Codan can't find them without being told. |
| <li>You can turn off the Codan errors, or <a href="PLUGINS_ROOT/org.eclipse.ptp.doc.user/html/includes.html">set up the remote include files</a>. |
| </li></ul> |
| <p>Codan Errors are identified with "bug icons" and they are listed in the |
| Problems View as well. |
| <p><img src="images/codan-errors.png"> |
| <p>If the include file path settings are not correct, Codan will report that the referenced APIs are in error |
| on the local Eclipse workbench. |
| For <a href="PLUGINS_ROOT/org.eclipse.ptp.doc.user/html/sync.html">synchronized projects</a>, if you do not care to see errors on the local copies or use Eclipse |
| hyperlink navigation within the editor, you may not want to see Codan errors. |
| (The build system on the remote target probably correctly locates include files during build). |
| <p>You may want to turn off Codan or change its default reporting to Warning instead of Error. |
| <p>To modify the Codan settings, open Preferences |
| (Window > Preferences, or on Mac OS X, Eclipse > Preferences) |
| and under <b>C/C++</b> select <b>Code Analysis</b> |
| <p><img src="images/codan-prefs.png"> |
| <p>To turn off the Codan errors, uncheck the boxes - uncheck the box at the top of |
| each category and it will disable all the items in that category. |
| Be sure to scroll down in the <b>Problems</b> list to see them all. |
| You can also change |
| the error or warning level of each item by selecting the <b>Customize Selected...</b> |
| button. |
| <p>If the Codan errors don't disappear when you close the Preferences dialog, you may need |
| to re-run Codan. You can re-run Codan by selecting the project in the Project Explorer, |
| and selecting rightmouse > Run C/C++ Code Analysis via the context menu. |
| <p><img src="images/codan-run.png"> |
| <p>If you turned off Codan errors in the Preferences, then the error markers should disappear. |
| <p> <p> <p> |
| <p><a href="#top">Back to Top</a> | <a href="toc.html">Back to PLDT Table of Contents</a> |
| |
| </body> |
| </html> |