]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/tokenizer.h
Use default member initializers for simple types
[libs/gl.git] / source / glsl / tokenizer.h
index 46aa62fbea282c61ae016dd232f39b6fa73971f9..26c4b93c683ac7316fff92fda8aa8ab082215298 100644 (file)
@@ -14,9 +14,9 @@ class Preprocessor;
 struct Location
 {
        std::string name;
-       unsigned line;
+       unsigned line = 0;
 
-       Location(): line(0) { }
+       Location() = default;
        Location(const std::string &n, unsigned l): name(n), line(l) { }
 };
 
@@ -29,9 +29,9 @@ private:
        std::string::const_iterator iter;
        std::string::const_iterator source_end;
        Location location;
-       bool progress_mark;
-       bool allow_preprocess;
-       bool suppress_line_advance;
+       bool progress_mark = false;
+       bool allow_preprocess = true;
+       bool suppress_line_advance = false;
        std::string last_token;
        std::deque<std::string> next_tokens;