[Lldb-commits] [lldb] [lldb] Assert on invalid default {S, U}Int64 (NFC) (PR #126590)
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Mon Feb 10 14:53:25 PST 2025
================
@@ -68,11 +68,10 @@ class OptionValueSInt64 : public Cloneable<OptionValueSInt64, OptionValue> {
}
bool SetDefaultValue(int64_t value) {
- if (value >= m_min_value && value <= m_max_value) {
- m_default_value = value;
- return true;
- }
- return false;
+ assert(value >= m_min_value && value <= m_max_value &&
----------------
JDevlieghere wrote:
No, the default value is set by LLDB itself. The situation this assert catches is someone defining a default value in the tablegen file that's larger or smaller than the mix/max value. AFAIK there is no way for a user to set a default value.
Currently, `SetMinValue` is only called for the terminal width and height. There are no other users.
https://github.com/llvm/llvm-project/pull/126590
More information about the lldb-commits
mailing list