The next paragraph after that reads:

"To allow for distributed implementations, there may be several flag-code pairs. In this case, after a call to GetError returns a value other than NO ERROR each subsequent call returns the non-zero code of a distinct flag-code pair (in unspecified order), until all non-NO ERROR codes have been returned." 

Also as per the spec, we only record the most recent GL error, see here: https://github.com/kripken/emscripten/blob/master/src/library_gl.js#L65 so there does not exist a queue of errors, but only a fixed field of two errors, one from the Emscripten GL layer and another from the browser itself. I still think our implementation should be correct to the spec.