lisz-works

プログラミングと興味を貴方に

Unity「Library/PackageCache~」でエラーが発生。簡単1発解決だった。

【スポンサーリンク】

Unity

久々にUnityしたらめっちゃエラー出た。

こんな感じエラーが、めっちゃ大量に出ました。

D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/FastAction.cs(24,45): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification

エラー内容

全部版がこちら。ちょっと長いので畳みます。

エラー全文版を開く

D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/FastAction.cs(24,45): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/FastAction.cs(59,45): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/FastAction.cs(94,45): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/FastAction.cs(129,45): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/MaterialReferenceManager.cs(585,74): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/MaterialReferenceManager.cs(621,74): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(408,82): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(408,99): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(638,69): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(771,60): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(986,51): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1081,238): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1098,83): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1131,53): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1222,238): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1241,83): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1306,209): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1458,209): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1876,82): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_FontAsset.cs(1880,83): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_InputField.cs(1561,148): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_InputField.cs(1607,139): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_InputField.cs(1682,152): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(368,58): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(428,68): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(430,62): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(450,68): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(452,62): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(501,70): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_MaterialManager.cs(503,62): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_SpriteAnimator.cs(48,65): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_SpriteAsset.cs(170,68): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_SpriteAsset.cs(188,56): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_SpriteAsset.cs(205,58): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_StyleSheet.cs(72,61): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(1948,75): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2060,75): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2170,75): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2252,75): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2417,75): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2561,75): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2633,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2703,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2773,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2843,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2911,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(2979,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(3047,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(3114,80): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(3812,73): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(3945,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(3945,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(3958,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(5446,177): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(5446,214): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(5458,179): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(5458,216): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_Text.cs(5919,66): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMP_TextUtilities.cs(2039,100): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_Private.cs(1019,59): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_Private.cs(1751,73): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_Private.cs(1903,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_Private.cs(1916,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_UGUI_Private.cs(1089,59): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_UGUI_Private.cs(1865,73): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_UGUI_Private.cs(2028,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification
D:/work/Unity/Project/Library/PackageCache/com.unity.textmeshpro@2.0.0/Scripts/Runtime/TMPro_UGUI_Private.cs(2041,130): error CS1644: Feature `out variable declaration' cannot be used because it is not part of the C# 4.0 language specification

解決方法

どうやら一時ファイルがアップデートにうまく対応できなかったようです。

エラーを見ていると、どうやら「com.unity.textmeshpro」というパッケージのフォルダがエラーしているようです。

ということで、このフォルダを消します。

/Library/PackageCache/com.unity.textmeshpro

ぼくは念の為、一旦リネームでUnityが読み込めないようにしました。

これで一気に消えました!

参考

こちらのページを参考にしました。ありがとうございました。

https://forum.unity.com/threads/case-1142289-textmesh-pro-feature-out-variable-declaration-cannot-be-used.653566/

あとがき

Unityのエラーの解決方法でした!

久々のUnityをしていますが苦難が多そうです……