Thanks! I'll have to move to another machine to test, though - my Mac Lion is 
running flex 2.5.35, and I no longer see those warnings. Interesting as I was 
under the impression that flex is no longer supported….


On Feb 20, 2012, at 4:36 PM, Paul H. Hargrove wrote:

> Ralph,
> 
> The change below removes the warning, but very slightly changes the syntax 
> that is parsed.
> In the original, anything following the "[tag]" was considered trailing 
> context.
> However that made inputs like "[tag]foo]" ambiguous to the parser (hence the 
> warning).
> With the change below, both "]" will be in the matched string.
> I am pretty sure that shouldn't ever happen in valid inputs anyway.
> NOTE: I've not yet actually tested the resulting show_help utility [but soon].
> 
> -Paul
> 
> Index: opal/util/show_help_lex.l
> ===================================================================
> --- opal/util/show_help_lex.l   (revision 25974)
> +++ opal/util/show_help_lex.l   (working copy)
> @@ -62,7 +62,7 @@
> 
> #.*\n               ; /* comment line */
> 
> -^\[.+\]/.*\n { BEGIN(CHOMP); return OPAL_SHOW_HELP_PARSE_TOPIC; }
> +^\[.+\]/[^\]\n]*\n { BEGIN(CHOMP); return OPAL_SHOW_HELP_PARSE_TOPIC; }
> 
> <CHOMP>.*\n { BEGIN(INITIAL); }
> 
> 
> 
> On 2/20/2012 3:26 PM, Ralph Castain wrote:
>> My bad - didn't look closely enough. I'll take a look at it and see if there 
>> is anything we can do.
>> 
>> On Feb 20, 2012, at 4:12 PM, Paul H. Hargrove wrote:
>> 
>>> Ralph,
>>> 
>>> Are you sure this is a flex-generated file?
>>> I am looking at opal/util/show_help_lex.l in the svn trunk and it certainly 
>>> looks human-generated to me.
>>> Please clue me in if I am missing something.
>>> 
>>> The warning is from flex when processing the .l file, NOT from the 
>>> compilation of the flex-generated .c file.
>>> 
>>> -Paul
>>> 
>>> On 2/19/2012 7:55 PM, Ralph Castain wrote:
>>>> We get that everywhere, unfortunately - it comes from flex and is outside 
>>>> our control as the file it complains about is actually generated by flex 
>>>> itself. Unfortunately, flex is no longer maintained, and so nothing has 
>>>> been done to correct it.
>>>> 
>>>> 
>>>> On Feb 19, 2012, at 8:47 PM, Paul H. Hargrove wrote:
>>>> 
>>>>> I've not checked any other systems, but building the trunk on OpenBSD and 
>>>>> FreeBSD (w/ flex-2.5.4) I see the following:
>>>>>>  LEX    show_help_lex.c
>>>>>> "[srcdir]/opal/util/show_help_lex.l", line 65: warning, dangerous 
>>>>>> trailing context
>>>>> I found this message in the flex documentation, and it mentions that the 
>>>>> POSIX draft for LEX leaves such cases undefined.
>>>>> http://flex.sourceforge.net/manual/Limitations.html
>>>>> 
>>>>> -Paul
>>>>> 
>>>>> -- 
>>>>> Paul H. Hargrove                          phhargr...@lbl.gov
>>>>> Future Technologies Group
>>>>> HPC Research Department                   Tel: +1-510-495-2352
>>>>> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
>>>>> 
>>>>> _______________________________________________
>>>>> devel mailing list
>>>>> de...@open-mpi.org
>>>>> http://www.open-mpi.org/mailman/listinfo.cgi/devel
>>>> _______________________________________________
>>>> devel mailing list
>>>> de...@open-mpi.org
>>>> http://www.open-mpi.org/mailman/listinfo.cgi/devel
>>> -- 
>>> Paul H. Hargrove                          phhargr...@lbl.gov
>>> Future Technologies Group
>>> HPC Research Department                   Tel: +1-510-495-2352
>>> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
>>> 
>>> _______________________________________________
>>> devel mailing list
>>> de...@open-mpi.org
>>> http://www.open-mpi.org/mailman/listinfo.cgi/devel
>> 
>> _______________________________________________
>> devel mailing list
>> de...@open-mpi.org
>> http://www.open-mpi.org/mailman/listinfo.cgi/devel
> 
> -- 
> Paul H. Hargrove                          phhargr...@lbl.gov
> Future Technologies Group
> HPC Research Department                   Tel: +1-510-495-2352
> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
> 
> _______________________________________________
> devel mailing list
> de...@open-mpi.org
> http://www.open-mpi.org/mailman/listinfo.cgi/devel


Reply via email to