instead of toStringRef. The file system APIs need c strings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120601
91177308-0d34-0410-b5e6-
96231b3b80d8
// Get arguments.
SmallString<128> from_storage;
SmallString<128> to_storage;
- StringRef f = from.toStringRef(from_storage);
- StringRef t = to.toStringRef(to_storage);
+ StringRef f = from.toNullTerminatedStringRef(from_storage);
+ StringRef t = to.toNullTerminatedStringRef(to_storage);
const size_t buf_sz = 32768;
char buffer[buf_sz];
// Get arguments.
SmallString<128> from_storage;
SmallString<128> to_storage;
- StringRef f = from.toStringRef(from_storage);
- StringRef t = to.toStringRef(to_storage);
+ StringRef f = from.toNullTerminatedStringRef(from_storage);
+ StringRef t = to.toNullTerminatedStringRef(to_storage);
// Convert to utf-16.
SmallVector<wchar_t, 128> wide_from;