Content deleted Content added
→top: false implication that it is unknown how Citrine is unlike Smalltalk (“However unlike Smalltalk”) (missing comma) |
→Syntax: grammatical number; notation |
||
(13 intermediate revisions by the same user not shown) | |||
Line 20:
}}
'''Citrine''' is a general-purpose [[programming language]] for [[Cross-platform|various operating systems]]. It focuses on readability and maintainability. Readability is achieved by syntactic and conceptual minimalism. The language is heavily inspired by [[Smalltalk]] and [[Self (programming language)|Self]] but has some very distinctive features. Like Smalltalk, Citrine treats everything as an object and focuses on sending messages to these objects. However, unlike Smalltalk, Citrine lacks the concept of a class. In this regard, Citrine is more like Self and [[JavaScript]] because it uses [[Prototype-based programming|prototypes]]. The combination of Smalltalk
==Syntax==
Citrine has a very limited syntax
* {{code|Nil}}
Line 33:
* <code>{ ...params.. ...block of code... }</code>
The code block literal uses a ''pipe'' symbol ⟨|⟩ to separate the parameters from the logic
parameters, the backslash should be used instead.
Citrine only supports full-line comments, which start with
A Citrine program is basically a sequence of messages sent to objects. For instance, to determine whether 5 is an even number, the message 'even?' is sent to the number 5.
|