This is an archive of the discontinued LLVM Phabricator instance.

Replace getcwd with the llvm equivalent
ClosedPublic

Authored by labath on Jan 18 2017, 6:10 AM.

Details

Summary

getcwd() is not available (well.. um.. deprecated?) on windows, and the way
PosixApi.h is providing it causes strange compile errors when it's included in
the wrong order. The best way to avoid that is to just not use chdir.

This replaces all uses of getcwd in generic code. There are still a couple of
more uses, but these are in platform-specific code.

chdir() is causing a similar problem, but for that there is no llvm equivalent
for that (yet).

Diff Detail

Repository
rL LLVM

Event Timeline

labath created this revision.Jan 18 2017, 6:10 AM

Any objections to this, Zach?

This revision was automatically updated to reflect the committed changes.