Project

General

Profile

Feature #124

change long args in matrices into MachineInt (?)

Added by Anna Maria Bigatti about 12 years ago. Updated almost 11 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
Category:
Safety
Target version:
Start date:
04 Apr 2012
Due date:
% Done:

100%

Estimated time:
Spent time:

Description

For "public" functions (not member functions) like

  void SetEntry(MatrixView& M, long i, long j, const BigInt& N)

should we have instead
  void SetEntry(MatrixView& M, MachineInt i, MachineInt j, const BigInt& N)

?


Related issues

Related to CoCoALib - Bug #89: MachineInt or long as fn arg type for indicesClosed2012-02-09

Related to CoCoALib - Design #925: MachineInt or long for args which are indices (yet again)In Progress2016-09-20

History

#1 Updated by John Abbott about 12 years ago

The args being considered are "indices"; we should be consistent regarding all sorts of index (well, at least non-negative index).

Here are some examples:
  • matrix row/column
  • indet in a PolyRing or PPMonoid
  • component in a module
  • argument to operator[] in any context (??)

Even though the permitted values may often be non-negative, we should not use any unsigned integral type.

#2 Updated by John Abbott almost 11 years ago

  • Category set to Safety
  • Status changed from New to Rejected
  • Assignee set to John Abbott
  • Target version set to CoCoALib-0.9953
  • % Done changed from 0 to 100

I am rejecting this task since it is effectively covered by #89 which deals with indices in general; and it seems simplest to regard matrix row/col indices as a specific case of general indices. I believe it would be odd to handle matrix indices differently from other ones.

#3 Updated by John Abbott over 7 years ago

  • Related to Design #925: MachineInt or long for args which are indices (yet again) added

Also available in: Atom PDF