Putting sugar in a gas tank may clog up a car's fuel filter, which could make changing the filter more frequently necessary, but it's unlikely to enter a car's fuel line and cause any serious problems. There are no particular chemical properties of sugar that make it react negatively with gasoline, and any problems caused by pouring sugar in a gas tank come merely from its granular qualities.
The standard prank lore goes that pouring sugar in a car's gas tank disables the engine and renders the car inoperable. However, it's unlikely that any amount of sugar in a gas tank can travel all the way to the car's engine. Sugar doesn't dissolve in gasoline, so the odds of it moving throughout the car's fuel lines are quite low. Any sugar that does make its way out of the tank is likely to get caught in the car's fuel filter, which is designed to catch solid objects. The effect of pouring sugar in a gas tank is no different than pouring in sand. Some may accumulate in the fuel filter, but almost certainly not enough to clog the fuel line completely and stop the car from running. Pouring water in a fuel tank, however, can cause major problems because the water floats on top of the gasoline and can make its way through the fuel line into the engine.