Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTAssignment.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A node representing an assignment
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTBinaryExpression.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A trait representing a binary expression of a node of a source code.
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTBooleanLiteral.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A boolean literal
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTCharacterLiteral.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A character literal
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
32 changes: 3 additions & 29 deletions src/FAST-Core-Model/FASTTConditionalStatement.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ I represent any statement that has a boolean condition (eg. ifStatement)
### Children
| Relation | Origin | Opposite | Type | Comment |
|---|
| `condition` | `FASTTConditionalStatement` | `parentConditionalStatement` | `FASTTExpression` | The boolean condition tested|
| `condition` | `FASTTWithCondition` | `parentConditional` | `FASTTExpression` | The boolean condition tested|


## Properties
Expand All @@ -27,11 +27,8 @@ I represent any statement that has a boolean condition (eg. ifStatement)
"
Trait {
#name : 'FASTTConditionalStatement',
#instVars : [
'#condition => FMOne type: #FASTTExpression opposite: #parentConditionalStatement'
],
#traits : 'FASTTStatement',
#classTraits : 'FASTTStatement classTrait',
#traits : 'FASTTStatement + FASTTWithCondition',
#classTraits : 'FASTTStatement classTrait + FASTTWithCondition classTrait',
#category : 'FAST-Core-Model-Traits',
#package : 'FAST-Core-Model',
#tag : 'Traits'
Expand All @@ -45,26 +42,3 @@ FASTTConditionalStatement classSide >> annotation [
<generated>
^ self
]

