Frama-C Bug Tracking System

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002119Frama-CKernelpublic2015-05-20 15:112016-01-26 13:50
Reporterhugo.illous 
Assigned Toyakobowski 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in VersionFrama-C Magnesium 
Summary0002119: "If" statement with only one successor
DescriptionWhen a "If" statements contains in its true block the sequence "do {} while (0);", in the CFG, this statement will have only one successor.
Steps To ReproduceYou can simply try with this C program and compute List.length stmt.succs
void f(int n) {
  if (n == 0) do {} while (0);
}
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0005922)
yakobowski (manager)
2015-05-23 11:58
edited on: 2015-05-23 11:58

To clarify a bit: the AST is not outright incorrect, because the statement corresponding to 'return' is indeed the successor of both the 'then' and 'else' branch. Thus one unique successor may make sense.

On the other hand, it is much better for everyone to always have two successors for an 'if', furthermore ordered by 'then < else'.

(0005926)
yakobowski (manager)
2015-05-29 11:25

Fix committed to master branch.
(0005940)
monate (reporter)
2015-06-10 14:16

C'est en cours !
(0005941)
monate (reporter)
2015-06-10 14:17

Mais avec une petite vérification de cohérence de sid quand même, donc ça sera un peu plus long...
(0006135)
yakobowski (manager)
2016-01-26 13:50

Hum, honnêtement, c'est tellement obscur que ça ne concernera personne, et je n'arriverai pas à l'expliquer dans le Changelog.

- Issue History
Date Modified Username Field Change
2015-05-20 15:11 hugo.illous New Issue
2015-05-22 10:15 signoles Assigned To => virgile
2015-05-22 10:15 signoles Status new => assigned
2015-05-23 11:32 yakobowski Assigned To virgile => yakobowski
2015-05-23 11:58 yakobowski Note Added: 0005922
2015-05-23 11:58 yakobowski Note Edited: 0005922 View Revisions
2015-05-29 11:25 yakobowski Note Added: 0005926
2015-05-29 11:25 yakobowski Status assigned => resolved
2015-05-29 11:25 yakobowski Resolution open => fixed
2015-06-10 14:16 monate Note Added: 0005940
2015-06-10 14:17 monate Note Added: 0005941
2016-01-26 08:51 signoles Fixed in Version => Frama-C Magnesium
2016-01-26 08:52 signoles Status resolved => closed
2016-01-26 13:50 yakobowski Note Added: 0006135


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker