X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=sidebyside;f=source%2Fglsl%2Foutput.h;h=dbdd888e5923aa69355c9fe75923bcadf7e12c61;hb=76cc18518fc8b0b4fa11fda153e7d9b3899ed112;hp=6bdb1ab76d054ce64d7fd250590ebc44c762f41b;hpb=a4cd67f1c9f1f375bacacfbb421d40f78a22644b;p=libs%2Fgl.git diff --git a/source/glsl/output.h b/source/glsl/output.h index 6bdb1ab7..dbdd888e 100644 --- a/source/glsl/output.h +++ b/source/glsl/output.h @@ -13,19 +13,17 @@ namespace SL { class Formatter: private TraversingVisitor { private: - Stage *stage; + Stage *stage = 0; std::string formatted; - unsigned source_index; - unsigned source_line; - unsigned indent; - bool parameter_list; - bool omit_builtin; + unsigned source_index = 0; + unsigned source_line = 1; + unsigned indent = 0; + bool parameter_list = false; + bool omit_builtin = false; + bool r_empty_name = false; public: - Formatter(); - - const std::string &apply(Stage &); - const std::string &apply(Node &n) { n.visit(*this); return formatted; } + std::string apply(Stage &); private: void append(const std::string &);