Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Commit

Permalink
fix can't compile in regular Unity(C# 6.0) #328
Browse files Browse the repository at this point in the history
  • Loading branch information
neuecc committed Jul 24, 2018
1 parent 4001368 commit bcac2f2
Show file tree
Hide file tree
Showing 17 changed files with 41 additions and 23 deletions.
2 changes: 1 addition & 1 deletion Assembly-CSharp-firstpass-vs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion Assembly-CSharp-firstpass.Player.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -896,7 +896,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion Assembly-CSharp-firstpass.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -676,7 +676,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion Assembly-CSharp-vs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion Assembly-CSharp.Player.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -910,7 +910,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion Assembly-CSharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if (NET_4_6 || NET_STANDARD_2_0) && UNITY_2018_1_OR_NEWER
#if CSHARP_7_OR_LATER
#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member

using System;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if UNITY_2018_1_OR_NEWER && (NET_4_6 || NET_STANDARD_2_0 || CSHARP_7_OR_LATER) && !UNITY_WSA
#if CSHARP_7_OR_LATER
#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member

using System;
Expand Down
16 changes: 8 additions & 8 deletions Assets/Scripts/RuntimeUnitTestToolkit/UnitTest.unity
Original file line number Diff line number Diff line change
Expand Up @@ -511,8 +511,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 207.25, y: -634.5}
m_SizeDelta: {x: 414.5, y: 1269}
m_AnchoredPosition: {x: 198, y: -400}
m_SizeDelta: {x: 396, y: 800}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1264454900
MonoBehaviour:
Expand Down Expand Up @@ -587,8 +587,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 202.25, y: -30}
m_SizeDelta: {x: 384.5, y: 40}
m_AnchoredPosition: {x: 193, y: -30}
m_SizeDelta: {x: 366, y: 40}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1337584758
MonoBehaviour:
Expand Down Expand Up @@ -925,7 +925,7 @@ RectTransform:
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 15, y: 0}
m_SizeDelta: {x: -15, y: -1242}
m_SizeDelta: {x: -15, y: -773}
m_Pivot: {x: 0, y: 1}
--- !u!114 &1607029148
MonoBehaviour:
Expand Down Expand Up @@ -1108,7 +1108,7 @@ RectTransform:
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: -1209}
m_SizeDelta: {x: 0, y: -740}
m_Pivot: {x: 0, y: 1}
--- !u!114 &1903152287
MonoBehaviour:
Expand Down Expand Up @@ -1187,8 +1187,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 631.75, y: -634.5}
m_SizeDelta: {x: 414.5, y: 1269}
m_AnchoredPosition: {x: 604, y: -400}
m_SizeDelta: {x: 396, y: 800}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &2044738991
MonoBehaviour:
Expand Down
18 changes: 18 additions & 0 deletions Assets/Scripts/Tests/_AsyncTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,24 @@ public async UniTask ExceptionlessCancellation()
canceled.IsTrue();
}

public async UniTask ExceptionCancellation()
{
var cts = new CancellationTokenSource();

UniTask.DelayFrame(10).ContinueWith(_ => cts.Cancel()).Forget();

bool occur = false;
try
{
var value = await UniTask.DelayFrame(100, cancellationToken: cts.Token);
}
catch (OperationCanceledException ex)
{
occur = true;
}
occur.IsTrue();
}

IEnumerator ToaruCoroutineEnumerator()
{
yield return null;
Expand Down
2 changes: 1 addition & 1 deletion NewAssembly.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -707,7 +707,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion UniRx.Async.Player.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -912,7 +912,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion UniRx.Async.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion UniRx.Player.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -1074,7 +1074,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion UniRx.Plugins.Player.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -937,7 +937,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion UniRx.Plugins.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -700,7 +700,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion UniRx.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -904,7 +904,7 @@
<PropertyGroup>
<IncrementalCompiler>true</IncrementalCompiler>
<CscToolPath>C:\Users\neuecc\AppData\Local\Unity\cache\packages\packages.unity.com\com.unity.incrementalcompiler@0.0.42-preview.14\.bin</CscToolPath>
<DocumentationFile>41588</DocumentationFile>
<DocumentationFile>5746</DocumentationFile>
<UseCommonOutputDirectory>true</UseCommonOutputDirectory>
</PropertyGroup>
</Project>

0 comments on commit bcac2f2

Please sign in to comment.