Each time I see this it breaks my heart. I mean, Liam's iconic and all, but... no. This is so /sad/. This precise part must have been so hard for both of them.
This is the second time Liam calls Sherlock by his first name. When the first time was a moment of joy for both of them, this time, it's a marker of the end of this sort of fragile friendship they shared.
Of course their feelings were true, and this is even worse ! Because they both didn't think or weren't sure it was the same for the other. Or at least for Sherlock. Liam surely knew but forced himself into the villain's role for the plan.
Liam looks so purely happy when he let himself call Sherlock with familiarity, and he probably sees very well how it makes Sherlock happy too. He knows that it's surely meaningless and this will have to stop but he still allows himself this little thing.
Which turned out to not be a little thing at all. It was surely put here on purpose so when the time comes, it makes things even more heartbreaking. The "Sherlock" Liam says the second time is written with quotation marks, which means he says it with a particular tone, probably ironical.
As if he used this little friendship moment they shared to hurt Sherlock. Like, to make it looks like he wanted to hurt him, as "hahaha see I'm the bad guy", so Sherlock would take the role in the plan. To make sure that there is no doubt of him being bad and that Sherlock would kill him more easily.
But we know Liam for sure really doesn't want to hurt him. And it must have been so hard for him to know he actually did. Liam hates to make ppl suffer, especially in this bastard way.
Because Sherlock, despite of acting seriously and being genuinely happy that Liam is the LoC, was hurt anyway. He responds with assurance and doesn't let his emotions show, but he's feeling bad inside.
He was SO happy when Liam said his name the first time. Even if he stayed on his guard, he likes Liam far too much to not hope that they could actually share feelings.
He also knew it maybe meant nothing, but when he heard Liam use his name this way, in full LoC role, it still must have been hard.
Because Liam made sure that it looked like an evil move to break his enemy using his feelings, and even if Sherlock was prepared, and Liam was only acting... it /was/ hurtful, for both.
And it's both amazing and awful to have put this in chap 31 just to make it worse after 😭