mirror of
https://codeberg.org/ProgramSnail/lang_2023.git
synced 2025-12-06 06:58:45 +00:00
build_visitor first iteration
This commit is contained in:
parent
622b86f6c6
commit
582ad5668e
5 changed files with 338 additions and 116 deletions
|
|
@ -480,7 +480,7 @@ struct LambdaFunction : public Node {
|
|||
|
||||
struct NameSuperExpression : public Node {
|
||||
std::vector<TypeSubExpression> namespaces;
|
||||
std::vector<NameSubSuperExpression> expressions; // last is not SuperExpression
|
||||
std::vector<NameSubSuperExpression> expressions;
|
||||
};
|
||||
|
||||
struct NameExpression : public Node {
|
||||
|
|
@ -511,13 +511,13 @@ struct TypeConstructor : public Node {
|
|||
};
|
||||
|
||||
struct TupleType : public Node {
|
||||
TypeIdentifierDefinition type; // optional
|
||||
std::vector<std::pair<NameIdentifier, AnyType>> entities; // NameIdentifier is optional
|
||||
std::optional<TypeIdentifierDefinition> type;
|
||||
std::vector<std::pair<std::optional<NameIdentifier>, AnyType>> entities;
|
||||
};
|
||||
|
||||
struct VariantType : public Node {
|
||||
TypeIdentifierDefinition type; // optional
|
||||
std::vector<std::pair<TypeIdentifierDefinition, std::unique_ptr<TupleType>>> constructors;
|
||||
std::optional<TypeIdentifierDefinition> type;
|
||||
std::vector<std::variant<TypeIdentifierDefinition, std::unique_ptr<TupleType>>> constructors;
|
||||
};
|
||||
|
||||
struct AnnotatedType : public Node {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue