4 Star 4 Fork 0

Gitee 极速下载 / Speedle

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/oracle/speedle
克隆/下载
lexerStream.go 648 Bytes
一键复制 编辑 原始数据 按行查看 历史
cynthia.ding@oracle.com 提交于 2019-03-26 00:13 . first commit
package govaluate
type lexerStream struct {
source []rune
position int
length int
}
func newLexerStream(source string) *lexerStream {
var ret *lexerStream
var runes []rune
for _, character := range source {
runes = append(runes, character)
}
ret = new(lexerStream)
ret.source = runes
ret.length = len(runes)
return ret
}
func (this *lexerStream) readCharacter() rune {
var character rune
character = this.source[this.position]
this.position += 1
return character
}
func (this *lexerStream) rewind(amount int) {
this.position -= amount
}
func (this lexerStream) canRead() bool {
return this.position < this.length
}
1
https://gitee.com/mirrors/Speedle.git
git@gitee.com:mirrors/Speedle.git
mirrors
Speedle
Speedle
1643d905b0e4

搜索帮助