Even before a driverless Uber vehicle struck and killed a pedestrian in Arizona this week, a slight majority of Americans said they were at least somewhat worried about the development of autonomous cars and hesitant about riding in one if given the chance.

Slightly more than half of U.S. adults (54%) said in a Pew Research Center survey conducted in May 2017 that they were somewhat or very worried about the development of driverless vehicles, while 40% said they were at least somewhat enthusiastic about it. A majority of U.S. adults (56%) also said they would not personally want to ride in a driverless car if they had the opportunity, compared with 44% who would.

The accident in Tempe, Arizona, was believed to be the first time a pedestrian had been killed in an incident involving a driverless car. In response, Uber announced it would suspend testing of driverless vehicles in four North American cities where the ridesharing company had been piloting the technology: Pittsburgh, San Francisco, Tempe and Toronto.

In the Center’s 2017 survey, women were more likely than men to say they were at least somewhat worried about the development of driverless cars (63% vs. 44%) and that they would not personally want to ride in one (64% vs. 47%), as were adults with a high school diploma or less when compared with college graduates.

The most common reasons cited by Americans who said they would not personally want to ride in a self-driving car were a lack of trust or fear of giving up control to a machine (42%) and other specific safety concerns (30%).

Among those who said they would want to ride in a self-driving car, the largest share (37%) cited a love of technology and/or a desire for an exciting or new experience. Another 17% pointed to safety in the belief that a driverless car would be safer than a car driven by a human.

Overall, around two-thirds of Americans (65%) said they expected most vehicles on the road to be autonomous sometime within the next half-century. The remainder either said they expect it to take 50 years or more for most cars on the road to become driverless, or that self-driving cars would never account for most vehicles on the road.

The public was closely divided over the safety implications in the event that the use of autonomous cars becomes widespread. For instance, 39% of adults said that they anticipated that the number of people killed or injured in traffic accidents would decrease. Slightly fewer (30%) said traffic fatalities or injuries would increase, while 31% said that the number of deaths or injuries would stay about the same.

There was wider agreement over rules and restrictions to govern the use of self-driving cars. Large majorities said they would favor requiring driverless cars to have a person in the driver’s seat who could take control in an emergency situation (87%); restricting such vehicles to dedicated traffic lanes (83%); and restricting them from traveling near certain areas, such as schools (69%).

States and the federal government have taken a variety of approaches when it comes to regulating self-driving vehicles. In Arizona, the state recently stopped requiring that autonomous cars be accompanied by a human driver, though the car involved in this week’s crash did have a human driver inside.

John Gramlich  is an associate director at Pew Research Center.