]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/validate.h
Record information of the provoking location of a diagnostic
[libs/gl.git] / source / glsl / validate.h
index b64973276536e2dbc653ac30f142866ccb3b3fcb..9477b67d70cb7a7ecc9acc38ad81e76d81af1c97 100644 (file)
@@ -14,11 +14,14 @@ class Validator: protected TraversingVisitor
 {
 protected:
        Stage *stage;
+       Node *last_provoker;
 
        Validator();
 
-       void diagnose(Node &, Diagnostic::Severity, const std::string &);
+       void diagnose(Node &, Node &, Diagnostic::Severity, const std::string &);
+       void diagnose(Node &n, Diagnostic::Severity s, const std::string &m) { diagnose(n, n, s, m); }
        void error(Node &n, const std::string &m) { diagnose(n, Diagnostic::ERR, m); }
+       void add_info(Node &, const std::string &);
 };
 
 class TypeValidator: private Validator