Skip to content

Commit f358dc2

Browse files
authored
Switch ImageUtils.cpp to use co_return (#12572)
* Switch ImageUtils.cpp to use co_return In this async method, we should be using co_return. It appears MSVC is a bit more forgiving than clang on this front. * Change files
1 parent 61fbc9e commit f358dc2

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"type": "prerelease",
3+
"comment": "Switch ImageUtils.cpp to use co_return",
4+
"packageName": "react-native-windows",
5+
"email": "[email protected]",
6+
"dependentChangeType": "patch"
7+
}

vnext/Microsoft.ReactNative/Utils/ImageUtils.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ winrt::IAsyncOperation<winrt::IRandomAccessStream> GetImageStreamAsync(ReactImag
6060
}
6161

6262
winrt::Windows::Storage::Streams::IRandomAccessStreamWithContentType stream{openReadAsync.GetResults()};
63-
return stream;
63+
co_return stream;
6464
}
6565

6666
auto httpMethod{

0 commit comments

Comments
 (0)