# C# 7

**URL:** https://discussions.unity.com/t/c-7/663106
**Category:** C# & .NET
**Tags:** 2017.1-beta
**Created:** [April 28, 2017, 6:48pm UTC](https://discussions.unity.com/t/c-7/663106 "2017-04-28T18:48:59Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![makeshiftwings](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/makeshiftwings/32/334244_2.png) [@makeshiftwings](https://discussions.unity.com/u/makeshiftwings)
#### Post date: [April 28, 2017, 6:48pm UTC](https://discussions.unity.com/t/c-7/663106/1 "2017-04-28T18:48:59Z")

</div>

I noticed the new .NET 4.6 mode only supports C# 6 by default. Is there any way to enable C# 7 support?

---

<div class="post-metadata">

### Author: ![WendelinReich1](https://avatars.discourse-cdn.com/v4/letter/w/4491bb/32.png) [@WendelinReich1](https://discussions.unity.com/u/WendelinReich1)
#### Post date: [April 29, 2017, 9:22am UTC](https://discussions.unity.com/t/c-7/663106/2 "2017-04-29T09:22:23Z")

</div>

Bumb that, C# 7 rocks.

Note however that you **can** already use most of the C# 7 features if you compile your code into a library inside VS 2017. Out variables, pattern matching, local functions all work out of the box. I haven’t tested tuples but they should work (as noted [here](https://blogs.msdn.microsoft.com/dotnet/2017/03/09/new-features-in-c-7-0/)) if you import the System.ValueTuple package.

---

<div class="post-metadata">

### Author: ![thomak-dev](https://avatars.discourse-cdn.com/v4/letter/t/8491ac/32.png) [@thomak-dev](https://discussions.unity.com/u/thomak-dev)
#### Post date: [June 30, 2017, 7:10pm UTC](https://discussions.unity.com/t/c-7/663106/3 "2017-06-30T19:10:07Z")

</div>

I’d like to use C#7 in Unity too. Return by ref is a really nice language feature for optimization. At this rate we are just going to get another outdated C# version as the new default

---

<div class="post-metadata">

### Author: ![stefan\_furcht](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/stefan_furcht/32/347137_2.png) [@stefan\_furcht](https://discussions.unity.com/u/stefan_furcht)
#### Post date: [June 30, 2017, 9:31pm UTC](https://discussions.unity.com/t/c-7/663106/4 "2017-06-30T21:31:18Z")

</div>

Seconded, C# 7 is better than 4,5 & 6 together.

---

<div class="post-metadata">

### Author: ![system](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/system/32/97283_2.png) [@system](https://discussions.unity.com/u/system)
#### Post date: [July 1, 2017, 11:40am UTC](https://discussions.unity.com/t/c-7/663106/5 "2017-07-01T11:40:15Z")

</div>

Mono only recently introduced c# 7 support, so time is needed to let it stabilize then integrate, test and move things forward. Now that we’re working more closely with the .Net Foundation, expect things to move faster - however this topic is not pertinent to this beta.

---

<div class="post-metadata">

### Author: ![elbows](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/elbows/32/222790_2.png) [@elbows](https://discussions.unity.com/u/elbows)
#### Post date: [July 1, 2017, 11:58am UTC](https://discussions.unity.com/t/c-7/663106/6 "2017-07-01T11:58:55Z")

</div>

Sounds cool to me, confirms what I thought that the long period where the mono/.NET side of things was in a sort of limbo (apart from IL2CPP) was due to factors that are now gone and so is now well behind us 🙂

---

<div class="post-metadata">

### Author: ![PedroGV\_1](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/pedrogv_1/32/467973_2.png) [@PedroGV\_1](https://discussions.unity.com/u/PedroGV_1)
#### Post date: [July 7, 2017, 4:52pm UTC](https://discussions.unity.com/t/c-7/663106/7 "2017-07-07T16:52:34Z")

</div>

ETA for c# 7 (after Unity 2017 gets released)?

---

<div class="post-metadata">

### Author: ![system](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/system/32/97283_2.png) [@system](https://discussions.unity.com/u/system)
#### Post date: [July 10, 2017, 8:54am UTC](https://discussions.unity.com/t/c-7/663106/8 "2017-07-10T08:54:28Z")

</div>

> [@PedroGV\_1](#):
>
> ETA for c# 7 (after Unity 2017 gets released)?

No ETA other than we’ll be working on it and getting it stable from our side.
