Open JaiganeshKumaran opened 1 year ago
This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 5 days.
This issue needs to be fixed, as it prevents basic tasks with x:Bind in a C++/WinRT application. Please anyone.
@bpulliam
Also, consider allowing C++ developers to contribute to the open-source XAML compiler.
Hi, does this repro in WinAppSDK / WinUI3? Or just in WinUI2? Thanks!
@JesseCol Yes, the generated code is still broken in WinUI 3.
Describe the bug
Can't two-way bind a property of a primitive type to IInspectable because the generated code uses unknown_cast, which doesn't exist, instead of unbox_value.
Steps to reproduce the bug
Expected behavior
Generated code should correctly use unbox_value.
Screenshots
NuGet package version
WinUI 2 - Microsoft.UI.Xaml 2.8.1
Windows version
Windows 11 (21H2): Build 22000
Additional context
Workaround by defining unknown_cast in pch.h: