File tree 3 files changed +11
-11
lines changed 3 files changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -385,11 +385,11 @@ ClangDocContext::ClangDocContext(tooling::ExecutionContext *ECtx,
385
385
}
386
386
387
387
void ScopeChildren::sort () {
388
- std ::sort (Namespaces.begin (), Namespaces.end ());
389
- std ::sort (Records.begin (), Records.end ());
390
- std ::sort (Functions.begin (), Functions.end ());
391
- std ::sort (Enums.begin (), Enums.end ());
392
- std ::sort (Typedefs.begin (), Typedefs.end ());
388
+ llvm ::sort (Namespaces.begin (), Namespaces.end ());
389
+ llvm ::sort (Records.begin (), Records.end ());
390
+ llvm ::sort (Functions.begin (), Functions.end ());
391
+ llvm ::sort (Enums.begin (), Enums.end ());
392
+ llvm ::sort (Typedefs.begin (), Typedefs.end ());
393
393
}
394
394
} // namespace doc
395
395
} // namespace clang
Original file line number Diff line number Diff line change @@ -104,9 +104,7 @@ struct Reference {
104
104
105
105
bool mergeable (const Reference &Other);
106
106
void merge (Reference &&I);
107
- bool operator <(const Reference &Other) const {
108
- return llvm::toStringRef (USR) < llvm::toStringRef (Other.USR );
109
- }
107
+ bool operator <(const Reference &Other) const { return Name < Other.Name ; }
110
108
111
109
// / Returns the path for this Reference relative to CurrentPath.
112
110
llvm::SmallString<64 > getRelativeFilePath (const StringRef &CurrentPath) const ;
@@ -327,7 +325,7 @@ struct SymbolInfo : public Info {
327
325
if (Loc.size () > 0 && Other.Loc .size () > 0 ) {
328
326
return Loc[0 ] < Other.Loc [0 ];
329
327
}
330
- return llvm::toStringRef (USR ) < llvm::toStringRef ( Other.USR );
328
+ return extractName ( ) < Other.extractName ( );
331
329
}
332
330
};
333
331
Original file line number Diff line number Diff line change @@ -272,14 +272,16 @@ namespace AnotherNamespace {
272
272
// HTML-GLOBAL-INDEX: <h1>Global Namespace</h1>
273
273
// HTML-GLOBAL-INDEX: <h2 id="Namespaces">Namespaces</h2>
274
274
// HTML-GLOBAL-INDEX: <li>@nonymous_namespace</li>
275
- // HTML-GLOBAL-INDEX: <li>PrimaryNamespace</li>
276
275
// HTML-GLOBAL-INDEX: <li>AnotherNamespace</li>
276
+ // HTML-GLOBAL-INDEX: <li>PrimaryNamespace</li>
277
+
277
278
278
279
// MD-GLOBAL-INDEX: # Global Namespace
279
280
// MD-GLOBAL-INDEX: ## Namespaces
280
281
// MD-GLOBAL-INDEX: * [@nonymous_namespace](..{{[\/]}}@nonymous_namespace{{[\/]}}index.md)
281
- // MD-GLOBAL-INDEX: * [PrimaryNamespace](..{{[\/]}}PrimaryNamespace{{[\/]}}index.md)
282
282
// MD-GLOBAL-INDEX: * [AnotherNamespace](..{{[\/]}}AnotherNamespace{{[\/]}}index.md)
283
+ // MD-GLOBAL-INDEX: * [PrimaryNamespace](..{{[\/]}}PrimaryNamespace{{[\/]}}index.md)
284
+
283
285
284
286
// MD-ALL-FILES: # All Files
285
287
// MD-ALL-FILES: ## [@nonymous_namespace](@nonymous_namespace{{[\/]}}index.md)
You can’t perform that action at this time.
0 commit comments