[Mesa-dev] [PATCH 3/9] dispatch: properly handle parameter name mismatches in glapitemp.h.

Chad Versace chad.versace at linux.intel.com
Wed Oct 31 15:04:14 PDT 2012


On 10/30/2012 10:42 AM, Paul Berry wrote:
> Previously, when code-generating aliased functions in glapitemp.h, we
> weren't consistent about which function alias we used to obtain the
> parameter names, with the risk that we would generate incorrect code
> like this:
> 
>   KEYWORD1 void KEYWORD2 NAME(Foo)(GLint x)
>   {
>     (void) x;
>     DISPATCH(Foo, (x), (F, "glFoo(%d);\n", x));
>   }
>   KEYWORD1 void KEYWORD2 NAME(FooEXT)(GLint y)
>   {
>     (void) x;
>     DISPATCH(Foo, (x), (F, "glFooEXT(%d);\n", x));
>   }
> 
> At the moment there are no aliased functions with mismatched parameter
> names, so this isn't the problem.  But when we introduce GLES1
> functions into the dispatch table, there will be
> (MapBufferRange/MapBufferRangeEXT).  This patch paves the way for that
> by fixing the code generation script to handle the mismatch correctly.
> ---
>  src/mapi/glapi/gen/gl_XML.py     | 7 +++++--
>  src/mapi/glapi/gen/gl_apitemp.py | 2 +-
>  2 files changed, 6 insertions(+), 3 deletions(-)

Reviewed-by: Chad Versace <chad.versace at linux.intel.com>




More information about the mesa-dev mailing list