PEX for hot water tank
PEX is usually rated at 180° F (82° C) -- it should say on the side of the pipe what the actual rating is. As long as your water heater temperature is below that, you're fine.

From wikipedia: 


  There are two seemingly conflicting safety issues around water heater temperature—the risk of scalding from excessively hot water greater than 55 °C (131 °F), and the risk of incubating bacteria colonies, particularly Legionella, in water that is not hot enough to kill them. Both risks are potentially life threatening and are balanced by setting the water heater's thermostat to at least 54.4 °C (130 °F). The European Guidelines for Control and Prevention of Travel Associated Legionnaires’ Disease recommend that hot water should be stored at 60 °C (140 °F) and distributed such that a temperature of at least 50 °C and preferably 55 °C is achieved within one minute at outlets.


As @Michael points out, a T&amp;P safety valve is rated to go off at 210°F (100°C), so if something does go wrong and your water heater overheats, there is a possibility the PEX will fail. If the PEX does fail, it almost certainly will happen right above the tank (which will be the hottest place, obviously). It will also serve somewhat the same job as the T&amp;P valve, except that a T&amp;P valve will close once the temperature/pressure has lowered, while a burst pipe will just keep gushing water until someone shuts off the supply.

The chances of water heater overheating like this are quite low: electrical heaters have thermal fuses in them that serve as an electronic safety (very hard to find the temperature rating of these: seems like it's anywhere from 167 to 210°F). In addition, the electronics are pretty reliable, and just very unlikely to fail "on", and without drawing too much current that would cause the breaker to trip.