This repository was archived by the owner on Dec 24, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +11
-3
lines changed
NuGet.Core/ServiceStack.Text.Core
tests/ServiceStack.Text.Tests Expand file tree Collapse file tree 4 files changed +11
-3
lines changed Original file line number Diff line number Diff line change 27
27
<dependency id =" Microsoft.CSharp" version =" [4.0.1, )" />
28
28
<dependency id =" System.Reflection.Emit" version =" [4.0.1, )" />
29
29
<dependency id =" System.Reflection.Extensions" version =" [4.0.1, )" />
30
- <dependency id =" NETStandard.Library" version =" [1.6.0, )" />
30
+ <dependency id =" System.Runtime.InteropServices.RuntimeInformation" version =" [4.0.0, )" />
31
+ <dependency id =" NETStandard.Library" version =" [1.6.0, )" />
31
32
</group >
32
33
<group targetFramework =" .NETStandard1.3" >
33
34
<dependency id =" System.Runtime.Serialization.Primitives" version =" [4.1.1, )" />
Original file line number Diff line number Diff line change 12
12
using System . Globalization ;
13
13
using System . Reflection ;
14
14
using System . Reflection . Emit ;
15
+ using System . Runtime . InteropServices ;
15
16
16
17
#if NETSTANDARD1_3
17
18
using System . Collections . Specialized ;
@@ -56,6 +57,11 @@ public class NetStandardPclExport : PclExport
56
57
public NetStandardPclExport ( )
57
58
{
58
59
this . PlatformName = Platforms . NetStandard ;
60
+ #if NETSTANDARD1_3
61
+ this . DirSep = Path . DirectorySeparatorChar ;
62
+ #else
63
+ this . DirSep = RuntimeInformation . IsOSPlatform ( OSPlatform . Windows ) ? '\\ ' : '/' ;
64
+ #endif
59
65
}
60
66
61
67
public override string ReadAllText ( string filePath )
Original file line number Diff line number Diff line change 31
31
"System.Reflection.Emit" : " 4.0.1" ,
32
32
"System.Reflection.Emit.LightWeight" : " 4.0.1" ,
33
33
"System.Reflection.Extensions" : " 4.0.1" ,
34
- "System.Linq.Expressions" : " 4.1.0"
34
+ "System.Linq.Expressions" : " 4.1.0" ,
35
+ "System.Runtime.InteropServices.RuntimeInformation" : " 4.0.0"
35
36
}
36
37
},
37
38
"netstandard1.3" : {
Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ public void Can_LastLeftPart_and_LastRightPart_string_needle()
101
101
}
102
102
103
103
private static readonly char DirSep = Path . DirectorySeparatorChar ;
104
- private static readonly char AltDirSep = Path . DirectorySeparatorChar == '/' ? ' \\ ' : '/' ;
104
+ private static readonly char AltDirSep = '/' ;
105
105
106
106
[ Test ]
107
107
public void Does_get_ParentDirectory ( )
You can’t perform that action at this time.
0 commit comments