Avoid unnecessary casting