mirror of
https://github.com/godotengine/godot.git
synced 2025-10-20 00:13:30 +00:00
Merge pull request #90860 from vnen/gdscript-get-dependencies
GDScript: Implement `get_dependencies()`
This commit is contained in:
commit
c4733e8003
4 changed files with 29 additions and 7 deletions
|
@ -1429,6 +1429,8 @@ private:
|
|||
void reset_extents(Node *p_node, GDScriptTokenizer::Token p_token);
|
||||
void reset_extents(Node *p_node, Node *p_from);
|
||||
|
||||
HashSet<String> dependencies;
|
||||
|
||||
template <typename T>
|
||||
T *alloc_node() {
|
||||
T *node = memnew(T);
|
||||
|
@ -1572,9 +1574,11 @@ public:
|
|||
bool annotation_exists(const String &p_annotation_name) const;
|
||||
|
||||
const List<ParserError> &get_errors() const { return errors; }
|
||||
const List<String> get_dependencies() const {
|
||||
// TODO: Keep track of deps.
|
||||
return List<String>();
|
||||
const HashSet<String> &get_dependencies() const {
|
||||
return dependencies;
|
||||
}
|
||||
void add_dependency(const String &p_dependency) {
|
||||
dependencies.insert(p_dependency);
|
||||
}
|
||||
#ifdef DEBUG_ENABLED
|
||||
const List<GDScriptWarning> &get_warnings() const { return warnings; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue