Sorry to hear about your accident - be prepared to take a while to physically recover even if you want to get back on the bike now.
You will have the option to chase things up with the driver's insurance company, but honesty is the best policy and you should only go for the 'write off' claim if your bike is truly mis-shapen. You also have to be aware that chasing up an insurance claim takes time and effort, time that you could be using more productively. A claim can be emotionally stressful and I personally prefer to walk away from following that avenue because an accident does not need to be re-lived, just moved on from.
As for judging whether your bike is truly pranged, straighten up the bars and go for a small, low-speed ride in a car-free area with smooth surfaces, e.g. a car-park after hours. Take your hex-wrenches with you.
Ride around and feel your bike. There may be brake levers out of place and other parts that can be adjusted back. These parts are surprisingly resilient but not totally crash-proof so inspect any parts that you need to reset. Your hands should have their own memory of where the bars were and you should know (and be able to double check) if the bars have been bent.
The wheels also survive reasonably well considering how they are constructed out of a few bits of wire and a 20mm or so wide rim. Make sure they are centered in the frame/fork properly and that they are true. If off-centre then you may have a damaged fork - double check this by taking the front-wheel out and putting it back in turned 180 degrees - if it is still off to one side then you have a sideways-bent front fork. As for the back wheel, that can be out of track, a similar process of checking is needed to determine that.
Look down your head tube and how the forks meet up. Are they parallel to the head-tube like they used to be? Is the steering more twitchy? If so then the fork could be pranged, but not necessarily, the frame could have bent instead. Examine where the top tube and down tube join the head tube - are there any bulges underneath or paint that is flaking off/wrinkled? If this is the case you have a damaged frame, damaged but not necessarily unsafe, aluminium does not catastrophically fatigue after being bent once and, although a different shape, may not be any weaker. I have ridden front-stacked frames for a long time after the incident and even preferred the added twitchy-ness.
Next you will need a bit of string. Wrap it round from the left-hand rear dropout to the head-tube and back down to the right-hand rear dropout. Now check that the seat-tube is in the centre of the two bits of string. If it is not bang-centre then you have a tracking problem - either historical or fresh from the crash.
Run through the gears and make sure you do not get any noises from the front derailleur. Check the rear derailleur is perpendicular to the ground when the bike is vertical.
With that initial inspection over you should double-check your carbon fork. Generally carbon forks are a lot stronger than their alloy/steel counterparts but they have a different failure mode.
Not all carbon forks have a carbon steerer, some can be a clumsy mess of glued together bits hidden in the head tube. Your stem is easy enough to remove, pop it off and have a look at what is going on around the lower bearing race. Give it a good clean and inspect for cracks.
X-ray scanning will not be able to detect any of the problem areas that you will be able to see for yourself in a quiet car-park with a bit of string.
For a second opinion ask at your LBS, preferably one that deals in second hand bikes. Shop staff that assess trade ins should be able to spot crash damage at fifty paces, your regular mechanic at a new-sales-only shop may not be so tuned into checking this.