Skip to content

Commit 61c6c22

Browse files
committed
Issue #19 (ALF11-4) - Updated constraint text as proposed.
1 parent 157df27 commit 61c6c22

40 files changed

+220
-213
lines changed

org.modeldriven.alf.eclipse.papyrus/Libraries/resources/error-messages.txt

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
arithmeticExpressionOperandTypes
22
Illegal operand types.
3-
The operands of an arithmetic expression must both have type Integer or Real, unless the operator is + or %. If the operator is +, then both operands may also both have type String. If the operator is %, then both operands must have type Integer.
3+
The operands of an arithmetic expression must both have a type that conforms to type Integer or Real, unless the operator is + or %. If the operator is +, then both operands may also both have type a type that conforms to String. If the operator is %, then both operands must have a type that conforms to type Integer.
44

55
assignmentExpressionAssignmentsBefore
66

@@ -12,7 +12,7 @@ For a compound assignment, both the left-hand and right-hand sides must have a m
1212

1313
assignmentExpressionCompoundAssignmentTypeConformance
1414
Illegal types for the operator used.
15-
For a compound assignment, if the operator is an arithmetic operator, then either the left-hand side and the right-hand side both have type Integer, the left-hand side has type Real and the right-hand side has type Integer or Real, or they both have type String and the operator is +. If the operator is a logical operator, then either the left-hand side and the right-hand side both have type Boolean or Bit String or the left-hand side has type Bit String and the right-hand side has type Integer. If the operator is a shift operator, then the left-hand side must have type Bit String and the right-hand side must have type Integer.
15+
For a compound assignment, if the operator is an arithmetic operator, then either the left-hand side and the right-hand side both have a type that conforms to type Integer, the left-hand side has a type that conforms to type Real and the right-hand side has a type that conforms to type Integer or Real, or they both have a type that conforms to type String and the operator is +. If the operator is a logical operator, then either the left-hand side and the right-hand side both have a type that conforms to type Boolean or Bit String or the left-hand side has type Bit String and the right-hand side has a type that conforms to type Integer. If the operator is a shift operator, then the left-hand side must have a type that conforms to type Bit String and the right-hand side must have a type that conforms to type Integer.
1616

1717
assignmentExpressionDataValueUpdateLegality
1818
Illegal data value update.
@@ -48,11 +48,11 @@ The operands of a binary expression must both have a multiplicity upper bound no
4848

4949
bitStringUnaryExpressionOperand
5050
Operand must have type BitString or Integer and multiplicity upper bound of 1.
51-
The operand expression of a BitString unary expression must have type BitString or Integer and a multiplicity upper bound of 1.
51+
The operand expression of a BitString unary expression must have a type that conforms to type BitString or Integer and a multiplicity upper bound of 1.
5252

5353
booleanUnaryExpressionOperand
5454
Operand must have type Boolean and multiplicity upper bound of 1.
55-
The operand expression of a Boolean unary expression must have type Boolean and a multiplicity upper bound of 1.
55+
The operand expression of a Boolean unary expression must have a type that conforms to type Boolean and a multiplicity upper bound of 1.
5656

5757
castExpressionAssignmentsBefore
5858

@@ -76,7 +76,7 @@ The type name in a classification expression must resolve to a non-template clas
7676

7777
conditionalLogicalExpressionOperands
7878
Operands must have type Boolean.
79-
The operands of a conditional logical expression must have type Boolean.
79+
The operands of a conditional logical expression must have a type that conforms to type Boolean.
8080

8181
conditionalTestExpressionAssignmentsAfter
8282

@@ -88,7 +88,7 @@ The assignments before the first operand expression of a conditional-test expres
8888

8989
conditionalTestExpressionCondition
9090
First operand must have type Boolean and multiplicity upper bound of 1.
91-
The first operand expression of a conditional-test expression must be of type Boolean and have a multiplicity upper bound of 1.
91+
The first operand expression of a conditional-test expression must be of a type that conforms to type Boolean and have a multiplicity upper bound of 1.
9292

9393
expressionUniqueAssignments
9494

@@ -128,15 +128,15 @@ The target expression of the feature reference may not be untyped, nor may it ha
128128

129129
forAllOrExistsOrOneExpressionArgument
130130
Argument must have type Boolean and multiplicity upper bound of 1.
131-
The argument of a forAll, exists or one expression must have type Boolean and a multiplicity upper bound of 1.
131+
The argument of a forAll, exists or one expression must have a type that conforms to type Boolean and a multiplicity upper bound of 1.
132132

133133
incrementOrDecrementExpressionAssignmentsBefore
134134

135135
The assignments before the operand of an increment or decrement expression are the same as those before the increment or decrement expression.
136136

137137
incrementOrDecrementExpressionOperand
138138
Operand must have a type Integer or Real and multiplicity upper bound of 1.
139-
The operand expression must have type Integer or Real and a multiplicity upper bound of 1.
139+
The operand expression must have a type that conforms to type Integer or Real and a multiplicity upper bound of 1.
140140

141141
instanceCreationExpressionConstructor
142142
Constructor name must resolve to a compatible constructor operation, class or data type.
@@ -221,7 +221,7 @@ If the target of a name left-hand side disambiguates to a feature reference, the
221221

