View Issue Details

IDProjectCategoryView StatusLast Update
0019113LazarusIDEpublic2011-12-01 11:26
ReporterZex Atilla Assigned ToJuha Manninen  
Status closedResolutionno change required 
Product Version0.9.30.1 (SVN) 
Summary0019113: Assertion error doesn't open the right source
DescriptionWhen an Assert triggers the exception, it would be nice if Lazarus would open the source file at the position where that Assert was located.

I don't know why is it opening the UTrace.pp file every time. Can't the real address be read from call stack?
Tagsassert, assertion, assertions, button, trace, utrace.pp
Fixed in Revision
Attached Files


Vincent Snijders

2011-04-06 19:25

manager   ~0047291

I think the utrace unit is the real address, because that is the place where the assertproc points to.

2011-05-06 19:04


AssertionFailure.jpg (16,301 bytes)   
AssertionFailure.jpg (16,301 bytes)   

Juha Manninen

2011-05-06 19:10

developer   ~0048097

The solution is to NOT use "UTrace" unit. Without it an Assert failure shows the correct unit and line number. See the attched screenshot.

Martin Friebe

2011-05-07 22:05

manager   ~0048125

The problem is also present if utrace isn't used. It is only hidden, since the rtl has no debug info (compile rtl with dbg info, and the issue will become visible)

Also, it is supposed to work with utrace too. So this seems to be a bug.

However, this appears to be an issue in fpc. "assert" contains code similar to the one in 0012528

Martin Friebe

2011-05-08 11:45

manager   ~0048127

the issue is now reported as 0019310

Issue History

Date Modified Username Field Change
2011-04-06 18:51 Zex Atilla New Issue
2011-04-06 18:51 Zex Atilla Widgetset => Win32/Win64
2011-04-06 18:51 Zex Atilla Tag Attached: assert
2011-04-06 18:51 Zex Atilla Tag Attached: assertion
2011-04-06 18:51 Zex Atilla Tag Attached: assertions
2011-04-06 18:51 Zex Atilla Tag Attached: trace
2011-04-06 18:51 Zex Atilla Tag Attached: utrace.pp
2011-04-06 18:52 Zex Atilla Tag Attached: button
2011-04-06 19:25 Vincent Snijders Note Added: 0047291
2011-05-06 18:56 Juha Manninen Status new => assigned
2011-05-06 18:56 Juha Manninen Assigned To => Juha Manninen
2011-05-06 19:04 Juha Manninen File Added: AssertionFailure.jpg
2011-05-06 19:10 Juha Manninen LazTarget => -
2011-05-06 19:10 Juha Manninen Status assigned => resolved
2011-05-06 19:10 Juha Manninen Resolution open => no change required
2011-05-06 19:10 Juha Manninen Note Added: 0048097
2011-05-07 22:05 Martin Friebe Note Added: 0048125
2011-05-08 11:45 Martin Friebe Note Added: 0048127
2011-12-01 11:26 Marc Weustink Status resolved => closed