Number of shares doesn't matter, enterprise value does and it doesn't change. Your implying that there would be a further equity issuance which doesn't routinely happen on buybacks.
Reducing shares increases the price (while keeping market cap the same). Share splits increases the shares outstanding and decreases the price. So... yes, shares outstanding does matter.
Whether the company destroys the shares or retains them as treasury stock is irrelevant. Investors don't care if their share price went up by 10%, or if they effectively have 1.10 shares.