On Friday, 8 November 2024 at 21:55:53 UTC, Liam McGillivray wrote:
if(isNumeric!T)
```
Error: cannot implicitly convert expression `40.0F` of type `float` to `Milligrams`
```

I dont believe phoboes type detection templates are well designed; given some sort of type pattern matching issue you should write your own with the pattern

```
void dummyNumbericFunction(T)(T t){
  auto foo=t+t;
  ...
}
enum isNumbertic(T)=__traits(compiles,dummyNumbericFunction!T);
```

Reply via email to