<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Functions with a return type of ExceptionOr&lt;String&gt; cannot &quot;return emptyString();&quot;"
   href="https://bugs.webkit.org/show_bug.cgi?id=165477#c4">Comment # 4</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Functions with a return type of ExceptionOr&lt;String&gt; cannot &quot;return emptyString();&quot;"
   href="https://bugs.webkit.org/show_bug.cgi?id=165477">bug 165477</a>
              from <span class="vcard"><a class="email" href="mailto:jer.noble&#64;apple.com" title="Jer Noble &lt;jer.noble&#64;apple.com&gt;"> <span class="fn">Jer Noble</span></a>
</span></b>
        <pre>(In reply to <a href="show_bug.cgi?id=165477#c2">comment #2</a>)
<span class="quote">&gt; Let me know if the workaround works or not.</span >

It does!

<span class="quote">&gt; I’m sure we can come up with a way to make the syntax more elegant if this
&gt; comes up a lot.</span >

I understand the motivation for not allowing &quot;initialization-by-copy-constructor&quot; by default, but I think this pattern may become more common. Enum values in WebIDL are turn into Strings in the bindings, and I've often defined &quot;static const String&amp; enumValue();&quot; methods in tho bound classes to represent each enumerated value. A getter that can either return an enum value or throw an exception will likely hit this quirk.  It may be worth it to make an exception (hah!) for ExceptionOr&lt;String&gt; or ExceptionOr&lt;AtomicString&gt;.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>