]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/output.h
Use default member initializers for simple types
[libs/gl.git] / source / glsl / output.h
index 1e59a445ebdd1f16eead08246ac98196b3a286ca..dbdd888e5923aa69355c9fe75923bcadf7e12c61 100644 (file)
@@ -13,20 +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;
-       bool r_empty_name;
+       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();
-
        std::string apply(Stage &);
-       std::string apply(Node &n) { n.visit(*this); return formatted; }
 
 private:
        void append(const std::string &);