forked from jasder/antlr
A few small corrections after the previous merge.
This commit is contained in:
parent
ef247f1939
commit
91a7657d73
|
@ -39,9 +39,8 @@ using namespace antlr4::atn;
|
|||
using namespace antlr4::misc;
|
||||
|
||||
const Ref<LexerMoreAction> LexerMoreAction::getInstance() {
|
||||
static Ref<LexerMoreAction> instance = std::shared_ptr<LexerMoreAction>(
|
||||
new LexerMoreAction());
|
||||
return instance;
|
||||
static Ref<LexerMoreAction> instance(new LexerMoreAction());
|
||||
return instance;
|
||||
}
|
||||
|
||||
LexerMoreAction::LexerMoreAction() {
|
||||
|
|
|
@ -39,8 +39,7 @@ using namespace antlr4::atn;
|
|||
using namespace antlr4::misc;
|
||||
|
||||
const Ref<LexerPopModeAction> LexerPopModeAction::getInstance() {
|
||||
static Ref<LexerPopModeAction> instance = std::shared_ptr<LexerPopModeAction>(
|
||||
new LexerPopModeAction());
|
||||
static Ref<LexerPopModeAction> instance(new LexerPopModeAction());
|
||||
return instance;
|
||||
}
|
||||
|
||||
|
|
|
@ -34,8 +34,6 @@
|
|||
#include "atn/LexerAction.h"
|
||||
#include "atn/LexerActionType.h"
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace antlr4 {
|
||||
namespace atn {
|
||||
|
||||
|
|
|
@ -39,8 +39,7 @@ using namespace antlr4::atn;
|
|||
using namespace antlr4::misc;
|
||||
|
||||
const Ref<LexerSkipAction> LexerSkipAction::getInstance() {
|
||||
static Ref<LexerSkipAction> instance = std::shared_ptr<LexerSkipAction>(
|
||||
new LexerSkipAction());
|
||||
static Ref<LexerSkipAction> instance(new LexerSkipAction());
|
||||
return instance;
|
||||
}
|
||||
|
||||
|
@ -61,11 +60,11 @@ void LexerSkipAction::execute(Lexer *lexer) {
|
|||
|
||||
size_t LexerSkipAction::hashCode() const {
|
||||
size_t hash = MurmurHash::initialize();
|
||||
hash = MurmurHash::update(hash, (size_t) getActionType());
|
||||
hash = MurmurHash::update(hash, (size_t)getActionType());
|
||||
return MurmurHash::finish(hash, 1);
|
||||
}
|
||||
|
||||
bool LexerSkipAction::operator ==(const LexerAction &obj) const {
|
||||
bool LexerSkipAction::operator == (const LexerAction &obj) const {
|
||||
return &obj == this;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue