mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Rojas <alexan...@mesosphere.io>
Subject Re: Review Request 55435: Windows: Fixed the locale guard in jsonify.hpp.
Date Thu, 12 Jan 2017 10:27:23 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/55435/#review161365
-----------------------------------------------------------




3rdparty/stout/include/stout/jsonify.hpp (lines 66 - 72)
<https://reviews.apache.org/r/55435/#comment232605>

    Add a TODO about pulling the locale manipulation to an eventual `locale.hpp`



3rdparty/stout/include/stout/jsonify.hpp (lines 75 - 78)
<https://reviews.apache.org/r/55435/#comment232604>

    We actually should verify it the application already has that enabled and revert only
if per thread locale wasn't set up when we create the RAII. e.g.
    
    ```c++
    per_thread = (_configthreadlocale(_ENABLE_PER_THREAD_LOCALE) == _ENABLE_PER_THREAD_LOCALE);
    
    // play with locale
    // ...
    
    if (!per_thread) {
      _configthreadlocale(_DISABLE_PER_THREAD_LOCALE)
    }
    ```


- Alexander Rojas


On Jan. 12, 2017, 1:56 a.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/55435/
> -----------------------------------------------------------
> 
> (Updated Jan. 12, 2017, 1:56 a.m.)
> 
> 
> Review request for mesos, Alexander Rojas, Daniel Pravat, Alex Clemmer, and Michael Park.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Changing locales in Windows is mainly accomplished via `setlocale`,
> which takes a bit mask (with constants named slightly differently
> than in the POSIX headers) and a `char*`.
> 
> 
> Diffs
> -----
> 
>   3rdparty/stout/include/stout/jsonify.hpp 3c48046e087de2a66139a31449327fd94c149371 
> 
> Diff: https://reviews.apache.org/r/55435/diff/
> 
> 
> Testing
> -------
> 
> Windows:
> 
> msbuild Mesos.sln /p:PreferredToolArchitecture=x64 /m /t:stout-tests
> 3rdparty\stout\tests\Debug\stout-tests.exe --gtest_filter="*Json*"
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message