[Webkit-unassigned] [Bug 193550] New: [WHLSL] Fix the combination of setters and post-{increment/decrement}

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jan 17 12:56:02 PST 2019


            Bug ID: 193550
           Summary: [WHLSL] Fix the combination of setters and
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebGPU
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: rmorisset at apple.com

The reference implementation currently behaves really weirdly on post-incrementing a field of a struct with an overriden setter (and getter).
It correctly uses the getter for having the current value, increment it, uses the setter for updating it.. but somehow returns the new value instead of the old one.
I believe this is a bug in the reference implementation.

struct Foo {
  int z;
int operator.w(Foo foo) {
  return 8;
Foo operator.w=(Foo foo, int value) {
  foo.z = value;
return foo;
int bar() {
  Foo foo;
  foo.z = 3;
  int value = foo.w++;
  return value*100 + foo.z*10 + foo.w;
Calling bar() return 998 instead of 898 as I would expect.

You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20190117/90ddc6e9/attachment-0001.html>

More information about the webkit-unassigned mailing list