User-defined operators: AST

This commit is contained in:
wechman
2023-02-22 00:06:17 +01:00
committed by Kamil Śliwak
parent fa0d3a44a7
commit 9a36438441
7 changed files with 141 additions and 5 deletions
+6 -1
View File
@@ -312,7 +312,12 @@ struct MemberAccessAnnotation: ExpressionAnnotation
util::SetOnce<VirtualLookup> requiredLookup;
};
struct BinaryOperationAnnotation: ExpressionAnnotation
struct OperationAnnotation: ExpressionAnnotation
{
util::SetOnce<FunctionDefinition const*> userDefinedFunction;
};
struct BinaryOperationAnnotation: OperationAnnotation
{
/// The common type that is used for the operation, not necessarily the result type (which
/// e.g. for comparisons is bool).