summaryrefslogtreecommitdiffhomepage
path: root/src/codegen.c
diff options
context:
space:
mode:
authorMasaki Muranaka <[email protected]>2013-03-13 13:30:40 +0900
committerMasaki Muranaka <[email protected]>2013-03-14 15:13:12 +0900
commit1ffc9ba3255f8b63164c42ea8304115f5a6b2464 (patch)
tree696cc7a62568dd72974e5a20c7fa8486cb5b58e2 /src/codegen.c
parent0739960b7fab2ce61bbeaedef7680cd4805a03f4 (diff)
downloadmruby-1ffc9ba3255f8b63164c42ea8304115f5a6b2464.tar.gz
mruby-1ffc9ba3255f8b63164c42ea8304115f5a6b2464.zip
Define type mrb_bool. It is typedef-ed to _Bool on C99, unsigned int on MSVC.
It is safer than applying 1bit bit-fields to signed int. For forward compatibility, you should substiture only 1 or 0 for the variable typed mrb_bool.
Diffstat (limited to 'src/codegen.c')
-rw-r--r--src/codegen.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/codegen.c b/src/codegen.c
index ed44f1792..cbbd2d16a 100644
--- a/src/codegen.c
+++ b/src/codegen.c
@@ -49,7 +49,7 @@ typedef struct scope {
int pc;
int lastlabel;
int ainfo:15;
- int mscope:1;
+ mrb_bool mscope:1;
struct loopinfo *loop;
int ensure_level;