Closed GoogleCodeExporter closed 9 years ago
This is likely a spec bug. See
https://cvs.khronos.org/bugzilla/show_bug.cgi?id=8656 (auth required)
Original comment by dan...@transgaming.com
on 28 Feb 2012 at 1:34
Original comment by dan...@transgaming.com
on 5 Mar 2012 at 3:42
Original comment by nicolas....@gmail.com
on 8 Mar 2012 at 9:28
There is an apparent spec contradiction between the the grammar rules (on
p.174) and the spec language in p.34.
Based on discussions with the various spec authors, the general consensus is
that that the line 'k=k+3' should fail as a redeclaration. The grammar is
correct in this case, and the body text "A function body has a scope nested
inside the function’s definition." is suspect. If that is taken to mean that
a function definition defines at least two scopes, then it is definitely wrong.
This is because function_prototype already begins a new scope (for the function
parameter names). There is nesting occurring, but it starts between the
function name and the parameter list, not between the parameter list and the
function body.
Hopefully there will be eventual spec clarifications.
Closing as wontfix since we currently implement the desired behaviour.
Original comment by dan...@transgaming.com
on 21 Mar 2012 at 6:42
Excellent. Thank you. I will fix my code to meet the projected spec change.
Original comment by kosmo...@gmail.com
on 22 Mar 2012 at 3:08
Original issue reported on code.google.com by
kosmo...@gmail.com
on 23 Nov 2011 at 11:22