Error Messages/40460

< Error Messages
Revision as of 00:39, 6 February 2016 by Bbecane (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Error message examples

In an assignment of the form 'Slice(X, 1) := ...', the value of the local variable
X must have an implicit dimension of be one-dimensional.

Cause

You are either:

  1. assigning to a slice of a non dimensional variable.
  2. assigning to a slice of a multidimensional variable.

You cannot use the Slice function with non dimensional variables. You need to specify the dimension being used to slice for a multidimensional variable.

In the following example, an assignment is made to a slice of C, a multidimensional variable.

Index A := 1..3;
Index B := 4..6;
Var C: Array(A, B, A*B);
Slice(C, A, 1) := 5;
...

Remedies

If you are trying to slice a multidimensional variable, pass in the index being used to slice the variable for assignment.

See Also

Comments


You are not allowed to post comments.