Skip to content

Commit

Permalink
fix #11963, remove apparently redundant shift operator definitions
Browse files Browse the repository at this point in the history
  • Loading branch information
JeffBezanson committed Jul 2, 2015
1 parent afc6308 commit 8ad0c1c
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions base/int.jl
Original file line number Diff line number Diff line change
Expand Up @@ -95,14 +95,6 @@ for T in IntTypes
(&)(x::$T, y::$T) = box($T,and_int(unbox($T,x),unbox($T,y)))
(|)(x::$T, y::$T) = box($T, or_int(unbox($T,x),unbox($T,y)))
($)(x::$T, y::$T) = box($T,xor_int(unbox($T,x),unbox($T,y)))

<<(x::$T, y::Int) = box($T, shl_int(unbox($T,x),unbox(Int,y)))
>>>(x::$T, y::Int) = box($T,lshr_int(unbox($T,x),unbox(Int,y)))
end
if issubtype(T,Unsigned)
@eval >>(x::$T, y::Int) = box($T,lshr_int(unbox($T,x),unbox(Int,y)))
else
@eval >>(x::$T, y::Int) = box($T,ashr_int(unbox($T,x),unbox(Int,y)))
end

This comment has been minimized.

Copy link
@dpsanders

dpsanders Jul 2, 2015

Contributor

Don't you need to remove this end too?

This comment has been minimized.

Copy link
@yuyichao

yuyichao Jul 2, 2015

Contributor

It's from five lines above

for S in IntTypes
(S === Int128 || S === UInt128) && continue
Expand Down

2 comments on commit 8ad0c1c

@dpsanders
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah OK, sorry.

@phaverty
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might this have something to do with da0dc58 (restoring performance of bitshift operators) running into trouble?

Please sign in to comment.