Reduce duplication in MCSymbol Name handling.  NFC>

Based on feedback to r239428 by David Blaikie, use const_cast to reduce
duplication of the const and non-const versions of getNameEntryPtr.

Also have that method return the pointer to the name directly instead
of users having to then get the name from the union.

Finally, add a FIXME that we should use a static_assert once available in
the new operator.

llvm-svn: 239429
diff --git a/llvm/lib/MC/MCSymbol.cpp b/llvm/lib/MC/MCSymbol.cpp
index a5097bc..f0f35f7 100644
--- a/llvm/lib/MC/MCSymbol.cpp
+++ b/llvm/lib/MC/MCSymbol.cpp
@@ -28,6 +28,7 @@
   // For safety, ensure that the alignment of a pointer is enough for an
   // MCSymbol.  This also ensures we don't need padding between the name and
   // symbol.
+  // FIXME: Use static_assert when constexpr is supported.
   assert(alignOf<MCSymbol>() <= alignOf<NameEntryStorageTy>() &&
          "Bad alignment of MCSymbol");
   void *Storage = Ctx.allocate(Size, alignOf<NameEntryStorageTy>());