I am using DynamicResource in a template, and StaticResourceExtensions as resource inside each style using that template, so that the DynamicResource is evaluated differentl
Pretty sure this is a BAML compilation related bug. The code will work if compiled dynamically at run time using XamlReader.Parse. This could be used as a workaround as well, i suppose.