Revision 860b0d604377d3635f6fa994993371399327129f authored by Tim Foley on 13 June 2018, 18:18:44 UTC, committed by GitHub on 13 June 2018, 18:18:44 UTC
PR #577 tries to eliminate empty `struct` types by replacing them with a `LegalType::tuple` with zero elements, but this seems to run into problems in some cases, where we end up trying to match up `::none` values with empty `::tuple`s. An alternative way to handle this is to never create empty `LegalType::tuple`s (and the same for `LegalVal::tuple`), and instead create `LegalType::none` and `LegalVal::none`. PR #577 avoided this because there were various cases in the legalization logic that didn't robustly handle `LegalType::Flavor::none`. This PR thus includes two main changes: 1. Construct a `::none` type when we have an empty `struct` type. 2. Survery all places that handle the `::tuple` case and extend them to handle the `::none` case if it was missing. This fixes an issue filed in Falcor's internal GitLab as number 424.
1 parent 167d857
File | Mode | Size |
---|---|---|
docs | ||
examples | ||
external | ||
source | ||
tests | ||
tools | ||
.editorconfig | -rw-r--r-- | 937 bytes |
.gitattributes | -rw-r--r-- | 95 bytes |
.gitignore | -rw-r--r-- | 398 bytes |
.gitmodules | -rw-r--r-- | 107 bytes |
.travis.yml | -rw-r--r-- | 1.6 KB |
CODE_OF_CONDUCT.md | -rw-r--r-- | 3.1 KB |
LICENSE | -rw-r--r-- | 1.1 KB |
Makefile | -rw-r--r-- | 6.3 KB |
README.md | -rw-r--r-- | 4.9 KB |
appveyor.yml | -rw-r--r-- | 3.5 KB |
premake5.lua | -rw-r--r-- | 20.1 KB |
slang.h | -rw-r--r-- | 42.1 KB |
slang.sln | -rw-r--r-- | 8.9 KB |
test.bat | -rw-r--r-- | 1.4 KB |
Computing file changes ...