Gatling Assertion using other Assertions

I’ve a list of assertions that run perfectly, but I’m trying to have an assertion to say something like this

details("C").successfulRequests.count.equals( (details("A").successfulRequests.count + details("B").successfulRequests.count) )

i.e. I wish to use the counts from other assertions to check against another assertion count

But Gatling gives a type mismatch error, which I can understand but I can’t figure out how to do achieve the above assertion.

Do anyone know the correct syntax for what I’m trying to do above?

Thanks

J