This is a glitch that can be performed in Generation 4, in which this has to be done, from what I read:
1. Gather the following: a Ditto, Any Pokémon that learns Mimic, and a Smeargle with Rage and three moves of your choice.
2. Get into a Double Battle with Ditto and the Pokemon with Mimic up front. If the Pokémon with Mimic is slower than Ditto, have Ditto use Transform and have the other Pokémon use Mimic on Ditto. If the Pokémon with Mimic is faster than Ditto, have it use something else while Ditto Transforms, then use Mimic on Ditto during Turn 2.
3. Once Transform has been Mimicked, switch Ditto out for Smeargle, then Transform into Smeargle.
4. Once your Mimic Pokémon has Transformed into Smeargle, have it use up all of Rage's PP.
5. Win the battle, then check on the Pokémon with Mimic. It should now have Smeargle's moveset.
Basically, if a Pokémon from Generation 3 and earlier can learn TMs, they can learn Mimic, so some like Wobbuffet or Caterpie is not able to learn this move, and subsequently, a moveset with unlimited potential. In Generation 4, only Chatot can learn Mimic, and Chimchar's family and Glameow's family can use through Assist. This means that those Pokémon is able to learn any moves in that Generation, and one Generation 5 move (preferably one that is not widely distributed) as Sketch is one of the copied moves. So, you can have stuff like a Flareon with Flare Blitz, Aerodactyl with Head Smash or Sceptile with Spikes. To an extent, you may even have Blissey with Cotton Guard, Weavile with Icicle Drop or Chatot with Butterfly Dance.
Now, I feel that this warrants its own topic because there are unlimited possibilities on what can be used with this glitch, and it will be an interesting topic to talk about the best or funny things that can be made as a result. One thing to discuss is if more Egg Move combinations should be made possible for Generation 5 Pokémon since some of the combinations cannot be normally inherited, like Ferroseed/Tesshido not being able to normally get Stealth Rock, Spikes and Leech Seed on the same moveset, or Pawniard/Komatana getting Sucker Punch and Stealth Rock at the same time.
Thanks for reading.