[llvm-commits] [llvm] r51013 - /llvm/trunk/docs/LangRef.html
Chris Lattner
clattner at apple.com
Fri May 23 14:09:41 PDT 2008
On May 12, 2008, at 4:51 PM, Dan Gohman wrote:
> URL: http://llvm.org/viewvc/llvm-project?rev=51013&view=rev
> Log:
> Initial documentation for first-class aggregates changes.
Nice,
> +<h5>Example:</h5>
> +
> +<pre>
> + %result = extractvalue {i32, float} %agg, i32 0 <i>; yields
> i32</i>
> +</pre>
> +</div>
Since the indices are constants, not "Value*"'s, I don't think there
should be a type specified for them. Something like:
%result = extractvalue {{i32, float}} %agg, 0, 1
Should be enough.
> +<!--
> _______________________________________________________________________
> -->
> +<div class="doc_subsubsection">
> + <a name="i_insertvalue">'<tt>insertvalue</tt>' Instruction</a>
> +</div>
> ++<h5>Arguments:</h5>
> +
> +<p>
> +The first operand of an '<tt>insertvalue</tt>' instruction is a
> +value of <a href="#t_struct">struct</a> or <a
> href="#t_array">array</a> type.
> +The second operand is a first-class value to insert.
> +type of the first operand.
Sentence fragment?
> The following operands are constant indicies
If they aren't value*'s, please don't call them operands.
> +<h5>Example:</h5>
> +
> +<pre>
> + %result = insertvalue {i32, float} %agg, i32 1, i32 0 <i>;
> yields {i32, float}</i>
Also, no types please.
Should the discussion of first-class types and other type
classifications be updated?
-Chris
More information about the llvm-commits
mailing list