POV-Ray : Newsgroups : povray.beta-test : Confusing Error message : Re: Confusing Error message Server Time
28 Jul 2024 18:19:30 EDT (-0400)
  Re: Confusing Error message  
From: Warp
Date: 15 Oct 2007 07:24:40
Message: <47134df8@news.povray.org>
Warp <war### [at] tagpovrayorg> wrote:
>   I wonder how hard would it be to add some kind of error/warning catching.
> In other words, when an error or warning happens, some SDL code is executed.
> (Then you could write there eg. #debug commands which output values of loop
> variables, etc. This would help a lot debugging.)

  This could perhaps be one possibility:

#macro MyMacro()
  #debug concat(str(Index, 0, 0), "\n")
#end

#onerror MyMacro

#declare Index = 0;
#while(Index < 1000)
  cylinder { something } // The error happens in this line
  #declare Index = Index+1;
#end

-- 
                                                          - Warp


Post a reply to this message

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