Commit 4000b067 authored by Dimitri van Heesch's avatar Dimitri van Heesch

Bug 703170 - Segmentation fault parsing a fortran file

parent 8a0c9440
...@@ -1142,6 +1142,7 @@ void parseFortranCode(CodeOutputInterface &od,const char *className,const QCStri ...@@ -1142,6 +1142,7 @@ void parseFortranCode(CodeOutputInterface &od,const char *className,const QCStri
(void)className; (void)className;
if (s.isEmpty()) return; if (s.isEmpty()) return;
TooltipManager::instance()->clearTooltips();
g_code = &od; g_code = &od;
g_inputString = s; g_inputString = s;
g_inputPosition = 0; g_inputPosition = 0;
...@@ -1189,6 +1190,10 @@ void parseFortranCode(CodeOutputInterface &od,const char *className,const QCStri ...@@ -1189,6 +1190,10 @@ void parseFortranCode(CodeOutputInterface &od,const char *className,const QCStri
endFontClass(); endFontClass();
g_code->endCodeLine(); g_code->endCodeLine();
} }
if (fd)
{
TooltipManager::instance()->writeTooltips(*g_code);
}
if (exBlock && g_sourceFileDef) if (exBlock && g_sourceFileDef)
{ {
// delete the temporary file definition used for this example // delete the temporary file definition used for this example
......
...@@ -567,7 +567,7 @@ SCOPENAME ({ID}{BS}"::"{BS})* ...@@ -567,7 +567,7 @@ SCOPENAME ({ID}{BS}"::"{BS})*
/*------- type definition -------------------------------------------------------------------------------*/ /*------- type definition -------------------------------------------------------------------------------*/
<Start,ModuleBody>^{BS}type { <Start,ModuleBody>^{BS}type/[^a-z0-9] {
if(YY_START == Start) if(YY_START == Start)
{ {
addModule(NULL); addModule(NULL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment