Skip to content

Commit aaf8d6f

Browse files
committed
fix: Keep internal accessor slot unnamed, even after code transforms
1 parent 08fb40f commit aaf8d6f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

packages/typegpu/src/core/slot/accessor.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import {
2121
} from '../../types.ts';
2222
import { isTgpuFn } from '../function/tgpuFn.ts';
2323
import { getGpuValueRecursively, valueProxyHandler } from '../valueProxyUtils.ts';
24-
import { slot as slotConstructor } from './slot.ts';
24+
import { slot } from './slot.ts';
2525
import type { TgpuAccessor, TgpuMutableAccessor, TgpuSlot } from './slotTypes.ts';
2626

2727
// ----------
@@ -72,7 +72,7 @@ abstract class AccessorBase<
7272
this.defaultValue = defaultValue;
7373

7474
// NOTE: in certain setups, unplugin can run on package typegpu, so we have to avoid auto-naming triggering here
75-
this.slot = slotConstructor(defaultValue);
75+
this.slot = (() => slot(defaultValue))();
7676
this[$getNameForward] = this.slot;
7777
}
7878

0 commit comments

Comments
 (0)