POV-Ray : Newsgroups : povray.bugreports : Parse error: Uncategorized error thrown at parser/parsertypes.cpp line 62 Server Time
4 May 2024 18:52:24 EDT (-0400)
  Parse error: Uncategorized error thrown at parser/parsertypes.cpp line 62 (Message 13 to 13 of 13)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: William F Pokorny
Subject: Re: Parse error:Uncategorizederrorthrownatparser/parsertypes.cppline62
Date: 21 Mar 2020 13:07:09
Message: <5e7649bd$1@news.povray.org>
On 3/26/19 6:46 AM, William F Pokorny wrote:
> On 3/25/19 7:41 PM, clipka wrote:
>> Am 25.03.2019 um 23:55 schrieb clipka:
>>
>>> If `Cond_Stack.back().PMac->endPosition == CurrentFilePosition()` 
>>> throws an exception, it means either of two things:
>>>
>>> (A) The positions compared are from two different files, which means 
>>> the calling code has failed to check whether it is even in the right 
>>> file.
>>>
>>> (B) The line/column tracking is buggy, and yields different positions 
>>> in different situations.
>>
>>
>> Well, looking at the code of `IsEndOfInvokedMacro()` again, it 
>> _strongly_ reeks of scenario (A):
>>
>>      return (Cond_Stack.back().PMac->endPosition ==
>>                  CurrentFilePosition()) &&
>>             (Cond_Stack.back().PMac->source.fileName ==
>>                  mTokenizer.GetInputStreamName());
>>
>> should probably be swapped around, like so:
>>
>>      return (Cond_Stack.back().PMac->source.fileName ==
>>                  mTokenizer.GetInputStreamName()) &&
>>             (Cond_Stack.back().PMac->endPosition ==
>>                  CurrentFilePosition());
>>
>> so that the `LexemePosition` comparison operator is only invoked if 
>> the file names match.
>>
...

Documenting that Christoph's suggested code change up top, which fixed 
the bug with Warren's original test case and related test cases I 
created, is NOT in the v38 master branch as of commit 74b3ebe0 (March 8, 
2019).

Christoph - I think - planned to fix the core issue, but this has not 
happened as of today so the bug persists.

Bill P.


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.