Re: [RFClue] Constant declaration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tuesday 11 October 2005 17:37, Felix Oxley wrote:

> I think I am getting it!
> But is there any point in declaring
> 
> const char *foo = "";
> 
> isn't this equivalent to:
> 
> char *foo;

Assuming this is outside of any function body,
then in this last case foo is initialized to 0
which is means it is a pointer to NULL not a
pointer to an empty string.


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux