diff options
author | Chris Lattner <sabre@nondot.org> | 2001-07-22 00:18:10 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2001-07-22 00:18:10 +0000 |
commit | 7ac1040ecefd90e9d45358ee63b9f0761ca36846 (patch) | |
tree | be573e55bc91c2f42a695855c11afa6082edc17e /include/llvm/Support/StringUtils.h | |
parent | 68498cefe602bf5364168b4acd0bd5806cdd72ec (diff) | |
download | external_llvm-7ac1040ecefd90e9d45358ee63b9f0761ca36846.zip external_llvm-7ac1040ecefd90e9d45358ee63b9f0761ca36846.tar.gz external_llvm-7ac1040ecefd90e9d45358ee63b9f0761ca36846.tar.bz2 |
Destroy the StringUtils.h file
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@262 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/StringUtils.h')
-rw-r--r-- | include/llvm/Support/StringUtils.h | 75 |
1 files changed, 0 insertions, 75 deletions
diff --git a/include/llvm/Support/StringUtils.h b/include/llvm/Support/StringUtils.h deleted file mode 100644 index db42964..0000000 --- a/include/llvm/Support/StringUtils.h +++ /dev/null @@ -1,75 +0,0 @@ -// $Id$ -*-c++-*- -//*************************************************************************** -// -// File: -// ProgramOptions.h -// -// Purpose: -// A representation of options for any program. -// -// History: -// 08/08/95 - adve - Created in the dHPF compiler -// 10/10/96 - mpal, dbaker - converted to const member functions. -// 10/19/96 - meven - slightly changed interface to accomodate -// arguments other than -X type options -// 07/15/01 - vadve - Copied to LLVM system and modified -// -//**************************************************************************/ - -#ifndef LLVM_SUPPORT_PROGRAMOPTIONS_h -#define LLVM_SUPPORT_PROGRAMOPTIONS_h - -//************************** System Include Files **************************/ - -#include <string> -#include <hash_map> - -//*************************** User Include Files ***************************/ - -#include "llvm/Support/Unique.h" -class ProgramOption; - -//************************ Forward Declarations ****************************/ - -//***************************** String Functions ****************************/ - -struct eqstr -{ - bool operator()(const char* s1, const char* s2) const - { - return strcmp(s1, s2) == 0; - } -}; - -//***************************** String Classes *****************************/ - -template <class DataType> -class StringMap: - public hash_map<const char*, DataType, hash<const char*>, eqstr> -{ -public: - typedef hash_map<const char*, DataType, hash<const char*>, eqstr>::iterator - iterator; - typedef hash_map<const char*, DataType, hash<const char*>, eqstr>::const_iterator - const_iterator; - -public: - DataType* query(const char* _key) - { - hash_map<const char*, DataType, hash<const char*>, eqstr>::iterator - hashPair = this->find(_key); - return (hashPair == this->end())? NULL : & (*hashPair).second; - } - - const DataType* query(const char* _key) const - { - hash_map<const char*, DataType, hash<const char*>, eqstr>::const_iterator - hashPair = this->find(_key); - return (hashPair == this->end())? NULL : & (*hashPair).second; - } -}; - -//**************************************************************************/ - -#endif - |