<?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>157148</bug_id>
          
          <creation_ts>2016-04-28 13:13:11 -0700</creation_ts>
          <short_desc>Assertion failure when accessing static class getter named &quot;name&quot;</short_desc>
          <delta_ts>2020-08-22 14:25:00 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>JavaScriptCore</component>
          <version>WebKit Local Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>179734</dup_id>
          
          <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="André Bargull">andre.bargull</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ashvayka</cc>
    
    <cc>ggaren</cc>
    
    <cc>gskachkov</cc>
    
    <cc>saam</cc>
    
    <cc>ysuzuki</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1188357</commentid>
    <comment_count>0</comment_count>
    <who name="André Bargull">andre.bargull</who>
    <bug_when>2016-04-28 13:13:11 -0700</bug_when>
    <thetext>SVN: rev200124
Build with: perl Tools/Scripts/build-jsc --gtk --debug


The following test case triggers this assertion error:
---
ASSERTION FAILED: !(attributes &amp; ReadOnly)
---


Test case:
---
(class c { static get name(){ } }).name
---


Stack trace:
---
#0  0x00007ffff6e289ac in WTFCrash () at ../../Source/WTF/wtf/Assertions.cpp:322
#1  0x000000000044cddf in JSC::JSObject::putDirectInternal&lt;(JSC::JSObject::PutMode)1&gt; (this=0x7fffaedbf580, vm=..., propertyName=..., value=..., attributes=6, slot=...)
    at ../../Source/JavaScriptCore/runtime/JSObject.h:1380
#2  0x00000000004461bd in JSC::JSObject::putDirect (this=0x7fffaedbf580, vm=..., propertyName=..., value=..., attributes=6) at ../../Source/JavaScriptCore/runtime/JSObject.h:1524
#3  0x00007ffff6bf47ce in JSC::JSFunction::reifyName (this=0x7fffaedbf580, exec=0x7fffffffcb60, name=...) at ../../Source/JavaScriptCore/runtime/JSFunction.cpp:630
#4  0x00007ffff6bf456a in JSC::JSFunction::reifyName (this=0x7fffaedbf580, exec=0x7fffffffcb60) at ../../Source/JavaScriptCore/runtime/JSFunction.cpp:612
#5  0x00007ffff6bf48fc in JSC::JSFunction::reifyLazyPropertyIfNeeded (this=0x7fffaedbf580, exec=0x7fffffffcb60, propertyName=...) at ../../Source/JavaScriptCore/runtime/JSFunction.cpp:641
#6  0x00007ffff6bf2dcc in JSC::JSFunction::getOwnPropertySlot (object=0x7fffaedbf580, exec=0x7fffffffcb60, propertyName=..., slot=...) at ../../Source/JavaScriptCore/runtime/JSFunction.cpp:395
#7  0x0000000000445d94 in JSC::JSObject::getNonIndexPropertySlot (this=0x7fffaedbf580, exec=0x7fffffffcb60, propertyName=..., slot=...) at ../../Source/JavaScriptCore/runtime/JSObject.h:1320
#8  0x0000000000445919 in JSC::JSObject::getPropertySlot (this=0x7fffaedbf580, exec=0x7fffffffcb60, propertyName=..., slot=...) at ../../Source/JavaScriptCore/runtime/JSObject.h:1262
#9  0x0000000000448de4 in JSC::JSValue::getPropertySlot (this=0x7fffffffc9c0, exec=0x7fffffffcb60, propertyName=..., slot=...) at ../../Source/JavaScriptCore/runtime/JSCJSValueInlines.h:785
#10 0x0000000000448ce0 in JSC::JSValue::get (this=0x7fffffffc9c0, exec=0x7fffffffcb60, propertyName=..., slot=...) at ../../Source/JavaScriptCore/runtime/JSCJSValueInlines.h:767
#11 0x00007ffff6a23ed4 in JSC::(anonymous namespace)::llint_slow_path_get_by_id (exec=0x7fffffffcb60, pc=0x7fffae9f3590) at ../../Source/JavaScriptCore/llint/LLIntSlowPaths.cpp:569
#12 0x00007ffff6a30587 in llint_entry () at ../../Source/JavaScriptCore/runtime/JSCJSValueInlines.h:1037
#13 0x00007ffff6a2d895 in vmEntryToJavaScript () at ../../Source/JavaScriptCore/runtime/JSCJSValueInlines.h:1037
#14 0x00007ffff69d46d2 in JSC::JITCode::execute (this=0x7ffff0d9c640, vm=0x7fffb09f1000, protoCallFrame=0x7fffffffcd30) at ../../Source/JavaScriptCore/jit/JITCode.cpp:80
#15 0x00007ffff6997f4f in JSC::Interpreter::execute (this=0x7ffff0def058, program=0x7fffaedfbf70, callFrame=0x7fffaede7940, thisObj=0x7fffaedba360)
    at ../../Source/JavaScriptCore/interpreter/Interpreter.cpp:960
#16 0x00007ffff6b849ad in JSC::evaluate (exec=0x7fffaede7940, source=..., thisValue=..., returnedException=...) at ../../Source/JavaScriptCore/runtime/Completion.cpp:106
#17 0x000000000043a120 in runInteractive (globalObject=0x7fffaede7900) at ../../Source/JavaScriptCore/jsc.cpp:2083
#18 0x000000000043abcb in runJSC (vm=0x7fffb09f1000, options=...) at ../../Source/JavaScriptCore/jsc.cpp:2244
#19 0x000000000043b0a1 in jscmain (argc=1, argv=0x7fffffffdbb8) at ../../Source/JavaScriptCore/jsc.cpp:2293
#20 0x000000000043967f in main (argc=1, argv=0x7fffffffdbb8) at ../../Source/JavaScriptCore/jsc.cpp:1947
---</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1196700</commentid>
    <comment_count>1</comment_count>
    <who name="Yusuke Suzuki">ysuzuki</who>
    <bug_when>2016-05-26 05:31:56 -0700</bug_when>
    <thetext>We performed putDirect for static members, but in that case, we don&apos;t consider about non-JSObject cases (in this case, it is JSFunction). Then, we put &quot;name&quot; field forcefully.
So later, JSFunction reify its &quot;name&quot; field, and fail.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1402379</commentid>
    <comment_count>2</comment_count>
    <who name="André Bargull">andre.bargull</who>
    <bug_when>2018-02-27 12:03:31 -0800</bug_when>
    <thetext>Test case no longer reproduces at r228977.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1682171</commentid>
    <comment_count>3</comment_count>
    <who name="Alexey Shvayka">ashvayka</who>
    <bug_when>2020-08-22 14:25:00 -0700</bug_when>
    <thetext>(In reply to André Bargull from comment #0)
&gt; Test case:
&gt; ---
&gt; (class c { static get name(){ } }).name
&gt; ---

(In reply to André Bargull from comment #2)
&gt; Test case no longer reproduces at r228977.

No reproduction at r265669 either.
According to the ChangeLog, it was fixed in r224927.
Test coverage: JSTests/stress/class-static-get-weird.js

*** This bug has been marked as a duplicate of bug 179734 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>