================ @@ -50,29 +50,29 @@ llvm::json::Value toJSON(const SourceLLDBData &); struct Symbol { /// The symbol id, usually the original symbol table index. - uint32_t id; + uint32_t id = 0; /// True if this symbol is debug information in a symbol. - bool isDebug; + bool isDebug = false; /// True if this symbol is not actually in the symbol table, but synthesized /// from other info in the object file. - bool isSynthetic; + bool isSynthetic = false; /// True if this symbol is globally visible. - bool isExternal; + bool isExternal = false; /// The symbol type. - lldb::SymbolType type; + lldb::SymbolType type = lldb::eSymbolTypeInvalid; /// The symbol file address. - lldb::addr_t fileAddress; + lldb::addr_t fileAddress = 0; /// The symbol load address. - std::optional<lldb::addr_t> loadAddress; + std::optional<lldb::addr_t> loadAddress = std::nullopt; ---------------- JDevlieghere wrote:
Isn't a `std::optional` default initialized to a nullopt? ```suggestion std::optional<lldb::addr_t> loadAddress; ``` https://github.com/llvm/llvm-project/pull/157150 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits