Support only integer primitive ranges and progressions in optimized for loop codegen.

Do not call getProgressionFinalElement, use new progression properties 'first' and 'last' instead.
This commit is contained in:
Ilya Gorbunov
2015-11-13 05:29:55 +03:00
parent 5d4e72ed7f
commit 96f301fdec
6 changed files with 44 additions and 113 deletions

View File

@@ -5,4 +5,6 @@ fun f() {
// 0 iterator
// 0 getStart
// 0 getEnd
// 0 getEnd
// 0 getFirst
// 0 getLast

View File

@@ -5,4 +5,6 @@ fun f(a: Int, b: Int) {
// 0 iterator
// 0 getStart
// 0 getEnd
// 0 getEnd
// 0 getFirst
// 0 getLast

View File

@@ -6,6 +6,6 @@ fun f() {
}
// 0 iterator
// 2 getStart
// 2 getEnd
// 2 getFirst
// 2 getLast
// 2 getIncrement

View File

@@ -4,5 +4,7 @@ fun f(r: IntRange) {
}
// 0 iterator
// 1 getStart
// 1 getEnd
// 0 getStart
// 0 getEnd
// 1 getFirst
// 1 getLast