Project

General

Profile

Actions

Bug #8017

closed

Comply with POSIX.1-2008 and C++11 for the definition of NULL

Added by Aurélien Larcher over 5 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Category:
-
Start date:
2017-03-31
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
needs-triage
Gerrit CR:

Description

Currently NULL is only defined in sys/null.h as an integer type (int for 32bit and long for 64bit):

1) While ISO C does not require it, POSIX.1-2008 defines NULL to be cast as void *.

2) While C++98/03 uses an integer type, C++11 onwards defines NULL as a pointer literal.

The definitions should be added accordingly.

Actions

Also available in: Atom PDF