Browse Source

Add documentation for immediates with type bool.

This makes the documentation for the new bconst instruction more complete.
pull/3/head
Dan Gohman 7 years ago
parent
commit
89634fa645
  1. 7
      docs/langref.rst
  2. 2
      lib/cretonne/meta/base/immediates.py

7
docs/langref.rst

@ -265,6 +265,13 @@ indicate the different kinds of immediate operands on an instruction.
A 64-bit immediate floating point number in the IEEE 754-2008 binary64
interchange format. All bit patterns are allowed.
.. type:: bool
A boolean immediate value, either false or true.
In the textual format, :type:`bool` immediates appear as 'false'
and 'true'.
.. type:: intcc
An integer condition code. See the :inst:`icmp` instruction for details.

2
lib/cretonne/meta/base/immediates.py

@ -49,7 +49,7 @@ ieee64 = ImmediateKind('ieee64', 'A 64-bit immediate floating point number.')
#:
#: This type of immediate boolean can interact with SSA values with any
#: :py:class:`cretonne.BoolType` type.
boolean = ImmediateKind('boolean', 'An immediate boolean.',
boolean = ImmediateKind('bool', 'An immediate boolean.',
rust_type='bool')
#: A condition code for comparing integer values.

Loading…
Cancel
Save