# Section 6.8.9:
Creation Expressions

Sather defines two forms of creation expression; one which is programmer defined but has a special syntax variant - otherwise being identical to any other routine call; the other is an expression used when creating a new reference object which is the return value of the method call.

#### Concrete Syntax

creation expression = create expression | new expression ;

### 8.9.1 Create Expression

Routine methods entitled 'create' have an operator form and a method call form. The method call syntax is the same as that for any other method. Using an operator the syntax is given below.

#### Concrete Syntax

create expression = create op, [type_specifier], routine call args ;

#### Abstract Syntax

#### Static Semantics

#### Dynamic Semantics

### 8.9.2 New Expression

All non-immutable object creation requires the use of the new expression below. Note that an expression must be provided when creating an object which has an array component (see constructor class AREF).

#### Concrete Syntax

new expression = New_SY, [parenthesised expression] ;

#### Abstract Syntax

#### Static Semantics

#### Dynamic Semantics

| Specification Index |  | Language Index |  | Section 6 Index

Comments or enquiries should be made to Keith Hopper. Page last modified: Tuesday, 23 May 2000. |