Purely based on an operational standpoint of semiconductive devices, equivalent resistances are considerably higher at low temperatures, and thus any calibrated circuit or component, including Rcomps, DLLs, PLLs, and clock compensators, will operate unexpectedly or not at all. These kinds of circuits are specifically developed with PVT (process, voltage, temperature) conditions and ranges built into the core design, so operating ranges not considered, accounted for, or tested, will (likely) cause the circuits to fail or work poorly. The wider the temperature ranges needed, the harder the design, because there are power, timing, noise, variation, and EM tradeoffs that occur across low and high temps.
Analog circuits are often very sensitive to small differences in voltage and temperature, so various drivers, amplifiers, oscillators, and LDOs will be affected considerably by low temperatures compared to when operating at RT. RF transmitters and receivers are particularly prickly.
Note that surface temperatures of these bodies can range massively. The moon has 13-day periods of sunshine, followed by 13-day nights; temperatures range from 100 K to 400 K. The range on Mars at any given location (say, on the equator) is less pronounced, but still sizeable; for instance, Viking measured a temperature range of 160 K to 260 K at its landing site. And Spirit measured temperatures in excess of 300 K. That's a large temperature range, and the electronics and material thermal properties of expansion, etc., need to deliver at either extreme of the spectrum.
At very low temperatures, the linearity that exists between carrier density and temperature is completely disrupted, and depending on the base semiconductive material used (Si vs Ge, for instance), the ionized mobility of circuits can deprecate to the point that there's insufficient carriers for the circuits to operate at all. This phenomenon is known as "freeze-out", but it generally occurs at temperatures below 100 K, becoming particularly prominent below 77 K, LN temperatures.
Due to low temperature effects on carrier mobility, the speed that signals propagate across channels and through digital gates and electronics will be affected. Although there are several attractive qualities introduced into CMOS devices at low and ultra-low temperatures, such as virtually eliminating transistor latchup, designing electronics to respond to wide temperature ranges presents problems with certifying timing arcs across all temperatures, and timing convergence of all paths can be mission-critical.
So yes, batteries might be the first thing to fail, but in the event that they don't, there are a myriad of other 1st-order electronics issues that could occur rendering a rover unusable for its intended purpose of measuring and transmitting data and moving around the surface of a moon or planet. I haven't even gotten into condensation, thermal expansion, mechanical defects, or failing sensors, as those aren't really my area of knowledge.