Skip to content
Commit 47d56149 authored by Zachary Turner's avatar Zachary Turner
Browse files

[Support] Add StringRef::withNullAsEmpty()

When porting large bodies of code from using const char*
to StringRef, it is helpful to be able to treat nullptr
as an empty string, since that it is often what it is used
to indicate in C-style code.

Differential Revision: https://reviews.llvm.org/D24697

llvm-svn: 281906
parent 9be72675
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment