17642, "e-kayrakli", "Should type and non-type "overloads" of functions in the Types module have the same names?", "2021-05-05T22:46:47Z"
opened 10:46PM - 05 May 21 UTC
area: Libraries / Modules
type: Design
In the [Types](https://chapel-lang.org/docs/master/modules/standard/Types.html) … module, we have several functions like
```chpl
proc isBoolType(type x) param {}
proc isBool(x) param {}
```
should these versions have the same name and be more proper overloads of the same function? e.g.:
```chpl
proc isBool(type x) param {}
proc isBool(x) param {}
```
I think they should. I don't think the `Type` suffix adds much value to the interface and feel like the user should be able to just use `isBool` and be able to pass whatever they like to it.
In the Types module, we have several functions like
proc isBoolType(type x) param {}
proc isBool(x) param {}
should these versions have the same name and be more proper overloads of the same function? e.g.:
proc isBool(type x) param {}
proc isBool(x) param {}
I think they should. I don't think the Type
suffix adds much value to the interface and feel like the user should be able to just use isBool
and be able to pass whatever they like to it.