.. include:: ../global.rst .. _`property tables`: Value Properties ^^^^^^^^^^^^^^^^ We can associate properties with *values*. Normally these are the signature and document strings for functions and a name for closures. The properties of a value are a :ref:`keyword table `. You can then reference or set a property within that table. .. note:: Property tables are not automatically created for values. .. _`%properties`: .. idio:function:: %properties o [default] return the properties table for `o` :param o: value to get properties for :type o: any non-``#n`` :param default: value to return if no properties exist :type default: any, optional :return: properties table :rtype: keyword table :raise ^rt-parameter-nil-error: :raise ^rt-hash-key-not-found-error: .. _`%set-properties!`: .. idio:function:: %set-properties! o properties set the properties table for `o` to `properties` :param o: value to set properties for :type o: any non-``#n`` :param properties: properties table :type properties: keyword table :return: ``#`` :raise ^rt-parameter-nil-error: .. seealso:: :ref:`make-keyword-table ` for a means to create a proprty table .. _`%property`: .. idio:function:: %property o kw [default] return the property `kw` for `o` :param o: value to get properties for :type o: any non-``#n`` :param kw: property :type kw: keyword :param default: value to return if no such property exists :type default: any, optional :return: property value :rtype: any :raise ^rt-parameter-nil-error: :raise ^rt-hash-key-not-found-error: .. _`%set-property!`: .. idio:function:: %set-property! o kw v set the property `kw` for `o` to `v` :param o: value to set properties for :type o: non-``#n`` :param kw: property :type kw: keyword :param v: value :type v: any :return: ``#`` :raise ^rt-parameter-nil-error: .. include:: ../commit.rst