What versions of MSX-BASIC does support the use of Indentation? (General discussion Foros MSX)MSX Resource Center            
                       
English Nederlands Espa�ol Portugu�s Russian                  
 Noticias
   Página principal
  Almacén de noticias
  Temas de noticias

 Recursos
   Foros MSX
  Artículos
  Analisis
  Informe de ferias/RUs
  Álbum de fotos
  Ferias y encuentros
  Encuestas
  Enlaces
  Buscar

 Software
   Descargas
  Tienda Online

 MRC
   Quiénes somos
  Únete a nuestro equipo
  Donar
  Políticas
  Contacta con nosotros
  Enlázanos
  Estadísticas

 Buscar
 
  

  

 Login
 

Login

Contraseña




¿Aún no tienes una cuenta? ¡Conviértete en miembro del MSX Resource Center! ¡Únete a nosotros!.


 Estadísticas
 

Hay 37 invitados y 2 miembros en línea

Eres un usuario anónimo.
 

Foros MSX


Foros MSX

General discussion - What versions of MSX-BASIC does support the use of Indentation?

Autor

What versions of MSX-BASIC does support the use of Indentation?

Yukio
msx professional
Mensajes: 828
Publicado: Octubre 18 2007, 18:56   
Can the version that you use support this "feature"?
Indentation is widely spread over the computer classes around the world.

The MSX-BASIC is also interpreted instead of being a compiled language. Much of the newer and structured (commercial) versions of BASIC for Personal Computers are now compiled languages, even resembling something from Pascal and other languages.

If a BASIC list is saved in plain ASCII it could be edited into almost any universal Text Editor, only the tokenized files need to be converted for use into other machines ...


[D-Tail]

msx guru
Mensajes: 3026
Publicado: Octubre 18 2007, 19:12   
MSX BASIC is a non-procedural language, so indentation seems pretty useless to me. It can be done, but it'll only eat up bytes and speed.
mohai
msx freak
Mensajes: 133
Publicado: Octubre 19 2007, 11:48   
I think it is not that useless.
You can use it as a way to "tidy up" your BASIC listing. and will make the reading much more easy.
It only takes a couple of bytes more in memory (TAB=0x09) and i think it will not affect to speed.

Compare:

10 screen 2
20 for i=0 to 255
30 vpoke 0+i,i
40 vpoke 8192+i,i
50 next

and

10 screen 2
20 for i=0 to 255
30 _____vpoke 0+i,i
40 _____vpoke 8192+i,i
50 next

BASIC interpreter will do the same, as it will ignore extra spaces or TABS...

Hey! MSX.ORG editor DO support TABs, but the post DO NOT show them, so i had to use "undescores" (by the way).
manuel
msx guru
Mensajes: 3635
Publicado: Octubre 19 2007, 12:07   
Try the [ code ] tag:
10 screen 2
20 for i=0 to 255
30     vpoke 0+i,i
40     vpoke 8192+i,i
50 next


By the way, as MSX-BASIC is an interpreter, these spaces do cost time. Better use NestorPreter, a great MSX-BASIC preprocessor. You can code in great style and the preprocessor will generate an efficient run time version. http://www.konamiman.com/msx/msx-e.html#nestorpreter
NYYRIKKI
msx master
Mensajes: 1533
Publicado: Octubre 19 2007, 14:12   
Actually it takes some more space as MSX-BASIC editor converts TABs to spaces during editing. MSX-BASIC interpreter anyway works with TABs, so you just need some external BASIC editor. (I just don't think there exists any)
AuroraMSX

msx master
Mensajes: 1277
Publicado: Octubre 19 2007, 22:16   
Quote:

so you just need some external BASIC editor. (I just don't think there exists any)

Vi(m), Emacs, Notepad, jEdit, VisualStudio , SlickEdit, Crimson, TED, ...

Any text editor will do the trick
NYYRIKKI
msx master
Mensajes: 1533
Publicado: Octubre 19 2007, 22:37   
Ah, I didn't realize that this conversion does not happen when loading ASCII file.
Well... problem solved...
 
 







(c) 1994 - 2009 Fundación MSX Resource Center. MSX es una marca registrada de MSX Licensing Corporation