<- Back to shtanton's homepage
aboutsummaryrefslogtreecommitdiff
path: root/subex/subexast.go
diff options
context:
space:
mode:
authorCharlie Stanton <charlie@shtanton.xyz>2023-04-19 12:31:07 +0100
committerCharlie Stanton <charlie@shtanton.xyz>2023-04-19 12:31:07 +0100
commit61fd31368f26637a353cde6402b9a353b6b82e8b (patch)
tree25be689e78b5f9bb375a8900bcbae61e085b5f55 /subex/subexast.go
parent1c2d7a4e9258ed72f5c8ebecc3d575d065f25c5d (diff)
downloadstred-go-61fd31368f26637a353cde6402b9a353b6b82e8b.tar
Replaces a few instances of SubexStates with pointers as they should be
This potentially avoids bugs/errors and also improves the performance of pruning
Diffstat (limited to 'subex/subexast.go')
-rw-r--r--subex/subexast.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/subex/subexast.go b/subex/subexast.go
index cec75f7..e191a30 100644
--- a/subex/subexast.go
+++ b/subex/subexast.go
@@ -118,7 +118,7 @@ type SubexASTRepeat struct {
func (ast SubexASTRepeat) compileWith(next SubexState) SubexState {
var state SubexState = &SubexDeadState{}
for _, convex := range ast.acceptable {
- state = SubexGroupState {state, convex.compile(ast.content, next)}
+ state = &SubexGroupState {state, convex.compile(ast.content, next)}
}
return state
}