-
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.
Fix for macro bug sumbitted by broscutamaker
- Loading branch information
zik.saleeba
committed
Mar 16, 2013
1 parent
6cb57ee
commit 64373d9
Showing
4 changed files
with
29 additions
and
5 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
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,17 @@ | ||
#include "stdio.h" | ||
|
||
#define MIN(a,b) ((a) < (b) ? (a) : (b)) | ||
|
||
void main() | ||
{ | ||
float x = MIN(1,2); | ||
int y = 14; | ||
float z; | ||
z = MIN(y, 13.5); | ||
y = MIN(y, 13); | ||
|
||
float pi = 3.14; | ||
int pi_int = pi; | ||
|
||
printf("Macro test: %d %d %f %d \n", x, y, z, pi_int); | ||
} |
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 @@ | ||
Macro test: 1 13 13.500000 3 |
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