diff options
Diffstat (limited to 'src/hir/path.hpp')
-rw-r--r-- | src/hir/path.hpp | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/src/hir/path.hpp b/src/hir/path.hpp new file mode 100644 index 00000000..e51e3c50 --- /dev/null +++ b/src/hir/path.hpp @@ -0,0 +1,41 @@ + +#ifndef _HIR_PATH_HPP_ +#define _HIR_PATH_HPP_ +#pragma once + +#include <common.hpp> + +namespace HIR { + +class TypeRef; + +/// Simple path - Absolute with no generic parameters +struct SimplePath +{ + SimplePath(::std::string crate): + m_crate_name( mv$(crate) ) + { + } + + ::std::string m_crate_name; + ::std::vector< ::std::string> m_components; +}; +/// Generic path - Simple path with one lot of generic params +class GenericPath +{ +public: + SimplePath m_path; + ::std::vector<TypeRef> m_params; +}; + +class Path +{ + // Two possibilities + // - UFCS + // - Generic path +}; + +} // namespace HIR + +#endif + |