Opened 10 years ago

Closed 10 years ago

#2968 closed defect (fixed)

Function pointers are not checked for being assigned before use

Reported by: Per Östlund Owned by: Martin Sjölund
Priority: high Milestone: 1.9.2
Component: MetaModelica Version: trunk
Keywords: Cc:

Description

This function currently segfaults without any error from the compiler:

function test
  output Integer n;

protected
  partial function func
    output Integer n;
  end func;

  func f; // <- Not assigned!
algorithm
  n := f();
end test;

Change History (2)

comment:1 by Martin Sjölund, 10 years ago

Fixed in r23252.

comment:2 by Martin Sjölund, 10 years ago

Milestone: Future1.9.2
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.