222222
numericUnaryExpressionOperand
223223
Operand must have a type Integer or Real and multiplicity upper bound of 1.
224-
The operand expression must have type Integer or Real and a multiplicity upper bound of 1.
224+
The operand expression must have a type that conforms to type Integer or Real and a multiplicity upper bound of 1.
225225

226226
outputNamedExpressionForm
227227
Illegal for output named expression.
@@ -257,11 +257,11 @@ If the unqualified name of a qualified name has a template binding, then the tem
257257

258258
relationalExpressionOperandTypes
259259
Operands must either both have type Natural, Integer or Real, or both have type Natural or UnlimitedNatural.
260-
The operand expressions for a comparison operator must both be of type Natural, Integer or Real, or both be of type Natural or UnlimitedNatural.
260+
The operand expressions for a comparison operator must both be of a type that conforms to type Natural, Integer or Real, or both be of a type that conforms to type Natural or UnlimitedNatural.
261261

262262
selectOrRejectExpressionArgument
263263
Argument must have type Boolean and multiplicity upper bound of 1.
264-
The argument of a select or reject expression must have type Boolean and a multiplicity upper bound of 1.
264+
The argument of a select or reject expression must have a type that conforms to type Boolean and a multiplicity upper bound of 1.
265265

266266
sequenceAccessExpressionIndexMultiplicity
267267
Index expression multiplicity upper bound must be 1.
@@ -277,7 +277,7 @@ If the elements of a sequence construction expression are given by a sequence ex
277277

278278
sequenceConstructionExpressionElementType
279279
Element types not compatible with the expression type.
280-
If the elements of a sequence construction expression are given by a sequence range, then the expression must have type Integer. If the expression does not have multiplicity, then its type must be a collection class.
280+
If the elements of a sequence construction expression are given by a sequence range, then the expression must have a type that conforms to type Integer. If the elements are given by a sequence element list, and the sequence construction expression has a non-empty type, then each expression in the list must have a type that either conforms to the type of the sequence construction expression or is convertible to it by bit string conversion or real conversion.
281281

282282
sequenceConstructionExpressionType
283283
Type cannot be empty, cannot be a template and must either have a multiplicity indicator or be a template class instantiation.
@@ -341,7 +341,7 @@ The referent behavior must have two in parameters, a return parameter and no oth
341341

342342
shiftExpressionOperands
343343
First operand must have type BitString or Integer; second operand must have type Integer.
344-
The first operand expression of a shift expression must have the type BitString or Integer. The second operand expression must have the type Integer.
344+
The first operand expression of a shift expression must have a type that conforms to the type BitString or Integer. The second operand expression must have that conforms to the type Integer.
345345

346346
superInvocationExpressionConstructorCall
347347
Superclass constructor call not allowed here.
@@ -493,7 +493,7 @@ The assignments before the block of a do statement are the same as the assignmen
493493

494494
doStatementCondition
495495
Condition expression must have type Boolean and multiplicity upper bound of 1.
496-
The condition expression of a do statement must have type Boolean and a multiplicity upper bound of 1.
496+
The condition expression of a do statement must have that conforms to type Boolean and a multiplicity upper bound of 1.
497497

498498
doStatementEnclosedStatements
499499

@@ -588,8 +588,8 @@ Expression type must conform to declared loop variable type.
588588
If the type of a loop variable definition is not inferred, then the first expression of the definition must have a type that conforms to the declared type.
589589

590590
loopVariableDefinitionRangeExpressions
591-
Range expressions must have type Integer and multiplicity upper bound of 1; same name cannot be assigned in both expressions
592-
If a loop variable definition has two expressions, then both expressions must have type Integer and a multiplicity upper bound of 1, and no name may be newly assigned or reassigned in more than one of the expressions.
591+
Range expressions must have type Integer and multiplicity upper bound of 1; same name cannot be assigned in both expressions.
592+
If a loop variable definition has two expressions, then both expressions must have that conforms to type Integer and a multiplicity upper bound of 1, and no name may be newly assigned or reassigned in more than one of the expressions.
593593

594594
loopVariableDefinitionTypeName
595595
Type name must resolve to a non-template classifier.
@@ -609,7 +609,7 @@ If a name is unassigned before the condition expression of a non-final clause, t
609609

610610
nonFinalClauseConditionType
611611
Condition expression must have type Boolean and multiplicity upper bound of 1.
612-
The condition of a non-final clause must have type Boolean and a multiplicity upper bound no greater than 1.
612+
The condition of a non-final clause must have that conforms to type Boolean and a multiplicity upper bound no greater than 1.
613613

614614
returnStatementAssignmentsAfter
615615

@@ -676,7 +676,7 @@ whileStatementAssignmentsBefore
676676
The assignments before the condition expression of a while statement are the same as the assignments before the while statement. The assignments before the block of the while statement are the same as the assignments after the condition expression.
677677

678678
whileStatementCondition
679-
Condition expression must have type Boolean and multiplicity upper bound of 1.
679+
Condition expression must have that conforms to type Boolean and multiplicity upper bound of 1.
680680
The condition expression of a while statement must have type Boolean and a multiplicity upper bound of 1.
681681

682682
whileStatementEnclosedStatements

0 commit comments

Comments
 (0)