updated for version 7.3.213
Problem: Javascript object literal is not indented correctly.
Solution: Make a special case for when "J1" is in 'cino'. (Luc Deschenaux)
diff --git a/src/misc1.c b/src/misc1.c
index 913da2a..d69f12f 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -6965,7 +6965,7 @@
* ldfd) {
* }
*/
- if ((ind_keep_case_label
+ if (ind_js || (ind_keep_case_label
&& cin_iscase(skipwhite(ml_get_curline()), FALSE)))
amount = get_indent();
else
diff --git a/src/testdir/test3.in b/src/testdir/test3.in
index 1b5cf89..1cfd8f2 100644
--- a/src/testdir/test3.in
+++ b/src/testdir/test3.in
Binary files differ
diff --git a/src/testdir/test3.ok b/src/testdir/test3.ok
index cf4f85d..8475aff 100644
--- a/src/testdir/test3.ok
+++ b/src/testdir/test3.ok
@@ -1337,6 +1337,7 @@
}
+NAMESPACESTART
/* valid namespaces with normal indent */
namespace
{
@@ -1401,3 +1402,19 @@
NAMESPACEEND
+
+JSSTART
+var bar = {
+ foo: {
+ that: this,
+ some: ok,
+ },
+ "bar":{
+ a : 2,
+ b: "123abc",
+ x: 4,
+ "y": 5
+ }
+}
+JSEND
+
diff --git a/src/version.c b/src/version.c
index f648160..7ae7984 100644
--- a/src/version.c
+++ b/src/version.c
@@ -710,6 +710,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 213,
+/**/
212,
/**/
211,