bugGforth - Bugs: bug #50013, "file-size" returns...

 
 

bug #50013: "file-size" returns three items on the stack when it should only return two

Submitted by:  None
Submitted on:  Tue 10 Jan 2017 10:19:40 AM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: Invalid
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Tue 10 Jan 2017 12:37:32 PM UTC, comment #1:

The "ud" data type is unsigned double, so takes two cells on the stack. See https://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Double-precision.html in the manual.

Same misunderstanding as in the last reported bug, https://savannah.gnu.org/bugs/?49798

Bernd Paysan <paysan>
Project Administrator
Tue 10 Jan 2017 10:19:40 AM UTC, original submission:

When using "file-size" it returned more items on the stack than expected.
From the Gforth manual file-size ( wfileid – ud wior)
Here is a example typed straight into Gforth demonstrating the issue

  1. value fd-in ok

.s <0> ok
s" ./testin-1.txt" r/o open-file throw to fd-in ok
.s <0> ok
fd-in file-size ok
.s <3> 943877 0 0 ok

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by paysan (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 10 Jan 2017 12:37:32 PM UTCpaysanStatusNone=>Invalid
      Open/ClosedOpen=>Closed

    Back to the top


    Powered by Savane 3.1-cleanup1