Files
Fig/src/Value/interface.hpp
PuqiAR f58a60c8e3 [VER] 0.3.3-alpha
[FEAT] interface + impl 支持! Duck Typing + 严格的检查让语言健壮
[FEAT][IMPL] 增加辅助函数 isTypeMatch等
[IMPL] TypeInfo构造函数FString 现在 explicit
2025-12-30 12:02:27 +08:00

20 lines
401 B
C++

#pragma once
#include <Ast/Statements/InterfaceDefSt.hpp>
#include <Value/Type.hpp>
#include <vector>
namespace Fig
{
struct InterfaceType
{
TypeInfo type;
std::vector<Ast::InterfaceMethod> methods;
bool operator==(const InterfaceType &other) const
{
return type == other.type; // only compare type info (chain -> typeinfo.id)
}
};
}