Hi Ian,
Thanks for clarifying, yes it's no harm to leave the code untouched.
On Tuesday, August 15, 2023 at 3:21:57 AM UTC+8 Ian Lance Taylor wrote:
> On Mon, Aug 14, 2023 at 11:28 AM metronome wrote:
> >
> > >> If several different goroutines decide to wake up the polling
> > >> goroutine
Sorry, just thought it could also use clear to start getting accostumed :)
// GroupValue returns a new Value for a list of Attrs.
// The caller must not subsequently mutate the argument slice.
func GroupValue(as ...Attr) Value {
// Remove empty groups.
// It is simpler overall to do
Hello everyone, thank you for reading. I'm looking at the code of
slog.GroupValue
(https://cs.opensource.google/go/go/+/refs/tags/go1.21.0:src/log/slog/value.go;l=171)
and was wondering if we could benefit from reusing the same slice like this:
// GroupValue returns a new Value for a list of
Thank you very much, that's actually what I was looking for.
On Monday, 14 August 2023 at 13:57:35 UTC-3 Axel Wagner wrote:
> You might be interested in https://github.com/golang/go/issues/61372
>
> On Mon, Aug 14, 2023 at 3:52 PM Diego Augusto Molina <
> diegoaugu...@gmail.com> wrote:
>
>> Hi,
The scenario is:
1) sudo starts and sets up a signal handler for SIGCHLD
2) pam modules gets loaded
3) Go gets initialized and sets the SA_ONSTACK flag specifically by calling
rt_sigaction with a pointer to the existing signal handler in *sa_handler *
field*.*
4) Sudo initialized a new signal
On Mon, Aug 14, 2023 at 4:54 PM Pablo Caballero wrote:
> I started working on a Golang project (from my work). The following
> pattern makes the company configured linter to complain with:
> sloppyReassign: re-assignment to `err` can be replaced with `err :=
> myFunc2()` (gocritic)
>
> func
I started working on a Golang project (from my work). The following pattern
makes the company configured linter to complain with:
sloppyReassign: re-assignment to `err` can be replaced with `err :=
myFunc2()` (gocritic)
func myFunc() error {
...
blah, err := getBlah()
if err != nil {
return
On Mon, Aug 14, 2023 at 11:28 AM metronome wrote:
>
> >> If several different goroutines decide to wake up the polling
> >> goroutine before the polling goroutine wakes up, they will each write
> >> a single byte
>
> Wondering, with the introduction of "netpollWakeSig", does it still hold
>
On Mon, Aug 14, 2023 at 12:02 PM Chandrasekhar R wrote:
>
> My understanding currently is sudo sets up a signal handler in pre_exec and
> another signal handler later on which is tied into its main event loop.
> Go gets initialized when the pre_exec signal handler is used and it adds
>
My understanding currently is sudo sets up a signal handler in pre_exec and
another signal handler later on which is tied into its main event loop.
Go gets initialized when the pre_exec signal handler is used and it adds
rt_sigaction(SIGCHLD..) with the SA_ONSTACK flag as mentioned here
>> If several different goroutines decide to wake up the polling
>> goroutine before the polling goroutine wakes up, they will each write
>> a single byte
Wondering, with the introduction of "netpollWakeSig", does it still hold
true? Thanks.
On Tuesday, July 11, 2023 at 9:00:36 AM UTC+8 Ian
You might be interested in https://github.com/golang/go/issues/61372
On Mon, Aug 14, 2023 at 3:52 PM Diego Augusto Molina <
diegoaugustomol...@gmail.com> wrote:
> Hi, thank you for reading. Whenever I need to use a zero value for a
> generic type in a func I do something like the following:
>
>
Hi, thank you for reading. Whenever I need to use a zero value for a
generic type in a func I do something like the following:
func SetZero[T any](pt *T) T {
var zeroT T
*pt = zeroT
}
That's all good, but I wonder how, if possible, it could be proved to the
compiler that zeroT is the
>
> Do you have any evidence to the contrary?
Only that when Go 1.12 dropped, our similar function stopped working and
that reducing the skip seemed to do the trick.
The symptom was that our function would see an assembly file as the caller,
which I interpreted to mean that we'd skipped too
On Friday, 11 August 2023 at 17:56:01 UTC+1 Shinya Sakae wrote:
I often hear the term `shallow copy', but I don't know what `shallow clone`
means.
Don't worry: they are the same thing.
When cloning a map, the keys and values are set using ordinary assignment,
as the description says. It
15 matches
Mail list logo