Null references used for type dispatch
Open
thrust
- Dominant language
- C++
- Stars
- 2.5k
- Forks
- 486
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 295
Description
Here: https://github.com/thrust/thrust/blob/417d78471dadefa3087ff274e64f43ce74acfd3d/thrust/detail/reference.inl#L120 and at some other places in this file and also in its associated `.h` file, null pointers are created and passed to functions which are known to dereference them.
According to the comments and by looking at how they are ultimately used, it seems that we only care about the type. Is there anything that prevents using meta-programmation instead of passing actual, invalid values?
Contributor guide
Assessment
This issue has not been assessed yet.