|
|
@ -1038,7 +1038,7 @@ namespace ICSharpCode.Decompiler.Tests.TestCases.Pretty |
|
|
|
{ |
|
|
|
{ |
|
|
|
await Task.Delay(100); |
|
|
|
await Task.Delay(100); |
|
|
|
if (string.IsNullOrEmpty(str)) { |
|
|
|
if (string.IsNullOrEmpty(str)) { |
|
|
|
#if ROSLYN
|
|
|
|
#if CS70
|
|
|
|
if (int.TryParse(str, out int id)) { |
|
|
|
if (int.TryParse(str, out int id)) { |
|
|
|
#else
|
|
|
|
#else
|
|
|
|
int id; |
|
|
|
int id; |
|
|
@ -1050,6 +1050,12 @@ namespace ICSharpCode.Decompiler.Tests.TestCases.Pretty |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void NullCoalescing() |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
Test<Func<string, string, string>>((string a, string b) => a ?? b, (string a, string b) => a ?? b); |
|
|
|
|
|
|
|
Test<Func<int?, int>>((int? a) => a ?? 1, (int? a) => a ?? 1); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
internal static class Extensions |
|
|
|
internal static class Extensions |
|
|
|