const-correctness for smart-pointers throughout context