Menu

#18 current-input-port should be stdin

tinyscheme-v1.43
open
nobody
Patch (2)
5
2020-09-23
2010-11-15
nimiezko
No

There is confusion between inport and loadport.
The read-char, read... functions try to read from the currently loaded file rather than standard input.

Discussion

  • Kevin Cozens

    Kevin Cozens - 2011-01-02

    I'm rejecting the first part of the patch which modifies opdefines.h as it would allow up to 2 arguments for open-input-file but the R5RS only shows 1 argument as valid. I need to take a closer look at the changes for the scheme.c file.

     
  • nimiezko

    nimiezko - 2011-02-20

    Patch is not meant to be applied. Just a workaround that worked for me.
    I have not sufficient skills to produce a better patch.

     
  • Kevin Cozens

    Kevin Cozens - 2013-03-25
    • labels: --> Patch
     

    Last edit: Kevin Cozens 2013-03-25
  • James Woodcock

    James Woodcock - 2013-07-09

    I think I have found a fix for this issue. I have attached a patch.

     
  • James Woodcock

    James Woodcock - 2013-07-09

    Here's a simple test case. inport_test.readme explains how it works.

     
  • Kevin Cozens

    Kevin Cozens - 2020-09-22
    • Group: --> tinyscheme-v1.43
     
  • Rodion Gorkovenko

    Seemingly is duplicated by https://sourceforge.net/p/tinyscheme/patches/26/ but in current version just removing two lines (as suggested there) looks enough (works correctly in both interpreted and script mode).

     

Log in to post a comment.