Unity-Technologies / Unity-Technologies/Unity.Mathematics
Importing Unity.Mathematics.math shadows type names
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 1.4k
- Forks
- 159
- PR merge metrics
- No merged PRs in 30d
Description
When using static Unity.Mathematics.math, type names get shadowed by functions of the same name (e.g. float3, float4x4, quaternion), making it imposible to access their static members without fully qualifying the type name.
This makes it really annoying to use static members such as float3.zero, float4x4.PerspectiveFov, quaternion.AxisAngle, etc. having to either qualify them with Unity.Mathematics. or dropping the using static altogether and qualify all math with math..
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the name-shadowing with using static Unity.Mathematics.math and the examples float3.zero, float4x4.PerspectiveFov, and quaternion.AxisAngle. Inspect the Unity.Mathematics.math functions and the affected type declarations; done means static members remain usable without fully qualifying the type names.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, unity
- Domain
- developer-experience
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100