t;>> ```
>>>> main » cat main.go
>>>> // +build production
>>>> // +build linux
>>>>
>>>> package main
>>>>
>>>> 21:13:35 ~/tmp/testrepo0017 0:00:00
>>>> main » go fmt .
>>>> main
ction && linux
>> // +build production,linux
>>
>> package main
>> ```
>> - sean
>>
>>
>> On Fri, Nov 11, 2022 at 9:13 PM Sandeep Kalra
>> wrote:
>>
>>> and similar issue with other style of adding tags as we
main.go
>
> 21:13:39 ~/tmp/testrepo0017 0:00:00
> main » cat main.go
> //go:build production && linux
> // +build production,linux
>
> package main
> ```
> - sean
>
>
> On Fri, Nov 11, 2022 at 9:13 PM Sandeep Kalra wrote:
>
>> and similar issue with o
and similar issue with other style of adding tags as well
i.e.
// +build tag1,tag2
// +build tag1 tag2
etc
On Friday, November 11, 2022 at 3:07:40 PM UTC-6 Sandeep Kalra wrote:
> Original code:
>
> $ cat production.go
>
> //go:build production
> // +build production
roduction.go
$ cat production.go
//go:build production
// +build production
package main
const (
isProductionCode = true
isDebugCode = false
)
Thanks,
Sandeep Kalra
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscr
Thanks for confirming.
On Monday, May 6, 2019 at 6:16:49 PM UTC-4, Ian Lance Taylor wrote:
>
> On Sun, May 5, 2019 at 11:13 AM >
> wrote:
> >
> > Hi, Is there a way to renew a context that has already reached a
> deadline?
>
> No, sorry.
>
> Ian
>
--
You received this message because you
Hi, Is there a way to renew a context that has already reached a deadline?
package main
import (
"context"
"fmt"
"time"
)
func sleepAndPrint(ctx context.Context, msg <-chan string, b <-chan bool) {
for {
select {
case <-ctx.Done():
fmt.Println("
Thanks Harley.
I will pick your example and will see if this is do-able...
Sandeep
Best Regards,
Sandeep Kalra
On Mon, Mar 20, 2017 at 11:48 PM, Harley Laue
wrote:
> I have some code that I've sat on for some time:
>
> type Cell int
> type Function func() error
>
>
;
>
> On Mon, Mar 20, 2017 at 7:57 PM, Sandeep Kalra > wrote:
>
>> Is there any option to convert []byte to func (Assuming that []byte
>> carries valid function)
>>
>> package main
>>
>> import (
>> "fmt"
>>
Is there any option to convert []byte to func (Assuming that []byte
carries valid function)
package main
import (
"fmt"
"io/ioutil"
)
func run(b []byte) {
/// HERE ?
}
func main() {
if b, e := ioutil.ReadFile("./file.go"); e != nil {
fmt.Println(e)
} else {
10 matches
Mail list logo