summaryrefslogtreecommitdiff
path: root/include/lld/Core/File.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/lld/Core/File.h')
-rw-r--r--include/lld/Core/File.h24
1 files changed, 11 insertions, 13 deletions
diff --git a/include/lld/Core/File.h b/include/lld/Core/File.h
index 20418688dfa0b..54f533576a4b3 100644
--- a/include/lld/Core/File.h
+++ b/include/lld/Core/File.h
@@ -43,7 +43,7 @@ class File {
public:
virtual ~File();
- /// \brief Kinds of files that are supported.
+ /// Kinds of files that are supported.
enum Kind {
kindErrorObject, ///< a error object file (.o)
kindNormalizedObject, ///< a normalized file (.o)
@@ -59,7 +59,7 @@ public:
kindArchiveLibrary ///< archive (.a)
};
- /// \brief Returns file kind. Need for dyn_cast<> on File objects.
+ /// Returns file kind. Need for dyn_cast<> on File objects.
Kind kind() const {
return _kind;
}
@@ -114,10 +114,8 @@ public:
AtomRange(AtomVector<T> &v) : _v(v) {}
AtomRange(const AtomVector<T> &v) : _v(const_cast<AtomVector<T> &>(v)) {}
- typedef std::pointer_to_unary_function<const OwningAtomPtr<T>&,
- const T*> ConstDerefFn;
-
- typedef std::pointer_to_unary_function<OwningAtomPtr<T>&, T*> DerefFn;
+ using ConstDerefFn = const T* (*)(const OwningAtomPtr<T>&);
+ using DerefFn = T* (*)(OwningAtomPtr<T>&);
typedef llvm::mapped_iterator<typename AtomVector<T>::const_iterator,
ConstDerefFn> ConstItTy;
@@ -174,19 +172,19 @@ public:
AtomVector<T> &_v;
};
- /// \brief Must be implemented to return the AtomVector object for
+ /// Must be implemented to return the AtomVector object for
/// all DefinedAtoms in this File.
virtual const AtomRange<DefinedAtom> defined() const = 0;
- /// \brief Must be implemented to return the AtomVector object for
+ /// Must be implemented to return the AtomVector object for
/// all UndefinedAtomw in this File.
virtual const AtomRange<UndefinedAtom> undefined() const = 0;
- /// \brief Must be implemented to return the AtomVector object for
+ /// Must be implemented to return the AtomVector object for
/// all SharedLibraryAtoms in this File.
virtual const AtomRange<SharedLibraryAtom> sharedLibrary() const = 0;
- /// \brief Must be implemented to return the AtomVector object for
+ /// Must be implemented to return the AtomVector object for
/// all AbsoluteAtoms in this File.
virtual const AtomRange<AbsoluteAtom> absolute() const = 0;
@@ -196,7 +194,7 @@ public:
/// of a different file. We need to destruct all atoms before any files.
virtual void clearAtoms() = 0;
- /// \brief If a file is parsed using a different method than doParse(),
+ /// If a file is parsed using a different method than doParse(),
/// one must use this method to set the last error status, so that
/// doParse will not be called twice. Only YAML reader uses this
/// (because YAML reader does not read blobs but structured data).
@@ -214,12 +212,12 @@ public:
}
protected:
- /// \brief only subclasses of File can be instantiated
+ /// only subclasses of File can be instantiated
File(StringRef p, Kind kind)
: _path(p), _kind(kind), _ordinal(UINT64_MAX),
_nextAtomOrdinal(0) {}
- /// \brief Subclasses should override this method to parse the
+ /// Subclasses should override this method to parse the
/// memory buffer passed to this file's constructor.
virtual std::error_code doParse() { return std::error_code(); }