1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-01 16:33:37 +01:00
llvm-mirror/lib/MC/MCParser/MCAsmLexer.cpp
Daniel Dunbar 2be7d27677 MC: Move getLoc() to MCAsmLexer().
llvm-svn: 108154
2010-07-12 17:10:00 +00:00

28 lines
715 B
C++

//===-- MCAsmLexer.cpp - Abstract Asm Lexer Interface ---------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#include "llvm/MC/MCParser/MCAsmLexer.h"
#include "llvm/Support/SourceMgr.h"
using namespace llvm;
MCAsmLexer::MCAsmLexer() : CurTok(AsmToken::Error, StringRef()), TokStart(0) {
}
MCAsmLexer::~MCAsmLexer() {
}
SMLoc MCAsmLexer::getLoc() const {
return SMLoc::getFromPointer(TokStart);
}
SMLoc AsmToken::getLoc() const {
return SMLoc::getFromPointer(Str.data());
}