This patch is a less intrusive implementation of 2d53527.
It introduces a new PlatformMetadata held by every platform that
contains various objects that might be used my a platform instance.
In its current form, the PlatformMetadata holds a reference to the
Debugger and a ScriptedMetadata pointer. These are necessary in other to
instanciate the scripted object that the ScriptedPlatform interacts with.
In order to make it less introsive with the rest of lldb's platform
creation code, platform metadata are set after the platform creation,
and requires to platform to reload them (using Platform::ReloadMetadata).
This approach has the tradeoff that the ScriptedPlaform instance is
technically invalid and useless right after its creation. However, the user
should never be in that situation, since we reload the platform metadata
everytime with create or select the platform.
Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
newline