Optimal custom operator with generic type constraint for numerical type
I imagine that you started out with something like this: 

infix operator ¿%

func ¿% &lt;T: NumericType&gt;(percentage: T, ofTotal: Double) -&gt; Double {
    return percentage * ofTotal / 100.0
} 


And received the error: 


  binary operator '*' cannot be applied to operands of type 'T' and 'Double'


You've solved this by creating a function with signature NumericType * Double -&gt; Double... which works, but as you've found requires a bunch of boilerplate.

The alternative approach is to to find a way to convert NumericType to a double so that in the end you're doing the multiplication on two doubles:

(NumericType -&gt; Double) * Double - &gt; Double

An implementation of this would look something like this: 

protocol NumericType {
    var doubleValue: Double { get }
}

infix operator ¿%
infix operator %?

func ¿% &lt;T: NumericType&gt;(percentage: T, ofTotal: Double) -&gt; Double {
    return percentage.doubleValue * ofTotal / 100.0
}

func %? &lt;T: NumericType&gt;(segment: T, ofTotal: Double) -&gt; Double {
    return segment.doubleValue * 100 / ofTotal
}

extension Double: NumericType {
    var doubleValue: Double { return self }
}

extension Int: NumericType {
    var doubleValue: Double { return Double(self) }
}


However, please please please reconsider using custom operators like this. 

I don't think that it's improving the readability or maintainability of your code, and unless you're using it every single day, I feel like it's something that will cause headaches in the future.