Home | About | Partners | Contact Us

SourceForge Logo

Quick Links
Building XL
XL Mailing List

Understanding XL
Conceptual overview
XL examples
Inside XL
Concept Programming

In depth
Browse GIT
SourceForge Info

Other projects
GNU Project
The Mozart Project

XLR: Extensible Language and Runtime

The art of turning ideas into code


Prev: The Difference between Objects and Concepts


Next: Semantics

The syntax defines the shape of programs, using set of rules governing the visible aspects of the code. English syntax is what makes "The eat cat fish" incorrect, because the (visible) order of words is incorrect (see semantics to contrast that with semantic errors).

In most development environments, the code space is represented as text (known as "source code"), and the syntax essentially defines the format of that text. For instance, in C, an identifier such as the name of a variable or function must be a sequence of alpha-numeric or underscore characters beginning with a letter or underscore. So Blob, a29_ or ___000 are all valid C identifiers, whereas short-sighted is not. Syntactic rules are dependent on the programming environment: short-sighted would be a valid Lisp identifier, whereas ___000 would not be any kind of recognized identifier for an Ada compiler.

By extension, we can call "syntax" the visible aspects of non-textual source code. For instance, when a programmer edits a window graphically in Visual Basic or NeXT/Apple Interface Builder, one can think of this as a graphical syntax for GUI elements.

For Concept Programming, one objective of a well-designed syntax is to reduce syntactic noise. From that point of view, the visual editing of GUI elements is close to an ideal, because it fairly directly represents the associated concepts from the problem space. At this point, XL mostly focuses on text-only source representations, though this is really more a simplifying assumption than a design limitation. Graphical representation of some particular XL0 trees is desirable in the future.

Prev: The Difference between Objects and Concepts


Next: Semantics

Copyright 2008 Christophe de Dinechin (Blog)
E-mail: XL Mailing List (polluted by spam, unfortunately)