ID:2089976
 
BYOND Version:510
Operating System:Windows 7 Ultimate
Web Browser:Chrome 50.0.2661.102
Applies to:Dream Maker
Status: Open

Issue hasn't been assigned a status value.
Descriptive Problem Summary:
See title and http://www.byond.com/ forum/?post=2086980&page=2#comment19776775
I don't know that this is a bug per se. It was intended behavior at one time; I'm just not sure why.
It happens because the tag is visible when highlighting instances from the instance list, it makes identifying specific instances insanely easier. When generating from states or directions it allows you to quickly spot what is what.

It's been known to cause issues when you don't realize it's happening for as long as I remember, though. Way back in the day I suggested a means of labeling instances without having to alter the tag variable (which would allow this to be phased out), but we could never settle on whether it would be an actual read-only (well, writable by the instance editor, but not at runtime) datum variable like "instance_name" or an IDE-level setting stored in the int file or something.

Either way, that's why the feature exists, I remember clearly this being an issue mentioned and discussed at one point in the past.
As for \ref returning the tag, I've hated that for a looooong time because tag conflicts happen a lot, but actual ref conflicts never happen.

Worst thing you have happen with a ref number conflict is picking the wrong object (clicking an old link after something has been deleted and/or created to fill the old reference number with a different object than expected).

With a tag conflict it'll pick the first one in the world, which in the case of moving objects can actually change without any creations or deletions. Ironically, I think the first time I ever encountered this problem was when SS13 first got decompiled and the code was finding one console on the map when it was expected to find another because \ref was spitting out a tag that should have pointed at the console you were clicking, but it ended up picking up another console earlier in the world contents that had the same tag, it took forever to figure out what was happening.

I know a few things that rely on this behavior though, so it can't just be up and changed, but you could always add something like \rawref or \refnum (whatever you wanna name it) that will always spit out the reference number despite a tag existing. I assume locate() doesn't care if there's a tag or not when doing a lookup based on a reference number?