Skip to content

Commit

Permalink
Spell check src/machine/ and src/systems/
Browse files Browse the repository at this point in the history
  • Loading branch information
eglaysher committed May 4, 2015
1 parent 824c078 commit ec6b3b7
Show file tree
Hide file tree
Showing 43 changed files with 84 additions and 85 deletions.
2 changes: 1 addition & 1 deletion src/machine/general_operations_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
// exposed in general_operations.h.

// Contains details on how to get a certain object from an input
// RLMachine. Templates are specialized in the cpp file.
// RLMachine. Templates are specialized in the cc file.
namespace getSystemObjImpl {

template <typename RETTYPE>
Expand Down
2 changes: 1 addition & 1 deletion src/machine/memory.cc
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ void Memory::SetStringValue(int type, int number, const std::string& value) {
global_->strM[number] = value;
break;
case libreallive::STRS_LOCATION: {
// Possibly record the orriginal value for a piece of local memory.
// Possibly record the original value for a piece of local memory.
std::map<int, std::string>::iterator it =
local_.original_strS.find(number);
if (it == local_.original_strS.end()) {
Expand Down
6 changes: 3 additions & 3 deletions src/machine/memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ BOOST_CLASS_VERSION(LocalMemory, 2)
//
// @note Because I use BSD code from xclannad in some of the methods
// in this class, for licensing purposes, that code is separated
// into RLMachine_intmem.cpp.
// into memory_intmem.cc.
class Memory {
public:
// Default constructor; creates a Memory object which owns its own
Expand All @@ -195,7 +195,7 @@ class Memory {
// declaration of the form \#intvar[index] or \#strvar[index].
Memory(RLMachine& machine, Gameexe& gamexe);

// Creates an overlayed memory object. An overlay takes another Memory's
// Creates an overlaid memory object. An overlay takes another Memory's
// global memory. Local integer memory isn't initialized; it isn't even
// memset zeroed out.
//
Expand Down Expand Up @@ -250,7 +250,7 @@ class Memory {
void TakeSavepointSnapshot();

// Converts a RealLive letter index (A-Z, AA-ZZ) to its numeric
// equivalent. These letter indexies are used in \#NAME definitions.
// equivalent. These letter indexes are used in \#NAME definitions.
static int ConvertLetterIndexToInt(const std::string& value);

private:
Expand Down
4 changes: 2 additions & 2 deletions src/machine/opcode_log.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@
#include <map>
#include <string>

// An optional component to an RLMachine that counts the number of instnaces of
// An optional component to an RLMachine that counts the number of instances of
// an opcode. An OpcodeLog can be used to count the number of times an opcode
// was run during the lifetime of a program, or the number of times an
// undefined opcode was encountered, et cetera.
// undefined opcode was encountered, etc.
class OpcodeLog {
public:
typedef std::map<std::string, int> Storage;
Expand Down
6 changes: 3 additions & 3 deletions src/machine/reference.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class Memory;

// Accessor class passed back to user when the iterator is
// dereferenced. Each IntAcessor will (probably) be a short-lived
// temporary object which is immediatly casted to an int, or it may
// temporary object which is immediately casted to an int, or it may
// have a value assigned to it.
class IntAccessor {
public:
Expand All @@ -60,8 +60,8 @@ class IntAccessor {
};

// Accessor class passed back to user when the iterator is
// dereferenced. Each StringAcessor will (probably) be a short-lived
// temporary object which is immediatly casted to an string, or it may
// dereferenced. Each StringAccessor will (probably) be a short-lived
// temporary object which is immediately casted to an string, or it may

This comment has been minimized.

Copy link
@darkstar

darkstar May 4, 2015

shouldn't that be "immediately cast" instead of "casted"?

// have a value assigned to it.
class StringAccessor {
public:
Expand Down
4 changes: 2 additions & 2 deletions src/machine/rlmachine.cc
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ void RLMachine::AttachModule(RLModule* module) {
if (it != modules_.end()) {
RLModule& cur_mod = *it->second;
std::ostringstream ss;
ss << "Module identification clash: tyring to overwrite " << cur_mod
ss << "Module identification clash: trying to overwrite " << cur_mod
<< " with " << *module << std::endl;

// Free |module| since we took ownership of it
Expand Down Expand Up @@ -616,7 +616,7 @@ void RLMachine::LoadDLL(int slot, const std::string& name) {
loaded_dlls_.emplace(slot, std::unique_ptr<RealLiveDLL>(dll));
} else {
std::ostringstream oss;
oss << "Can't load emulated dll named '" << name << "'";
oss << "Can't load emulated DLL named '" << name << "'";
throw rlvm::Exception(oss.str());
}
}
Expand Down
10 changes: 5 additions & 5 deletions src/machine/rlmachine.h
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ class RLMachine {
// Returns the actual Scenario on the top top of the call stack.
const libreallive::Scenario& Scenario() const;

// ------------------------------------------------ [ Execuion interface ]
// ------------------------------------------------ [ Execution interface ]
// Normally, execute_next_instruction will call RunOnMachine() on
// whatever BytecodeElement is currently pointed to by the
// instruction pointer.
Expand All @@ -229,7 +229,7 @@ class RLMachine {

// Guess the encoding for all text of the game.
//
// Because of how rlbabel works, each scenario in the SEEN archive can have
// Because of how rlBabel works, each scenario in the SEEN archive can have
// its own encoding. This guesses what the text output encoding is,
// regardless of the current scenario. (As we're probably running a scenario
// that hasn't been patched at the time this method is called.)
Expand Down Expand Up @@ -274,7 +274,7 @@ class RLMachine {
// Call executeNextInstruction() repeatedly until the RLMachine is
// halted. This function is used in unit testing, and would never be
// called during real usage of an RLMachine instance since other
// subsytems (graphics, sound, etc) would need to have a chance to
// subsystems (graphics, sound, etc) would need to have a chance to
// fire between RLMachine instructions.
void ExecuteUntilHalted();

Expand Down Expand Up @@ -338,7 +338,7 @@ class RLMachine {
// stack, though it does clear the shadow save stack.
void LocalReset();

// Adds a programatic action triggered by a line marker in a specific SEEN
// Adds a programmatic action triggered by a line marker in a specific SEEN
// file. This is used both by lua_rlvm to trigger actions specified in lua to
// drive rlvm's playing certain games, but is also used for game specific
// hacks.
Expand Down Expand Up @@ -412,7 +412,7 @@ class RLMachine {
std::unique_ptr<ActionMap> on_line_actions_;

typedef std::unordered_map<int, std::unique_ptr<RealLiveDLL>> DLLMap;
// Currenlty loaded "DLLs".
// Currently loaded "DLLs".
DLLMap loaded_dlls_;

// boost::serialization support
Expand Down
4 changes: 2 additions & 2 deletions src/machine/rlmodule.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,10 @@ class RLModule {
// Accessor that returns this module's type number
int module_type() const { return module_type_; }

// Accessor that returns this modules's identification number
// Accessor that returns this module's identification number
int module_number() const { return module_number_; }

// Accessor that returns this module's mnemonic nmae
// Accessor that returns this module's mnemonic name
const std::string& module_name() const { return module_name_; }

void SetProperty(int property, int value);
Expand Down
8 changes: 3 additions & 5 deletions src/machine/rloperation.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ class RLModule;
// @defgroup RLOperationGroup RLOperation and its type system
//
// Defines the base classes from which all of the opcode
// implementations derive from. This heirarchy of classes works by
// implementations derive from. This hierarchy of classes works by
// having one of your operation classes, which handles a specific
// prototype of a specific opcode, derive from one of the subclases
// prototype of a specific opcode, derive from one of the subclasses
// of RLOperation, specifically RLOpcode<> and RLOpcodeStore<>. The
// template parameters of these subclasses refer to the types of the
// parameters, some of which can be composed to represent more complex
Expand Down Expand Up @@ -96,8 +96,6 @@ class RLOperation {
public:
// Default constructor
RLOperation();

// Destructor
virtual ~RLOperation();

void set_name(const std::string& name) { name_ = name; }
Expand Down Expand Up @@ -219,7 +217,7 @@ struct Empty_T {

// Implements a special case operation. This should be used with
// things that don't follow the usually function syntax in the
// bytecode, such as weird gotos, et cetera.
// bytecode, such as weird gotos, etc.
//
// RLOp_SpecialCase gives you complete control of the Dispatch,
// performing no type checking, no parameter conversion, and no
Expand Down
2 changes: 1 addition & 1 deletion src/machine/rlvm_instance.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class RLVMInstance {
// Loads the specified save file as soon as emulation starts if not -1.
int load_save_;

// Dumps psuedokepago of the current seen to stdout and exit if not -1.
// Dumps pseudo-kepago of the current seen to stdout and exit if not -1.
int dump_seen_;
};

Expand Down
2 changes: 1 addition & 1 deletion src/machine/save_game_header.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

// Header structure written to and read from the start of each save
// game file. This structure is at the top of the file since it is
// what gets queried by SaveDate, SaveTime, et cetera.
// what gets queried by SaveDate, SaveTime, etc.
struct SaveGameHeader {
SaveGameHeader();
explicit SaveGameHeader(const std::string& in_title);
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/cgm_table.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class RLMachine;
// The cgm file is a mapping between file names and an index into the intZ[]
// global memory array, where intZ[index] is 1 when a cg has been viewed. The
// CGMTable class is responsible for loading the cgm data and providing an
// interface to querrying whether a CG was viewed.
// interface to querying whether a CG was viewed.
class CGMTable {
public:
// Initializes an empty CG table (for games that don't use this feature).
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/colour_filter_object_data.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class ColourFilterObjectData : public GraphicsObjectData {
// Returns the colour filter, lazily creating it if necessary.
ColourFilter* GetColourFilter();

// Overriden from GraphicsObjectData:
// Overridden from GraphicsObjectData:
virtual void Render(const GraphicsObject& go,
const GraphicsObject* parent,
std::ostream* tree) override;
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/event_listener.h
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ enum KeyCode {
RLKEY_BREAK = 318,
RLKEY_MENU = 319,
RLKEY_POWER = 320, // Power Macintosh power key
RLKEY_EURO = 321, // Some european keyboards
RLKEY_EURO = 321, // Some European keyboards
RLKEY_UNDO = 322, // Atari keyboard has Undo
};

Expand Down
6 changes: 3 additions & 3 deletions src/systems/base/event_system.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class EventSystem {
//
// "Frame counters are designed to make it simple to ensure events happen at a
// constant speed regardless of the host system's specifications. Once a frame
// counter has been initialised, it will count from one arbitrary number to
// counter has been initialized, it will count from one arbitrary number to
// another, over a given length of time. The counter can be queried at any
// point to get its current value."
//
Expand Down Expand Up @@ -132,15 +132,15 @@ class EventSystem {
// Keyboard and Mouse Input (Reallive style)
//
// RealLive applications poll for input, with all the problems that sort of
// event handeling has. We therefore provide an interface for polling.
// event handling has. We therefore provide an interface for polling.
//
// Don't use it. This interface is provided for RealLive
// bytecode. EventListeners should be used within rlvm code, instead.

// Returns whether shift is currently pressed.
virtual bool ShiftPressed() const = 0;

// Returns whether ctrl has been presed since the last invocation of
// Returns whether ctrl has been pressed since the last invocation of
// ctrlPresesd().
virtual bool CtrlPressed() const = 0;

Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/frame_counter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ void FrameCounter::Finished() {
}

// -----------------------------------------------------------------------
// Simpe Frame Counter
// Simple Frame Counter
// -----------------------------------------------------------------------

SimpleFrameCounter::SimpleFrameCounter(EventSystem& es,
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/graphics_object.cc
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@ void GraphicsObject::AddObjectMutator(std::unique_ptr<ObjectMutator> mutator) {
MakeImplUnique();

// If there's a currently running mutator that matches the incoming mutator,
// we ignore the incoming mutator. Kud Wafter's ED relies on this behaviour.
// we ignore the incoming mutator. Kud Wafter's ED relies on this behavior.
for (std::unique_ptr<ObjectMutator>& mutator_ptr : object_mutators_) {
if (mutator_ptr->OperationMatches(mutator->repr(), mutator->name())) {
return;
Expand Down
4 changes: 2 additions & 2 deletions src/systems/base/graphics_object.h
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ class GraphicsObject {
bool is_cleared() const { return impl_ == s_empty_impl; }

private:
// Makes the ineternal copy for our copy-on-write semantics. This function
// Makes the internal copy for our copy-on-write semantics. This function
// checks to see if our Impl object has only one reference to it. If it
// doesn't, a local copy is made.
void MakeImplUnique();
Expand All @@ -333,7 +333,7 @@ class GraphicsObject {

Impl& operator=(const Impl& rhs);

// Visiblitiy. Different from whether an object is in the bg or fg layer
// Visibility. Different from whether an object is in the bg or fg layer
bool visible_;

// The positional coordinates of the object
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/graphics_object_of_file.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ class GraphicsObjectOfFile : public GraphicsObjectData {
// The encapsulated surface to render
std::shared_ptr<const Surface> surface_;

// Number of miliseconds to spend on a single frame in the
// Number of milliseconds to spend on a single frame in the
// animation
unsigned int frame_time_;

Expand Down
3 changes: 2 additions & 1 deletion src/systems/base/graphics_system.cc
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ struct GraphicsSystem::GraphicsObjectSettings {
// Number of graphical objects in a layer.
int objects_in_a_layer;

// Each is a valid index into data, refering to
// Each is a valid index into data, associating each object slot with an
// ObjectSettings instance.
std::unique_ptr<unsigned char[]> position;

std::vector<ObjectSettings> data;
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/graphics_text_object.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class Surface;
class System;

// Represents the textual data made with commands such as obj_of_text,
// obj_set_text, obj_text_opts, et cetera.
// obj_set_text, obj_text_opts, etc.
class GraphicsTextObject : public GraphicsObjectData {
public:
explicit GraphicsTextObject(System& system);
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/hik_script.cc
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ HIKScript::Layer& HIKScript::CurrentLayer() {
HIKScript::Animation& HIKScript::CurrentAnimation() {
Layer& layer = CurrentLayer();
if (layer.animations.size() == 0) {
throw rlvm::Exception("Invalid unkowns reference");
throw rlvm::Exception("Invalid unknowns reference");
}

return layer.animations.back();
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/hik_script.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class HIKScript {
int frame_length_ms;
};

// The contents of the 30000 keys. I used to call this structure Unkowns;
// The contents of the 30000 keys. I used to call this structure Unknowns;
// "Animation" is a tentative name as it contains individual Frames that are
// played in sequence.
struct Animation {
Expand Down
6 changes: 3 additions & 3 deletions src/systems/base/ovk_voice_sample.cc
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ std::string oggErrorCodeToString(int code) {
case OV_FALSE:
return "Not true, or no data available";
case OV_HOLE:
return "Vorbisfile encoutered missing or corrupt data in the bitstream. "
return "Vorbisfile encountered missing or corrupt data in the bitstream. "
"Recovery is normally automatic and this return code is for "
"informational purposes only.";
case OV_EREAD:
Expand All @@ -103,7 +103,7 @@ std::string oggErrorCodeToString(int code) {
"supported.";
case OV_EBADLINK:
return "The given link exists in the Vorbis data stream, but is not "
"decipherable due to garbacge or corruption.";
"decipherable due to garbage or corruption.";
case OV_ENOSEEK:
return "The given stream is not seekable";
default:
Expand Down Expand Up @@ -153,7 +153,7 @@ char* OVKVoiceSample::Decode(int* size) {
int rate = vinfo->rate;
int channels = vinfo->channels;

// We start offseted from the beginning of the buffer since this is where the
// We start offsetted from the beginning of the buffer since this is where the
// WAV header will be placed.
int buffer_pos = WAV_HEADER_SIZE;
int buffer_size = INITSIZE;
Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/ovk_voice_sample.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class OVKVoiceSample : public VoiceSample {
// Creates a sample from a full .ogg |file|.
explicit OVKVoiceSample(boost::filesystem::path file);

// Creates a sample from an ogg file embeded in the archive at |file|.
// Creates a sample from an ogg file embedded in the archive at |file|.
OVKVoiceSample(boost::filesystem::path file, int offset, int length);
virtual ~OVKVoiceSample();

Expand Down
2 changes: 1 addition & 1 deletion src/systems/base/rect.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ class Rect {

bool is_empty() const { return origin_.is_empty() && size_.is_empty(); }

// Whether loc is inside this Rect.
// Whether |loc| is inside this Rect.
bool Contains(const Point& loc);

// Whether we intersect with |rhs|.
Expand Down
Loading

0 comments on commit ec6b3b7

Please sign in to comment.