-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
zik.saleeba
committed
Mar 1, 2014
1 parent
f006d6c
commit 18fb350
Showing
3 changed files
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#include <stdio.h> | ||
|
||
void demo_error() | ||
{ | ||
int value = 5; | ||
|
||
printf("Here's a print statement before quitting.\n"); | ||
|
||
if(1) { | ||
printf("returning; there should be no further output.\n"); | ||
return; | ||
} | ||
|
||
printf("This statement should not print, and does not.\n"); | ||
|
||
switch(value) | ||
{ | ||
case 5: | ||
printf("case 5: value = %d\n", value); | ||
break; | ||
case 0: | ||
printf("case 0: value=%d\n", value); | ||
break; | ||
} | ||
|
||
printf("This statement also should not and does not print.\n"); | ||
|
||
return; | ||
} | ||
|
||
void main() | ||
{ | ||
demo_error(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Here's a print statement before quitting. | ||
returning; there should be no further output. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters