当前位置:   article > 正文

Github C++项目积累

github c++

jagt/clumsy- 2023-11-07

在这里插入图片描述

该项目是基于 WinDivert 实现的手动控制 Windows 网络情况的工具,它无需安装下载即用,可用于模拟网络延迟、节流、丢包等。


lucasg/Dependencies- 2023-11-07

在这里插入图片描述

DLL 文件即动态链接库文件是一种共享库文件,Windows 系统上的可执行文件(.exe) 一般包含多个 .dll 后缀的文件。该项目是 Windows 上查看 DLL 文件依赖树的工具,能够帮助解决因依赖缺失,导致运行 .exe 程序失败的问题。


antirez/smallchat - 2023-11-07

Redis 创始人 antirez 用纯 C 语言代码写了一个聊天服务器的最小编程示例:Smallchat
可以看到,Smallchat 的核心代码仅 300 多行。antirez 称删除空行和注释后其实只有 200 多行。


lava/matplotlib-cpp - 2023-07-24

Extremely simple yet powerful header-only C++ plotting library built on the popular matplotlib

3.9k star

#include "matplotlibcpp.h"
namespace plt = matplotlibcpp;
int main() {
    plt::plot({1,3,2,4});
    plt::show();
}
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6

在这里插入图片描述


alibaba/yalantinglibs - 2023-07-17

A collection of C++20 libraries, include coro_rpc, struct_pack, struct_json, struct_xml, struct_pb, easylog, async_simple
854 star

yaLanTingLibs 是一个C++20基础工具库的集合, 现在它包括 struct_pack, struct_json, struct_xml, struct_pb, easylog, coro_rpc, coro_http 和 async_simple, 目前我们正在开发并添加更多的新功能。

yaLanTingLibs 的目标: 为C++开发者提供高性能,极度易用的C++20基础工具库, 帮助用户构建高性能的现代C++应用。


ipkn/crow - 2023-07-04

Crow is very fast and easy to use C++ micro web framework (inspired by Python Flask)
7.2k star

在这里插入图片描述
Crow is C++ microframework for web. (inspired by Python Flask)

#include "crow.h"

int main()
{
    crow::SimpleApp app;

    CROW_ROUTE(app, "/")([](){
        return "Hello world";
    });

    app.port(18080).multithreaded().run();
}
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12

contrem/arduino-timer - 2023-06-30

Non-blocking library for delaying function calls
260 star

/* Constructors */
/* Create a timer object with default settings:
   millis resolution, TIMER_MAX_TASKS (=16) task slots, T = void *
*/
Timer<> timer_create_default(); // auto timer = timer_create_default();

/* Create a timer with max_tasks slots and time_func resolution */
Timer<size_t max_tasks = TIMER_MAX_TASKS, unsigned long (*time_func)(void) = millis, typename T = void *> timer;
Timer<> timer; // Equivalent to: auto timer = timer_create_default()
Timer<10> timer; // Timer with 10 task slots
Timer<10, micros> timer; // timer with 10 task slots and microsecond resolution
Timer<10, micros, int> timer; // timer with 10 task slots, microsecond resolution, and handler argument type int

/* Signature for handler functions - T = void * by default */
bool handler(T argument);

/* Timer Methods */
/* Ticks the timer forward, returns the ticks until next event, or 0 if none */
unsigned long tick(); // call this function in loop()

/* Calls handler with opaque as argument in delay units of time */
Timer<>::Task
in(unsigned long delay, handler_t handler, T opaque = T());

/* Calls handler with opaque as argument at time */
Timer<>::Task
at(unsigned long time, handler_t handler, T opaque = T());

/* Calls handler with opaque as argument every interval units of time */
Timer<>::Task
every(unsigned long interval, handler_t handler, T opaque = T());

/* Cancel a timer task */
bool cancel(Timer<>::Task &task);
/* Cancel all tasks */
void cancel();

/* Returns the ticks until next event, or 0 if none */
unsigned long ticks();

/* Number of active tasks in the timer */
size_t size() const;

/* True if there are no active tasks */
bool empty() const;
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45

Simple non-blocking timer library for calling functions in / at / every specified units of time. Supports millis, micros, time rollover, and compile time configurable number of tasks.


pybind/pybind11 - 2023-06-06

Seamless operability between C++11 and Python
12.9k star

在这里插入图片描述

pybind11 可实现 C++11 和 Python 之间的无缝操作。

pybind11 是一个轻量级的只包含一组头文件的 C++ 库,可以在 Python 中使用 C++ 类型。主要用于创建已有 C++ 代码的 Python 封装版本。其目的和语法类似于 Boost.Python 库。为什么要创建这个项目的原因就是因为 Boost 。作者认为 Boost 很大很复杂。而目前的 C++11 兼容的编译器使用已经非常广泛,所以希望开发一个更轻量级更具备兼容性的项目。

除去注释之外,该项目的核心头文件只有 2500 行左右代码,依赖于 Python (2.7 或者 3.x) 和标准 C++ 库。这么精简的实现有赖于新的 C++11 语言特性。特别是元组、Lambda 函数以及可变模板。自从项目创建以来,其增长已经超过了 Boost.Python。


include-what-you-use/include-what-you-use - 2023-06-02

A tool for use with clang to analyze #includes in C and C++ source files
3.4k star

#include <fcntl.h>
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdint.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <unistd.h>
#include <sys/user.h>
#include <execinfo.h>

int main(int argc, char* argv[])
{
    return 0;
}
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16

在这里插入图片描述

A tool for use with clang to analyze #includes in C and C++ source files


leafsr/gcc-poison - 2023-06-02

find unsafe C/C++ functions
183 star

#include <stdio.h>
#include <string.h>
#include "gcc-poison.h"

int main(int argc, char *argv[]) {
   char buf[10];
   strcpy(buf, argv[1]);
   return 0;
}

$ gcc -o 2 2.c
1.c: In function ‘main’:
1.c:8:2: error: attempt to use poisoned "strcpy"
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13

gcc-poison is a simple header file for developers to ban unsafe C/C++ functions from applications. It uses the #pragma GCC poison directive to define a number of identifiers (function names) as unsafe. Compilation will fail if these are present in your code.


aantron/better-enums - 2023-06-02

C++ compile-time enum to string, iteration, in a single header file
1.5k star

在这里插入图片描述


sheredom/subprocess.h - 2023-04-24

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/凡人多烦事01/article/detail/719019
推荐阅读
相关标签