Don't expect .native() to return a string
authorChristopher Dykes <cdykes@fb.com>
Wed, 23 Nov 2016 23:19:57 +0000 (15:19 -0800)
committerFacebook Github Bot <facebook-github-bot-bot@fb.com>
Wed, 23 Nov 2016 23:23:30 +0000 (15:23 -0800)
Summary: It's called `.native()` for a reason, and returns a `wstring` on windows, so call `string()` instead.

Reviewed By: yfeldblum

Differential Revision: D4229254

fbshipit-source-id: d5f9658b41f45fd719ca3e878a2e61c9dce24f10

folly/experimental/test/NestedCommandLineAppTest.cpp
folly/experimental/test/ProgramOptionsTest.cpp

index d4b749c0f50972a587cad9499ef906c5f04529ac..597b15f7e1690bf7cb1bcccf1c0dd19e5fc48afc 100644 (file)
@@ -32,7 +32,7 @@ std::string getHelperPath() {
   if (!fs::exists(path)) {
     path = path.parent_path().parent_path() / basename / basename;
   }
-  return path.native();
+  return path.string();
 }
 
 std::string callHelper(std::initializer_list<std::string> args,
index c54dd54b0a8bb9630009db80820778b7aa193e0a..cd95970c0c3ae0e464f352c71e1ae51dc1e398e2 100644 (file)
@@ -33,7 +33,7 @@ std::string getHelperPath() {
   if (!fs::exists(path)) {
     path = path.parent_path().parent_path() / basename / basename;
   }
-  return path.native();
+  return path.string();
 }
 
 std::string callHelper(ProgramOptionsStyle style,