Bitwise operations: Difference between revisions

m
→‎{{header|Wren}}: Changed to Wren S/H
imported>Acediast
(→‎{{header|COBOL}}: Fixed to display properly.)
m (→‎{{header|Wren}}: Changed to Wren S/H)
Line 6,285:
 
Given this limitation, there is no difference between logical and arithmetic left and right shift operations. Although Wren doesn't support circular shift operators, it is not difficult to write functions to perform them.
<syntaxhighlight lang="ecmascriptwren">var rl = Fn.new { |x, y| x << y | x >> (32-y) }
 
var rr = Fn.new { |x, y| x >> y | x << (32-y) }
Line 6,320:
x rr y = 2147483650
</pre>
 
=={{header|x86 Assembly}}==
{{works with|nasm}}
9,476

edits