yihao yang,

If you can't use a better name than Int64Flag_xxxxxxxxxxxxxxIntervalMS then 
at least make the code readable. For example,

    interval := time.Duration(*Int64Flag_xxxxxxxxxxxxxxIntervalMS) * 
time.Millisecond
    time.Sleep(interval - time.Since(timeStart))

Peter

On Tuesday, July 25, 2017 at 7:43:53 PM UTC-4, yihao yang wrote:
>
> Hi,
>
> I have some problems on break long code into lines when developing in 
> golang.
> Could you please help me on how to break a long code as following?
> time.Sleep(time.Duration(*Int64Flag_xxxxxxxxxxxxxxIntervalMS) * time.
> Millisecond - time.Now().Sub(timeStart))
>
> Thanks,
> Yihao
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to