summaryrefslogtreecommitdiff
path: root/src/json_test.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-12-04 21:57:43 +0100
committerBram Moolenaar <Bram@vim.org>2019-12-04 21:57:43 +0100
commit4ba37b5833de99db9e9afe8928b31c864182405c (patch)
tree30662897c6ff3d608e47d22f8bab9ce8703b26e7 /src/json_test.c
parent2ab2e8608f9b2c85432715bb9a7f226fdbf8cd35 (diff)
downloadvim-git-4ba37b5833de99db9e9afe8928b31c864182405c.tar.gz
patch 8.1.2388: using old C style commentsv8.1.2388
Problem: Using old C style comments. Solution: Use // comments where appropriate.
Diffstat (limited to 'src/json_test.c')
-rw-r--r--src/json_test.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/json_test.c b/src/json_test.c
index 47bec8ee6..5fb772ee0 100644
--- a/src/json_test.c
+++ b/src/json_test.c
@@ -14,16 +14,16 @@
#undef NDEBUG
#include <assert.h>
-/* Must include main.c because it contains much more than just main() */
+// Must include main.c because it contains much more than just main()
#define NO_VIM_MAIN
#include "main.c"
-/* This file has to be included because the tested functions are static */
+// This file has to be included because the tested functions are static
#include "json.c"
#if defined(FEAT_EVAL)
/*
- * Test json_find_end() with imcomplete items.
+ * Test json_find_end() with incomplete items.
*/
static void
test_decode_find_end(void)
@@ -33,7 +33,7 @@ test_decode_find_end(void)
reader.js_fill = NULL;
reader.js_used = 0;
- /* string and incomplete string */
+ // string and incomplete string
reader.js_buf = (char_u *)"\"hello\"";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)" \"hello\" ";
@@ -41,13 +41,13 @@ test_decode_find_end(void)
reader.js_buf = (char_u *)"\"hello";
assert(json_find_end(&reader, 0) == MAYBE);
- /* number and dash (incomplete number) */
+ // number and dash (incomplete number)
reader.js_buf = (char_u *)"123";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)"-";
assert(json_find_end(&reader, 0) == MAYBE);
- /* false, true and null, also incomplete */
+ // false, true and null, also incomplete
reader.js_buf = (char_u *)"false";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)"f";
@@ -77,7 +77,7 @@ test_decode_find_end(void)
reader.js_buf = (char_u *)"nul";
assert(json_find_end(&reader, 0) == MAYBE);
- /* object without white space */
+ // object without white space
reader.js_buf = (char_u *)"{\"a\":123}";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)"{\"a\":123";
@@ -93,7 +93,7 @@ test_decode_find_end(void)
reader.js_buf = (char_u *)"{";
assert(json_find_end(&reader, 0) == MAYBE);
- /* object with white space */
+ // object with white space
reader.js_buf = (char_u *)" { \"a\" : 123 } ";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)" { \"a\" : 123 ";
@@ -107,13 +107,13 @@ test_decode_find_end(void)
reader.js_buf = (char_u *)" { ";
assert(json_find_end(&reader, 0) == MAYBE);
- /* JS object with white space */
+ // JS object with white space
reader.js_buf = (char_u *)" { a : 123 } ";
assert(json_find_end(&reader, JSON_JS) == OK);
reader.js_buf = (char_u *)" { a : ";
assert(json_find_end(&reader, JSON_JS) == MAYBE);
- /* array without white space */
+ // array without white space
reader.js_buf = (char_u *)"[\"a\",123]";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)"[\"a\",123";
@@ -129,7 +129,7 @@ test_decode_find_end(void)
reader.js_buf = (char_u *)"[";
assert(json_find_end(&reader, 0) == MAYBE);
- /* array with white space */
+ // array with white space
reader.js_buf = (char_u *)" [ \"a\" , 123 ] ";
assert(json_find_end(&reader, 0) == OK);
reader.js_buf = (char_u *)" [ \"a\" , 123 ";