Module: Mesa
Branch: master
Commit: da422663a6cacefcfae6be39154ab7598072cafa
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=da422663a6cacefcfae6be39154ab7598072cafa

Author: Jason Ekstrand <jason.ekstr...@intel.com>
Date:   Fri Mar 25 10:18:35 2016 -0700

nir: Add a variable_foreach_safe helper

Reviewed-by: Rob Clark <robdcl...@gmail.com>

---

 src/compiler/nir/nir.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/compiler/nir/nir.h b/src/compiler/nir/nir.h
index 37d2907..6bd871d 100644
--- a/src/compiler/nir/nir.h
+++ b/src/compiler/nir/nir.h
@@ -334,6 +334,9 @@ typedef struct nir_variable {
 #define nir_foreach_variable(var, var_list) \
    foreach_list_typed(nir_variable, var, node, var_list)
 
+#define nir_foreach_variable_safe(var, var_list) \
+   foreach_list_typed_safe(nir_variable, var, node, var_list)
+
 static inline bool
 nir_variable_is_global(const nir_variable *var)
 {

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to