mirror of
https://codeberg.org/ProgramSnail/lang_2023.git
synced 2025-12-24 07:48:45 +00:00
annotated types added to typeclass graph, fixes
This commit is contained in:
parent
d841e2754b
commit
0b53b2f218
8 changed files with 131 additions and 124 deletions
|
|
@ -3,7 +3,10 @@
|
|||
#include <ostream>
|
||||
|
||||
// for clangd
|
||||
#include "definitions.hpp"
|
||||
#include "error_handling.hpp"
|
||||
#include "typeclass_graph.hpp"
|
||||
#include "utils.hpp"
|
||||
#include "visitor.hpp"
|
||||
#include "global_info.hpp"
|
||||
|
||||
|
|
@ -13,7 +16,9 @@ namespace interpreter {
|
|||
class LinkSymbolsVisitor : public Visitor {
|
||||
public:
|
||||
explicit LinkSymbolsVisitor(info::GlobalInfo& global_info)
|
||||
: namespace_visitor_(global_info.CreateVisitor()) {}
|
||||
: namespace_visitor_(global_info.CreateVisitor()),
|
||||
global_info_(global_info),
|
||||
typeclass_graph_(*global_info.GetTypeclassGraph()) {}
|
||||
|
||||
void VisitSourceFile(SourceFile* source_file) override {
|
||||
Visitor::Visit(source_file);
|
||||
|
|
@ -121,8 +126,16 @@ private:
|
|||
// // void Visit(CharLiteral* node) override;
|
||||
// // void Visit(BoolLiteral* node) override;
|
||||
|
||||
//
|
||||
|
||||
void AddTypeFunctionsToTypeclassGraph(utils::IdType type_id,
|
||||
utils::IdType graph_id,
|
||||
utils::ClassInternalsModifier namespace_modifier);
|
||||
|
||||
private:
|
||||
info::GlobalInfo::NamespaceVisitor namespace_visitor_;
|
||||
info::GlobalInfo& global_info_;
|
||||
info::TypeclassGraph& typeclass_graph_;
|
||||
};
|
||||
|
||||
} // namespace interpreter
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue