From 54c005f465105459d60aafe04d0335d1a9d38ef6 Mon Sep 17 00:00:00 2001 From: Anton Korobeynikov Date: Thu, 20 Dec 2007 01:30:27 +0000 Subject: [PATCH] More eye-candy stuff :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45247 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/ADT/Trie.h | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/include/llvm/ADT/Trie.h b/include/llvm/ADT/Trie.h index 0770f0f36c6..47a3f4d59fd 100644 --- a/include/llvm/ADT/Trie.h +++ b/include/llvm/ADT/Trie.h @@ -147,7 +147,7 @@ public: inline const Node* &front() const { return Children.front(); } inline Node* &front() { return Children.front(); } inline const Node* &back() const { return Children.back(); } - inline Node* &back() { return Children.back(); } + inline Node* &back() { return Children.back(); } }; @@ -275,26 +275,21 @@ const Payload& Trie::lookup(const std::string& s) const { template struct GraphTraits > { - typedef typename Trie::Node NodeType; - typedef typename Trie::Node::iterator ChildIteratorType; + typedef Trie TrieType; + typedef typename TrieType::Node NodeType; + typedef typename NodeType::iterator ChildIteratorType; - static inline NodeType *getEntryNode(const Trie& T) { - return T.getRoot(); - } + static inline NodeType *getEntryNode(const TrieType& T) { return T.getRoot(); } - static inline ChildIteratorType child_begin(NodeType *N) { - return N->begin(); - } - static inline ChildIteratorType child_end(NodeType *N) { - return N->end(); - } + static inline ChildIteratorType child_begin(NodeType *N) { return N->begin(); } + static inline ChildIteratorType child_end(NodeType *N) { return N->end(); } typedef typename std::vector::const_iterator nodes_iterator; - static inline nodes_iterator nodes_begin(const Trie& G) { + static inline nodes_iterator nodes_begin(const TrieType& G) { return G.Nodes.begin(); } - static inline nodes_iterator nodes_end(const Trie& G) { + static inline nodes_iterator nodes_end(const TrieType& G) { return G.Nodes.end(); } -- 2.11.0