diff options
author | Lukas Rytz <lukas.rytz@gmail.com> | 2014-09-11 10:22:37 +0200 |
---|---|---|
committer | Lukas Rytz <lukas.rytz@gmail.com> | 2014-09-11 10:24:14 +0200 |
commit | 9132efa4a8511e267c808c95df4d2e3de68277e6 (patch) | |
tree | 1b3bd243bcb19ed41609e67ce0f6d94ee2704a78 /src/partest-extras/scala | |
parent | 59070cc385560b48267cbc77e872027dd8304c05 (diff) | |
download | scala-9132efa4a8511e267c808c95df4d2e3de68277e6.tar.gz scala-9132efa4a8511e267c808c95df4d2e3de68277e6.tar.bz2 scala-9132efa4a8511e267c808c95df4d2e3de68277e6.zip |
Address review feedback.
Diffstat (limited to 'src/partest-extras/scala')
-rw-r--r-- | src/partest-extras/scala/tools/partest/ASMConverters.scala | 4 | ||||
-rw-r--r-- | src/partest-extras/scala/tools/partest/BytecodeTest.scala | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/partest-extras/scala/tools/partest/ASMConverters.scala b/src/partest-extras/scala/tools/partest/ASMConverters.scala index d443a31112..67a4e8ae01 100644 --- a/src/partest-extras/scala/tools/partest/ASMConverters.scala +++ b/src/partest-extras/scala/tools/partest/ASMConverters.scala @@ -141,9 +141,9 @@ object ASMConverters { } def sameVar(v1: Int, v2: Int) = same(v1, v2, varMap) def sameLabel(l1: Label, l2: Label) = same(l1.offset, l2.offset, labelMap) - def sameLabels(ls1: List[Label], ls2: List[Label]) = ls1.length == ls2.length && (ls1, ls2).zipped.forall(sameLabel) + def sameLabels(ls1: List[Label], ls2: List[Label]) = (ls1 corresponds ls2)(sameLabel) - def sameFrameTypes(ts1: List[Any], ts2: List[Any]) = ts1.length == ts2.length && (ts1, ts2).zipped.forall { + def sameFrameTypes(ts1: List[Any], ts2: List[Any]) = (ts1 corresponds ts2) { case (t1: Label, t2: Label) => sameLabel(t1, t2) case (x, y) => x == y } diff --git a/src/partest-extras/scala/tools/partest/BytecodeTest.scala b/src/partest-extras/scala/tools/partest/BytecodeTest.scala index c6fa279c50..3261cada37 100644 --- a/src/partest-extras/scala/tools/partest/BytecodeTest.scala +++ b/src/partest-extras/scala/tools/partest/BytecodeTest.scala @@ -84,7 +84,7 @@ abstract class BytecodeTest { /** * Compare the bytecodes of two methods. * - * The for the `similar` function, you probably want to pass [[ASMConverters.equivalentBytecode]]. + * For the `similar` function, you probably want to pass [[ASMConverters.equivalentBytecode]]. */ def similarBytecode(methA: MethodNode, methB: MethodNode, similar: (List[Instruction], List[Instruction]) => Boolean) = { val isa = instructionsFromMethod(methA) |