airt / libuvx

coroutine + libuv

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

libuvx

Build Status

libuv + coroutine

Code Example

Basic

#include <uvx>

int main() {

  auto c = co::create([] {
    puts("2");
    co::yield();
    puts("4");
  });

  puts("1");
  co::resume(c);
  puts("3");
  co::resume(c);
  puts("5");

}

More

Build and Test

git submodule update --init --recursive

run scripts

scripts/build.sh
scripts/test.sh

or run within container

docker build -t uvx-test .
docker run -it uvx-test

About

coroutine + libuv

License:MIT License


Languages

Language:C++ 90.4%Language:CMake 6.9%Language:C 1.1%Language:Shell 0.8%Language:Dockerfile 0.7%