Just a couple of comments: Only 39K on a 5 year old vehicle, wow! These are complicated systems, your mechanic could be correct; but, I would ask a few questions, like: 1) What has failed on the compressor, the clutch, or an internal failure? Generally, if it is an internal failure, there will be noise. 2) When it is running and stabilized at a specific ambient, what are the low and high pressures in the system? (there are numerous online charts that show pressures by ambient and what they can mean) If the pressures are OK, you likely have a control failure as opposed to refrigeration system failure. You don't want to get into a whack-a-mole starting with the most expensive component. 3) If an internal compressor failure has occurred, the belt and the filter/separator must be replaced as well, at the very least.
Good luck and let us know how it turns out!