4 ms·
This library is a fork of Antirez's linenoise, so it's perhaps not only an inspiration but a quality that the code had to begin with, which the author of the fo
by jks 5y ago
This library is a fork of Antirez's linenoise, so it's perhaps not only an inspiration but a quality that the code had to begin with, which the author of the fork declares that she intends to preserve.
The linenoise README mentions "sensibility for small easy to understand code". It's not really explained further in the README, but I suppose the point is that you can read the ~1200 lines of source code and get a feel for it yourself.
- cloudbonsai 5y agoTbh, it doesn't seem to me like a great code. https://github.com/jart/bestline/blob/master/bestline.c#L2865 https://github.com/jart/bestline/blob/master/bestline.c#L286... This interface function is already terrible. Why doesn't it check the error code of bestlineHistoryLoad()? It smells like a sloppy C program with obscure failure modes.