Skip to content

Commit

Permalink
Add UPLINE character. Fixes #95
Browse files Browse the repository at this point in the history
  • Loading branch information
eigenhombre committed Aug 21, 2024
1 parent b906435 commit 125bddc
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
6 changes: 6 additions & 0 deletions intro.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ helpful for this sort of construction:
QUOTE
DQUOTE
BQUOTE
UPLINE

These all evaluate to atoms whose names are the unreadable characters,
some of which may be helpful for text games and other diversions:
Expand Down Expand Up @@ -211,6 +212,11 @@ some of which may be helpful for text games and other diversions:
()
>

The `UPLINE` character, in particular, which moves the cursor to the
beginning of the previous line, is useful for making command-line
output which repeatedly updates the line in place, rather than
printing multiple lines.

## Functions

Functions come in two flavors: temporary functions, called "lambda"
Expand Down
6 changes: 6 additions & 0 deletions l1.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ helpful for this sort of construction:
QUOTE
DQUOTE
BQUOTE
UPLINE

These all evaluate to atoms whose names are the unreadable characters,
some of which may be helpful for text games and other diversions:
Expand Down Expand Up @@ -211,6 +212,11 @@ some of which may be helpful for text games and other diversions:
()
>

The `UPLINE` character, in particular, which moves the cursor to the
beginning of the previous line, is useful for making command-line
output which repeatedly updates the line in place, rather than
printing multiple lines.

## Functions

Functions come in two flavors: temporary functions, called "lambda"
Expand Down
1 change: 1 addition & 0 deletions lisp/builtin.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ func InitGlobals() Env {
globals.Set("QUOTE", Atom{"'"})
globals.Set("BQUOTE", Atom{"`"})
globals.Set("DQUOTE", Atom{"\""})
globals.Set("UPLINE", Atom{"\033[F"})
return globals
}

Expand Down

0 comments on commit 125bddc

Please sign in to comment.