diff options
author | David Shah <dave@ds0.me> | 2020-11-14 09:06:59 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-14 09:06:59 +0000 |
commit | b8d0e622fd6650b9d79920943aac5ac0fa363dd8 (patch) | |
tree | 1534a3662bfebe58f9afa4c7c43bd3008b69845a | |
parent | 319046fed73967004611213188098d3364faa5f2 (diff) | |
parent | 8686b6dada11881e6f75cff48dd74dad18835d42 (diff) | |
download | nextpnr-b8d0e622fd6650b9d79920943aac5ac0fa363dd8.tar.gz nextpnr-b8d0e622fd6650b9d79920943aac5ac0fa363dd8.tar.bz2 nextpnr-b8d0e622fd6650b9d79920943aac5ac0fa363dd8.zip |
Merge pull request #514 from YosysHQ/no-copy-relptr
RelPtr: remove copy constructor and copy assignment
-rw-r--r-- | ecp5/arch.h | 3 | ||||
-rw-r--r-- | ice40/arch.h | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/ecp5/arch.h b/ecp5/arch.h index ecf653fc..32dc31d6 100644 --- a/ecp5/arch.h +++ b/ecp5/arch.h @@ -45,6 +45,9 @@ template <typename T> struct RelPtr const T &operator*() const { return *(get()); } const T *operator->() const { return get(); } + + RelPtr(const RelPtr &) = delete; + RelPtr &operator=(const RelPtr &) = delete; }; NPNR_PACKED_STRUCT(struct BelWirePOD { diff --git a/ice40/arch.h b/ice40/arch.h index 02519252..1274a52a 100644 --- a/ice40/arch.h +++ b/ice40/arch.h @@ -41,6 +41,9 @@ template <typename T> struct RelPtr const T &operator*() const { return *(get()); } const T *operator->() const { return get(); } + + RelPtr(const RelPtr &) = delete; + RelPtr &operator=(const RelPtr &) = delete; }; NPNR_PACKED_STRUCT(struct BelWirePOD { |