Code Monkey home page Code Monkey logo

byok's Introduction

Hi there 👋

Here's a small selection of personal projects I've got hosted in Github:

  • UK Ordnance Survey maps - A small frontend app written in Typescript using React, Chakra UI and Leaflet.js, deployed with Github Actions and hosted via Github Pages. maps-leisure

  • Zaup 2.0 - Another frontend app (also Typescript, React, Chakra) that displays imported TOTP codes. It is another "serverless" app - all the data is persisted in local storage (and AES encrypted) screenshot

  • Asteroids - A golang implementation of the classic arcade game that cross-compiles into WASM so you can play it in a browser. screenshot

  • 8-bit Trip - An experiment in webaudio. web-app

  • BYOK 3 - A Forth interpreter/compiler written in Scala with Cats. screencast

byok's People

Contributors

rm-hull avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

byok's Issues

Dump return stack trace

In stack_abort() something a bit more fancy than:

    printf("RS: ");
    dlist_elem_t *element = dlist_tail(ctx->rs);
    while (element != NULL)
    {
        int *num = dlist_data(element);

        printnum(*num, ctx->base);
        element = dlist_prev(element);
    }
    printf("\n");

LITERAL use in [CHAR] / ASCII

LITERAL is defined (as a primitive), along the lines:

: LITERAL ( n -- ) compile (lit) , ; immediate

When used to implement [CHAR]:

: [CHAR]  ( <char> -- char , for compile mode )
    char [compile] literal 
; immediate

Which we can then test with a trivial definition:

: f [char] F ;

yields the following disassembly:

00004828:  58 71 11 00  |Xq..|  NEST
0000482c:  70 ff 00 00  |p...|  (LIT)
00004830:  46 00 00 00  |F...|
00004834:  90 71 11 00  |.q..|  ,
00004838:  74 71 11 00  |tq..|  UNNEST

Using LITERAL for this seems incorrect, or at least should be used with a different compiler-controlling word

DUMP word

( a-addr n -- ) Dump memory at a-addr for n bytes

extern void rpad(char *text, int width, char padc);
extern void safeputch(int i);
extern void dump(int addr, int len);

Execution loop: properly exhaust return stack

With the following simple words:

: HELLO  ." hello " ;
: GOODBYE  ." goodbye " ;

It should be possible to chain them as follows:

' goodbye >body >r  hello

i.e. pushing the address of GOODBYE onto the return stack, to fool the execution loop to think it's a return address.

Currently __EXEC exits as soon as it encounters an unnest. It should probably carry on until the stack is exhausted.

Tab completion bug - cycling over choices

Enter D<tab> and cycle round all the words beginning with D.
Clear the line, enter S<tab> and cycle round all the words beginning with S, eventually it will revert to words beginning with D.

Not sure if the error is with readline or the completer function

Add cut/copy/paste functionality to readline & block editor

Key Action Scope Direction
Ctrl-d Delete the character underneath the cursor
Ctrl-u Delete everything ⇤ from the cursor back to the line start
Ctrl-k Delete everything ⇥ from the cursor to the end of the line
Alt-d Delete word ⇨ until before the next word boundary
Ctrl-w Delete word ⇦ until after the previous word boundary
Ctrl-y Yank/Paste prev. killed text at the cursor position
Alt-y Yank/Paste prev. prev. killed text at the cursor position
Ctrl-t Transpose/drag char. before the cursor ↷ over the character at the cursor
Alt-t Transpose/drag word before the cursor ↷ over the word at/after the cursor

http://www.bigsmoke.us/readline/shortcuts

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.