Does this code lead to errors?