1//===- DefSymParser.h -----------------------------------------------------===// 2// 3// The MCLinker Project 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9#ifndef MCLD_DEFSYM_PARSER_H 10#define MCLD_DEFSYM_PARSER_H 11 12#include <mcld/Module.h> 13#include <llvm/ADT/StringRef.h> 14 15namespace mcld { 16 17/** \class DefSymParser 18 * \brief DefSymParser parses --defsym option. 19 */ 20class DefSymParser 21{ 22public: 23 DefSymParser(const Module& pModule); 24 25 // parse a valid expression and set the value in the second parameter 26 bool parse(llvm::StringRef, uint64_t&); 27 28private: 29 const Module& m_Module; 30}; 31 32} // mcld 33 34#endif 35