Declarations of Musimat typedefs and aliases. More...
Go to the source code of this file.
Defines | |
#define | Repeat while (true) |
Repeat execution of a compound statement continuously. | |
#define | Halt exit |
Terminate execution at program location where Halt appears. | |
#define | Return return |
Terminate execution of function and return a value (if given). | |
#define | Break break |
Terminate the smallest enclosing repeating statement. | |
#define | Continue continue |
Pass control to the next iteration of the smallest enclosing repeating statement. | |
#define | If if |
Conditionally execute simple or compound statement. | |
#define | Else else |
Terminate execution of function and return a value (if given). | |
#define | Do do |
Execute statement repeatedly until expression becomes False. | |
#define | While while |
Execute statement repeatedly until expression becomes False. | |
#define | Goto goto |
Transfer control directly. | |
#define | For for |
Transfer control directly. | |
#define | Void void |
Void declarator. | |
#define | Const const |
Const declarator. | |
#define | Volatile volatile |
Volatile declarator. | |
#define | True true |
Positive boolean value. | |
#define | False false |
Negative boolean value. | |
#define | Character char |
Datatype of a single character. | |
#define | Static static |
Static declarator. | |
#define | Reference & |
Static declarator. | |
#define | And && |
And operator. | |
#define | Or || |
Or operator. | |
#define | Switch switch |
Conditionally execute multi-way branching. | |
#define | Case case |
#define | Default default |
#define | Break break |
Terminate the smallest enclosing repeating statement. | |
Typedefs | |
typedef int | Integer |
Type of an integer variable. | |
typedef double | Real |
Type of a real variable. | |
typedef bool | Bool |
Type of a boolean variable. | |
typedef const char * | String |
String data type. |
Declarations of Musimat typedefs and aliases.
Definition in file Aliases.h.
#define And && |
And operator.
The logical operators, And and Or, are used to combine multiple conditions formed using relational or equality expressions. The And operator returns the integral value 1 if both operands are nonzero; otherwise, it returns 0. And has left-to-right associativity.
In C++, And is implemented as &&.
Definition at line 300 of file Aliases.h.
Referenced by Matrix< Type >::operator+(), Matrix< Type >::operator-(), Rhythm::operator==(), Rational::operator==(), and Matrix< Type >::SetSize().
#define Break break |
Terminate the smallest enclosing repeating statement.
Terminate the smallest enclosing Do, For, Switch, While or Repeat statement in which it appears. In C++, Break is implemented as break.
Definition at line 346 of file Aliases.h.
Referenced by Pitch::isAccidental(), Pitch::isPitchClass(), Pitch::print(), and Pitch::transpose().
#define Break break |
#define Character char |
Datatype of a single character.
In C++, Character is implemented as char.
Definition at line 254 of file Aliases.h.
Referenced by Pitch::print().
#define Const const |
Const declarator.
When modifying a data declaration, the Const keyword specifies that the object or variable is not modifiable. When following a member function's parameter list, the const keyword specifies that the function doesn't modify the object for which it is invoked.
In C++, Const is implemented as const.
Definition at line 213 of file Aliases.h.
Referenced by RealToRational().
#define Continue continue |
#define Do do |
Execute statement repeatedly until expression becomes False.
Do statement While( expression );
Execute statement repeatedly until controlling expression becomes False (0).
In C++, Do is implemented as do.
#define Else else |
Terminate execution of function and return a value (if given).
If( expression ) statement1 [Else statement2]
See If.
In C++, Else is implemented as else.
Definition at line 117 of file Aliases.h.
Referenced by List< Type >::checkSize(), operator>>(), Pitch::Pitch(), Pitch::print(), randTendency(), RealToRational(), List< Type >::SetListSize(), Matrix< Type >::SetSize(), and Pitch::transpose().
#define False false |
Negative boolean value.
False is the other of the two values that a variable of type Bool can have. In C++, False is implemented as false.
Definition at line 248 of file Aliases.h.
Referenced by Matrix< Type >::operator==(), and List< Type >::operator==().
#define For for |
Transfer control directly.
For( [init-expr]; [cond-expr]; [loop-expr] ) statement
The For keyword executes statement repeatedly.
First, the initialization (init-expr) is evaluated. Then, while the conditional expression (cond-expr) evaluates to a nonzero value, statement is executed and the loop expression (loop-expr) is evaluated. When cond-expr becomes 0, control passes to the statement following the For loop.
In C++, For is implemented as for.
Definition at line 180 of file Aliases.h.
Referenced by IntegerListToPitchList(), Invert(), List< Type >::invert(), Map(), List< Type >::max(), List< Type >::maxPos(), List< Type >::min(), List< Type >::minPos(), List< Type >::operator!=(), Matrix< Type >::operator*(), List< Type >::operator*(), Matrix< Type >::operator+(), List< Type >::operator+(), List< Type >::operator+=(), Matrix< Type >::operator-(), List< Type >::operator-(), List< Type >::operator-=(), List< Type >::operator/(), Matrix< Type >::operator==(), List< Type >::operator==(), Pitch::Pitch(), PitchListToIntegerList(), Matrix< Type >::print(), List< Type >::print(), RandomRow(), RealListToRationalList(), RealToRational(), List< Type >::retrograde(), SetComplex(), shuffle(), stretch(), Transpose(), and List< Type >::transpose().
#define Goto goto |
#define Halt exit |
#define If if |
Conditionally execute simple or compound statement.
If( expression ) statement1 [Else statement2]
The If keyword executes statement1 if expression is true (nonzero); If else is present and expression is false (zero), it executes statement2. After executing statement1 or statement2, control passes to the next statement.
In C++, If is implemented as if.
Definition at line 104 of file Aliases.h.
Referenced by List< Type >::checkSize(), Random::lCRandom(), List< Type >::maxPos(), List< Type >::minPos(), List< Type >::operator!=(), Matrix< Type >::operator=(), List< Type >::operator=(), Matrix< Type >::operator==(), List< Type >::operator==(), operator>>(), palindrome(), permute(), Pitch::Pitch(), Rhythm::print(), Rational::print(), Pitch::print(), Matrix< Type >::print(), List< Type >::print(), Complex::print(), RandomRow(), randTendency(), Rational::Rational(), RealToRational(), Rhythm::Rhythm(), List< Type >::rotate(), List< Type >::SetListSize(), Matrix< Type >::SetSize(), Pitch::transpose(), and List< Type >::~List().
#define Or || |
Or operator.
The logical operators, And and Or, are used to combine multiple conditions formed using relational or equality expressions. The Or operator returns the integral value 1 if either operand is nonzero; otherwise, it returns 0. Or has left-to-right associativity.
In C++, Or is implemented as ||.
#define Reference & |
Static declarator.
A Reference is a 16-bit or 32-bit quantity that holds the address of an object but behaves syntactically like that object. A Reference declaration consists of an (optional) list of specifiers followed by a Reference declarator.
Any object whose address can be converted to a given pointer type can also be converted to the analogous Reference type.
In C++, Reference is implemented as &.
#define Repeat while (true) |
Repeat execution of a compound statement continuously.
Put Repeat at the head of a compound list to cause the enclosed statements to repeat indefinitely. NOTE: the compound list must contain a Halt, Return, Break or Continue statement, otherwise the program will enter an infinite loop.
#define Return return |
Terminate execution of function and return a value (if given).
Terminate execution of the function in which it appears and returns control (and the value of expression if given) to the calling function. In C++, Return is implemented as return.
Definition at line 74 of file Aliases.h.
Referenced by Abs(), AbsDuration(), Rhythm::absDuration(), Accidental(), Pitch::accidental(), Atan(), Atan2(), Ceiling(), Matrix< Type >::cols(), Conjugate(), Cos(), cycle(), dBCoefficient(), dBSIL(), dBSPL(), Pitch::degree(), Divide(), Duration(), Rhythm::duration(), Exp(), Floor(), Random::getTime(), Pitch::hertz(), Pitch::HzReference(), ImagPart(), inRange(), IntegerListToPitchList(), InterpTendency(), Invert(), IRandom(), Pitch::isAccidental(), isnumeric(), Pitch::isPitchClass(), Join(), KeyToHertz(), LCRandom(), Random::lCRandom(), Length(), List< Type >::length(), LinearInterpolate(), linearInterpolate(), Log(), Log10(), Map(), Max(), List< Type >::max(), MaxPos(), List< Type >::maxPos(), metronome(), Min(), List< Type >::min(), MinPos(), List< Type >::minPos(), Minus(), Rhythm::mm(), Mod(), Multiply(), Octave(), Pitch::octave(), Pitch::operator Integer(), Pitch::operator Real(), Rhythm::operator!=(), Rational::operator!=(), Pitch::operator!=(), Matrix< Type >::operator!=(), List< Type >::operator!=(), Pitch::operator%(), Rhythm::operator*(), Rational::operator*(), Pitch::operator*(), Matrix< Type >::operator*(), List< Type >::operator*(), Rhythm::operator*=(), Rational::operator*=(), Pitch::operator*=(), Rhythm::operator+(), Rational::operator+(), Pitch::operator+(), Matrix< Type >::operator+(), List< Type >::operator+(), Rhythm::operator+=(), Rational::operator+=(), Pitch::operator+=(), List< Type >::operator+=(), Rhythm::operator-(), Rational::operator-(), Pitch::operator-(), Matrix< Type >::operator-(), List< Type >::operator-(), Rhythm::operator-=(), Rational::operator-=(), Pitch::operator-=(), List< Type >::operator-=(), Rhythm::operator/(), Rational::operator/(), Pitch::operator/(), List< Type >::operator/(), Rhythm::operator/=(), Rational::operator/=(), Pitch::operator/=(), Rhythm::operator<(), Rational::operator<(), Pitch::operator<(), operator<<(), Rhythm::operator<=(), Rational::operator<=(), Pitch::operator<=(), Rational::operator=(), Matrix< Type >::operator=(), List< Type >::operator=(), Rhythm::operator==(), Rational::operator==(), Pitch::operator==(), Matrix< Type >::operator==(), List< Type >::operator==(), Rhythm::operator>(), Rational::operator>(), Pitch::operator>(), Rhythm::operator>=(), Rational::operator>=(), Pitch::operator>=(), operator>>(), Matrix< Type >::operator[](), List< Type >::operator[](), palindrome(), permute(), Pitch::pianoKey(), Pitch::Pitch(), PitchClass(), Pitch::pitchClass(), PitchListToIntegerList(), PitchToHertz(), Plus(), PosMod(), Pow(), Rhythm::print(), Rational::print(), Pitch::print(), Random(), Random::random(), RandomRow(), randTendency(), RealListToRationalList(), RealPart(), RealToRational(), Retrograde(), Rotate(), Round(), Matrix< Type >::rows(), Random::seed(), SeedRandom(), SetComplex(), shuffle(), Sin(), Sqrt(), stretch(), Rhythm::tempo(), Time(), Transpose(), and unitInterp().
#define Static static |
Static declarator.
When modifying a variable, the static keyword specifies that the variable has static duration (it is allocated when the program begins and deallocated when the program ends) and initializes it to 0 unless another value is specified. When modifying a variable or function at file scope, the static keyword specifies that the variable or function has internal linkage (its name is not visible from outside the file in which it is declared).
In C++, when modifying a data member in a class declaration, the static keyword specifies that one copy of the member is shared by all the instances of the class. When modifying a member function in a class declaration, the static keyword specifies that the function accesses only static members.
In C++, Static is implemented as static.
#define Switch switch |
Conditionally execute multi-way branching.
Switch ( expression ) { Case 1: [ Case 1a: . . . ] statement1 ; [ statemet1a ; . . . ; ] Break; Case 2: [ Case 2a: . . . ] statement2 ; [ statement2a ; . . . ; ] Break; . . . [ Default: statementNa ; [ statementNb ; . . .] break; ] } If the result of evaluating the Switch expression matches the value of any Case, the corresponding statement or statements are executed until the corresponding break statement, whereupon the Switch block is exited. If no Case matches the expression, and there is a Default expression, then the default statement(s) are executed. If there is no Default statement, and no Case matches the Switch expression, nothing in the Switch block is executed. Note: each Case's statement block must be terminated by Break. If it is not, then execution continues at the next statement inline. This is either a bug or a feature depending on whether you forget or remember this fact. Here's an example: In C++, Switch is implemented as switch, Case is implemented as case, Break as break, and Default as default.
#define True true |
Positive boolean value.
True is one of the two values that a variable of type Bool can have. In C++, True is implemented as true.
Definition at line 241 of file Aliases.h.
Referenced by List< Type >::operator!=(), Matrix< Type >::operator==(), and List< Type >::operator==().
#define Void void |
Void declarator.
When used as a function return type, the Void keyword specifies that the function does not return a value. When used for a function's parameter list, Void specifies that the function takes no parameters. When used in the declaration of a pointer, Void specifies that the pointer is "universal."
If a pointer's type is Void *, the pointer can point to any variable that is not declared with the Const or Volatile keyword. A Void pointer cannot be dereferenced unless it is cast to another type. A Void pointer can be converted into any other type of data pointer.
A Void pointer can point to a function, but not to a class member.
Variables may not be declared to be of type void.
In C++, Void is implemented as void.
#define Volatile volatile |
Volatile declarator.
The volatile keyword is a type qualifier used to declare that an object can be modified in the program by something other than statements, such as the operating system, the hardware, or a concurrently executing thread.
Objects declared as volatile are not used in optimizations because their value can change at any time. The system always reads the current value of a volatile object at the point it is requested, even if the previous instruction asked for a value from the same object. Also, the value of the object is written immediately on assignment.
One use of the volatile qualifier is to provide access to memory locations used by asynchronous processes such as interrupt handlers.
In C++, Volatile is implemented as volatile.
#define While while |
Execute statement repeatedly until expression becomes False.
while ( expression ) statement
The expression is evaluated.
If expression is initially false, the body of the While statement is never executed, and control passes from the While statement to the next statement in the program. If expression is True (nonzero), the body of the statement is executed and the process is repeated beginning at step 1.
The While statement can also terminate when a Break, Goto, or Return within the statement body is executed. Use the Continue statement to terminate an iteration without exiting the While loop. The Continue statement passes control to the next iteration of the While statement.
In C++, While is implemented as while.
Definition at line 150 of file Aliases.h.
Referenced by Mod(), operator>>(), Pitch::Pitch(), PosMod(), and Pitch::transpose().
typedef bool Bool |
typedef int Integer |
typedef double Real |
typedef const char* String |
String data type.
In C++, String is implemented as const char*. Note, this is a change in this release. String used to be implemented as just "char*" but is now a constant string pointer to avoid warnings about "deprecated conversion from string constant to 'char*' warnings.