Spicy
visitors.h
1 // Copyright (c) 2020-2021 by the Zeek Project. See LICENSE for details.
2 
3 #pragma once
4 
5 #include <iostream>
6 #include <memory>
7 #include <utility>
8 #include <vector>
9 
10 #include <hilti/ast/id.h>
11 #include <hilti/compiler/context.h>
12 
13 namespace hilti {
14 class Node;
15 class Unit;
16 
17 namespace printer {
18 class Stream;
19 }
20 
21 } // namespace hilti
22 
23 namespace spicy::detail::ast {
24 
26 void buildScopes(const std::shared_ptr<hilti::Context>& ctx, hilti::Node* root, hilti::Unit* unit);
27 
29 bool normalize(const std::shared_ptr<hilti::Context>& ctx, hilti::Node* root, hilti::Unit* unit);
30 
32 bool print(const hilti::Node& root, hilti::printer::Stream& out);
33 
35 bool resolve(const std::shared_ptr<hilti::Context>& ctx, hilti::Node* root, hilti::Unit* unit);
36 
38 void validate_pre(const std::shared_ptr<hilti::Context>& ctx, hilti::Node* root, hilti::Unit* unit);
39 
41 void validate_post(const std::shared_ptr<hilti::Context>& ctx, hilti::Node* root, hilti::Unit* unit);
42 
43 } // namespace spicy::detail::ast
Definition: printer.h:16
Definition: visitors.h:23
void print(const T &t, bool newline=true)
Definition: hilti.h:22
Definition: unit.h:49
Definition: node.h:111