[Issue 19049] New: object.hashOf - don't wrap a public function with an identical public function

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Jul 2 16:28:26 UTC 2018


https://issues.dlang.org/show_bug.cgi?id=19049

          Issue ID: 19049
           Summary: object.hashOf - don't wrap a public function with an
                    identical public function
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: druntime
          Assignee: nobody at puremagic.com
          Reporter: n8sh.secondary at hotmail.com

This is hashOf in object.d:

```
size_t hashOf(T)(auto ref T arg, size_t seed = 0)
{
    import core.internal.hash;
    return core.internal.hash.hashOf(arg, seed);
}
```

This serves no purpose because `core.internal.hash.hashOf` is public and also
has an `auto ref` argument. So `core.internal.hash.hashOf` should either be
publicly imported or exposed through an alias.

This issue has synergy with PR https://github.com/dlang/druntime/pull/2238.

--


More information about the Digitalmars-d-bugs mailing list