{ #category : 'accessing' }
FASTTConditionalStatement >> condition [
"Relation named: #condition type: #FASTTExpression opposite: #parentConditionalStatement"

<generated>
<FMComment: 'The boolean condition tested'>
^ condition
]

{ #category : 'accessing' }
FASTTConditionalStatement >> condition: anObject [

<generated>
condition := anObject
]

{ #category : 'navigation' }
FASTTConditionalStatement >> conditionGroup [
<generated>
<navigation: 'Condition'>
^ MooseSpecializedGroup with: self condition
]
37 changes: 22 additions & 15 deletions src/FAST-Core-Model/FASTTExpression.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ An abstract superclass representing an expression node of a source code.
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand All @@ -29,14 +29,14 @@ An abstract superclass representing an expression node of a source code.
Trait {
#name : 'FASTTExpression',
#instVars : [
'#argumentOwner => FMOne type: #FASTTWithArguments opposite: #arguments',
'#assignedIn => FMOne type: #FASTTAssignment opposite: #expression',
'#parentExpressionLeft => FMOne type: #FASTTBinaryExpression opposite: #leftOperand',
'#parentExpressionRight => FMOne type: #FASTTBinaryExpression opposite: #rightOperand',
'#parentConditionalStatement => FMOne type: #FASTTConditionalStatement opposite: #condition',
'#expressionStatementOwner => FMOne type: #FASTTExpressionStatement opposite: #expression',
'#returnOwner => FMOne type: #FASTTReturnStatement opposite: #expression',
'#parentConditional => FMOne type: #FASTTWithCondition opposite: #condition',
'#parentExpression => FMOne type: #FASTTUnaryExpression opposite: #expression',
'#argumentOwner => FMOne type: #FASTTWithArguments opposite: #arguments'
'#parentExpressionLeft => FMOne type: #FASTTBinaryExpression opposite: #leftOperand',
'#parentExpressionRight => FMOne type: #FASTTBinaryExpression opposite: #rightOperand',
'#returnOwner => FMOne type: #FASTTReturnStatement opposite: #expression'
],
#traits : 'FASTTEntity',
#classTraits : 'FASTTEntity classTrait',
Expand Down Expand Up @@ -136,28 +136,35 @@ FASTTExpression >> isExpression [
]

{ #category : 'accessing' }
FASTTExpression >> parentConditionalStatement [
"Relation named: #parentConditionalStatement type: #FASTTConditionalStatement opposite: #condition"
FASTTExpression >> parentConditional [
"Relation named: #parentConditional type: #FASTTWithCondition opposite: #condition"

<generated>
<FMComment: 'Optional condition statement where this expression is used'>
<FMComment: 'Optional condition statement/expression where this expression is used'>
<container>
<derived>
^ parentConditionalStatement
^ parentConditional
]

{ #category : 'accessing' }
FASTTExpression >> parentConditionalStatement: anObject [
FASTTExpression >> parentConditional: anObject [

<generated>
parentConditionalStatement := anObject
parentConditional := anObject
]

{ #category : 'navigation' }
FASTTExpression >> parentConditionalStatementGroup [
FASTTExpression >> parentConditionalGroup [
<generated>
<navigation: 'ParentConditionalStatement'>
^ MooseSpecializedGroup with: self parentConditionalStatement
<navigation: 'ParentConditional'>
^ MooseSpecializedGroup with: self parentConditional
]

{ #category : 'accessing' }
FASTTExpression >> parentConditionalStatement [

self deprecated: 'Use #parentConditional instead.' transformWith: '`@rcv parentConditionalStatement' -> '`@rcv parentConditional'.
^ self parentConditional
]

{ #category : 'accessing' }
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTInvocation.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A invocation of a behavioural entity
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTLiteral.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ FLAG: should refactor some literals to core-model
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTNullPointerLiteral.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ An undefined object literal
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTNumericalLiteral.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A numerical literal
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTStringLiteral.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A string literal
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTUnaryExpression.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A trait representing an unary expression of a node of a source code.
| `argumentOwner` | `FASTTExpression` | `arguments` | `FASTTWithArguments` | my owner|
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
2 changes: 1 addition & 1 deletion src/FAST-Core-Model/FASTTVariableExpression.trait.st
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ A node that wraps around structural entity
| `assignedIn` | `FASTTExpression` | `expression` | `FASTTAssignment` | Optional assignment where this expression is used|
| `expressionStatementOwner` | `FASTTExpression` | `expression` | `FASTTExpressionStatement` | The expression statement that own me (if it's the case|
| `invokedIn` | `FASTTNamedEntity` | `invoked` | `FASTTInvocation` | Optional invocation where this name is used|
| `parentConditionalStatement` | `FASTTExpression` | `condition` | `FASTTConditionalStatement` | Optional condition statement where this expression is used|
| `parentConditional` | `FASTTExpression` | `condition` | `FASTTWithCondition` | Optional condition statement/expression where this expression is used|
| `parentExpression` | `FASTTExpression` | `expression` | `FASTTUnaryExpression` | Parent (unary) expression|
| `parentExpressionLeft` | `FASTTExpression` | `leftOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am left side|
| `parentExpressionRight` | `FASTTExpression` | `rightOperand` | `FASTTBinaryExpression` | Parent (binary) expression of which I am right side|
Expand Down
53 changes: 53 additions & 0 deletions src/FAST-Core-Model/FASTTWithCondition.trait.st
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
"
## Relations
======================

### Children
| Relation | Origin | Opposite | Type | Comment |
|---|
| `condition` | `FASTTWithCondition` | `parentConditional` | `FASTTExpression` | The boolean condition tested|



"
Trait {
#name : 'FASTTWithCondition',
#instVars : [
'#condition => FMOne type: #FASTTExpression opposite: #parentConditional'
],
#category : 'FAST-Core-Model-Traits',
#package : 'FAST-Core-Model',
#tag : 'Traits'
}

{ #category : 'meta' }
FASTTWithCondition classSide >> annotation [

<FMClass: #TWithCondition super: #Object>
<package: #'FAST-Core-Model'>
<generated>
^ self
]

{ #category : 'accessing' }
FASTTWithCondition >> condition [
"Relation named: #condition type: #FASTTExpression opposite: #parentConditional"

<generated>
<FMComment: 'The boolean condition tested'>
^ condition
]

{ #category : 'accessing' }
FASTTWithCondition >> condition: anObject [

<generated>
condition := anObject
]

{ #category : 'navigation' }
FASTTWithCondition >> conditionGroup [
<generated>
<navigation: 'Condition'>
^ MooseSpecializedGroup with: self condition
]
Loading