diff --git a/codeCore/src/prog8/code/ast/AstExpressions.kt b/codeCore/src/prog8/code/ast/AstExpressions.kt index 043ca8e4c..c7c30932e 100644 --- a/codeCore/src/prog8/code/ast/AstExpressions.kt +++ b/codeCore/src/prog8/code/ast/AstExpressions.kt @@ -350,12 +350,11 @@ class PtRange(type: DataType, position: Position) : PtExpression(type, position) val fromLv = from as? PtNumber val toLv = to as? PtNumber - val stepLv = step as? PtNumber - if(fromLv==null || toLv==null || stepLv==null) + if(fromLv==null || toLv==null) return null val fromVal = fromLv.number.toInt() val toVal = toLv.number.toInt() - val stepVal = stepLv.number.toInt() + val stepVal = step.number.toInt() return makeRange(fromVal, toVal, stepVal) } } diff --git a/docs/source/todo.rst b/docs/source/todo.rst index e52c5173a..7a9657cf6 100644 --- a/docs/source/todo.rst +++ b/docs/source/todo.rst @@ -7,7 +7,8 @@ TODO Future Things and Ideas ^^^^^^^^^^^^^^^^^^^^^^^ -- implement const long to store a 32 bit signed integer value. (constants should be able to be long?) +- implement const long to store a 32 bit signed integer value. (constants should be able to be long?) -> const_long branch +- get rid of the BuiltinFunctionCall (and PtBuiltinFunctionCall) ast nodes distinction, just use 1 node type, they're mixed up now already anyways. - something to reduce the need to use fully qualified names all the time. 'with' ? Or 'using '? - Why are blocks without an addr moved BEHIND a block with an address? That's done in the StatementReorderer. - on the C64: make the floating point routines @banked so that basic can be permanently banked out even if you use floats? But this will crash when the call is done from program code at $a000+