[cxx-abi-dev] Mangling for noexcept operator

John McCall rjmccall at apple.com
Tue Sep 4 18:17:57 UTC 2012


On Sep 4, 2012, at 6:39 AM, Mike Herrick wrote:
> We don't seem to have a mangling for the new noexcept operator.  
> 
> How's this:
> 
>  <operator-name> ::= nx		# noexcept (an expression)
> 
> For example:
> 
>  void f(int) noexcept;
>  void f(float) throw (int);
>  template <class T> auto g(T p) -> decltype((int (*)[noexcept(f(p))])0);
>  int main() {
>    g(1);
>  }
> 
> Which would provide a mangled name of: _Z1gIiEDTcvPAnxcl1ffp_E_iLi0EET_ for g.

This seems like a fine mangling, but it shouldn't be an <operator-name>.
Let's just do:
  <expression> ::= nx <expression>

John.


More information about the cxx-abi-dev mailing list