How can I destroy an object if it touches NOTHING

I want to destroy a wall if it doesn’t touch another wall upon spawning. That’s why I can’t use OnTriggerEnter2D. This is the code I tried to use, but it only works if something else collides with the wall.

public class BlockWall_Destroyer : MonoBehaviour
{
    void OnTriggerEnter2D(Collider2D other)
    {
        if (other.gameObject.tag != "Wall+Ground" | other.gameObject.tag != "Player")
        {
            Destroy(gameObject);
        }
    } 
}

I need a function that can test if my spawned wall doesn’t touch anything.

You will need to create an overlap box, Pretend that its an explosion (look at this video GRENADE / BOMB in Unity (Tutorial) - YouTube). Then make an if statement that checks if there are objects of the tags you are looking for. If there are none then it will destroy.