Skip to content

Change C++ MethodResult::Success and Error methods to use reference arguments #63975

@stuartmorgan-g

Description

@stuartmorgan-g

Currently Success takes a pointer, since the return value is optional. However, that makes the case where there is a return value annoying if it's not a complex EncodableValue that was already constructed, since you have to write things like:

EncodableValue response(true);
result->Success(&response);

We should add an overload that would allow for the more natural

result->Success(EncodableValue(true));

Metadata

Metadata

Labels

P3Issues that are less important to the Flutter projecta: desktopRunning on desktope: glfwGLFW desktop embeddingengineflutter/engine related. See also e: labels.platform-windowsBuilding on or for Windows specifically

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions