Skip to content

Commit 7cdea97

Browse files
committed
docs: fix description of select_enum_addr
1 parent d601782 commit 7cdea97

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/SIL.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3169,16 +3169,16 @@ select_enum_addr
31693169
````````````````
31703170
::
31713171

3172-
sil-instruction ::= 'select_enum' sil-operand sil-select-case*
3172+
sil-instruction ::= 'select_enum_addr' sil-operand sil-select-case*
31733173
(',' 'default' sil-value)?
31743174
':' sil-type
31753175

3176-
%n = select_enum %0 : $U, \
3176+
%n = select_enum_addr %0 : $*U, \
31773177
case #U.Case1: %1, \
31783178
case #U.Case2: %2, /* ... */ \
31793179
default %3 : $T
31803180

3181-
// $U must be an enum type
3181+
// %0 must be the address of an enum type $*U
31823182
// #U.Case1, Case2, etc. must be cases of enum $U
31833183
// %1, %2, %3, etc. must have type $T
31843184
// %n has type $T

0 commit comments

Comments
 (0)