mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-15 05:24:01 +00:00
Fold the useful features of alist and alist_node into ilist, and
a new ilist_node class, and remove them. Unlike alist_node, ilist_node doesn't attempt to manage storage itself, so it avoids the associated problems, including being opaque in gdb. Adjust the Recycler class so that it doesn't depend on alist_node. Also, change it to use explicit Size and Align parameters, allowing it to work when the largest-sized node doesn't have the greatest alignment requirement. Change MachineInstr's MachineMemOperand list from a pool-backed alist to a std::list for now. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54146 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -18,6 +18,7 @@
|
||||
#define LLVM_BITCODE_ARCHIVE_H
|
||||
|
||||
#include "llvm/ADT/ilist.h"
|
||||
#include "llvm/ADT/ilist_node.h"
|
||||
#include "llvm/System/Path.h"
|
||||
#include <map>
|
||||
#include <set>
|
||||
@ -39,7 +40,7 @@ class ArchiveMemberHeader; // Internal implementation class
|
||||
/// construct ArchiveMember instances. You should obtain them from the methods
|
||||
/// of the Archive class instead.
|
||||
/// @brief This class represents a single archive member.
|
||||
class ArchiveMember {
|
||||
class ArchiveMember : public ilist_node<ArchiveMember> {
|
||||
/// @name Types
|
||||
/// @{
|
||||
public:
|
||||
@ -164,23 +165,10 @@ class ArchiveMember {
|
||||
/// @brief Replace contents of archive member with a new file.
|
||||
bool replaceWith(const sys::Path &aFile, std::string* ErrMsg);
|
||||
|
||||
/// @}
|
||||
/// @name ilist methods - do not use
|
||||
/// @{
|
||||
public:
|
||||
const ArchiveMember *getNext() const { return next; }
|
||||
const ArchiveMember *getPrev() const { return prev; }
|
||||
ArchiveMember *getNext() { return next; }
|
||||
ArchiveMember *getPrev() { return prev; }
|
||||
void setPrev(ArchiveMember* p) { prev = p; }
|
||||
void setNext(ArchiveMember* n) { next = n; }
|
||||
|
||||
/// @}
|
||||
/// @name Data
|
||||
/// @{
|
||||
private:
|
||||
ArchiveMember* next; ///< Pointer to next archive member
|
||||
ArchiveMember* prev; ///< Pointer to previous archive member
|
||||
Archive* parent; ///< Pointer to parent archive
|
||||
sys::PathWithStatus path; ///< Path of file containing the member
|
||||
sys::FileStatus info; ///< Status info (size,mode,date)
|
||||
|
Reference in New Issue
Block a user