浏览代码

Help: Fix string(JSON ... LENGTH ...) signature

The list of indices and/or member names is optional, i.e., can be
empty. For example, string(JSON foo LENGTH "[0,0,0]") sets foo to 3.
Tobias Nießen 3 年之前
父节点
当前提交
2f0a3d43e1
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Help/command/string.rst

+ 1 - 1
Help/command/string.rst

@@ -612,7 +612,7 @@ Requires an element of object type.
 .. code-block:: cmake
 .. code-block:: cmake
 
 
   string(JSON <out-var> [ERROR_VARIABLE <error-variable>]
   string(JSON <out-var> [ERROR_VARIABLE <error-variable>]
-         LENGTH <json-string> <member|index> [<member|index> ...])
+         LENGTH <json-string> [<member|index> ...])
 
 
 Get the length of an element in ``<json-string>`` at the location
 Get the length of an element in ``<json-string>`` at the location
 given by the list of ``<member|index>`` arguments.
 given by the list of ``<member|index>`` arguments.