Recent

Author Topic: [BUG] JEDI doesn't work with asm if...  (Read 1511 times)

totya

  • Hero Member
  • *****
  • Posts: 720
[BUG] JEDI doesn't work with asm if...
« on: June 16, 2019, 09:11:15 am »
Hi!

if I list the used register at the end of the asm block, de JEDI formatter doesn't work.

Code: Pascal  [Select][+][-]
  1. {$asmmode intel}
  2. procedure TForm1.Button1Click(Sender: TObject);
  3. begin
  4.   asm
  5.  
  6.   end; ['rsi'];
  7. end;
  8.  

If I comment this line, JEDI works:

Code: Pascal  [Select][+][-]
  1. {$asmmode intel}
  2. procedure TForm1.Button1Click(Sender: TObject);
  3. begin
  4.   asm
  5.  
  6.   end; //['rsi'];
  7. end;      
  8.  

rvk

  • Hero Member
  • *****
  • Posts: 6163
Re: [BUG] JEDI doesn't work with asm if...
« Reply #1 on: June 16, 2019, 09:26:31 am »
Is this also the case if you remove the semicolon between the end and the registry list?
(I can't test it right now)

See the wiki (without the extra semicolon).

Code: Pascal  [Select][+][-]
  1. asm  
  2.   Movl $1,%ebx  
  3.   Movl $0,%eax  
  4.   addl %eax,%ebx  
  5. end [’EAX’,’EBX’];
https://www.freepascal.org/docs-html/ref/refse87.html

If it is still a problem you could search (and if needed add it to the) the bugtracker.

totya

  • Hero Member
  • *****
  • Posts: 720
Re: [BUG] JEDI doesn't work with asm if...
« Reply #2 on: June 16, 2019, 09:31:56 am »
Hi Master!

JEDI doesn't work that way too:

Code: Pascal  [Select][+][-]
  1. {$asmmode intel}
  2. procedure TForm1.Button1Click(Sender: TObject);
  3. begin
  4.   asm
  5.  
  6.   end ['rsi'];
  7. end;
  8.  

Bug tracker... oh yes... done!
« Last Edit: June 16, 2019, 09:46:56 am by totya »

Thaddy

  • Hero Member
  • *****
  • Posts: 14373
  • Sensorship about opinions does not belong here.
Re: [BUG] JEDI doesn't work with asm if...
« Reply #3 on: June 16, 2019, 10:49:37 am »
Jedi is still rather Delphi windows flavor. This needs a fix for fpc only, but I don't know if it is maintained. Intel mode + delphi works correct: there you don't have to close with used registers.
« Last Edit: June 16, 2019, 11:07:21 am by Thaddy »
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

totya

  • Hero Member
  • *****
  • Posts: 720
Re: [BUG] JEDI doesn't work with asm if...
« Reply #4 on: June 17, 2019, 04:59:44 pm »
but I don't know if it is maintained

Thanks for the answer! As I see on the bug tracker, JEDI errors usually corrected...

 

TinyPortal © 2005-2018