new syntax to get items from collection: collection[index]. Supported collections are string, list and dict
This commit is contained in:
@@ -74,6 +74,14 @@ func (self *scanner) unreadChar() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func (self *scanner) lastPos() (r, c int) {
|
||||
if self.prev != nil {
|
||||
r = self.prev.row
|
||||
c = self.prev.col
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (self *scanner) Previous() *Token {
|
||||
return self.prev
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user