Warning about side-effects in constructors