summaryrefslogtreecommitdiff
path: root/src/library/scala/SerialVersionUID.scala
Commit message (Collapse)AuthorAgeFilesLines
* Fix for SerialVersionUID instability.Paul Phillips2012-11-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Can hardly believe this has been broken for a decade or so, but there it is - see test case. Four classes attempt to set their SerialVersionUID to 13. One succeeds. No warnings or errors. The output before this patch (for me anyway - your random numbers may differ) was: 860336111422349646 13 8409527228024057943 -7852527872932878365 There was already code in place for rejecting annotations with non-constant args when constant args are required, but that check is only performed on ClassfileAnnotations, and SerialVersionUID was a StaticAnnotation. Maybe people don't reach for ClassfileAnnotation because of this giant warning which I see no way to suppress: warning: Implementation restriction: subclassing Classfile does not make your annotation visible at runtime. If that is what you want, you must write the annotation class in Java. Why did I change the name of the field from uid to value? If you don't use the name 'value', you have to name the argument every time you use it, even if it's the only parameter. I didn't relish breaking every usage of scala's @SerialVersionUID in the known universe.
* Brings all copyrights (in comments) up-to-date, from 2011/12 to 2013Heather Miller2012-11-021-1/+1
|
* Eliminate breaking relative names in source.Paul Phillips2012-09-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These things are killing me. Constructions like package scala.foo.bar.baz import foo.Other DO NOT WORK in general. Such files are not really in the "scala" package, because it is not declared package scala package foo.bar.baz And there is a second problem: using a relative path name means compilation will fail in the presence of a directory of the same name, e.g. % mkdir reflect % scalac src/reflect/scala/reflect/internal/util/Position.scala src/reflect/scala/reflect/internal/util/Position.scala:9: error: object ClassTag is not a member of package reflect import reflect.ClassTag ^ src/reflect/scala/reflect/internal/util/Position.scala:10: error: object base is not a member of package reflect import reflect.base.Attachments ^ As a rule, do not use relative package paths unless you have explicitly imported the path to which you think you are relative. Better yet, don't use them at all. Unfortunately they mostly work because scala variously thinks everything scala.* is in the scala package and/or because you usually aren't bootstrapping and it falls through to an existing version of the class already on the classpath. Making the paths explicit is not a complete solution - in particular, we remain enormously vulnerable to any directory or package called "scala" which isn't ours - but it greatly limts the severity of the problem.
* 2nd round of clean ups (see r25285)michelou2011-07-151-4/+1
|
* Updated copyright notices to 2011Antonio Cunei2011-01-201-1/+1
|
* Moved ClassfileAnnotation/StaticAnnotation/Anno...Paul Phillips2010-12-061-1/+1
| | | | | | | Moved ClassfileAnnotation/StaticAnnotation/Annotation/TypeConstraint into scala.annotation and enabled the deprecated type aliases in scala.* to point there. Also enclosed is a new starr to bootstrap. No review.
* Removed more than 3400 svn '$Id' keywords and r...Antonio Cunei2010-05-121-1/+0
| | | | | Removed more than 3400 svn '$Id' keywords and related junk.
* Updated copyright notices to 2010Antonio Cunei2009-12-071-1/+1
|
* fixed headers/comments/svn props, made some pro...michelou2009-09-151-3/+3
| | | | | | fixed headers/comments/svn props, made some progress with serializable classes
* Updated (all) copyright notices to 2009Antonio Cunei2009-01-131-1/+1
|
* Added "scalacfork" ant task and enabled it to b...Lukas Rytz2008-08-191-1/+1
| | | | | | | | | Added "scalacfork" ant task and enabled it to build locker and quick. Removed sabbus.jar (sabbus ant tasks are included in scala-compiler.jar for some time now) Made serializable, cloneable, SerialVersionUID, BeanProperty static annotations Fixed the Pickler not to crash on repeated annotations
* renamed attributes to annotations; added @syntax.Martin Odersky2007-02-091-2/+2
|
* added generation of attributes in scaladocmichelou2006-09-221-2/+2
|
* Added scala.throws(java.lang.Class) attribute t...mihaylov2006-05-191-1/+1
| | | | | | Added scala.throws(java.lang.Class) attribute to specify the checked exceptions thrown by a method
* Rearranged header and updated copyright messagemihaylov2006-03-021-2/+9
|
* Switching to the new build system and to the ne...Gilles Dubochet2005-12-191-0/+12
Switching to the new build system and to the new build system. This is a MAJOR commit, so be careful when updating.