How to check if two objects have same tag?

Hello, I made two objects, with same tag. And I need to check if these two objects have a same tag.
How can I get current object’s tag? I managed to get second object’s tag but not firsts… Please help…

	void OnTriggerEnter2D (Collider2D other) {
		if (other.tag == "Red")
			player.transform.position = spawnPoint.transform.position;
	}

so I just had this same question, kinda tested stuff out, and was really surprised it worked this way (not because it’s all that surprising, just because it was easy!) I’m hoping I’m understanding your question and that it’s the same as mine was but this is how I worked it out!

void OnTriggerEnter2D(Collider2D other)
	{
		if (other.gameObject.CompareTag(this.gameObject.tag))
			Debug.Log("does it work this way??");
	}

spoiler alert: it did!