The src/object
Directory
Namespace object
, delivered from TC-1/2 to TC-EXTS.
Wrappers around other modules accepting objects syntax.
File: local.am (src/object/)
This is a Makefile configuration relative to the
src/object/
directory. It is responsible for the integration into thelibtc
library with everything exported from theobject
module, and the linkage of the directory’s unit tests in the test-suite.
File: libobject.* (src/object/)
The interface of the
object
module. It exports thebind
,types_check
,rename
,desugar
andraw_desugar
procedures. Those are overloads accepting object-related constructs.
File: tasks.* (src/object/)
Tasks related to the
object
module (see: The src/task Directory).
File: fwd.hh (src/object/)
Forward declarations for the
object
module.
File: binder.* (src/object/)
Given at TC-3. The
object::Binder
visitor. Binds uses to definitions (works on syntax with objects). Inherits frombind::Binder
.
File: type-checker.* (src/object/)
Given at TC-4. The
object::TypeChecker
visitor. Computes the types of anAST
and adds type labels to the corresponding nodes (works on syntax with objects). Inherits fromtype::TypeChecker
.
File: renamer.* (src/object/)
Given at TC-4. The
object::Renamer
visitor. Renames every identifier to a unique name (works on syntax with objects), and keeps a record of the names of the renamed classes. Inherits frombind::Renamer
.
File: default-visitor.* (src/type/)
Given at TC-EXTS. Implementation of the
GenDefaultVisitor
class template, which walks the abstract syntax tree, doing nothing. This visitor does not define visit methods for nodes related to object-oriented constructs (classes, methods, etc.); thus it is an abstract class, and is solely used as a basis for deriving other visitors. It is instantiated twice:GenDefaultVisitor<misc::constify_traits>
andGenDefaultVisitor<misc::id_traits>
.
File: desugar-visitor.* (src/object/)
Given at TC-EXTS. The
object::DesugarVisitor
visitor. Transforms anAST
with objects into anAST
without objects.
File: test-*.cc (src/type/)
Unit tests.