Jump to content
Sign in to follow this  
Mike Torrettinni

Simple debugger bug in 11.1

Recommended Posts

Delphi 11.1, no patch 1 installed, yet.

 

Can someone confirm they get same/similar debugger bug in this example code:

uses System.StrUtils;

procedure TForm1.Button2Click(Sender: TObject);
var
  vPos1, vPos2: Integer;
  vLine, s: string;
begin
  vLine :='testingcompiler';
  vPos1 := 5;
  vPos2 := 7;
  s := MidStr(vLine, vPos1 + 1, vPos2 - vPos1 - 1);  <-- Park cursor here and copp MidStr call to debugger
end;

 

Run and park on MidStr() call and copy the expression to debugger. I get an error F2084 Internal error... instead of 'n' in watch value:

 

image.thumb.png.e7be7c32163821a3ac7cdf3f80d2c960.png

 

 

I really hope is just my copy and perhaps reinstall or patch 1 solves this.

 

No problems with this code in 10.2.3

Share this post


Link to post

Indeed broken since after 10.2.3, can repro the F2084 in the evaluator in 10.3.3, 10.4.2 and 11.1

Share this post


Link to post
2 minutes ago, Stefan Glienke said:

Indeed broken since after 10.2.3, can repro the F2084 in the evaluator in 10.3.3, 10.4.2 and 11.1

Hm, quite disappointing, but maybe this is very rarely used the way I use MidStr, or perhaps MidStr is on the way to be deprecated and they don't want to waste time on it.

Share this post


Link to post
Posted (edited)

MidStr has nothing to do with it - it's a bug in the evaluator. If you put MidStr(vLine, 6, 1) into the evaluator it properly shows 'n'.

Please report

Edited by Stefan Glienke

Share this post


Link to post
12 minutes ago, Stefan Glienke said:

MidStr has nothing to do with it - it's a bug in the evaluator. If you put MidStr(vLine, 6, 1) into the evaluator it properly shows 'n'.

Please report

OK, it makes sense. Well, at least the workaround is simple: don't give debugger any tough math to do.

  • Haha 1

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×