# Calling \`max\` function when it's hidden by static member

**URL:** <https://forums.swift.org/t/calling-max-function-when-its-hidden-by-static-member/30647>\
**Category:** Using Swift\
**Tags:** scope\
**Created:** [November 9, 2019, 8:59pm UTC](https://forums.swift.org/t/calling-max-function-when-its-hidden-by-static-member/30647 "2019-11-09T20:59:11Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![eskimo](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/eskimo/32/13558_2.png) [@eskimo](https://forums.swift.org/u/eskimo)\
**Post date:** [November 11, 2019, 8:43am UTC](https://forums.swift.org/t/calling-max-function-when-its-hidden-by-static-member/30647/6 "2019-11-11T08:43:56Z")

</div>

> though I am not sure how it applies to a file format such as `.MP4`

That’s an interesting question. MPEG-4’s container format is a ‘child’ of QuickTime, and QuickTime definitely used MacRoman for this. I’m not sure whether they removed that dependency as part of the standardisation process. It’s possible that they didn’t address it at all, and just standardised on the `UInt32` values. The only way to know for sure is to look at the MPEG-4 standard itself.

> Note about `String.data(using:)`:
> 
> I had a hard time understanding where this is coming from.

Indeed. The Quick Help usually has a link to the documentation but that’s not present in this case. I suspect this is because the symbol is implemented in Foundation’s Swift overlay. Regardless, the fact that Xcode won’t take you to the documentation is bugworthy IMO. Please file a [bug](https://developer.apple.com/bug-reporting/) about that (and post your bug number, just for the record).

> … it requires Foundation. Right?

Yes.

> So this function requires bridging `String` to `NSString`.

If I’m right, and this is part of Foundation’s Swift overlay, the bridging situation is nuanced.

Personally, I don’t lose a lot of sleep worrying about this sort of bridging. If something is slow and I’ve profiled it and the profile shows that bridging is part of the problem, I look into it. Otherwise I just accept it as a part of life.

Share and Enjoy

Quinn “The Eskimo!” @ DTS @ Apple

---

_[View the full topic](https://forums.swift.org/t/calling-max-function-when-its-hidden-by-static-member/30647)._
