1 // Copyright (C) 2020-2025 Free Software Foundation, Inc.
3 // This file is part of GCC.
5 // GCC is free software; you can redistribute it and/or modify it under
6 // the terms of the GNU General Public License as published by the Free
7 // Software Foundation; either version 3, or (at your option) any later
10 // GCC is distributed in the hope that it will be useful, but WITHOUT ANY
11 // WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15 // You should have received a copy of the GNU General Public License
16 // along with GCC; see the file COPYING3. If not see
17 // <http://www.gnu.org/licenses/>.
19 #ifndef RUST_TYTY_VISITOR
20 #define RUST_TYTY_VISITOR
22 #include "rust-tyty.h"
30 virtual void visit (InferType
&type
) = 0;
31 virtual void visit (ADTType
&type
) = 0;
32 virtual void visit (TupleType
&type
) = 0;
33 virtual void visit (FnType
&type
) = 0;
34 virtual void visit (FnPtr
&type
) = 0;
35 virtual void visit (ArrayType
&type
) = 0;
36 virtual void visit (SliceType
&type
) = 0;
37 virtual void visit (BoolType
&type
) = 0;
38 virtual void visit (IntType
&type
) = 0;
39 virtual void visit (UintType
&type
) = 0;
40 virtual void visit (FloatType
&type
) = 0;
41 virtual void visit (USizeType
&type
) = 0;
42 virtual void visit (ISizeType
&type
) = 0;
43 virtual void visit (ErrorType
&type
) = 0;
44 virtual void visit (CharType
&type
) = 0;
45 virtual void visit (ReferenceType
&type
) = 0;
46 virtual void visit (PointerType
&type
) = 0;
47 virtual void visit (ParamType
&type
) = 0;
48 virtual void visit (StrType
&type
) = 0;
49 virtual void visit (NeverType
&type
) = 0;
50 virtual void visit (PlaceholderType
&type
) = 0;
51 virtual void visit (ProjectionType
&type
) = 0;
52 virtual void visit (DynamicObjectType
&type
) = 0;
53 virtual void visit (ClosureType
&type
) = 0;
59 virtual void visit (const InferType
&type
) = 0;
60 virtual void visit (const ADTType
&type
) = 0;
61 virtual void visit (const TupleType
&type
) = 0;
62 virtual void visit (const FnType
&type
) = 0;
63 virtual void visit (const FnPtr
&type
) = 0;
64 virtual void visit (const ArrayType
&type
) = 0;
65 virtual void visit (const SliceType
&type
) = 0;
66 virtual void visit (const BoolType
&type
) = 0;
67 virtual void visit (const IntType
&type
) = 0;
68 virtual void visit (const UintType
&type
) = 0;
69 virtual void visit (const FloatType
&type
) = 0;
70 virtual void visit (const USizeType
&type
) = 0;
71 virtual void visit (const ISizeType
&type
) = 0;
72 virtual void visit (const ErrorType
&type
) = 0;
73 virtual void visit (const CharType
&type
) = 0;
74 virtual void visit (const ReferenceType
&type
) = 0;
75 virtual void visit (const PointerType
&type
) = 0;
76 virtual void visit (const ParamType
&type
) = 0;
77 virtual void visit (const StrType
&type
) = 0;
78 virtual void visit (const NeverType
&type
) = 0;
79 virtual void visit (const PlaceholderType
&type
) = 0;
80 virtual void visit (const ProjectionType
&type
) = 0;
81 virtual void visit (const DynamicObjectType
&type
) = 0;
82 virtual void visit (const ClosureType
&type
) = 0;
88 #endif // RUST_TYTY_VISITOR