This is an archive of the discontinued LLVM Phabricator instance.

Don't return error for settings set .experimental. settings that are absent
ClosedPublic

Authored by jasonmolenda on Apr 5 2018, 7:33 PM.

Details

Summary

setting paths that include .experimental. are intended for settings that may be promoted to "real" settings in the future, or may be removed. When users put these settings in their ~/.lldbinit files, we don't want to emit an error if the setting has gone away. And if the setting has been promoted to a real setting, we want to do the right thing.

The first part of that -- not emitting an error -- did not work correctly. I fixed that, and added tests to check all of these behaviors.

Diff Detail

Event Timeline

jasonmolenda created this revision.Apr 5 2018, 7:33 PM
labath added a subscriber: labath.Apr 6 2018, 2:07 AM
labath added inline comments.
packages/Python/lldbsuite/test/settings/TestSettings.py
544–545

Isn't this basically what self.expect would do (only with better logging and error messages)?

source/Interpreter/OptionValueProperties.cpp
210–215

Not a big deal, but I would expect that the magicness of experimental would kick in only for the components which are come after experimental keyword.
So something like target.experimental.non-existant-setting should be subject to the magic behavior, but target.non-existant-setting.experimental.foo should not (?)

rewrote the test cases in terms of self.expect. Haven't looked at being totally correct with flagging paths with .experimental. as never-errored.

This revision was not accepted when it landed; it landed in state Needs Review.May 1 2018, 3:54 PM
This revision was automatically updated to reflect the committed changes.