From 1f3b53753a20933f8eb73d64d379e6c20df8f725 Mon Sep 17 00:00:00 2001 From: Syed Daanish Date: Sat, 22 Aug 2026 15:31:21 +0100 Subject: [PATCH] Cleanup. --- README.md | 17 ++--------------- include/internal/address/address.h | 2 +- src/bed/handle.cc | 1 - src/internal/address/resolve.cc | 2 +- 4 files changed, 4 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index b607986..8bc487d 100644 --- a/README.md +++ b/README.md @@ -40,21 +40,8 @@ An ed implementation (mostly posix compliant) but with: - Internal buffer: - Super fast and memory efficient buffer implementation done. - Loading from files/subshell commands done. -- Most of the posix ed commands except regex ones done. - -### Modules - -#### `Vase` - -Vase is a avl piece tree like structure which handles loading, insertion, erasure, regex searching, regex replacing etc. -
-done. - -#### `hl` - -`hl` is a stateful super fast syntax highlighter. -
-mostly done. +- Syntax highlighter and block parser system done. +- All ed addressing modes and block addressing done (also `%`). #### `lsp` diff --git a/include/internal/address/address.h b/include/internal/address/address.h index 2e98713..0fa0c7a 100644 --- a/include/internal/address/address.h +++ b/include/internal/address/address.h @@ -14,7 +14,6 @@ struct Address { // it expands in theory to a Num,Num and so can be followed by chaining more adresses the ed way. // this is handled and resolved by the handle function, // the constuctor and resolve etc. are also only called in the handle function, - // i.e. handle is the only public facing API from this namespace & class for now. // // in case of any issue an instance of address_error(const char *) is thrown. @@ -46,6 +45,7 @@ struct Address { std::string re; }; + // extended types struct Diagnostic { // #n# for diagnostic number n. (From lsp.) uint16_t n; }; diff --git a/src/bed/handle.cc b/src/bed/handle.cc index b2735bb..902747e 100644 --- a/src/bed/handle.cc +++ b/src/bed/handle.cc @@ -57,7 +57,6 @@ void BEd::handle(std::string_view cmd_, bool eof) { if (suffixes[cmd[i] - 'a'].has_value()) suffix = &(suffixes[cmd[i++] - 'a'].value()); skip_space(); - std::cout << i << " " << cmd << std::endl; if (i < cmd.size()) throw ed_error("Command error."); } diff --git a/src/internal/address/resolve.cc b/src/internal/address/resolve.cc index ec73900..9b75d80 100644 --- a/src/internal/address/resolve.cc +++ b/src/internal/address/resolve.cc @@ -71,6 +71,6 @@ uint64_t Address::resolve(BEd &ctx) { base ); - return result + offset; + return result; } }; // namespace bed::internal::address