summaryrefslogtreecommitdiff
path: root/core/script_language.h
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2018-08-10 16:22:41 -0300
committerGitHub <noreply@github.com>2018-08-10 16:22:41 -0300
commit783fd23deab0360366b52c551b3717a894f42ab7 (patch)
treee3be780af897539c89839c8b3c0a7a934e3e25b9 /core/script_language.h
parent7e33b2085c244b3d41f46f1fb4498a81af0a97c7 (diff)
parenteb481198218399c9f86e5bfe1879757e1aa9a86e (diff)
Merge pull request #19993 from vnen/gdscript-warnings
System for GDScript warnings
Diffstat (limited to 'core/script_language.h')
-rw-r--r--core/script_language.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/core/script_language.h b/core/script_language.h
index 4e81b9b626..71d550d404 100644
--- a/core/script_language.h
+++ b/core/script_language.h
@@ -207,13 +207,20 @@ public:
virtual void finish() = 0;
/* EDITOR FUNCTIONS */
+ struct Warning {
+ int line;
+ int code;
+ String string_code;
+ String message;
+ };
+
virtual void get_reserved_words(List<String> *p_words) const = 0;
virtual void get_comment_delimiters(List<String> *p_delimiters) const = 0;
virtual void get_string_delimiters(List<String> *p_delimiters) const = 0;
virtual Ref<Script> get_template(const String &p_class_name, const String &p_base_class_name) const = 0;
virtual void make_template(const String &p_class_name, const String &p_base_class_name, Ref<Script> &p_script) {}
virtual bool is_using_templates() { return false; }
- virtual bool validate(const String &p_script, int &r_line_error, int &r_col_error, String &r_test_error, const String &p_path = "", List<String> *r_functions = NULL, Set<int> *r_safe_lines = NULL) const = 0;
+ virtual bool validate(const String &p_script, int &r_line_error, int &r_col_error, String &r_test_error, const String &p_path = "", List<String> *r_functions = NULL, List<Warning> *r_warnings = NULL, Set<int> *r_safe_lines = NULL) const = 0;
virtual String validate_path(const String &p_path) const { return ""; }
virtual Script *create_script() const = 0;
virtual bool has_named_classes() const = 0;