The SpaceX plan is to refuel the second stage in LEO for the trip to Mars. On Mars the fuel will be manufactured for the return trip.
A Moon base greatly increases costs and the time to attempt a Mars mission, which is why the government likes that plan.
I didn't say a Moon base, I said Lunar orbit. Starting a trans-Martian trip from Lunar orbit is less energy intensive than starting from LEO. The trade-off of course is the higher cost in getting construction materials, fuel, and equipment to Lunar Orbit in order to assemble the trans-Martian space craft.
One compromise solution is to assemble the trans-Martian craft in LEO, only give it enough fuel to establish Lunar orbit, refuel from Moon-manufactured fuel, then the make the push to Mars.