I noticed this while reviewing the pull request for SERVER-74371 "Support arbitrary expressions for 'field' parameter for $getField" - a test case there shows the following:
Current Behavior
{$toString: "$foo"}
will become one of the following, depending on the serialization options:
Representative Shape
{$convert: { input: "$foo", to: "?" }}
Debug Shape
{$convert: { input: "$foo", to: "?string" }}
Proposed New Behavior
I would propose we do the following instead:
Representative Shape
{$convert: { input: "$foo", to: "string" }}
Debug Shape
{$convert: { input: "$foo", to: "string" }}
- is depended on by
-
SERVER-85111 Tracking: Known M2 correctness bugs
- Closed
- related to
-
SERVER-74371 Support arbitrary expressions for 'field' parameter for $getField
- Closed