On Fri, Mar 12, 2021 at 04:31:07AM -0800, schle...@gmail.com wrote:
> I am not sure about the technical details, but would it be possible to rename
> those identifiers with?: (require (rename-in fluent [→ ~>] [→→ ~~>]))
> I think if you define those arrows as syntax parameters they could be renamed,
> but I don't know whether that is the "right" way to do it in racket.
> https://docs.racket-lang.org/reference/stxparam.html?q=syntax-parameter

AFAICT, syntax-parse doesn't resolve syntax-parameters. I can parameterise the 
parse pattern using syntax classes, but those can't be changed using rename-in.

There is probably a solution to this problem. I'm just not seeing it yet.

> 
> I like the ~> and ~~> arrows they are quite distinct, seems like a good 
> default
> to me.
> I think the rackety way would be to have one default name and make them
> rename-able.
> Then fluent/unicode would not be necessary, but I also would not be bothered 
> by
> it.
> 
> On a technical level I would prefer a solution that does not result in more 
> and
> more code generation for every renamed variant.
> Roger Keays schrieb am Donnerstag, 11. März 2021 um 19:44:28 UTC+1:
> 
>     > > > It might be nice to use ~> and ~>> (or |> and |>> or choose your 
> own)
>     as infix
>     > > > to avoid clashing with >.
> 
>     I'm thinking about changing the default operators to ~> and ~~> and making
>     the unicode versions available using (require fluent/unicode). I actually
>     prefer the long arrow for thread-last to the current syntax (>>).
> 
>     Any thoughts?
> 
>     On Wed, Mar 10, 2021 at 07:31:08PM -0500, Hendrik Boom wrote:
>     > On Wed, Mar 10, 2021 at 08:23:46PM +0700, Roger Keays wrote:
>     > > > I've been using the Clojure-like threading package for a while now
>     and this has
>     > > > some nice advantages that are mentioned in the docs, like blending
>     the first
>     > > > arg > and last arg >> variants easily in a sequence.
>     > > >
>     > > > How does fluent manage this infixing from a (require ...) rather 
> than
>     a #lang?
>     > >
>     > > It provides a custom #%app macro which rearranges the code into 
> regular
>     s-expressions. I was surprised by how much flexibility this feature of
>     racket gives you. It would have taken months to build this from scratch in
>     any other language. The racket version is 25 lines of code. [1]
>     > >
>     > > > It might be nice to use ~> and ~>> (or |> and |>> or choose your 
> own)
>     as infix
>     > > > to avoid clashing with >.
>     > >
>     > > I wanted a single character because I use it so often. I suppose with
>     the unicode (→) option, there is less need for a single-character 
> solution.
>     Need to think about this...
>     >
>     > Only if your keyboard has a convenient single key to type it with.
>     >
>     > -- hendrik
>     >
>     > >
>     > >
>     > > [1] https://github.com/rogerkeays/racket-fluent/blob/main/main.rkt
>     > > >
>     > > >
>     > > > Dan
>     > > >
>     > > > --
>     > > > You received this message because you are subscribed to the Google
>     Groups
>     > > > "Racket Users" group.
>     > > > To unsubscribe from this group and stop receiving emails from it,
>     send an email
>     > > > to racket-users...@googlegroups.com.
>     > > > To view this discussion on the web visit 
> https://groups.google.com/d/
>     msgid/
>     > > > racket-users/
>     > > > CAFKxZVVBV1sP%2BKk%2B%2Bdw7k7a_TcEsL-yz6%2BLKDLZOa2Wfc1RAYw%
>     40mail.gmail.com.
>     > >
>     > > --
>     > > You received this message because you are subscribed to the Google
>     Groups "Racket Users" group.
>     > > To unsubscribe from this group and stop receiving emails from it, send
>     an email to racket-users...@googlegroups.com.
>     > > To view this discussion on the web visit https://groups.google.com/d/
>     msgid/racket-users/sigid.0703ba7d55.20210310132341.GA3081%40papaya.papaya.
>     >
>     > --
>     > You received this message because you are subscribed to the Google 
> Groups
>     "Racket Users" group.
>     > To unsubscribe from this group and stop receiving emails from it, send 
> an
>     email to racket-users...@googlegroups.com.
>     > To view this discussion on the web visit https://groups.google.com/d/
>     msgid/racket-users/20210311003108.qjqsrn4kd6nbwtd5%40topoi.pooq.com.
> 
> --
> You received this message because you are subscribed to the Google Groups
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email
> to racket-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/
> racket-users/79e3eb5f-90cb-49fb-824b-92e5b184053en%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-users/sigid.27054beaab.20210312185750.GA6624%40papaya.papaya.

Reply via email to