Is it true that, "I guarantee the absence of anything at a zero address."



  • I'm reading the directory of C and I'm on the line. "I guarantee there's nothing at a zero address." Second paragraph. https://cpp.com.ru/shildt_spr_po_c/05/0507.html Is that correct? Is it possible that the standard describes it somewhere?



  • Standard

    6.3.2.3 Pointers

    An integer constant expression with the value 0, or such an expression cast to type void *, is called a null pointer constant. If a null pointer constant is converted to a pointer type, the resulting pointer, called a null pointer, is guaranteed to compare unequal to a pointer to any object or function.

    It is said that the introduction of a zero indicator on any type cannot be equal to a real object or function.


Log in to reply
 

Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2