Well technically it's priority not right of way. My guess is that the concept was only codified with the introduction of traffic laws, which in most places didn't happen before the 20th century. Until then, "priority" in land probably came down to common sense: size, conventions, and social status.