Add an example to the trunc instruction to clarify trunc to bool.

Example provided by Baptiste Lepilleur.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32931 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Reid Spencer 2007-01-05 21:33:08 +00:00
parent 068c5f47ea
commit 5cf0fe40d0

View File

@ -2701,6 +2701,7 @@ It will always truncate bits.</p>
<pre> <pre>
%X = trunc i32 257 to i8 <i>; yields i8:1</i> %X = trunc i32 257 to i8 <i>; yields i8:1</i>
%Y = trunc i32 123 to bool <i>; yields bool:true</i> %Y = trunc i32 123 to bool <i>; yields bool:true</i>
%Y = trunc i32 122 to bool <i>; yields bool:false</i>
</pre> </pre>
</div> </div>