[Mesa-dev] [Bug 59013] New: GLES2: definition of glShaderSource is not compliant with the specification

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Jan 3 23:45:12 PST 2013


https://bugs.freedesktop.org/show_bug.cgi?id=59013

          Priority: medium
            Bug ID: 59013
          Assignee: mesa-dev at lists.freedesktop.org
           Summary: GLES2: definition of glShaderSource is not compliant
                    with the specification
          Severity: normal
    Classification: Unclassified
                OS: All
          Reporter: SmSpillaz at gmail.com
          Hardware: Other
            Status: NEW
           Version: unspecified
         Component: Mesa core
           Product: Mesa

glShaderSource is defined in the GLES2 spec as so:

void glShaderSource(    GLuint shader,
     GLsizei count,
     const GLchar **string,
     const GLint *length);

However trunk mesa (and 9.1.0) has a definition like this:

GL_APICALL void         GL_APIENTRY glShaderSource (GLuint shader, GLsizei
count, const GLchar* const* string, const GLint* length);

The difference being const GLchar **string, vs const GLchar* const* string

That means that if you have a function pointer to glShaderSource using the old
definition, and assign the new function to it, it will fail to compile.

(And I know that code using function pointers to core functionality is insane,
but it is better than using ifdefs to switch between using function pointers
where that functionality is extension-only, and real function declarations
where it is core functionality)

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20130104/941d4ccf/attachment.html>


More information about the mesa-dev mailing list