Hi, there! How to properly clean up sessions after before disconnecting
the server or before starting it? have a problem that the server
is on a free hosting that periodically shuts down the server.
Since cookies are stored with me and they are no longer relevant,
my server is panicking. This
Thanks for confirming. I wrote that function and erased a good bit of the
overhead.
bytes.Buffer for the no-escapes path and strconv.Quote otherwise.
On Wed, Oct 13, 2021, 8:49 PM Ian Lance Taylor wrote:
> On Wed, Oct 13, 2021 at 3:46 PM 'Tim Hockin' via golang-nuts
> wrote:
> >
> > Is
On Wed, Oct 13, 2021 at 3:46 PM 'Tim Hockin' via golang-nuts
wrote:
>
> Is there any ready-built function that can tell me whether `strconv.Quote()`
> would produce a different string than its input, without actually running it?
> Or is there a clearly documented set of rules one could use to
If I find a string with a stray backslash in it (which passes IsPrint()) I
still need to quote.
I dug into the Quote() impl and this seems like the right path. Thanks!
On Wed, Oct 13, 2021 at 4:31 PM Robert Engels wrote:
> I was thinking the other way. If !IsPrint() then strconv.Quote()
>
>
I was thinking the other way. If !IsPrint() then strconv.Quote()
> On Oct 13, 2021, at 6:24 PM, Tim Hockin wrote:
>
>
> ` IsPrint(r) || r == '\\' || r == '"' ` passes tests. I need to build
> confidence in that, though :) Thanks.
>
>> On Wed, Oct 13, 2021 at 4:16 PM Robert Engels wrote:
` IsPrint(r) || r == '\\' || r == '"' ` passes tests. I need to build
confidence in that, though :) Thanks.
On Wed, Oct 13, 2021 at 4:16 PM Robert Engels wrote:
> A simple loop calling IsPrint is your best bet. You could then have a
> custom implementation of Quote that started at a specified
A simple loop calling IsPrint is your best bet. You could then have a custom
implementation of Quote that started at a specified index.
> On Oct 13, 2021, at 5:46 PM, 'Tim Hockin' via golang-nuts
> wrote:
>
> Is there any ready-built function that can tell me whether `strconv.Quote()`
>
Is there any ready-built function that can tell me whether
`strconv.Quote()` would produce a different string than its input, without
actually running it? Or is there a clearly documented set of rules one
could use to test each rune in a string?
I am trying to avoid allocations, and MOST of
Hi, I did a GitHub repo that offers gotips without compiling.
I wanted to use the Go fuzzing feature that's now merged on master in a CI
job for detecting bugs, but compiling go every time was slow, and caching
meant the build would get too stale.
I've released it here:
On Wed, Oct 13, 2021 at 11:36 AM roger peppe wrote:
> ISTM that in a sense, generics *are* behind a flag in 1.18, on a
> per-module basis at any rate - if your go.mod file doesn't declare a Go
> version of at least 1.18, then you can't use type parameters.
>
The (important) difference being
On Tue, 12 Oct 2021 at 01:42, Ian Lance Taylor wrote:
> On Mon, Oct 11, 2021 at 2:36 AM peter.m...@gmail.com
> wrote:
> >
> > I'm curious, was any consideration given to hiding generics behind a
> flag in 1.18? The idea being it's such a complex feature that one could
> imagine a backwards
11 matches
Mail list logo