To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.pbforthOpen lugnet.robotics.rcx.pbforth in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / pbFORTH / 555
554  |  556
Subject: 
What does =0 do ?
Newsgroups: 
lugnet.robotics.rcx.pbforth
Date: 
Tue, 23 Jul 2002 09:08:09 GMT
Viewed: 
2445 times
  
Hi,
While entering a program last night, I typed =0 instead of 0=, and the
interpreter accepted it; it took me quite a while to work out why my program
wasn't working properly. =0 does not seem to be a word (ie ' =0 results in the
"not found" error) so why does it get accepted, and what is it doing ? (I end
up with 60 on the stack after executing this word, although I didn't
investigate what else it was doing).

Cheers,
Richard



Message has 1 Reply:
  RE: What does =0 do ?
 
Richard, A little known fact is that if you "punctuate" a number with any of the following characters ,./-: you will get a double on the stack in the old FIG Forth. so 123-4567 will put the double value 1234567 on the stack. So why doesn't 0= get (...) (22 years ago, 23-Jul-02, to lugnet.robotics.rcx.pbforth)

2 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR