@@ -274,24 +274,24 @@ namespace winrt::impl
274274 }
275275 if constexpr (std::is_enum_v<T>)
276276 {
277- if (auto temp = value.try_as <Windows::Foundation::IReference<T>>())
277+ if (auto temp = value.template try_as <Windows::Foundation::IReference<T>>())
278278 {
279279 return temp.Value ();
280280 }
281281 else
282282 {
283- return static_cast <T>(value.as <Windows::Foundation::IReference<std::underlying_type_t <T>>>().Value ());
283+ return static_cast <T>(value.template as <Windows::Foundation::IReference<std::underlying_type_t <T>>>().Value ());
284284 }
285285 }
286286#ifdef WINRT_IMPL_IUNKNOWN_DEFINED
287287 else if constexpr (std::is_same_v<T, GUID>)
288288 {
289- return value.as <Windows::Foundation::IReference<guid>>().Value ();
289+ return value.template as <Windows::Foundation::IReference<guid>>().Value ();
290290 }
291291#endif
292292 else
293293 {
294- return value.as <Windows::Foundation::IReference<T>>().Value ();
294+ return value.template as <Windows::Foundation::IReference<T>>().Value ();
295295 }
296296 }
297297
@@ -300,28 +300,28 @@ namespace winrt::impl
300300 {
301301 if constexpr (std::is_enum_v<T>)
302302 {
303- if (auto temp = value.try_as <Windows::Foundation::IReference<T>>())
303+ if (auto temp = value.template try_as <Windows::Foundation::IReference<T>>())
304304 {
305305 return temp.Value ();
306306 }
307307
308- if (auto temp = value.try_as <Windows::Foundation::IReference<std::underlying_type_t <T>>>())
308+ if (auto temp = value.template try_as <Windows::Foundation::IReference<std::underlying_type_t <T>>>())
309309 {
310310 return static_cast <T>(temp.Value ());
311311 }
312312 }
313313#ifdef WINRT_IMPL_IUNKNOWN_DEFINED
314314 else if constexpr (std::is_same_v<T, GUID>)
315315 {
316- if (auto temp = value.try_as <Windows::Foundation::IReference<guid>>())
316+ if (auto temp = value.template try_as <Windows::Foundation::IReference<guid>>())
317317 {
318318 return temp.Value ();
319319 }
320320 }
321321#endif
322322 else
323323 {
324- if (auto temp = value.try_as <Windows::Foundation::IReference<T>>())
324+ if (auto temp = value.template try_as <Windows::Foundation::IReference<T>>())
325325 {
326326 return temp.Value ();
327327 }
0 commit comments