From 720c5a33b6a49cf328fdd7611f49153cf8f60247 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Wed, 8 Apr 2020 14:51:57 +0300 Subject: Separate tests and examples into individual packages Also make cli module to be explicitly enabled via the config.cli configuration variable. --- cli/semantics/class.hxx | 106 ------------------------------------------------ 1 file changed, 106 deletions(-) delete mode 100644 cli/semantics/class.hxx (limited to 'cli/semantics/class.hxx') diff --git a/cli/semantics/class.hxx b/cli/semantics/class.hxx deleted file mode 100644 index ca7de8c..0000000 --- a/cli/semantics/class.hxx +++ /dev/null @@ -1,106 +0,0 @@ -// file : cli/semantics/class.hxx -// author : Boris Kolpackov -// license : MIT; see accompanying LICENSE file - -#ifndef CLI_SEMANTICS_CLASS_HXX -#define CLI_SEMANTICS_CLASS_HXX - -#include - -#include - -namespace semantics -{ - class class_; - - class inherits: public edge - { - public: - class_& - base () const - { - return *base_; - } - - class_& - derived () const - { - return *derived_; - } - - public: - void - set_left_node (class_& n) - { - derived_ = &n; - } - - void - set_right_node (class_& n) - { - base_ = &n; - } - - protected: - class_* base_; - class_* derived_; - }; - - class class_: public scope - { - private: - typedef std::vector inherits_list; - - public: - bool - abstract () const - { - return abstract_; - } - - void - abstract (bool a) - { - abstract_ = a; - } - - public: - typedef pointer_iterator inherits_iterator; - - inherits_iterator - inherits_begin () const - { - return inherits_.begin (); - } - - inherits_iterator - inherits_end () const - { - return inherits_.end (); - } - - public: - class_ (path const& file, size_t line, size_t column) - : node (file, line, column), abstract_ (false) - { - } - - void - add_edge_left (inherits& e) - { - inherits_.push_back (&e); - } - - void - add_edge_right (inherits&) {} - - using scope::add_edge_left; - using scope::add_edge_right; - - private: - bool abstract_; - inherits_list inherits_; - }; -} - -#endif // CLI_SEMANTICS_CLASS_HXX -- cgit v1.1