[PATCH] D39394: Do not consider Shared symbols as defined symbols.

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 27 16:05:42 PDT 2017


ruiu created this revision.
Herald added a subscriber: emaste.

I don't remember why I made shared symbols one type of defined symbols.
Shared symbols aren't undefined, so it could be considered defined, but
categorizing three symbols as:

- defined
  - really defined
  - shared
- undefined

is not as intuitive as

- defined
- shared
- undefined

to me. So, in this patch, I made a change to stop handling shared
symbols as defined symbols.

Surprisingly, I didn't have to update any tests for this change.


https://reviews.llvm.org/D39394

Files:
  lld/ELF/Symbols.h


Index: lld/ELF/Symbols.h
===================================================================
--- lld/ELF/Symbols.h
+++ lld/ELF/Symbols.h
@@ -42,9 +42,9 @@
   enum Kind {
     DefinedFirst,
     DefinedRegularKind = DefinedFirst,
-    SharedKind,
     DefinedCommonKind,
     DefinedLast = DefinedCommonKind,
+    SharedKind,
     UndefinedKind,
     LazyArchiveKind,
     LazyObjectKind,


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39394.120715.patch
Type: text/x-patch
Size: 388 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171027/976ee35c/attachment.bin>


More information about the llvm-commits mailing list