Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Arno Welzel Newsgroups: comp.lang.php Subject: Re: Implied cast differs from explicit cast Date: Thu, 19 Jan 2012 13:39:07 +0100 Organization: A noiseless patient Spider Lines: 58 Message-ID: <4F180EEB.60900@arnowelzel.de> References: <4f1378ee$0$16741$882e7ee2@usenet-news.net> <4f139498$0$16818$882e7ee2@usenet-news.net> <4F150E2E.80003@arnowelzel.de> <4F180E42.9010502@arnowelzel.de> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Injection-Info: mx04.eternal-september.org; posting-host="KYiwCJH8Z2yKpLGgP5VBCw"; logging-data="22059"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19zclu6BQXfcxx//3tF2Ky2HnQbjG5lTI8=" User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:9.0) Gecko/20111222 Thunderbird/9.0.1 In-Reply-To: <4F180E42.9010502@arnowelzel.de> Cancel-Lock: sha1:xbEkkZ0X+QEbq9bTd9ZJWyCPsJg= Xref: x330-a1.tempe.blueboxinc.net comp.lang.php:4518 Arno Welzel, 2012-01-19 13:36: > Jerry Stuckle, 2012-01-17 14:16: > >> On 1/17/2012 12:59 AM, Arno Welzel wrote: >>> Jerry Stuckle, 2012-01-16 14:45: >>> >>>> On 1/16/2012 8:28 AM, The Natural Philosopher wrote: >>>>> lb wrote: >>>>>> jstucklex@attglobal.net wrote: >>>>>>> ... >>>>>>> No, it is not. '0x12' is a hex number, not an integer. (int)'0x12' >>>>>>> converts this correctly to 0. >>>>> >>>>> Looks like Jerry doesn't know what an integer is either. >>>>> >>>>> A hex number of course *is* an integer, unless its a hex representation >>>>> of floating point. >>>>> >>>>> Killfile the prat like I have. >>>>> >>>>> >>>> >>>> 0x12 is not an integer. It is a hexadecimal value. >>> >>> No, 0x12 (and *not* "0x12") is the hexadecimal *representation* of the >>> value 18. There is no thing like "hexadecimal value" and "0x12" is a >>> *string* and not a number at all. >>> >> >> No, it is a hexadecimal value. It may be an integer, it may be a >> character, it may be a set of flags... It does not have to be an integer. >> >>> In fact PHP only knows to types of numbers: integers and floating point. >>> There is no "hexadecimal" data type. >>> >> >> Excuse me - there is. See hexdec(). > > > > You don't know what a data type is? Do you? > > See and show me, where > the "hexadecimal data type" is explained. And you should read the section about *integer* literal in very carefully. There is no thing as "conversion of hexadecimal values to an integer". EOD for me. -- Arno Welzel http://arnowelzel.de http://de-rec-fahrrad.de