Merge pull request #925 from timmartin/bug730

Added documentation for the (keyword?) function
This commit is contained in:
Morten Linderud 2015-09-01 00:20:32 +02:00
commit cdd60ce77d

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: