Re: [sage-devel] Re: Infix mod operator?

2016-06-01 Thread Bruno Grenet
I've already commented on trac, but a very quick answer: Le 01/06/2016 00:07, Volker Braun a écrit : Well "mod 3" can't occur inside a valid Python expression so at most it'll unbreak currently-broken code ;-) It can be valid in Sage: sage: implicit_multiplication(True) sage: mod = 5 sage: mo

Re: [sage-devel] Re: Infix mod operator?

2016-06-01 Thread Daniel Krenn
On 2016-06-01 00:31, Nils Bruin wrote: > On Tuesday, May 31, 2016 at 3:11:00 PM UTC-7, Volker Braun wrote: > > PS: This would still leave room for a preparser hack for the > easy-to-implement paren-mod infix operator: > > X (mod Y) -->X * mod(Y) > > Thoughts? > The pr

Re: [sage-devel] Re: Infix mod operator?

2016-06-01 Thread Erik Bray
On Tue, May 31, 2016 at 7:07 PM, Nils Bruin wrote: > > On Tuesday, May 31, 2016 at 9:37:48 AM UTC-7, Volker Braun wrote: >> >> This was a request at sd74: >> >> sage: 42 mod 8 >> 2 >> sage: type(42 mod 8) >> >> >> Thoughts? Ticket is at http://trac.sagemath.org/ticket/20735 > > >

[sage-devel] Re: Infix mod operator?

2016-05-31 Thread Nils Bruin
On Tuesday, May 31, 2016 at 3:11:00 PM UTC-7, Volker Braun wrote: > > PS: This would still leave room for a preparser hack for the > easy-to-implement paren-mod infix operator: > > X (mod Y) -->X * mod(Y) > > Thoughts? > Sneaky. If we generalize that preparser rule and suppress the * gene

[sage-devel] Re: Infix mod operator?

2016-05-31 Thread Volker Braun
PS: This would still leave room for a preparser hack for the easy-to-implement paren-mod infix operator: X (mod Y) -->X * mod(Y) Thoughts? -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving

[sage-devel] Re: Infix mod operator?

2016-05-31 Thread Volker Braun
On Tuesday, May 31, 2016 at 7:07:14 PM UTC+2, Nils Bruin wrote: > > - you're introducing a new reserved word in sage, which will break > previous code. > Well "mod 3" can't occur inside a valid Python expression so at most it'll unbreak currently-broken code ;-) Though, especially for polynomi

[sage-devel] Re: Infix mod operator?

2016-05-31 Thread Nils Bruin
On Tuesday, May 31, 2016 at 9:37:48 AM UTC-7, Volker Braun wrote: > > This was a request at sd74: > > sage: 42 mod 8 > 2 > sage: type(42 mod 8) > > > Thoughts? Ticket is at http://trac.sagemath.org/ticket/20735 >