summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2013-05-31 02:28:33 +0200
committerAraq <rumpf_a@web.de>2013-05-31 02:28:33 +0200
commitddedefd4c44133f30cd19860ff2acb9259b3d88f (patch)
treeca6f5132e3d58c17eca78e5c0ffcdbfc2ad6e2ae
parent24955f83584de89d3222d409d499b01d42f4e83e (diff)
parent7d58b9247ee8990a1c035bd9b93383e07de95a2c (diff)
downloadNim-ddedefd4c44133f30cd19860ff2acb9259b3d88f.tar.gz
Merge branch 'master' of github.com:Araq/Nimrod
-rw-r--r--lib/pure/json.nim4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/pure/json.nim b/lib/pure/json.nim
index d2516adfb..df20bd852 100644
--- a/lib/pure/json.nim
+++ b/lib/pure/json.nim
@@ -641,11 +641,13 @@ proc `[]`*(node: PJsonNode, index: Int): PJsonNode =
   assert(node.kind == JArray)
   return node.elems[index]
 
-proc existsKey*(node: PJsonNode, key: String): Bool =
+proc hasKey*(node: PJsonNode, key: String): Bool =
   ## Checks if `key` exists in `node`.
   assert(node.kind == JObject)
   for k, item in items(node.fields):
     if k == key: return True
+proc existsKey*(node: PJsonNode, key: String): Bool {.deprecated.} = node.hasKey(key)
+  ## Deprecated for `hasKey`
 
 proc add*(father, child: PJsonNode) = 
   ## Adds `child` to a JArray node `father`.