compiler bug in r14B

Engquist, Jim Jim.Engquist@REDACTED
Sat Oct 9 03:03:36 CEST 2010


Here's a compilation error encountered in R14B (download from erlang.org
dated Sep 15, 2010):

 

% erlc foo.erl

foo: function test_run/4+45:

  Internal consistency check failed - please report this bug.

  Instruction: {test_heap,3,2}

  Error:       {{x,0},not_live}:

 

./foo.erl:12: Warning: variable 'TestCaseList' is unused

 

Here is the source file foo.erl (admittedly it's poorly written code,
but shouldn't produce an error like this):

 

-module(foo).

-export([test_run/4]).

 

test_run(Reference, TestCaseList, Listeners, ErrorLog) ->

    receive

        {done, Reference} ->

            cast(Listeners, {stop, Reference, self()}),

            receive

                {result, Reference, Result} ->

                    Result

            after 30000 ->

                    Result = {error, {noresult, check_for_timeout}}

            end,

            cast(ErrorLog, {geterrors, self()}),

            receive

                {{errors, Errors}, {tests, TestCount}} ->

                    {Result, TestCount, [], Errors}

            end

    end.

 

cast(_,_) ->

    ok.

 

 

 



More information about the erlang-bugs mailing list