diff --git a/include/fxos/memory.h b/include/fxos/memory.h index 730d83b..ced261a 100644 --- a/include/fxos/memory.h +++ b/include/fxos/memory.h @@ -32,7 +32,6 @@ namespace FxOS { struct MemoryArea { -public: /* Userspace seen from user and privileged mode */ static MemoryArea U0, P0; /* Second half of memory, only for privileged mode */ @@ -98,7 +97,7 @@ struct MemoryRegion /* Returns the size of the region */ uint32_t size() const noexcept; - /* Returns the area associated to the region (assuming it is fully + /* Returns the area associated with the region (assuming it is fully contained in one, which should always be the case) */ MemoryArea area() const noexcept; diff --git a/include/fxos/os.h b/include/fxos/os.h index 6cd42a5..893f701 100644 --- a/include/fxos/os.h +++ b/include/fxos/os.h @@ -34,8 +34,8 @@ class OS { public: /* Create an OS interface for this virtual space. If there is no data - loaded in ROM or the OS can't be identified, the type os OS is set to - UNKNOWN and no information is provided. */ + loaded in ROM or the OS can't be identified, the type os OS is set to + UNKNOWN and no information is provided. */ OS(VirtualSpace &space); /* Type of OS, determined at construction */ diff --git a/include/fxos/symbols.h b/include/fxos/symbols.h index a10ed90..2d7b7f3 100644 --- a/include/fxos/symbols.h +++ b/include/fxos/symbols.h @@ -21,6 +21,7 @@ #include #include #include +#include namespace FxOS { diff --git a/include/fxos/util/Queue.h b/include/fxos/util/Queue.h index 898e465..b5f7da7 100644 --- a/include/fxos/util/Queue.h +++ b/include/fxos/util/Queue.h @@ -4,7 +4,10 @@ // 0110 |_ 3.50 -> 3.60 | _\ \ / _ (_-< // // |_ base# + offset |_| /_\_\___/__/ // //---------------------------------------------------------------------------// -// fxos/util/Queue: Simple queue that handles recursivity +// fxos/util/Queue: Simple queue that handles recursion +// +// Can be instantiated for any T for which std::set is valid and properly +// checks objects' identity. //--- #ifndef FXOS_UTIL_QUEUE_H diff --git a/lib/lang.cpp b/lib/lang.cpp index 73252e3..40f3efd 100644 --- a/lib/lang.cpp +++ b/lib/lang.cpp @@ -288,6 +288,7 @@ bool AsmInstruction::isdelayed() const noexcept bool AsmInstruction::isvaliddelayslot() const noexcept { + // TODO: PC-relative move is a valid delay slot but it doesn't work return !isdelayed() && !isterminal() && !isjump() && !iscondjump() && strcmp(this->mnemonic, "mova") != 0; } diff --git a/shell/e.cpp b/shell/e.cpp index 9bc3c6c..a843e71 100644 --- a/shell/e.cpp +++ b/shell/e.cpp @@ -30,8 +30,8 @@ static _e_args parse_e(Session &session, Parser &parser) if(!args.space_name.empty()) { space = session.get_space(args.space_name); if(!space) { - std::string msg = - format("virtual space '%s' does not exist", args.space_name); + std::string msg + = format("virtual space '%s' does not exist", args.space_name); if(parser.completing()) throw Parser::CompletionRequest("_error", msg); else diff --git a/shell/parser.cpp b/shell/parser.cpp index c826ca2..d4d4574 100644 --- a/shell/parser.cpp +++ b/shell/parser.cpp @@ -249,12 +249,12 @@ std::variant Parser::expr_or_range(VirtualSpace *space) if(m_la.type == ':') { expect(':'); long length = expr(space); - return (Range){start, start + length}; + return (Range) {start, start + length}; } else if(m_la.type == '.') { expect('.'); long end = expr(space); - return (Range){start, end}; + return (Range) {start, end}; } else { return (long)start;