### 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
```
if (!p_preload->path) {
		return;
	}
	reduce_expression(p_preload->path);
	if (!p_preload->path->is_constant) {
		push_error("Preloaded path must be a constant string.", p_preload->path);
		return;
	}
	if (p_preload->path->reduced_value.get_type() != Variant::STRING) {
		push_error("Preloaded path must be a constant string.", p_preload->path);
	} else {
		p_preload->resolved_path = p_preload->path->reduced_value;
		
		if (p_preload->resolved_path.is_relative_path()) {
			p_preload->resolved_path = parser->script_path.get_base_dir().path_join(p_preload->resolved_path);
		}
		p_preload->resolved_path = p_preload->resolved_path.simplify_path();
		if (!ResourceLoader::exists(p_preload->resolved_path)) {
			Ref<FileAccess> file_check = FileAccess::create(FileAccess::ACCESS_RESOURCES);
			if (file_check->file_exists(p_preload->resolved_path)) {
				push_error(vformat(R"(Preload file "%s" has no resource loaders (unrecognized file extension).)", p_preload->resolved_path), p_preload->path);
			} else {
				push_error(vformat(R"(Preload file "%s" does not exist.)", p_preload->resolved_path), p_preload->path);
			}
		} else {
			
			
			
			if (ResourceLoader::get_resource_type(p_preload->resolved_path) == "GDScript") {
				Error err = OK;