diff options
Diffstat (limited to 'lld/ELF/Relocations.h')
-rw-r--r-- | lld/ELF/Relocations.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lld/ELF/Relocations.h b/lld/ELF/Relocations.h index 0ff02ef1c7c..bac52764bc5 100644 --- a/lld/ELF/Relocations.h +++ b/lld/ELF/Relocations.h @@ -75,6 +75,16 @@ template <class ELFT> void scanRelocations(InputSection<ELFT> &); template <class ELFT> void scanRelocations(InputSectionBase<ELFT> &, const typename ELFT::Shdr &); + +template <class ELFT> +static inline typename ELFT::uint getAddend(const typename ELFT::Rel &Rel) { + return 0; +} + +template <class ELFT> +static inline typename ELFT::uint getAddend(const typename ELFT::Rela &Rel) { + return Rel.r_addend; +} } } |