Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Unity3D-sdk] Remove null propagation for C# 4.0 #112

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

KorneiDontsov
Copy link

Null propagation operator was released in C# 6.0. Older versions of Unity use C# 4.0 which doesn't have null propagation operator. This leads to errors like this:

Assets/PocoSDK/PocoManager.cs(155,16): error CS1525: Unexpected symbol `.', expecting `[', or `identifier';

<Assembly-CSharp>\Assets\PocoSDK\PocoManager.cs:5345 Feature 'null propagating operator' is not available. Please use language version 6.0 or greater.

Documentation in README says that Poco-SDK supports Unity3D version 4 & 5 and above. To do this we should replace null propagation operator with the equivalent C# 4.0 code. This commit does it.

Null propagation operator was released in C# 6.0. Older versions of Unity use C# 4.0 which doesn't have null propagation operator. This leads to errors like this:
`Assets/PocoSDK/PocoManager.cs(155,16): error CS1525: Unexpected symbol `.', expecting `[', or `identifier'`;
`<Assembly-CSharp>\Assets\PocoSDK\PocoManager.cs:5345 Feature 'null propagating operator' is not available. Please use language version 6.0 or greater.`

Documentation in README says that Poco-SDK supports Unity3D version 4 & 5 and above. To do this we should replace null propagation operator with the equivalent C# 4.0 code. This commit does it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant