On Monday, 25 July 2016 at 12:37:18 UTC, Bahman Movaqar wrote:
But I'm curious; how can I check for a
`null` in this case?

Well, if you're happy with assertion failure by access violation, you may not even need to check for null, because generally if you try to call .empty on a null pointer you'll get an access violation (killing two birds with one stone).

Otherwise you could try
(!__traits(compiles, r is null) || r !is null) && !r.empty

Reply via email to