verify whether two records are equal - Maple Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Logic : Boolean : verify : verify/record

verify/record - verify whether two records are equal

Calling Sequence

verify(expr1, expr2, record)

verify(expr1, expr2, record(ver))

Parameters

expr1, expr2

-

anything

ver

-

name; verification

Description

• 

The verify(expr1, expr2, record) calling sequence returns true if the expressions expr1 and expr2 are both of type record, and are equal as records. Two records are considered equal if they have the same slot names, and corresponding slot values are equal or unassigned.

• 

The verify(expr1, expr2, record(ver)) calling sequence returns true if the expressions expr1 and expr2 are both of type record, and are equal with respect to the verification ver.  For a list of verifications, see verify.

• 

The special verifications %NULL, seq, and &, can be used to verify an expression sequence in a record. See verify/exprseq.

Examples

r:=Record'a'=2,'b'=3:

s:=Record'a'=2,'b'=4:

verifyr,r,'record'

true

(1)

verifyr,s,'record'

false

(2)

r:=Record'a'=2,'b'=3,c:

s:=Record'a'=2,'b'=3,c:

verifyr,s,'record'

true

(3)

r:=Record'a'=x21,'b'=3:

s:=Record'a'=x1x+1,'b'=3:

verifyr,s,'recordexpand'

true

(4)

See Also

expand, Record, verify


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam