Some spelling and grammar fixes in the comments.

PiperOrigin-RevId: 562802023
This commit is contained in:
Fergus Henderson 2023-09-05 09:26:15 -07:00 committed by Copybara-Service
parent be0cde8c2e
commit a19da25565

View File

@ -169,12 +169,12 @@ class CalculatorContract {
// For services which allow default initialization: // For services which allow default initialization:
// - `CalculatorGraph` will try to create corresponding service object by // - `CalculatorGraph` will try to create corresponding service object by
// default even if request is made optional // default even if request is made optional
// (`GraphServiceRequest::Optional()`) // (`GraphServiceRequest::Optional()`).
// //
// For services which disallow default initialization: // For services which disallow default initialization:
// - `CalculatorGraph` requires client to set corresponding service object and // - `CalculatorGraph` requires client to set corresponding service object and
// otherwise fails, unles request is mad optional // otherwise fails, unless request is made optional
// (`GraphServiceRequest::Optional()`) // (`GraphServiceRequest::Optional()`).
GraphServiceRequest& UseService(const GraphServiceBase& service) { GraphServiceRequest& UseService(const GraphServiceBase& service) {
auto it = service_requests_.emplace(service.key, service).first; auto it = service_requests_.emplace(service.key, service).first;
return it->second; return it->second;