Skip to content
Commit d85699eb authored by Joseph Huber's avatar Joseph Huber
Browse files

[libc] Move strdup implementation to a new header

The `strdup` family of functions rely on `malloc` to be implemented.
Its presence in the `string_utils.h` header meant that compiling many of
the string functions relied on `malloc` being implementated as well.
This patch simply moves the implementation into a new file to avoid
including `stdlib.h` from the other string functions. This was a barrier
for compiling string functions for the GPU where there is no malloc
currently.

Reviewed By: sivachandra

Differential Revision: https://reviews.llvm.org/D138607
parent 1114d1a9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment