Skip to content

The new System.MathF APIs should have wrappers created so they are available on .NETStandard #20113

Closed
@tannergooding

Description

@tannergooding

The new System.MathF APIs (#1151) where implemented in dotnet/coreclr#5492. However, they are currently only available in netcoreapp1.1 base applications.

Until they make their way back into the Desktop framework, I propose that simple wrapper implementations be provided so the APIs are accessible in .NETStandard based libraries.

The wrapper function should just call the corresponding System.Math API and cast the result back to System.Single.

For example, System.Acos(float) would be implemented as:

namespace System
{
    public static class MathF
    {
        public static float Acos(float value)
        {
            return (float)Math.Acos(value);
        }
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    api-needs-workAPI needs work before it is approved, it is NOT ready for implementationarea-System.Numerics

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions