Minor cleanups to the new ModuleList notification APIs: passing in the ModuleList as part of the callbacks, and not copying the notifier as part of copy constructing and assigning


git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@167592 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Target/Target.cpp b/source/Target/Target.cpp
index b961603..ec88710 100644
--- a/source/Target/Target.cpp
+++ b/source/Target/Target.cpp
@@ -1059,31 +1059,31 @@
 }
 
 void
-Target::WillClearList ()
+Target::WillClearList (const ModuleList& module_list)
 {
 }
 
 void
-Target::ModuleAdded (const ModuleSP &module_sp)
+Target::ModuleAdded (const ModuleList& module_list, const ModuleSP &module_sp)
 {
     // A module is being added to this target for the first time
-    ModuleList module_list;
-    module_list.Append(module_sp);
+    ModuleList my_module_list;
+    my_module_list.Append(module_sp);
     LoadScriptingResourceForModule(module_sp, this);
-    ModulesDidLoad (module_list);
+    ModulesDidLoad (my_module_list);
 }
 
 void
-Target::ModuleRemoved (const ModuleSP &module_sp)
+Target::ModuleRemoved (const ModuleList& module_list, const ModuleSP &module_sp)
 {
     // A module is being added to this target for the first time
-    ModuleList module_list;
-    module_list.Append(module_sp);
-    ModulesDidUnload (module_list);
+    ModuleList my_module_list;
+    my_module_list.Append(module_sp);
+    ModulesDidUnload (my_module_list);
 }
 
 void
-Target::ModuleUpdated (const ModuleSP &old_module_sp, const ModuleSP &new_module_sp)
+Target::ModuleUpdated (const ModuleList& module_list, const ModuleSP &old_module_sp, const ModuleSP &new_module_sp)
 {
     // A module is replacing an already added module
     m_breakpoint_list.UpdateBreakpointsWhenModuleIsReplaced(old_module_sp, new_module_sp);