summaryrefslogtreecommitdiff
path: root/src/fjbg
Commit message (Collapse)AuthorAgeFilesLines
* Fix InnerClasses attribute: anonymous classes d...Iulian Dragos2010-11-131-1/+8
| | | | | | | | Fix InnerClasses attribute: anonymous classes don't have an outer name. EnclosingMethod is correctly generated. Fixed isAnonymousClass definition. Updated test that depends on anonymous inner class names. Closes (again) #3249, references #2749. review by odersky,extempore.
* Generate EnclosingMethod classfile attributes. Iulian Dragos2010-11-122-0/+47
| | | | | | | | This should fix java signatures when they refer to method type parameters. I unrolled Adriaans previous fix for #3249, as this one is more general. Closes #3249, review by moors.
* Reverted previous commit as I think it is wedgi...Paul Phillips2010-10-1710-51/+21
| | | | | | Reverted previous commit as I think it is wedging under -optimise. No review.
* Made some changes to fjbg so when people run in...Paul Phillips2010-10-1610-21/+51
| | | | | | | | Made some changes to fjbg so when people run into #1133 at least it will tell them what method was the cause. The fact that ten files are touched in this commit instead of one or two is a testament to the wonder of checked exceptions. No review.
* Found the following inefficiencies in fjbg:Paul Phillips2010-09-221-3/+37
| | | | | | | | | | | | | | | | | | | | | | ldc being used instead of bipush or sipush. The cheaper instructions were only being used when the argument was typed as byte or short, but an Int in the byte or short range can as easily use them. This also saves an entry in the constant pool. iconst_n not being used except on Ints. Same issue in reverse: pushing short 3 on the stack is cheaper with iconst_3 than with sipush. Example: class A { def f1: Int = 100 // was ldc #X, now bipush 100 def f2: Int = 5000 // was ldc #X, now sipush 5000 def f3: Byte = 2 // was bipush 2, now iconst_2 def f4: Short = 2 // was sipush 2, now iconst_2 } Review by dragos.
* Guard against overflow in fjbg.Paul Phillips2010-09-191-3/+4
|
* Restoring negative literal parsing behavior to ...Paul Phillips2010-09-171-11/+16
| | | | | | | | | | | | | | | | | | | | | Restoring negative literal parsing behavior to what should be the least surprising option. Thanks much to Johannes Rudolph for identifying the bug in the bytecode generator which needed addressing for us to arrive at proper -0.0 behavior, and for writing the majority of this patch. A '-' followed immediately by either a number or a period should now always be treated as a single numeric literal, which means the minus binds more tightly than anything else. A specific example of how this differs from 2.8 final is: -5.+(10) == 5.0 // and not -15.0 The full range of potentially ambiguous parses involving prefix operators, numbers, and dots is quite large and still needs to be completely and clearly specified. Closes #2378 and #3657, review by odersky, jrudolph.
* Removed more than 3400 svn '$Id' keywords and r...Antonio Cunei2010-05-1226-26/+0
| | | | | Removed more than 3400 svn '$Id' keywords and related junk.
* Closes #3310 (very large Scala class is compile...Gilles Dubochet2010-04-291-0/+3
| | | | | | Closes #3310 (very large Scala class is compiled to invalid classfile because Scala signature can't fit into constant pool). Review by dragos.
* Scala signature is generated as an annotation (...Gilles Dubochet2010-03-231-4/+32
| | | | | | | | | | | | | Scala signature is generated as an annotation (that is accessible through Java reflection). - compiler generates all pickled Scala signatures as annotations to class files. - compiler can read class files with signature as annotations or old-style signatures as attributes. - Scalap has also been updated to new signatures (contributed by Ilya Sergey: thanks a lot). - FJBG updated to allow entering constant pool strings as byte arrays. - ByteCodecs decode method returns the length of the decoded array. Review by ilyas. Already mostly reviewed by odersky.
* Fixes and test cases for #2087 and #2400.Paul Phillips2009-11-141-1/+1
| | | | | | | fixing a long-standing bug in fjbg and recompiling fjbg.jar, which had the side effect of revealing that the current fjbg jar had never been recompiled with target 1.5, so now it's smaller and (I imagine) faster.
* SABBUS now builds FJBG, which sources are now p...Gilles Dubochet2009-09-2128-0/+6173
SABBUS now builds FJBG, which sources are now part of the Scala module.