classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Why are serialVersionUIDs explicitly set in Exceptions?


From: Mark Wielaard
Subject: Why are serialVersionUIDs explicitly set in Exceptions?
Date: Tue, 20 Feb 2001 00:37:41 +0100
User-agent: Mutt/1.3.12i

Hi,

Does anybody know why we are explicitly setting the serialVersionUID
on simple exceptions? I checked some classes by removing the
explicit setting of the serialVersionUID and recompiling with jikes
and gcj and the computed serialVersionUID was the same at the one
set explicitly in the class. I checked ConcurrentModificationException,
EmptyStackException, MissingResourceException, NoSuchElementException and
TooManyListenersException, but a lot more classes explicitly set the
serialVersionUID.

Since the computed values are the same as the explicitly set ones
I am wondering if we could not just remove them. It might hide bugs.
What do people think about it?

Cheers,

Mark

-- 
Stuff to read:
    <http://www.toad.com/gnu/whatswrong.html>
  What's Wrong with Copy Protection, by John Gilmore



reply via email to

[Prev in Thread] Current Thread [Next in Thread]