----------------------------------------------------------------
BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
WHEN YOU POST, include all relevant version numbers, log files,
and configuration files.  Don't make us guess your problem!!!
----------------------------------------------------------------

on 6/1/2000 1:21 AM, M. Greenblatt at [EMAIL PROTECTED] wrote:

> In the readWord() method of class Ajpv12InputStream.java we have the
> following bitwise operation:
> 
> return ((int)((b1 << 8) | b2)) & 0xffff;
> 
> Does anyone happen to know the utility of the '& 0xffff' in this?  From
> what I can see it has no effect whatsoever on the final result.
> 
> Let me give an example for those of us who dont enjoy bit logic.
> 
> Assume:
> b1 = 0000000010101010
> b2 = 0000000011001100
> 
> (b1 << 8) = 1010101000000000 | b2
> = 1010101011001100 & 0xffff
> = 1010101011001100
> 
> Just wondering if I'm missing something here...
> 
> Thanks,
> MG

I failed this course in college. :-) I need some more help here...

So, should I remove it? Does it hurt to leave it in there?

-jon



--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html>
Problems?:           [EMAIL PROTECTED]

Reply via email to