I think Moonbear pretty well summed it up. I work as security on a college campus and am not allowed to "fraternize" with the students while at work or off the clock. This even includes have a conversation that is anything other than professional in nature. I can't give a student a ride in my vehicle even if I can explain that there was no personal elements involved, say if I were driving to work and see a student walking to the school I can't stop and pick them up.
Not many of my co-workers really follow the rules very closely but since I am the only one of us who is any where near the age range of the students I worry far more about how it will be seen.
So I'm not a professor but maybe that will give you an idea of the rules they have at differant schools.