Use shared_ptr and references for Actions.

This slows terminal emulation slightly.
This commit is contained in:
John Hood
2017-05-11 01:22:12 -04:00
parent c6c7f09954
commit 42d2b5d029
13 changed files with 104 additions and 113 deletions
+4 -1
View File
@@ -36,6 +36,8 @@
#include <string>
#include <vector>
#include "shared.h"
namespace Terminal {
class Emulator;
}
@@ -59,7 +61,8 @@ namespace Parser {
virtual bool operator==( const Action &other ) const;
};
typedef std::vector<Action *> Actions;
typedef shared::shared_ptr<Action> ActionPointer;
typedef std::vector<ActionPointer> Actions;
class Ignore : public Action {
public: