JDK-8073624 : Fix warning "converting to non-pointer type 'bool' from NULL" in arraycopynode.cpp
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 9
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2015-02-23
  • Updated: 2015-06-03
  • Resolved: 2015-02-24
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 9
9 b55Fixed
Related Reports
Relates :  
Description
For the following code in arraycopynode.cpp which was introduced by JDK-6912521:

bool ArrayCopyNode::finish_transform(...) {
...
    if (in(TypeFunc::Control) != ctl) {
...
      return NULL;
    }
}

older versions of GCC and maybe other compilers warn about:

/arraycopynode.cpp:458: warning: converting to non-pointer type 'bool' from NULL

The fix is trivial - just return false instead of NULL as this is already done in several other places in the same function.