In that particular use case, I can think of 2 approaches. The first would be to extract the variable in the controller:
$first_name = $this->session->get('currentUser')['firstName'] ?? '';
Or you could drop down into PHP right in the template:
<span><?= $this->session->get('currentUser')['firstName'] ?? ''; ?></span>
As others have said, error suppresion is bad practice. As to why it's bad practice: You can't always know what errors are going to be generated. If you suppress errors you could be missing out on something important. Additionally, the code that gets written that causes the errors is.... causing errors. Code that causes errors is broken code.