Log On
Embarcadero Home
Watch, Follow, &
Connect with Us
Share This
QualityCentral
Communities
Articles
Blogs
Resources
Downloads
Help
QualityCentral
Delphi-BCB
Debugger
Evaluator
C++
Delphi
Pascal
You are not logged in.
Help
Print
Public Report
Report From:
Delphi-BCB/Debugger/Evaluator/C++
[ Add a report in this area ]
Report #:
84266
Status:
Closed
Wrong value in watch window
Project:
C++Builder
Build #:
6.20.3512.25769
Version:
14.0
Submitted By:
Alexey Beloborodov
Report Type:
Basic functionality failure
Date Reported:
5/1/2010 7:42:21 AM
Severity:
Serious / Highly visible problem
Last Updated:
3/20/2012 2:24:39 AM
Platform:
All platforms
Internal Tracking #:
276252
Resolution:
Retest
(Resolution Comments)
Resolved in Build:
:
16.0.4251.43429
Duplicate of:
None
Voting and Rating
Overall Rating:
No Ratings Yet
0.00 out of 5
Total Votes:
None
Description
Evaluator erroneously treats address of element of std::vector (like &R[10]) as value (not as
pointer).
Steps to Reproduce:
New VCL application, button on form.
#include <vector>
void __fastcall TForm1::Button1Click(TObject *Sender)
{
std::vector<int> R;
for(int i=0; i<50000; ++i) R.push_back(-i);
bool b=false;
for(int i=0; i<50000; ++i)
if(R[i]!=i) b=true; // set breakpoint here
if(b) ShowMessage(" ! ");
}
Add watches:
Watch Name
Value
-------------------------------------------
i 16
*R._Myfirst 0, -1, -2, -3, -4, -5, -6, -7, -8, -9
R[i] -16, -17, -18, -19, -20, -21, -22, -23, -24, -25
&R[i] -16
Last value is wrong.
-------------------------------------------
In CB2007 it works correctly:
Watch Name
Value
-------------------------------------------
i 16
*R._Myfirst 0, -1, -2, -3, -4, -5, -6, -7, -8, -9
R[i] -16, -17, -18, -19, -20, -21, -22, -23, -24, -25
&R[i] :0099F250
[0] -16 (0xFFFFFFF0)
-------------------------------------------
Workarounds
None
Attachment
None
Comments
None
View Your Reports
Search
Server Response from: ETNACODE01
Developer Tools
Blackfish SQL
C++Builder
Delphi
FireMonkey
Prism
InterBase
JBuilder
J Optimizer
HTML5 Builder
3rdRail & TurboRuby
Database Tools
Change Manager
DBArtisan
DB Optimizer
ER/Studio
Performance Center
Rapid SQL
Technical Articles
Tutorials
White Papers
Press Releases
Newsletters
Add Content (GetPublished)
Audio
Audio & Video
Video
Bugs & Suggestions (QualityCentral)
Discussion Forums
Examples (CodeCentral)
Tags
Technology Partners
Downloads
Free Trials
Registered User Downloads
Beta Programs
Add Content (GetPublished)
Articles
Blogs
Bugs & Suggestions (QualityCentral)
Discussion Forums
Examples (CodeCentral)
Member Services
About
Connect with Us