On 01/24/2012 11:20 PM, Waldek Hebisch wrote:
Due to long names this is tricky to indent nicely regardless of
rules.  I would probably format this as:

                patternMatch(x : %, p : Pattern Float,
                             l : PatternMatchResult(Float, %)) ==
                    patternMatch(x@Rep, p,
                                 l pretend PatternMatchResult(Float, Rep),
                                 kfltmatch
                                )$PatternMatchPolynomialCategory(Float,
                                    IndexedExponents K, K, R, Rep)
                                        pretend PatternMatchResult(Float, %)

Due to long names this is tricky to indent nicely regardless of
rules.  I would probably format this as:

               patternMatch(
                   x: %,
                   p: Pattern Float,
                   l: PatternMatchResult(Float, %)
               ) == patternMatch(
                   x@Rep,
                   p,
                   l pretend PatternMatchResult(Float, Rep),
                   kfltmatch
               )$PatternMatchPolynomialCategory(
                   Float,
                   IndexedExponents K,
                   K,
                   R,
                   Rep
               ) pretend PatternMatchResult(Float, %)

In fact, getting rid of the "pretend" part, would make that expression much more readable.

BTW, I quickly looked over the code, PatternMatchable, PatternMatchResult, PatternMatchTools, PatternMatchPushDown etc. require S: SetCategory as their first Parameter. But I haven't yet seen where they use S alone. (Hopefully, I didn't overlook something.) They all take signatures with "Pattern S". So it would probably make sense to pass around P: Cat where Cat is the category of Pattern(R) (without the RetractableTo(R) part).

Ralf

--
You received this message because you are subscribed to the Google Groups "FriCAS - 
computer algebra system" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/fricas-devel?hl=en.

Reply via email to