Define constructor differently so it works in 1.8.7.