/usr/share/axiom-20170501/src/algebra/U32VEC.spad is in axiom-source 20170501-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | )abbrev domain U32VEC U32Vector
++ Author: Waldek Hebisch
++ Description:
++ This is a low-level domain which implements vectors
++ (one dimensional arrays) of unsigned 32-bit numbers. Indexing
++ is 0 based, there is no bound checking (unless provided by
++ lower level).
U32Vector() : SIG == CODE where
SIG ==> OneDimensionalArrayAggregate Integer
CODE ==> add
Qsize ==> QVLENU32$Lisp
Qelt ==> ELTU32$Lisp
Qsetelt ==> SETELTU32$Lisp
Qnew ==> GETREFVU32$Lisp
#x == Qsize x
++ returns the length of the vector
++
++X t1:=new(10,10)$U32Vector
++X #t1
minIndex x == 0
++ minIndex returns the minimum index of the vector
++
++X t1:=new(10,10)$U32Vector
++X minIndex t1
empty() == Qnew(0$Lisp, 0$Lisp)
++ empty() returns a new vector of length 0
++
++X t1:=empty()$U32Vector
new(n, x) == Qnew (n, x)
++ new(n, x) returns a new vector of length n filled with x
++
++X t1:=new(10,7)$U32Vector
qelt(x, i) == Qelt(x, i)
++ qelt(x, i) returns the i-th element of x
++
++X t1:=new(10,7)$U32Vector
++X qelt(t1,3)
elt(x:%, i:Integer) == Qelt(x, i)
++ elt(x, i) returns the i-th element of x
++
++X t1:=new(10,7)$U32Vector
++X elt(t1,3)
qsetelt_!(x, i, s) == Qsetelt(x, i, s)
++ qsetelt(x, i, s) modifies the i-th element of x to be s
++
++X t1:=new(10,7)$U32Vector
++X qsetelt!(t1,3,9)
setelt(x:%, i:Integer, s:Integer) == Qsetelt(x, i, s)
++ setelt(x, i, s) modifies the i-th element of x to be s
++
++X t1:=new(10,7)$U32Vector
++X setelt(t1,3,9)
fill_!(x, s) == (for i in 0..((Qsize x) - 1) repeat Qsetelt(x, i, s); x)
++ fill!(x, s) modifies a vector x so every element has value s
++
++X t1:=new(10,7)$U32Vector
++X fill!(t1,9)
|