carbidecpp22devenv/configuration/org.eclipse.osgi/bundles/309/1/.cp/tasks/cdt_t_add_watch.htm
author cawthron
Fri, 04 Dec 2009 10:01:33 -0600
changeset 5 684bf18fdedf
permissions -rw-r--r--
add files for RCL_2_2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
5
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     2
<html lang="en">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     3
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     4
<head>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     5
<meta http-equiv="Content-Language" content="en-us">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     6
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     7
<meta name="ProgId" content="FrontPage.Editor.Document">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     8
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
     9
<title>Adding watchpoints</title>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    10
<link rel="stylesheet" type="text/css" href="../help.css">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    11
</head>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    12
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    13
<body>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    14
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    15
<h1>Adding watchpoints</h1>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    16
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    17
<p>A watchpoint is a special breakpoint that stops the execution of an 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    18
application whenever the value of a given expression changes, without specifying 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    19
where it might occur. Unlike breakpoints (which are line-specific), watchpoints 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    20
are associated with files. They take effect whenever a specified condition is 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    21
true, regardless of when or where it occurred. You can set a watchpoint on a global variable by highlighting the variable in the editor, or by selecting it in the Outline view. </p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    22
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    23
<p>To set a watchpoint on a global variable:</p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    24
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    25
<ol>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    26
  <li>Highlight the variable in the editor, or select it in the Outline view.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    27
  <li>Click <b>Run &gt; Toggle Watchpoint</b>.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    28
  <li>Do any of the following:</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    29
  <ul><li>To stop execution when the watch expression is read, select the
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    30
  <b>Read</b> check box.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    31
  <li>To stop execution when  the watch expression is written to, select the <b>Write</b> 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    32
  check box.</li></ul>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    33
  <li>The watchpoint appears in the <b>Breakpoints</b> view 
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    34
  list.</li>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    35
</ol>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    36
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    37
<p><img border="0" src="../images/ngconcepts.gif" ALT="Related concepts" width="143" height="21">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    38
<br>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    39
<a href="../concepts/cdt_c_over_cdt.htm">C/C++ Development perspective</a></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    40
<p><img border="0" src="../images/ngtasks.gif" ALT="Related tasks" width="143" height="21">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    41
<br>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    42
<a href="cdt_o_brkpnts_watch.htm">Using breakpoints and watchpoints</a></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    43
<p><img border="0" src="../images/ngref.gif" ALT="Related reference" width="143" height="21">
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    44
<br>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    45
<a href="../reference/cdt_o_run_dbg_pages.htm">Run and Debug dialog box</a></p>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    46
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    47
<img src="../images/ng00_04a.gif" ALT="QNX Copyright Statement" >
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    48
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    49
</body>
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    50
684bf18fdedf add files for RCL_2_2
cawthron
parents:
diff changeset
    51
</html>