GameObject rotation maxing out at 180

I am using the current code to rotate a camera and the rotation stops at 180. I would like it to continuously rotate so how would you fix this code?

var speed : int = 5;

function Update () {
    gameObject.transform.rotation.y += speed*Time.deltaTime;
}

Like bodec mentions in the comment section, every object’s rotation properties are actually a Quaternion. look for a video on Youtube about Quaternions, so you understand how they work.