为什么在locale设置为std :: locale()时会引发崩溃?

时间:2015-08-21 10:39:40

标签: c++ boost local

此代码的崩溃崩溃:

$list = Import-Csv C:\file.txt

#actual date
$date  = Get-date -Format d
$day   = $fecha.Substring(0,2)
$month = $fecha.Substring(3,2)
$year  = $fecha.Substring(6,4)
$date  = "$year$month$day"

#I do this because if I use $list will return me an pscustomobject object
$file = Get-Content -Path C:\file.txt

#Use a ForEach loop to process all lines in the source file
foreach ($entrada in $file) {
  $sub = $entrada.Substring(7,7)

  if ($date-like $sub) {Write-Host "They are equals"}
  if ($sub -Match $date) {Write-Host "They are equals"}
  if ($date.Equals($sub)) {Write-Host "They are equals"}
  if ($date-eq $sub) {Write-Host "They are equals"}
  if ($sub -contains $date) {Write-Host "They are equals"}
}
in“path_traits.hpp”:

boost::filesystem::path::imbue(std::locale());
boost::filesystem::path p (L"привет");

为什么呢? OSX和Linux上的问题

0 个答案:

没有答案