[MacPorts] #54183: qt4-mac @4.8.7: build failures with clang-4.0 due to comparison between pointer and zero

MacPorts noreply at macports.org
Tue May 16 20:25:21 UTC 2017


#54183: qt4-mac @4.8.7: build failures with clang-4.0 due to comparison between
pointer and zero
----------------------+-----------------
  Reporter:  kencu    |      Owner:
      Type:  defect   |     Status:  new
  Priority:  Normal   |  Milestone:
 Component:  ports    |    Version:
Resolution:           |   Keywords:
      Port:  qt4-mac  |
----------------------+-----------------

Comment (by michaelld):

 I was always taught to just do
 {{{
 if (pointer) ...
 }}}
 which implicitly compares it with whatever type of 0 the pointer is.
 That's been valid in C since I started using it, gotta be 30 years now. As
 far as I know, it's still valid in C or C++. Maybe frowned upon by modern
 standards which might use C++11's nullptr. Not sure what the equivalent in
 C is.

 Can you do a simple program & test to see if this works on your 10.6
 setup?

 If so, then I'd say to patch those explicit comparisons with 0 to be this
 type. Single patch would do.

--
Ticket URL: <https://trac.macports.org/ticket/54183#comment:1>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list