| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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 related junk.
|
|
|
|
|
|
| |
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 (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.
|
|
|
|
|
|
|
| |
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 part of the Scala module.
|