summaryrefslogtreecommitdiffstats
path: root/src/if_ruby.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-01-23 19:46:28 +0100
committerBram Moolenaar <Bram@vim.org>2016-01-23 19:46:28 +0100
commit520e1e41f35b063ede63b41738c82d6636e78c34 (patch)
tree4c6a94e4e8f3f2047b91886077d4ecb916b30401 /src/if_ruby.c
parent6920c72d4d62c8dc5596e9f392e38204f561d7af (diff)
patch 7.4.1154v7.4.1154
Problem: No support for JSON. Solution: Add jsonencode() and jsondecode(). Also add v:false, v:true, v:null and v:none.
Diffstat (limited to 'src/if_ruby.c')
-rw-r--r--src/if_ruby.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/if_ruby.c b/src/if_ruby.c
index 96d9453dbc..bb34de1316 100644
--- a/src/if_ruby.c
+++ b/src/if_ruby.c
@@ -1032,6 +1032,11 @@ static VALUE vim_to_ruby(typval_T *tv)
}
}
}
+ }
+ else if (tv->v_type == VAR_SPECIAL)
+ {
+ if (tv->vval.v_number <= VVAL_TRUE)
+ result = INT2NUM(tv->vval.v_number);
} /* else return Qnil; */
return result;