summaryrefslogtreecommitdiffhomepage
path: root/tools
diff options
context:
space:
mode:
authorkano4 <[email protected]>2013-03-12 23:08:37 +0900
committerkano4 <[email protected]>2013-03-12 23:08:37 +0900
commit3bad7857c36fc70edef6718206b08dd245d7301c (patch)
tree6dbad8b8971061249f7b8c9f47ec5a6383f79eec /tools
parentf63cd331da6257f9b44778dabff60be55b0721fa (diff)
downloadmruby-3bad7857c36fc70edef6718206b08dd245d7301c.tar.gz
mruby-3bad7857c36fc70edef6718206b08dd245d7301c.zip
Replace tabs with spaces
Diffstat (limited to 'tools')
-rw-r--r--tools/mruby/mruby.c27
1 files changed, 12 insertions, 15 deletions
diff --git a/tools/mruby/mruby.c b/tools/mruby/mruby.c
index 9d6182238..774680b3f 100644
--- a/tools/mruby/mruby.c
+++ b/tools/mruby/mruby.c
@@ -52,7 +52,7 @@ usage(const char *name)
printf("Usage: %s [switches] programfile\n", name);
while(*p)
- printf(" %s\n", *p++);
+ printf(" %s\n", *p++);
}
static int
@@ -189,14 +189,14 @@ showcallinfo(mrb_state *mrb)
if (irep->filename != NULL)
filename = irep->filename;
if (irep->lines != NULL) {
- mrb_code *pc;
+ mrb_code *pc;
- if (i+1 <= ciidx) {
- pc = mrb->cibase[i+1].pc;
- }
- else {
- pc = (mrb_code*)mrb_voidp(mrb_obj_iv_get(mrb, mrb->exc, mrb_intern(mrb, "lastpc")));
- }
+ if (i+1 <= ciidx) {
+ pc = mrb->cibase[i+1].pc;
+ }
+ else {
+ pc = (mrb_code*)mrb_voidp(mrb_obj_iv_get(mrb, mrb->exc, mrb_intern(mrb, "lastpc")));
+ }
if (irep->iseq <= pc && pc < irep->iseq + irep->ilen) {
line = irep->lines[pc - irep->iseq - 1];
}
@@ -211,19 +211,16 @@ showcallinfo(mrb_state *mrb)
method = mrb_sym2name(mrb, ci->mid);
if (method) {
const char *cn = mrb_class_name(mrb, ci->proc->target_class);
-
+
if (cn) {
- printf("\t[%d] %s:%d:in %s%s%s\n",
- i, filename, line, cn, sep, method);
+ printf("\t[%d] %s:%d:in %s%s%s\n", i, filename, line, cn, sep, method);
}
else {
- printf("\t[%d] %s:%d:in %s\n",
- i, filename, line, method);
+ printf("\t[%d] %s:%d:in %s\n", i, filename, line, method);
}
}
else {
- printf("\t[%d] %s:%d\n",
- i, filename, line);
+ printf("\t[%d] %s:%d\n", i, filename, line);
}
}
}