Skip to content

Conversation

@masaori335
Copy link
Contributor

I faced the below compile error with LLVM 15. It looks like Ptr.h needs to include <cstddef> explicitly.

In file included from HdrHeap.cc:34:
In file included from ./HdrHeap.h:35:
../../include/tscore/Ptr.h:284:12: error: no type named 'nullptr_t' in namespace 'std'; did you mean simply 'nullptr_t'?
operator==(std::nullptr_t, Ptr<T> const &rhs)
           ^~~~~~~~~~~~~~
           nullptr_t
/usr/local/opt/llvm/include/c++/v1/stddef.h:48:31: note: 'nullptr_t' declared here
    typedef decltype(nullptr) nullptr_t;
                              ^
In file included from HdrHeap.cc:34:
In file included from ./HdrHeap.h:35:
../../include/tscore/Ptr.h:291:12: error: no type named 'nullptr_t' in namespace 'std'; did you mean simply 'nullptr_t'?
operator!=(std::nullptr_t, Ptr<T> const &rhs)
           ^~~~~~~~~~~~~~
           nullptr_t
/usr/local/opt/llvm/include/c++/v1/stddef.h:48:31: note: 'nullptr_t' declared here
    typedef decltype(nullptr) nullptr_t;
                              ^
In file included from HdrHeap.cc:38:
In file included from /opt/src/github.com/apache/trafficserver-asf-master/iocore/eventsystem/I_EventSystem.h:31:
/opt/src/github.com/apache/trafficserver-asf-master/iocore/eventsystem/I_IOBuffer.h:1411:15: error: invalid operands to binary expression ('std::nullptr_t' and 'Ptr<IOBufferBlock>')
  if (nullptr == _head)
      ~~~~~~~ ^  ~~~~~
../../include/tscore/Ptr.h:298:1: note: candidate template ignored: could not match 'const T *' against 'std::nullptr_t'
operator==(T const *lhs, Ptr<T> const &rhs)
^
3 errors generated.
gmake[2]: *** [Makefile:1124: HdrHeap.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
gmake[2]: Leaving directory '/opt/src/github.com/apache/trafficserver-asf-master/proxy/hdrs'
gmake[1]: *** [Makefile:924: all-recursive] Error 1
gmake[1]: Leaving directory '/opt/src/github.com/apache/trafficserver-asf-master/proxy'
gmake: *** [Makefile:903: all-recursive] Error 1

@masaori335 masaori335 added the Build work related to build configuration or environment label Sep 26, 2022
@masaori335 masaori335 added this to the 10.0.0 milestone Sep 26, 2022
@masaori335 masaori335 self-assigned this Sep 26, 2022
@masaori335 masaori335 merged commit e26ee17 into apache:master Sep 26, 2022
zwoop pushed a commit that referenced this pull request Oct 4, 2022
@zwoop
Copy link
Contributor

zwoop commented Oct 4, 2022

Cherry-picked to v9.2.x

@zwoop zwoop modified the milestones: 10.0.0, 9.2.0 Oct 4, 2022
masaori335 pushed a commit to masaori335/trafficserver that referenced this pull request Feb 21, 2023
* asf/9.2.x:
  Updated ChangeLog
  s3_auth: Fix parsing of virtual_host (apache#9103)
  s3_auth: accept longer config lines (apache#9090)
  Add a proxy.config.http.per_server.connection.max test (apache#9097)
  Move plugin_init for verify cmd (apache#9102)
  Fix unused-but-set-variable warnings by llvm-15 (apache#9106)
  Fix compile error with llvm-15 (apache#9105)
  Fix expected sha1sum for the Proxy Verifier binary (apache#9112)
  Updating AuTest to use Proxy Verifier v2.4.2 (apache#9110)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Build work related to build configuration or environment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants