Improved file structure
This commit is contained in:
parent
b6400cd77e
commit
c0f399df7f
18 changed files with 106 additions and 378 deletions
|
@ -1,7 +1,5 @@
|
|||
package token
|
||||
|
||||
import "git.akyoto.dev/cli/q/src/keywords"
|
||||
|
||||
// Pre-allocate these byte buffers so we can re-use them
|
||||
// instead of allocating a new buffer every time.
|
||||
var (
|
||||
|
@ -87,7 +85,7 @@ func Tokenize(buffer []byte) List {
|
|||
buffer[position:i],
|
||||
}
|
||||
|
||||
if keywords.All[string(token.Bytes)] {
|
||||
if Keywords[string(token.Bytes)] {
|
||||
token.Kind = Keyword
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue