Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(493)

Side by Side Diff: src/IceCfg.h

Issue 1343843003: Refactor all instances of `typedef y x` to the C++11 `using x = y` syntax. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/IceAssemblerX86Base.h ('k') | src/IceCfg.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceCfg.h - Control flow graph ----------------*- C++ -*-===// 1 //===- subzero/src/IceCfg.h - Control flow graph ----------------*- C++ -*-===//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 /// 9 ///
10 /// \file 10 /// \file
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 /// Create a node and append it to the end of the linearized list. The loop 89 /// Create a node and append it to the end of the linearized list. The loop
90 /// nest depth of the new node may not be valid if it is created after 90 /// nest depth of the new node may not be valid if it is created after
91 /// computeLoopNestDepth. 91 /// computeLoopNestDepth.
92 CfgNode *makeNode(); 92 CfgNode *makeNode();
93 SizeT getNumNodes() const { return Nodes.size(); } 93 SizeT getNumNodes() const { return Nodes.size(); }
94 const NodeList &getNodes() const { return Nodes; } 94 const NodeList &getNodes() const { return Nodes; }
95 /// Swap nodes of Cfg with given list of nodes. 95 /// Swap nodes of Cfg with given list of nodes.
96 void swapNodes(NodeList &NewNodes); 96 void swapNodes(NodeList &NewNodes);
97 /// @} 97 /// @}
98 98
99 typedef int32_t IdentifierIndexType; 99 using IdentifierIndexType = int32_t;
100 /// Adds a name to the list and returns its index, suitable for the 100 /// Adds a name to the list and returns its index, suitable for the
101 /// argument to getIdentifierName(). No checking for duplicates is 101 /// argument to getIdentifierName(). No checking for duplicates is
102 /// done. This is generally used for node names and variable names 102 /// done. This is generally used for node names and variable names
103 /// to avoid embedding a std::string inside an arena-allocated 103 /// to avoid embedding a std::string inside an arena-allocated
104 /// object. 104 /// object.
105 IdentifierIndexType addIdentifierName(const IceString &Name) { 105 IdentifierIndexType addIdentifierName(const IceString &Name) {
106 IdentifierIndexType Index = IdentifierNames.size(); 106 IdentifierIndexType Index = IdentifierNames.size();
107 IdentifierNames.push_back(Name); 107 IdentifierNames.push_back(Name);
108 return Index; 108 return Index;
109 } 109 }
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 /// other uses are possible. 288 /// other uses are possible.
289 ICE_TLS_DECLARE_FIELD(const Cfg *, CurrentCfg); 289 ICE_TLS_DECLARE_FIELD(const Cfg *, CurrentCfg);
290 290
291 public: 291 public:
292 static void TlsInit() { ICE_TLS_INIT_FIELD(CurrentCfg); } 292 static void TlsInit() { ICE_TLS_INIT_FIELD(CurrentCfg); }
293 }; 293 };
294 294
295 } // end of namespace Ice 295 } // end of namespace Ice
296 296
297 #endif // SUBZERO_SRC_ICECFG_H 297 #endif // SUBZERO_SRC_ICECFG_H
OLDNEW
« no previous file with comments | « src/IceAssemblerX86Base.h ('k') | src/IceCfg.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698