<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>177568</bug_id>
          
          <creation_ts>2017-09-27 14:08:13 -0700</creation_ts>
          <short_desc>default_construct_at</short_desc>
          <delta_ts>2017-11-27 10:03:32 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Web Template Framework</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>177473</dup_id>
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=177473</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="JF Bastien">jfbastien</reporter>
          <assigned_to name="JF Bastien">jfbastien</assigned_to>
          <cc>benjamin</cc>
    
    <cc>buildbot</cc>
    
    <cc>cdumez</cc>
    
    <cc>cmarcelo</cc>
    
    <cc>darin</cc>
    
    <cc>dbates</cc>
    
    <cc>jfbastien</cc>
    
    <cc>jyasskin</cc>
    
    <cc>sam</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1353831</commentid>
    <comment_count>0</comment_count>
    <who name="JF Bastien">jfbastien</who>
    <bug_when>2017-09-27 14:08:13 -0700</bug_when>
    <thetext>https://bugs.webkit.org/show_bug.cgi?id=177473 has so pretty ugly code to default construct a generic ArrayPtr&lt;T&gt;:

  new (&amp;container.get()[i]) std::remove_reference_t&lt;decltype(*container.get())&gt;();

Let&apos;s add default_construct_at, which jyasskin suggested I do.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1353843</commentid>
    <comment_count>1</comment_count>
      <attachid>322015</attachid>
    <who name="JF Bastien">jfbastien</who>
    <bug_when>2017-09-27 14:10:33 -0700</bug_when>
    <thetext>Created attachment 322015
patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1353844</commentid>
    <comment_count>2</comment_count>
    <who name="Build Bot">buildbot</who>
    <bug_when>2017-09-27 14:12:08 -0700</bug_when>
    <thetext>Attachment 322015 did not pass style-queue:


ERROR: Source/WTF/wtf/StdLibExtras.h:164:  default_construct_at is incorrectly named. Don&apos;t use underscores in your identifier names.  [readability/naming/underscores] [4]
Total errors found: 1 in 2 files


If any of these errors are false positives, please file a bug against check-webkit-style.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1354210</commentid>
    <comment_count>3</comment_count>
    <who name="JF Bastien">jfbastien</who>
    <bug_when>2017-09-28 11:34:43 -0700</bug_when>
    <thetext>cdumez suggested I do this change straight in #177473 and use it there. Closing to do that instead.

*** This bug has been marked as a duplicate of bug 177473 ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1374248</commentid>
    <comment_count>4</comment_count>
      <attachid>322015</attachid>
    <who name="Darin Adler">darin</who>
    <bug_when>2017-11-22 11:30:00 -0800</bug_when>
    <thetext>Comment on attachment 322015
patch

Unlike the others who commented on this, I do think this might possibly make some call sites a little easier to read, and why not get on board now if it’s the future of C++ anyway. But I don’t think we should land the change without using it anywhere.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1374249</commentid>
    <comment_count>5</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2017-11-22 11:30:20 -0800</bug_when>
    <thetext>Oh, this bug is obsolete. Clearing the flags.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1374976</commentid>
    <comment_count>6</comment_count>
    <who name="JF Bastien">jfbastien</who>
    <bug_when>2017-11-27 10:03:32 -0800</bug_when>
    <thetext>(In reply to Darin Adler from comment #4)
&gt; Comment on attachment 322015 [details]
&gt; patch
&gt; 
&gt; Unlike the others who commented on this, I do think this might possibly make
&gt; some call sites a little easier to read, and why not get on board now if
&gt; it’s the future of C++ anyway. But I don’t think we should land the change
&gt; without using it anywhere.

I liked it too, it made the sample code way more readable, but it&apos;s admittedly a rare thing so I&apos;m happy not pushing it and leaving the obscure placement new code as-is.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>322015</attachid>
            <date>2017-09-27 14:10:33 -0700</date>
            <delta_ts>2017-11-22 11:30:35 -0800</delta_ts>
            <desc>patch</desc>
            <filename>0001-Add-default_construct_at.patch</filename>
            <type>text/plain</type>
            <size>1640</size>
            <attacher name="JF Bastien">jfbastien</attacher>
            
              <data encoding="base64">RnJvbSBkMjk3YWJjYjVmNzlkMzJlOTgzNzdiNzYxZTMxOWM2ZGI2ZWZkZGM5IE1vbiBTZXAgMTcg
MDA6MDA6MDAgMjAwMQpGcm9tOiBKRiBCYXN0aWVuIDxqZmJhc3RpZW5AYXBwbGUuY29tPgpEYXRl
OiBXZWQsIDI3IFNlcCAyMDE3IDE0OjEwOjA0IC0wNzAwClN1YmplY3Q6IFtQQVRDSF0gQWRkIGRl
ZmF1bHRfY29uc3RydWN0X2F0CgotLS0KIFNvdXJjZS9XVEYvQ2hhbmdlTG9nICAgICAgICAgIHwg
MTAgKysrKysrKysrKwogU291cmNlL1dURi93dGYvU3RkTGliRXh0cmFzLmggfCAgNyArKysrKysr
CiAyIGZpbGVzIGNoYW5nZWQsIDE3IGluc2VydGlvbnMoKykKCmRpZmYgLS1naXQgYS9Tb3VyY2Uv
V1RGL0NoYW5nZUxvZyBiL1NvdXJjZS9XVEYvQ2hhbmdlTG9nCmluZGV4IDYzZWFmODEuLmU1OTNi
NTggMTAwNjQ0Ci0tLSBhL1NvdXJjZS9XVEYvQ2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