New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add for/string and for*/string #2555
base: master
Are you sure you want to change the base?
Conversation
Is shrink-string calling make-vector?
…On Mon, Mar 25, 2019 at 8:33 AM Alex Knauth ***@***.***> wrote:
The for/string and for*/string forms are a lot like for/vector and
for*/vector, so I use the same common helper function for all four macro
definitions.
------------------------------
You can view, comment on, or merge this pull request online at:
#2555
Commit Summary
- add for/string and for*/string
File Changes
- *M* racket/collects/racket/private/for.rkt
<https://github.com/racket/racket/pull/2555/files#diff-0> (59)
Patch Links:
- https://github.com/racket/racket/pull/2555.patch
- https://github.com/racket/racket/pull/2555.diff
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#2555>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAYWsIIHT-gdZC2xVhpD_1GAALSjpw8dks5vaNBCgaJpZM4cG5PW>
.
|
Thanks, fixed now. |
Would this be better in |
Test cases, please.
…On Mon, Mar 25, 2019 at 8:49 AM Alex Knauth ***@***.***> wrote:
Thanks, fixed now.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#2555 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAYWsJfjN9XogqZsCR_HQsmkZFv6MSj9ks5vaNPggaJpZM4cG5PW>
.
|
And docs? |
And don't forget the `@history[]` that I always do! :)
…On Mon, Mar 25, 2019 at 9:27 AM Paulo Matos ***@***.***> wrote:
And docs?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#2555 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAYWsFZw3153sQsuFp5dwn1qF2rrFlAkks5vaNzZgaJpZM4cG5PW>
.
|
and exclude them from racket/base
May I ask for I actually needed
|
At this point I can't help but wonder if something like |
|
Why don't we have
and even an expression in this position? For efficiency I am sure but when did that hold us back in the past? |
In suggesting Maybe "racket/private/vector-wraps.rkt" is useful. Its macro would define a |
All the logic for (Currently its already duplicated, in both "racket/private/for.rkt" and "racket/private/vector-wraps.rkt") |
I am curious:
Is (for/string ...) faster than (vector->string (for/vector ...)) ?
/Jens Axel
Den man. 25. mar. 2019 kl. 21.04 skrev Alex Knauth <notifications@github.com
…:
All the logic for for/string and for/bytes is already in the compile-time
helper function for_/vector though. It would be a shame not to reuse that
code.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#2555 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAcLxfZJfrjI8DL1ihFeElMyLxuMIiJuks5vaSvPgaJpZM4cG5PW>
.
--
--
Jens Axel Søgaard
|
@mfelleisen Following up on this for posterity, this concept is now implemented in the reducers library I wrote:
There's a |
The
for/string
andfor*/string
forms are a lot likefor/vector
andfor*/vector
, so I use the same common helper function for all four macro definitions.