Giter Club home page Giter Club logo

watchful's Issues

Update for Janet 1.17

Janet 1.17 deprecates the old thread interface, meaning watchful fails to compile:

In file included from src/watchful/fse.c:1:
src/watchful/../watchful.h:77:3: error: unknown type name 'JanetThread'
   77 |   JanetThread *parent;
      |   ^~~~~~~~~~~
src/watchful/inotify.c: In function 'handle_event':
src/watchful/inotify.c:98:9: warning: implicit declaration of function 'janet_thread_send' [-Wimplicit-function-declaration]
   98 |         janet_thread_send(stream->parent, janet_wrap_pointer(event), 10);
      |         ^~~~~~~~~~~~~~~~~
src/watchful.c: In function 'cfun_watch':
src/watchful.c:350:25: warning: implicit declaration of function 'janet_thread_receive' [-Wimplicit-function-declaration]
  350 |         int timed_out = janet_thread_receive(&out, timeout);
      |                         ^~~~~~~~~~~~~~~~~~~~
In file included from src/watchful/inotify.c:1:
src/watchful/../watchful.h:77:3: error: unknown type name 'JanetThread'
   77 |   JanetThread *parent;
      |   ^~~~~~~~~~~
src/watchful/inotify.c: In function 'handle_event':
src/watchful/inotify.c:98:9: warning: implicit declaration of function 'janet_thread_send' [-Wimplicit-function-declaration]
   98 |         janet_thread_send(stream->parent, janet_wrap_pointer(event), 10);
      |         ^~~~~~~~~~~~~~~~~
In file included from src/watchful.c:1:
src/watchful.h:77:3: error: unknown type name 'JanetThread'
   77 |   JanetThread *parent;
      |   ^~~~~~~~~~~
src/watchful.c:94:8: error: unknown type name 'JanetThread'
   94 | static JanetThread *watchful_current_thread() {
      |        ^~~~~~~~~~~
src/watchful.c: In function 'watchful_current_thread':
src/watchful.c:96:13: error: 'JanetThread' undeclared (first use in this function); did you mean 'JanetStream'?
   96 |     return (JanetThread *)janet_unwrap_abstract(cfun(0, NULL));
      |             ^~~~~~~~~~~
      |             JanetStream
src/watchful.c:96:13: note: each undeclared identifier is reported only once for each function it appears in
src/watchful.c:96:26: error: expected expression before ')' token
   96 |     return (JanetThread *)janet_unwrap_abstract(cfun(0, NULL));
      |                          ^
src/watchful.c: In function 'cfun_watch':
src/watchful.c:350:25: warning: implicit declaration of function 'janet_thread_receive' [-Wimplicit-function-declaration]
  350 |         int timed_out = janet_thread_receive(&out, timeout);
      |                         ^~~~~~~~~~~~~~~~~~~~

It might be a lot of work to rewrite this...

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.