Tesla reports smaller loss than expected and predicts it will soon stop burning cash