http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47693

           Summary: warning flag for emission of vague linkage bits
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: c++
        AssignedTo: unassig...@gcc.gnu.org
        ReportedBy: b...@gcc.gnu.org


Request for -Wvague-linkage. 

This flag would warn for the lack of key function, etc that makes
typeinfo/vtable information emitted in every TU for polymorphic classes

  class regex_error
  : public std::runtime_error
  {
  public:
    explicit
    regex_error(regex_constants::error_type __ecode)
    : std::runtime_error("regex_error"), _M_code(__ecode)
    { }

    regex_constants::error_type
    code() const
    { return _M_code; }

  protected:
    regex_constants::error_type _M_code;
  };


It's hard to scan through the libstdc++ sources for other places where
maintainers might want to know exact linkage. However, the compiler already
knows this.

Reply via email to