[Mesa-dev] [PATCH 1/7] nir: Add a void type

Kenneth Graunke kenneth at whitecape.org
Thu Jan 29 16:13:20 PST 2015


On Thursday, January 29, 2015 12:50:16 PM Jason Ekstrand wrote:
> This allows us to indicate a concept of an invalid type.
> ---
>  src/glsl/nir/nir.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/src/glsl/nir/nir.h b/src/glsl/nir/nir.h
> index 980fdd0..f2050de 100644
> --- a/src/glsl/nir/nir.h
> +++ b/src/glsl/nir/nir.h
> @@ -576,6 +576,7 @@ void nir_alu_dest_copy(nir_alu_dest *dest, const nir_alu_dest *src,
>                         void *mem_ctx);
>  
>  typedef enum {
> +   nir_type_void = 0, /* Not a valid type */
>     nir_type_float,
>     nir_type_int,
>     nir_type_unsigned,

I think it would be clearer to call this nir_type_invalid, since "void" is a
real type in source languages.

--Ken
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20150129/2359d9b7/attachment.sig>


More information about the mesa-dev mailing list