UNPKG

pi-lens

Version:

Real-time code feedback for pi — LSP, linters, formatters, type-checking, structural analysis & booboo

21 lines (20 loc) • 396 B
id: c-no-malloc-free valid: - | int sum(const int *values, int count) { int total = 0; for (int i = 0; i < count; i++) { total += values[i]; } return total; } invalid: - | int *make_buffer(int count) { int *buf = malloc(sizeof(int) * count); return buf; } - | void release(int *buf) { free(buf); }