String Instructions
All checks were successful
per-push tests / build (push) Successful in 47s
per-push tests / test-utility (push) Successful in 53s
per-push tests / test-frontend (push) Successful in 59s
per-push tests / test-backend (push) Successful in 43s
per-push tests / timed-decomposer-parse (push) Successful in 51s
All checks were successful
per-push tests / build (push) Successful in 47s
per-push tests / test-utility (push) Successful in 53s
per-push tests / test-frontend (push) Successful in 59s
per-push tests / test-backend (push) Successful in 43s
per-push tests / timed-decomposer-parse (push) Successful in 51s
The following instructions are modified to act on strings: - INDEX: Now pulls a char out at index - SUBSL: Now pulls a substring out of a source string - INSER: Now inserts a char into a string at index - LENGTH: Now returns length of a string In addition to the above instructions, additional instructions are now implemented to handle strings: - CONCAT: appends a string onto another string - S_APPEND: appends a char on to the end of a string Fixes: #38 Signed-off-by: Ava Affine <ava@sunnypup.io>
This commit is contained in:
parent
63554191f8
commit
ddb49788af
3 changed files with 81 additions and 43 deletions
|
|
@ -312,3 +312,15 @@ name = "cdr"
|
|||
args = ["list"]
|
||||
output = "returns last element in cons cell"
|
||||
description = "takes an AST and returns last element in top level cons cell"
|
||||
|
||||
[[instructions]]
|
||||
name = "concat"
|
||||
args = ["string_l", "string_r"]
|
||||
output = "string_l+string_r"
|
||||
description = "concatenates string r to string l and returns a new string"
|
||||
|
||||
[[instructions]]
|
||||
name = "s_append"
|
||||
args = ["parent", "child"]
|
||||
output = ""
|
||||
description = "append in place child character into parent string"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue