BabylonJS / BabylonJS/BabylonNative

Shader with a variable called `new` will fail when running with Metal

Open
#1,355 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
C++
Stars
919
Forks
162
Avg merge
1d 15h
Merged PRs (30d)
19

Description

Shader with a variable called `new` will fail when running with Metal because Metal is based on C++14 and `new` is a keyword even though it is restricted.

See https://developer.apple.com/metal/Metal-Shading-Language-Specification.pdf

```
1.4.4
Restrictions
The following C++14 features are not available in Metal (section numbers in this list refer to the
C++14 Specification):
...
• new and delete operators (sections 5.3.4 and 5.3.5)
...
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.