Gears were once part of the game code and available through inventory edits. They had no use and were indestructible. They could only be placed on the sides of blocks, but were quite buggy as they weren’t meant to be used yet.
Removing the block they were placed on would turn the block invisible, but they would still be indestructible. If there was another block directly opposite of the block the gear was placed on, another gear would appear on that block. Gears were later removed from the game and its code was replaced by redstone. This makes it quite safe to assume gears were once supposed to work like redstone.