ROSE 0.11.145.147
Rosebud/BasicTypes.h
1#ifndef Rosebud_BasicTypes_H
2#define Rosebud_BasicTypes_H
3
4#include <Sawyer/Clexer.h>
5
456namespace Rosebud {
457
460
463
465enum class Expand {
466 NONE,
467 INTER,
468 PRIOR
469};
470
472enum class When {
473 NEVER,
474 ALWAYS,
475 AUTO
476};
477
478class Generator;
479using GeneratorPtr = std::shared_ptr<Generator>;
480class Serializer;
481using SerializerPtr = std::shared_ptr<Serializer>;
483// AST node types
484namespace Ast {
485class Node;
486using NodePtr = std::shared_ptr<Node>;
487class TokenList;
488using TokenListPtr = std::shared_ptr<TokenList>;
489class ArgumentList;
490using ArgumentListPtr = std::shared_ptr<ArgumentList>;
491class CppStack;
492using CppStackPtr = std::shared_ptr<CppStack>;
493class Attribute;
494using AttributePtr = std::shared_ptr<Attribute>;
495class Definition;
496using DefinitionPtr = std::shared_ptr<Definition>;
497class Property;
498using PropertyPtr = std::shared_ptr<Property>;
499class Class;
500using ClassPtr = std::shared_ptr<Class>;
501class File;
502using FilePtr = std::shared_ptr<File>;
503class Project;
504using ProjectPtr = std::shared_ptr<Project>;
505} // namespace
506
507} // namespace
508#endif
A node that holds a list of arguments.
Definition Ast.h:197
An attribute adjusting the details for a definition.
Definition Ast.h:218
Represents a class definition.
Definition Ast.h:363
Information about C preprocessor conditional compilation directives.
Definition Ast.h:132
Base class for class and property definitions.
Definition Ast.h:254
An input file.
Definition Ast.h:410
Root of an AST for one or more input files.
Definition Ast.h:542
Represents a class property definition.
Definition Ast.h:316
Node that holds a sequence of consecutive tokens from an input file.
Definition Ast.h:78
Base class for serialization generators.
Definition Serializer.h:13
std::shared_ptr< Class > ClassPtr
Shared-ownership pointer to a Class.
std::shared_ptr< Property > PropertyPtr
Shared-ownership pointer to a Property.
std::shared_ptr< Node > NodePtr
Shared-ownership pointer to a Node.
std::shared_ptr< Definition > DefinitionPtr
Shared-ownership pointer to a Definition.
std::shared_ptr< ArgumentList > ArgumentListPtr
Shared-ownership pointer to a ArgumentList.
std::shared_ptr< Project > ProjectPtr
Shared-ownership pointer to a Project.
std::shared_ptr< CppStack > CppStackPtr
Shared-ownership pointer to a CppStack.
std::shared_ptr< File > FilePtr
Shared-ownership pointer to a File.
std::shared_ptr< TokenList > TokenListPtr
Shared-ownership pointer to a TokenList.
std::shared_ptr< Attribute > AttributePtr
Shared-ownership pointer to a Attribute.
Rosebud is a tool to generate abstract syntax trees.
Definition Ast.h:14
When
When something should be done.
@ NEVER
Never do it.
@ AUTO
Sometimes do it.
@ ALWAYS
Always do it.
std::shared_ptr< Generator > GeneratorPtr
Shared-ownership pointer to a Generator.
Expand
How to obtain text when converting a sequence of tokens to a string.
@ NONE
Each token's [begin,end) individually.
@ INTER
From first token's begin to last token's end.
@ PRIOR
From first token's prior to last token's end.
std::shared_ptr< Serializer > SerializerPtr
Shared-ownership pointer to a Serializer.