We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
It would be handy in some cases to be able to assign enum fields with values matching some string. In fact, this functionality already exists, but it is internal to the package and so can't be accessed when using the generated code. See: https://github.com/apple/swift-protobuf/blob/master/Sources/SwiftProtobuf/NameMap.swift#L271
There's already a TODO comment about this, see: https://github.com/apple/swift-protobuf/blob/master/Sources/SwiftProtobuf/NameMap.swift#L11
Right now the only way I've found to do it, is MyMessage(textFormatString: "category: \(categoryString)").category which is clearly sub-optimal.
MyMessage(textFormatString: "category: \(categoryString)").category
The text was updated successfully, but these errors were encountered:
I believe this is a duplicate of #326.
Going the other way is #731.
Sorry, something went wrong.
No branches or pull requests
It would be handy in some cases to be able to assign enum fields with values matching some string. In fact, this functionality already exists, but it is internal to the package and so can't be accessed when using the generated code.
See: https://github.com/apple/swift-protobuf/blob/master/Sources/SwiftProtobuf/NameMap.swift#L271
There's already a TODO comment about this, see:
https://github.com/apple/swift-protobuf/blob/master/Sources/SwiftProtobuf/NameMap.swift#L11
Right now the only way I've found to do it, is
MyMessage(textFormatString: "category: \(categoryString)").category
which is clearly sub-optimal.The text was updated successfully, but these errors were encountered: