﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
1478	Corrupted method: segmentation fault	Jorge	Jorge	"The following code give rise segmentation fault within tol:

{{{
#Require GuiTools;

Real RealSquare( Real x, Set args )
{
  Real sqX = x*x;
  WriteLn( ""El cuadrado de "" << x << "" es "" << sqX );
  sqX
};

Real GuiTools::MenuManager::defineMenuCommand
( ""Real"",
  [[ Text name = ""Real_SQ"",
     Text label = ""Cuadrado del Real"",
     Real flagGroup = 0,
     Code CmdInvoke = RealSquare ]]
);

Real a = 1;

GuiTools::MenuManager::invokeEntry( ""Real_SQ"", [[ a ]] );
}}}

the error is:

{{{
<E>
ERROR: [1] Corrupted method RealSquare
Possibly this problem is due to a non standard use of OOP, if this function was assigned to a member of type Code of a NameBlock or Class instance that has been destroyed already.</E>
[Call stack]
Segmentation fault
}}}

I will try to isolate it from GuiTools.
"	defect	closed	highest	Mantainance	Kernel	3.1	blocker	fixed		
