The real important question is the subsequent one:
— What are your salary expectations?
— $X
— Ok! That means if we propose Y, would you envision it?
— Yeah, maybe, because I’m out of choice / No because I already have an offer at $X-1.
Source: I’m hiring (and yes, Y enters into consideration because most candidates overestimate their skills, but I always go for X if the candidate is as expected).