Recent

Author Topic: Enable the label/goto statements  (Read 1441 times)

Чебурашка

  • Hero Member
  • *****
  • Posts: 568
  • СЛАВА УКРАЇНІ! / Slava Ukraïni!
Enable the label/goto statements
« on: November 16, 2021, 10:46:54 am »
Hi everybody,
I added the -Sg option in order to enable the label/goto statements, but I still get a 'Illegal expr' error on these statements when compiling.

[0.000] Free Pascal Compiler version 3.0.4+dfsg-22 [2019/01/24] for x86_64
OS: debian 10.9

I think my fpc call is like this:

/usr/bin/fpc -Mfpc -Scghi -Cg -g -gl -l -vewnhibq -Filib/x86_64-linux -Fu. -FUlib/x86_64-linux -FE. -oproject002 -dVIRTUALIZED_TIME



I missing something...

Please help.
« Last Edit: November 16, 2021, 10:50:08 am by tt »
FPC 3.2.0/Lazarus 2.0.10+dfsg-4+b2 on Debian 11.5
FPC 3.2.2/Lazarus 2.2.0 on Windows 10 Pro 21H2

ccrause

  • Hero Member
  • *****
  • Posts: 856
Re: Enable the label/goto statements
« Reply #1 on: November 16, 2021, 11:06:20 am »
Please show relevant code and compiler error messages.

Чебурашка

  • Hero Member
  • *****
  • Posts: 568
  • СЛАВА УКРАЇНІ! / Slava Ukraïni!
Re: Enable the label/goto statements
« Reply #2 on: November 16, 2021, 11:27:00 am »
%)

I got confused with pascal syntax due to parallel operations on different prog langs.

Sorry for wasting your time.
FPC 3.2.0/Lazarus 2.0.10+dfsg-4+b2 on Debian 11.5
FPC 3.2.2/Lazarus 2.2.0 on Windows 10 Pro 21H2

MarkMLl

  • Hero Member
  • *****
  • Posts: 6686
Re: Enable the label/goto statements
« Reply #3 on: November 16, 2021, 11:57:22 am »
I got confused with pascal syntax due to parallel operations on different prog langs.

Sorry for wasting your time.

Such things are never a complete waste of time, since they indicate that somebody is having problems with the error messages and (possibly even the) documentation.

But next time PLEASE post the offending code and errors when you ask the question.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11452
  • FPC developer.
Re: Enable the label/goto statements
« Reply #4 on: November 16, 2021, 12:23:05 pm »
Also beware of {$mode statements in the source that might reset sub options like the "goto" state.

Thaddy

  • Hero Member
  • *****
  • Posts: 14373
  • Sensorship about opinions does not belong here.
Re: Enable the label/goto statements
« Reply #5 on: November 16, 2021, 03:58:33 pm »
Such things are never a complete waste of time,
Check the version. It is 3.0.4. That is unsupported. So a waste of time.
Help with the issue at hand may suddenly disappear with a correct version.

That said: here my trunk version does work with labels/goto's
DO NOT USE TRUNK YOURSELF!!!  3.2.2 should be fine.

Some sourcecode that actually compiles or fails would be very helpful to Mark, Marco and me and others. So hopefully to U2..

« Last Edit: November 16, 2021, 04:09:44 pm by Thaddy »
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

 

TinyPortal © 2005-2018