On 03/23/2017 11:01 AM, oldk1331 wrote: > About the name, in C++ there's 'map', but that would be a worse name. > I think 'KeyValue' is fine, or consider 'Pair'?
When I was looking for the domain that turned out to be Product, I actually looked for Pair first. Yes, I'd definitely choose Pair over KeyValue. I'd even define Pair(A: Type, B: Type): with first: % -> A second: % -> B pair: (A, B) -> % if A has BasicType and B has BasicType then BasicType ... That gives probably a long list of conditional exports, but I'd prefer that explicit definition over the implicit behaviour of Record. Maybe instead of "pair" one can also use "construct". However, I guess, writing [a,b] then most often needs [a,b]$Pair(A,B) and is thus not so much better, except in cases like p: Pair(A, B) := [a, b] or when the type of p has already been specified before and one could write p := [a, b] Still, p := pair(a, b) would be more readable in a big junk of code. Ralf -- You received this message because you are subscribed to the Google Groups "FriCAS - computer algebra system" group. To unsubscribe from this group and stop receiving emails from it, send an email to fricas-devel+unsubscr...@googlegroups.com. To post to this group, send email to fricas-devel@googlegroups.com. Visit this group at https://groups.google.com/group/fricas-devel. For more options, visit https://groups.google.com/d/optout.