flat assembler
Message board for the users of flat assembler.

Index > Linux > Interactive fasm, or howto cat /dev/stdin with fasm

Author
Thread Post new topic Reply to topic
MCD



Joined: 21 Aug 2004
Posts: 602
Location: Germany
MCD 25 Oct 2007, 17:21
Hi

I'm very busy so I'm just dropping by to tell this funny discovery.

I'm not sure if this is known yet, but at least in UN*X-like environments, you can make programs with fasm which assemble interactively. See this little example:
Code:
result= 0

virtual      at 0
  while result <> 'q'
    file       '/dev/stdin',1
    load    result byte     from %-1
  end while
  display    0xA,'you entered:',0xA
  repeat $
    load  part byte       from %-1
    display part
  end repeat
end virtual
display  0xA,'quitting interactive world!',0xA
    


This will display as assembler messages the text you enter.

Now, who builds the first text, hex, ram or disk editor with fasm? Wink

_________________
MCD - the inevitable return of the Mad Computer Doggy

-||__/
.|+-~
.|| ||
Post 25 Oct 2007, 17:21
View user's profile Send private message Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4624
Location: Argentina
LocoDelAssembly 25 Oct 2007, 19:48
You can do this on Windows too replacing '/dev/stdin' with 'CON' if you use the console version of fasm.
Post 25 Oct 2007, 19:48
View user's profile Send private message Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid 25 Oct 2007, 20:26
haha Very Happy
Post 25 Oct 2007, 20:26
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.