I great example of the trouble someone had to go to prove they were first is the ABC computer. It's an important case if you consider that without John Atanasoff the personal computer would never have existed. At the time IBM and some other corp I can't remember the name held some important patent on memory and other things that would prevent anyone from creating a personal computer without paying IBM. Those patents which had come from the creators of ENIAC were later found to have been heavely (well in reality stolen) from the ABC computer. After years of battles, IBM lost the patents and right after that the PC came to be.
For a worse horror story, just take a look at Farnsworth trouble with RCA about the TV patents.
You could still lose that fight, even if your work came first, if you never published it or filed a patent for it. First to invent only holds if you reduced it to practice (either by actually inventing the thing, or boiling it down so someone reasonably skilled in the art could then invent it) within that year. You lose rights to it after that if someone else wants to patent it. There's also first to conceive stipulations. The intellectual property class I took last semester would have been a lot easier if the U.S. just went first to file (like basically everywhere else).
The US is trying to make that transition. The bill passed the Senate, and Committee in the House, and goes to a full House vote in June 2011. But it will likely be difficult for the two bills to match and be agreed upon because of all the other crap in the bill which has good stuff and bad (much like the overwrought SBIR reauthorization bill that can never seem to pass and it just extended ad infinitum).
I like the "first to file" idea, but it puts the small inventor at a disadvantage. The main benefit is that it will hopefully lubricate university tech transfer offices. No more "oh I'll put in a disclosure and wait and see, I'm safe." it'll incentivize the inventors to file a provisional as soon as possible. But of you're building (or hacking) something in your garage you'd better get a patent attorney quick. And be patient, because response times on a first-to-file system will be horribly slow even compared to today's glacial system.