XamlX
XamlX copied to clipboard
`ExpressionParseError` when using `{TemplateBinding .}`
As the title suggests, using a TemplateBinding
with a path to the binding object itself ({TemplateBinding .}
) causes an exception during compile time. I am forced to use the verbose syntax of {Binding ., RelativeSource={RelativeSource TemplatedParent}}
.
FirmwareItem.axaml(83, 29): [XAMLIL] Internal compiler error while transforming node XamlX.Ast.XamlAstObjectNode:
Avalonia.Data.Core.ExpressionParseException: Unexpected '.'.
at Avalonia.Markup.Xaml.Parsers.PropertyParser.Parse(CharacterReader r)
at Avalonia.Markup.Xaml.XamlIl.CompilerExtensions.XamlIlAvaloniaPropertyHelper.CreateNode(AstTransformationContext context, String propertyName, IXamlAstTypeReference selectorTypeReference, IXamlLineInfo lineInfo)
at Avalonia.Markup.Xaml.XamlIl.CompilerExtensions.AvaloniaXamlIlLanguage.CustomValueConverter(AstTransformationContext context, IXamlAstValueNode node, IXamlType type, IXamlAstValueNode& result)
at XamlX.Transform.XamlTransformHelpers.TryConvertValue(AstTransformationContext context, IXamlAstValueNode node, IXamlType type, XamlAstClrProperty propertyContext, IXamlAstValueNode& rv)
at XamlX.Transform.Transformers.ConstructableObjectTransformer.TransformArgumentsAndGetConstructor(AstTransformationContext context, XamlAstObjectNode n)
at XamlX.Transform.Transformers.Con... Line 83, position 29.