### Godot version

Godot 4.0.1.stable

### System information

Windows 10, Forward+

### Issue description

Example code:

```gdscript
@warning_ignore("shadowed_global_identifier")
static func print_debug(msg: String):
```

the warning is ignored by pressing [ignore] in the warnings panel.

pressing it multiple times results in:
```gdscript
@warning_ignore("shadowed_global_identifier", "shadowed_global_identifier")
```


### Steps to reproduce

Shadowing a global function with a method of script:

```gdscript
@warning_ignore("shadowed_global_identifier")
static func print_debug(msg: String):
```


### Minimal reproduction project

```gdscript
@warning_ignore("shadowed_global_identifier")
static func print_debug(msg: String):
    pass
```
head = alloc_node<ClassNode>();
	head->fqcn = script_path;
	current_class = head;
	bool can_have_class_or_extends = true;
	while (!check(GDScriptTokenizer::Token::TK_EOF)) {
		if (match(GDScriptTokenizer::Token::ANNOTATION)) {
			AnnotationNode *annotation = parse_annotation(AnnotationInfo::SCRIPT | AnnotationInfo::STANDALONE | AnnotationInfo::CLASS_LEVEL);
			if (annotation != nullptr) {
				if (annotation->applies_to(AnnotationInfo::SCRIPT)) {
					
					if (annotation->name == SNAME("@icon")) {
						annotation->apply(this, head);