Page 1 of 1

tab ("get", "path") returns a drive letter without a trailing backslash

Posted: 20 Nov 2021 14:34
by Evolve
itematpos()
c:
c:\windows

tab ("get", "path")
c:\
c:\windows

It should either return both with a trailing backslash:
c:\
c:\windows\

or neither:
c:
c:\windows

PS: Unless there is a strong reason for that inconsistency...
PPS: Actually, this is more of a observation/question than a "wish". Like "I've noticed this inconsistency, is there any reason for that? Or if not, maybe it should be changed". This should probably be moved into "Questions" section.

Re: tab ("get", "path") returns a drive letter without a trailing backslash

Posted: 22 Nov 2021 10:05
by admin
Hmm, I'm unhappy about this. The rule is that variables and functions in XY should return paths without a trailing slash. So this is a bug. But if I fix it, it will likely break old user code. :( Any ideas?

Re: tab ("get", "path") returns a drive letter without a trailing backslash

Posted: 22 Nov 2021 10:17
by highend
In this case, you've set a rule. Follow it. Scripters must adapt^^

Re: tab ("get", "path") returns a drive letter without a trailing backslash

Posted: 22 Nov 2021 10:50
by admin
I'll classify this as a bug. Scripters will be happy about the fix.