- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a problem with conditional breakpoints - if I place a breakpoint in the code and specify a condition that uses a logical variable, VS crashes once the breakpoint location is reached. If I remove the condition, everything is OK and VS does not crash.
Breakpoint is set in a global subroutine (not in any module), the logical variable is used from a module (let's call it "Settings"), so the subroutine contains the line "use Settings, only : applyCorrection". The breakpoint condition is "applyCorrection.eq..TRUE.".
Am I specifying the breakpoint condition incorrectly?
I use VS 2010 Professional SP1 and IPS XE 2016 Update 3 on Windows 7 Professional SP1.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can you provide more details about the condition? What is the expression? Do you use "is true" or "has changed"?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am sorry, I forgot to be more specific. The expression is mentioned in my original post, it is
applyCorrection.eq..TRUE.
where logical*4 :: applyCorrection is a module variable and "Is true" is used in the breakpoint condition.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I don't know about the innards of the VS expression evaluator, but in Fortran you should have used
IF (applyCorrection) ...
instead of using the comparison operator .EQ., which should not be used to compare logical variables.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
applyCorrection.eq..TRUE. ! throws an error applyCorrection.eqv..TRUE. !works ok
In an example I made
but whey not have the condition as just applyCorrection
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What I see is that if I use .EQ. in the condition, the breakpoint isn't hit. If I use .EQV. it is. I can also just put the name of the variable as the condition and select "Is true". But I don't get a VS crash. This is in VS2010 with 16.0.3.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
additional: I note in your other thread you have VS2010, I tested in VS2013 and at run time that says the condition is invalid so maybe that is an improvement to VS2010 just crashing....
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for your quick help how to make the conditional breakpoint using logical variable work. I will give it a try after updating XE 2016 to Update 4. :-)
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page