No, it's incorrect; there has been some discussion to warn users about. Box<String>.f1 simply shadows Box<T>.f1. This means that there is no dynamic dispatch. E.g.
For more complex cases you can always create a protocol e.g. StringBox, that Box conditionally conforms to where T == String. Then, by conditionally casting self as? StringBox you can check for more complex values. For example, by having a conformance where T: StringProtocol you can customize your function based on whether your value conforms to a given protocol. However, I don’t know how efficient this is, you might have to benchmark against the aforementioned metatype comparison.