Skip to content

list assignment for matrix objects #4533

@ThomasBreuer

Description

@ThomasBreuer

The following happens in GAP 4.11.1 as well as in the master branch.

gap> m:= NewZeroMatrix( IsPlistMatrixRep, Integers, 2, 3 );
<2x3-matrix over Integers>
gap> m{[1,2]}:= m{[2,1]};
Error, List Assignments: <rhss> must be a dense list (not a positional object)
[...]

The point is that the operation {}:= (ASSS_LIST) calls AsssListCheck, and this calls RequireDenseList for the third argument (the right hand side of the assignment). However, the matrix objects in question aren't lists, in particular they are not dense lists.
We want {}:= for manipulation matrix objects that aren't lists, thus the checks must be changed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions