-
Notifications
You must be signed in to change notification settings - Fork 17.8k
New issue
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
testing: fix missing preposition in docstring #57389
Comments
Thanks. Want to send a patch? There's no need to track this change in an issue. See https://go.dev/doc/contribute. |
It's also fine as is, no fix needed. |
@robpike do you have a link to an explanation, or a name for this form of omitting "with"? All I can say as a non-native speaker is that I had never seen it before, so I'd definitely find the doc easier to read with the explicit "with". |
It's idiomatic English. I probably wrote that sentence myself. The preposition is either assumed or unnecessary. Putting it is correct, but so is leaving it out. To me it sounds right. But if it's bothersome to some, change it. If I were asked to make it clearer, instead of adding the preposition I would likely add quotes:
That demonstrates the text is a literal suffix. |
Ah, I see what you mean. I agree that the quotes make it clearer as well. |
Using the word "with" after "ends" clarifies that it is the name of the file that ends with the specified string, rather than the file itself. In general, it is important to use precise and clear language in order to avoid misunderstandings. In this case, using the word "with" after "ends" helps to make the intended meaning clear. I am non-native speaker. I find the string easier with the explicit "with". |
Thanks, I will send a patch then. It would also make the language consistent with what is used in other places in the codebase - one example is here go/src/cmd/go/internal/get/get.go Line 212 in a5a4744
|
Change https://go.dev/cl/458435 mentions this issue: |
The phrase in docstring here
go/src/testing/testing.go
Line 16 in 0b2ad1d
which instead should probably say
The text was updated successfully, but these errors were encountered: