Changeset View
Changeset View
Standalone View
Standalone View
src/qmljsc/compilerpasses/prettygeneratorpass.h
Show All 29 Lines | |||||
30 | 30 | | |||
31 | class PrettyGeneratorPass : public CompilerPass, public IR::Visitor | 31 | class PrettyGeneratorPass : public CompilerPass, public IR::Visitor | ||
32 | { | 32 | { | ||
33 | Q_OBJECT | 33 | Q_OBJECT | ||
34 | 34 | | |||
35 | public: | 35 | public: | ||
36 | PrettyGeneratorPass(); | 36 | PrettyGeneratorPass(); | ||
37 | 37 | | |||
38 | virtual void visit(IR::Component* component) override; | 38 | virtual void visit(IR::File* file) override; | ||
39 | virtual void endVisit(IR::Component* component) override; | 39 | virtual void endVisit(IR::File* file) override; | ||
40 | 40 | | |||
41 | public slots: | 41 | public slots: | ||
42 | void process(IR::Component* rootComponent) override; | 42 | void process(IR::File *file) override; | ||
43 | 43 | | |||
44 | private: | 44 | private: | ||
45 | int m_levelSpaceCount = 4; | 45 | int m_levelSpaceCount = 4; | ||
46 | QTextStream m_output; | 46 | QTextStream m_output; | ||
47 | bool m_componentRoot; | 47 | bool m_componentRoot; | ||
48 | 48 | | |||
49 | }; | 49 | }; | ||
50 | 50 | | |||
51 | } | 51 | } | ||
52 | 52 | | |||
53 | #endif // PRETTYGENERATORSTAGE_H | 53 | #endif // PRETTYGENERATORSTAGE_H |