From: | jhonan@mpx.com.au (Jamie Honan) |
Newsgroups: | comp.compilers |
Date: | 30 Mar 1998 21:40:45 -0500 |
Organization: | Compilers Central |
References: | 98-03-032 98-03-098 98-03-141 98-03-147 98-03-159 98-03-186 98-03-201 98-03-233 |
Keywords: | interpreter |
Chris Reedy
>A quick question: What are the key differences between a scripting
>language and an ordinary programming language? That is, what is it
>about a language that makes it better or worse for the uses described
>above?
Here's some features of languages (at least on Unix)
described as scripting that I think have in common.
Useful features.
================
Built-in support for hash tables, lists and regular expressions. Often
with syntax support.
Garbage collection. Consequent greater flexibility of creating and
disposing small objects, especially strings.
OS support provided simply - files, directories, fork, exec,
file handles and IPC (pipes and sockets)
Extension to native C code is often done simply
Byte code generated on fly or interpreted language. Aides portability,
'feedback' style development.
I don't like these aspects
==========================
Type checking is often minimal, often only done at runtime. I suppose
this feature is so you don't have to do extra typing for declarations
Often special characters are used to denote variable usage / type. These
are a pain, and often quoting special characters can be a problem.
The start-up time can be large, depending on script size and functionality
provided by the package.
Trends in scripting languages
=============================
Module and name space support. Attempt to provide some sort of
object-orientatedness
GUI interface.
Java considered a scripting language?
=====================================
I would guess three things stop Java being considered a scripting language
in the same sense and Perl, Python and TCL:
type checking
OS support is only done through the Java Way - for example no forking,
just threads.
C native code is not simple (although maybe with SWIG?)
Jamie Honan
jhonan@mpx.com.au
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.