Changes
Page history
loop
authored
Feb 06, 2020
by
Markus Klinik
Show whitespace changes
Inline
Side-by-side
Home.md
View page @
a177d1b5
...
...
@@ -390,3 +390,37 @@ bool onOff(int x)
[

](https://gitlab.science.ru.nl/mklinik/eca-symbolic-execution/blob/master/code/website/recursive-onOff-no-merge-highres.svg)
[

](https://gitlab.science.ru.nl/mklinik/eca-symbolic-execution/blob/master/code/website/recursive-onOff-highres.svg)
## A loop condition with side effect
```
c
int
main
()
{
i
=
0
;
while
(
foo
(
i
))
{
i
=
i
+
1
;
}
return
0
;
}
bool
foo
(
int
i
)
{
if
(
i
<
10
)
{
LED1
.
switchOn
();
return
true
;
}
else
{
LED1
.
switchOff
();
return
false
;
}
}
```
[

](https://gitlab.science.ru.nl/mklinik/eca-symbolic-execution/blob/master/code/website/loop-condition-with-side-effect-main-no-merge-highres.svg)
[

](https://gitlab.science.ru.nl/mklinik/eca-symbolic-execution/blob/master/code/website/loop-condition-with-side-effect-main-highres.svg)