<div dir="ltr"><div dir="ltr">llvm::Process::GetEnv looks like it does the right thing.</div><div dir="ltr"><br></div><div dir="ltr">I think we added it to deal with Unicode on Windows, though. We have plenty of calls to getenv that are mostly looking for '1', '0', or variable presence, and they pretty much work.<br></div></div><br><div class="gmail_quote"><div dir="ltr">On Wed, Sep 5, 2018 at 2:12 PM David Greene via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Is there an LLVM-ish way to handle environment variables?  Specifically,<br>
I want to check existence and/or value of an environment variable and<br>
take appropriate action.<br>
<br>
I was kind of surprised that LLVM doesn't seem to have any<br>
special/optimized way to deal with environment variables.  The one<br>
Stackoverflow I found on it suggested using getenv().<br>
<br>
Thanks!<br>
<br>
                  -David<br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div>