<- Back to shtanton's homepage
aboutsummaryrefslogtreecommitdiff
path: root/subex/subexstate.go
Commit message (Collapse)AuthorAgeFilesLines
* Implement new number systemnumbersCharlie Stanton13 days1-0/+21
|
* Add iterating destructuresCharlie Stanton2024-04-271-78/+0
|
* Change output subex internals to allow structuresCharlie Stanton2024-04-071-27/+40
| | | | Also add substitute register syntactic sugar
* Add " shorthand for string destructureCharlie Stanton2024-03-311-3/+2
|
* Add map destructureCharlie Stanton2024-03-301-0/+25
|
* Add array value destructureCharlie Stanton2024-03-301-2/+25
|
* Completely remove the path spaceCharlie Stanton2024-03-291-100/+149
| | | | The new design uses deeply nested values in the value space instead.
* Reimplements inserting basic values using subexesCharlie Stanton2023-07-211-9/+34
|
* Huge refactor to a more value based system, doing away with terminals. Also ↵Charlie Stanton2023-07-191-158/+204
| | | | introduces unit testing
* Update subex , literal to no longer include terminalsCharlie Stanton2023-04-261-4/+4
|
* Refines storing and loading to use ids generated when the subex is compiled ↵Charlie Stanton2023-04-251-2/+2
| | | | instead of the runes
* Replaces the interfaces implementation of Atom with a tagged union based ↵Charlie Stanton2023-04-211-9/+4
| | | | implementation
* Add :xyz: replacement syntax that removes whatever is before it and inserts ↵Charlie Stanton2023-04-211-0/+13
| | | | whatever is inside it
* Add subex syntax to copy across booleans, numbers, strings and valuesCharlie Stanton2023-04-211-0/+77
|
* Combines sum and product into an arithmetic state that contains a function ↵Charlie Stanton2023-04-191-113/+10
| | | | | | for it's operation Creates arithmetic.go which will house all of these functions
* Adds product/and operatorCharlie Stanton2023-04-191-18/+69
|
* Adjusts the sum operator to act as boolean OR when all inputs are booleansCharlie Stanton2023-04-191-5/+15
|
* Replaces the parent/child implementation for operators like store and sum ↵Charlie Stanton2023-04-191-148/+63
| | | | | | | | | with an output stack Previously a store state was a parent of another state machine that it would run inside of itself in order to capture the output to be stored. This was limited as the greedyness of the child would not be transferred to the parent. The new implementation gives states more control over the output state and turns it into a stack. By pushing to the stack before the child and popping afterwards, all of the child's output can be retrieved while the child is very much part of the complete machine.
* Adds casting strings to numbers in the sum operatorCharlie Stanton2023-04-191-12/+31
|
* Refactors store and sum states to use the new SubexParentState for states ↵Charlie Stanton2023-04-181-53/+104
| | | | that run machines within themselves
* Fixes bug where stores wouldn't work inside other stores sometimesCharlie Stanton2023-04-181-1/+1
| | | | Something like $a($b(test)..."$b") wouldn't work as expected, this works now
* Adds the sum operatorCharlie Stanton2023-04-181-0/+62
| | | | Currently doesn't parse strings as each atom is considered independantly. Instead individual characters in strings can be cast
* Adds the repeat construct, obsoleting maximise, minimise, try, maybe and ↵Charlie Stanton2023-04-181-0/+9
| | | | | | probably more The repeat construct repeats a subex a number of times, this number is based on a provided list which is ordered by priority and can be unbounded.
* Fix bug where SubexStoreState is sometimes not a pointerCharlie Stanton2023-03-151-1/+1
|
* Renames TransducerOutput to OutputContent (and related types) and moves into ↵Charlie Stanton2023-03-051-1/+23
| | | | main/subexstate.go
* Renames walk.Datum to walk.AtomCharlie Stanton2023-03-051-33/+32
|
* Replace append with walk.ConcatData in many places to fix bug to do with ↵Charlie Stanton2023-02-261-5/+5
| | | | | | semantics of append When doing append, be very careful as it does make changes in place to the underlying array of the slice which may affect other slices
* Modify subex to take JSON split into "data"Charlie Stanton2023-02-221-34/+49
| | | | | | Currently no way to reassemble the data on the other side Much of the potential data cannot be interacted with meaningfully, only the string functionality is implemented Should rename data to something else
* Introduces subex processingCharlie Stanton2023-02-191-0/+145
Doesn't integrate it at all yet