compiler bug in R10B-5

Fredrik Thulin <>
Fri Jun 17 11:28:09 CEST 2005


A friend of mine found this to me unexplainable compiler bug. It would 
be interesting to hear a few words about the cause, besides getting it 
fixed ;)

$ /pkg/erlang/R10B-5/bin/erlc bug.erl
Function pstnproxy_add_headers/2 refers to undefined label 6
./bug.erl:none: internal error in beam_clean;
crash reason: {{case_clause,{'EXIT',{undefined_label,6}}},

Trevlig helg / have a nice weekend

-------------- next part --------------


-record(request, {

-record(siporigin, {

pstnproxy_add_headers(Request, Origin) when is_record(Request, request),
                                            is_record(Origin, siporigin) ->
    NewHeaders1 = Request#request.header,
    NewHeaders2 =
        case (Origin#siporigin.proto == tls) or (Origin#siporigin.proto == tls6) of
            true ->
		keylist:delete("X-Foo2", NewHeaders1);
	    false ->
                keylist:delete("X-Foo2", NewHeaders1)
    NewHeaders3 =
      case (Origin#siporigin.proto == tls) or (Origin#siporigin.proto == tls6) of
          true ->
              keylist:delete("X-Foo3", NewHeaders2);
          false ->
              keylist:delete("X-Foo3", NewHeaders2)
    Request#request{header = NewHeaders3}.

More information about the erlang-bugs mailing list