diff options
author | Daniel Wirtz <dcode@dcode.io> | 2020-09-11 03:04:17 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-10 18:04:17 -0700 |
commit | 192757772adce7568fc1f3f3e733a4263b6392c6 (patch) | |
tree | 922fec8709cf9008d239a1fcbce7280e6ab46deb /src/binaryen-c.h | |
parent | cd6f0d908f0e4c68d72fd476a6e0e7cfb7ae8595 (diff) | |
download | binaryen-192757772adce7568fc1f3f3e733a4263b6392c6.tar.gz binaryen-192757772adce7568fc1f3f3e733a4263b6392c6.tar.bz2 binaryen-192757772adce7568fc1f3f3e733a4263b6392c6.zip |
Add anyref feature and type (#3109)
Adds `anyref` type, which is enabled by a new feature `--enable-anyref`. This type is primarily used for testing that passes correctly handle subtype relationships so that the codebase will continue to be prepared for future subtyping. Since `--enable-anyref` is meaningless without also using `--enable-reference-types`, this PR also makes it a validation error to pass only the former (and similarly makes it a validation error to enable exception handling without enabling reference types).
Diffstat (limited to 'src/binaryen-c.h')
-rw-r--r-- | src/binaryen-c.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/binaryen-c.h b/src/binaryen-c.h index beaf72499..e622419ac 100644 --- a/src/binaryen-c.h +++ b/src/binaryen-c.h @@ -101,6 +101,7 @@ BINARYEN_API BinaryenType BinaryenTypeVec128(void); BINARYEN_API BinaryenType BinaryenTypeFuncref(void); BINARYEN_API BinaryenType BinaryenTypeExternref(void); BINARYEN_API BinaryenType BinaryenTypeExnref(void); +BINARYEN_API BinaryenType BinaryenTypeAnyref(void); BINARYEN_API BinaryenType BinaryenTypeUnreachable(void); // Not a real type. Used as the last parameter to BinaryenBlock to let // the API figure out the type instead of providing one. @@ -196,6 +197,7 @@ BINARYEN_API BinaryenFeatures BinaryenFeatureExceptionHandling(void); BINARYEN_API BinaryenFeatures BinaryenFeatureTailCall(void); BINARYEN_API BinaryenFeatures BinaryenFeatureReferenceTypes(void); BINARYEN_API BinaryenFeatures BinaryenFeatureMultivalue(void); +BINARYEN_API BinaryenFeatures BinaryenFeatureAnyref(void); BINARYEN_API BinaryenFeatures BinaryenFeatureAll(void); // Modules |