Re: [edk2] Print(L"0x%.16x", Value) not working as expected

2014-10-22 Thread Bruce Cran
On 10/17/2014 5:04 AM, Nikolai Saoukh wrote: > IMHO, correct usage is > > Print (L"0x%.16lx", Value); // lower case L Using an upper-case 'L' might be better to avoid potential confusion with the number '1'. -- Bruce

Re: [edk2] Print(L"0x%.16x", Value) not working as expected

2014-10-20 Thread Stefan.Kaeser
Thanks for your replies. I will use %lx instead. Regards, Stefan From: Andrew Fish [mailto:af...@apple.com] Sent: Friday, October 17, 2014 5:06 PM To: edk2-devel@lists.sourceforge.net Subject: Re: [edk2] Print(L"0x%.16x", Value) not working as expected On Oct 17, 2014, at 3:22 AM,

Re: [edk2] Print(L"0x%.16x", Value) not working as expected

2014-10-17 Thread Andrew Fish
> On Oct 17, 2014, at 3:22 AM, stefan.kae...@infineon.com wrote: > > Hi, > I tried to print a UINT64 value as follows and hoped to get output > “0x1122334455667788”: > { > UINT64 Value = 0x1122334455667788; > Print(L“0x%.16x”, Value); > } > In the EDK x was a UINTN. This caused issues wit

Re: [edk2] Print(L"0x%.16x", Value) not working as expected

2014-10-17 Thread Sergey Isakov
You are right this is a bug but the library was deprecated. New one edk2/MdePkg/Library/BasePrintLib has no such bug. On 17.10.2014, at 14:22, wrote: > Hi, > I tried to print a UINT64 value as follows and hoped to get output > “0x1122334455667788”: > { > UINT64 Value = 0x1122334455667788; >

Re: [edk2] Print(L"0x%.16x", Value) not working as expected

2014-10-17 Thread Nikolai Saoukh
IMHO, correct usage is Print (L"0x%.16lx", Value); // lower case L On Fri, Oct 17, 2014 at 2:22 PM, wrote: > Hi, > > I tried to print a UINT64 value as follows and hoped to get output > “0x1122334455667788”: > > { > > UINT64 Value = 0x1122334455667788; > > Print(L“0x%.16x”, Value); > > } >

[edk2] Print(L"0x%.16x", Value) not working as expected

2014-10-17 Thread Stefan.Kaeser
Hi, I tried to print a UINT64 value as follows and hoped to get output "0x1122334455667788": { UINT64 Value = 0x1122334455667788; Print(L"0x%.16x", Value); } The actual output is "0x55667788" though. The leading 4 bytes seem to get lost in cast to unsigned int in BasePrintLibVSPrint,