more intuitive left shift and right shift operators
Before: * << is left shift, not allowed to shift 1 bits out * <<% is left shift, allowed to shift 1 bits out * >> is right shift, allowed to shift 1 bits out After: * << is left shift, allowed to shift 1 bits out * >> is right shift, allowed to shift 1 bits out * @shlExact is left shift, not allowed to shift 1 bits out * @shrExact is right shift, not allowed to shift 1 bits out Closes #413
This commit is contained in:
@@ -49,7 +49,7 @@ fn ilogb32(x: f32) -> i32 {
|
||||
|
||||
if (e == 0xFF) {
|
||||
math.raiseInvalid();
|
||||
if (u <<% 9 != 0) {
|
||||
if (u << 9 != 0) {
|
||||
return fp_ilogbnan;
|
||||
} else {
|
||||
return @maxValue(i32);
|
||||
@@ -84,7 +84,7 @@ fn ilogb64(x: f64) -> i32 {
|
||||
|
||||
if (e == 0x7FF) {
|
||||
math.raiseInvalid();
|
||||
if (u <<% 12 != 0) {
|
||||
if (u << 12 != 0) {
|
||||
return fp_ilogbnan;
|
||||
} else {
|
||||
return @maxValue(i32);
|
||||
|
||||
Reference in New Issue
Block a user