[libcxx-commits] [PATCH] D76045: [lldb/API] Make Launch(Simple) use args and env from target properties

Frederic Riss via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Mar 11 22:33:40 PDT 2020


friss created this revision.
friss added reviewers: jingham, labath.
Herald added projects: LLDB, libc++abi.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libc++abi.
friss updated this revision to Diff 249834.
friss added a comment.
friss removed a reviewer: libc++abi.
friss removed a project: libc++abi.
friss removed a subscriber: libcxx-commits.
friss added a parent revision: D76009: [lldb/Target] Initialize new targets environment variables from target.env-vars.

Remove unrelated change commited by accident


When no arguments or environment is provided to SBTarget::LaunchSimple,
make it use the values surrently set in the target properties. You can
get the current behavior back by passing an empty array instead.

It seems like using the target defaults is a much more intuitive
behavior for those APIs. It's unllikely that anyone passed NULL/None to
this API after having set properties in order to explicitely ignore them.

One direct application of this change is within the testsuite. We have
plenty of tests calling LaunchSimple and passing None as environment.
If you passed --inferior-env to dotest.py to, for example, set
(DY)LD_LIBRARY_PATH, it wouldn't be taken into account.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D76045

Files:
  lldb/include/lldb/API/SBTarget.h
  lldb/source/API/SBTarget.cpp
  lldb/test/API/commands/settings/TestSettings.py

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76045.249834.patch
Type: text/x-patch
Size: 4191 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20200312/0ce2e865/attachment.bin>


More information about the libcxx-commits mailing list