Assembler error

Just starting out? Need help? Post your questions and find answers here.
Fenix
Enthusiast
Enthusiast
Posts: 102
Joined: Wed May 07, 2003 1:45 am
Location: Germany

Assembler error

Post by Fenix »

I got a problem with nested Select/Case statements. Compiling the source leads to following error:


PureBasic.asm[731]:
_Case0:
error: symbol already defined.

(using command line compiler shows: "Assembly error ! Please mail us the file")

Any idea why?



Fenix
Fred
Administrator
Administrator
Posts: 18351
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Post by Fred »

Can you post your code ?
Fenix
Enthusiast
Enthusiast
Posts: 102
Joined: Wed May 07, 2003 1:45 am
Location: Germany

Post by Fenix »

Found the "error"!
It´s been two "empty" Select/Case statements (see : >>> lines)
Commenting those lines kills the "error"!

Code: Select all

   lEvent.l = WaitWindowEvent()                             ; Wait for event
   lEventWindow.l = EventWindowID()
   lEventMenu.l = EventMenuID()
   Select lEventWindow                                   ; check which window is affected
      Case #Main                                  ; main window?
>>>         Select EventGadgetID()                             ; check for gadget input
>>>         EndSelect
         Select lEventMenu                               ; check for menu input
            Case #mnOPTIONS
               Open_Options()
            Case #mnEXIT
               Goto Finish
            Case #mnABOUT
               Open_About()
         EndSelect
      Case #Options                               ; options window?
>>>         Select EventGadgetID()
>>>         EndSelect
      Case #About                                 ; about window?
         Select EventGadgetID()
            Case #bAboutOK                                  ; OK button -> closewindow
               CloseWindow(#About)
         EndSelect
   EndSelect
   
Until lEvent = #PB_Event_CloseWindow

Thx anyway

Fenix
Fred
Administrator
Administrator
Posts: 18351
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Post by Fred »

Nice one. I will fix it tonight.
Fred
Administrator
Administrator
Posts: 18351
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Post by Fred »

Fixed. For next version.
Post Reply