Re: Let's say you wrote a BASIC program the user is invited to change
Allen Huffman via Coco <coco-uNHYcr1XS/wmlAP/[email protected]>
| Newsgroups | gmane.comp.hardware.tandy.coco |
|---|---|
| Message-ID | <[email protected]> |
> On Jul 10, 2025, at 11:23 AM, Juan Castro via Coco <[email protected]> wrote: > >> That Syntax looks wacky. > > I imposed this limitation to myself: only use keywords that already > exist in the CoCo. One thing I want to get in some of the BASIC editor extensions (like the cool CoCoTools for Visual Studio Code) is the ability to force code to stay where it is (subroutines) while RENUMbering everything else. 5000 REM INPUT 5010 LINE INPUT A$:RETURN 5500 REM OUTPUT 5510 PRINT A$:RETURN There are ALOT of problems trying to do this, but just having it leave lines alone that are marked somehow, so a RENUM would do anything except lines marked. I thought maybe using “:” would work, since you cannot use that on a REM line and do anything: 5000 REM:INPUT … 5500 REM:OUTPUT Then as it renumbers, it would leave those lines alone, and reset whatever the “current” number is so renumbering starts there as if I did it manually with multiple renums. Does that make sense? To do it manually: 1 PRINT “ENTER YOUR NAME:”; 2 GOSUB 5000 3 PRINT “HELLO, “; 4 GOSUB 5500 5 END 5000 REM:INPUT 5001 LINE INPUT A$:RETURN 5500 REM:OUTPUT 5501 PRINT A$:RETURN Then you’d RENUM but you’d get: 10 PRINT “ENTER YOUR NAME:”; 20 GOSUB 5000 30 PRINT “HELLO, “; 40 GOSUB 5500 50 END 5000 REM:INPUT 5010 LINE INPUT A$:RETURN 5500 REM:OUTPUT 5510 PRINT A$:RETURN But I am sure there would be many unforeseen issues. -- Allen Huffman - PO Box 7634 - Urbandale IA 50323 - 515-999-0227 (vmail/TXT only) http://www.subethasoftware.com - https://www.facebook.com/subethasoftware -- Coco mailing list [email protected] https://pairlist5.pair.net/mailman/listinfo/coco