[vlmc-devel] Core: Use MeyersSingleton instead of ScopedSingleton

Hugo Beauzée-Luyssen hugo at beauzee.fr
Fri Jun 2 14:01:37 CEST 2017


On Fri, Jun 2, 2017, at 01:58 PM, Yikai Lu wrote:
> vlmc | branch: master | Yikai Lu <luyikei.qmltu at gmail.com> | Fri Jun  2
> 20:52:40 2017 +0900| [e48d5d10af7a54f36e0ac6402b4657737d03aa99] |
> committer: Yikai Lu
> 
> Core: Use MeyersSingleton instead of ScopedSingleton
> 
> > https://code.videolan.org/videolan/vlmc/commit/e48d5d10af7a54f36e0ac6402b4657737d03aa99
> ---
> 
>  src/Main/Core.h   | 2 +-
>  src/Main/main.cpp | 2 --
>  2 files changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/src/Main/Core.h b/src/Main/Core.h
> index 1e98998e..4e7ddaf8 100644
> --- a/src/Main/Core.h
> +++ b/src/Main/Core.h
> @@ -40,7 +40,7 @@ namespace Backend
>  #include <QElapsedTimer>
>  #include "Tools/Singleton.hpp"
>  
> -class Core : public ScopedSingleton<Core>
> +class Core : public MeyersSingleton<Core>
>  {
>      public:
>          Backend::IBackend*      backend();
> diff --git a/src/Main/main.cpp b/src/Main/main.cpp
> index f81119e6..776400bc 100644
> --- a/src/Main/main.cpp
> +++ b/src/Main/main.cpp
> @@ -97,7 +97,6 @@ VLMCGuimain( int argc, char **argv )
>  
>      Backend::IBackend* backend;
>      VLMCmainCommon( app, &backend );
> -    auto coreLock = Core::Policy_t::lock();
>  
>      /* Load a project file */
>      bool        project = false;
> @@ -192,7 +191,6 @@ VLMCCoremain( int argc, char **argv )
>  
>      Backend::IBackend* backend;
>      VLMCmainCommon( app, &backend );
> -    auto coreLock = Core::Policy_t::lock();
>  
>      /* Load a project file */
>      if ( app.arguments().count() < 3 )
> 
> _______________________________________________
> Vlmc-devel mailing list
> Vlmc-devel at videolan.org
> https://mailman.videolan.org/listinfo/vlmc-devel

Hey,

As discussed on IRC, feel free to burn the ScopedSingleton :)

Regards,

-- 
  Hugo Beauzée-Luyssen
  hugo at beauzee.fr


More information about the Vlmc-devel mailing list