Added documentation for the (keyword?) function

This commit is contained in:
Tim Martin 2015-08-31 20:35:37 +01:00
parent 920b35f129
commit 818ed5da72

View File

@ -436,6 +436,25 @@ themselves as an iterator when ``(iter x)`` is called. Contrast with
=> (iterator? (iter {:a 1 :b 2 :c 3}))
True
.. _keyword?-fn:
keyword?
--------
.. versionadded:: 0.10.1
Usage: ``(keyword? foo)``
Check whether *foo* is a :ref:`keyword<HyKeyword>`.
.. code-block:: hy
=> (keyword? :foo)
True
=> (setv foo 1)
=> (keyword? foo)
False
.. _list*-fn: