Hi Than
Thank you for your fix. I have some curious about the difference between
the main Go compiler and gollvm. I read gollvm's readme and know that the
main difference comes from the efficiency of GC. Is the other difference
causes the symbol undefined reference as you mentioned above? Or so
I was curious if reducing the capacity of slice makes that memory available to
be reclaimed?
(1) Reducing capacity using a three-index:
var s = make([]int64, 1e9)
... add data to s, keeping a count ..
s = s[:n:n] // reduce length and capacity to number of items read
(2) Reducing capacity by sl
On Thu, Jul 18, 2019 at 6:50 AM Yuan Ting wrote:
>
> Thank you for your fix. I have some curious about the difference between the
> main Go compiler and gollvm. I read gollvm's readme and know that the main
> difference comes from the efficiency of GC. Is the other difference causes
> the symbo
On Thu, Jul 18, 2019 at 7:24 AM robfig wrote:
>
> I was curious if reducing the capacity of slice makes that memory available
> to be reclaimed?
>
> (1) Reducing capacity using a three-index:
>
> var s = make([]int64, 1e9)
> ... add data to s, keeping a count ..
> s = s[:n:n] // reduce length and
see https://go101.org/article/panic-and-recover-more.html for detailed
explanations.
On Thursday, July 18, 2019 at 12:52:13 PM UTC+8, ZPL wrote:
>
> Sorry for the bad formatting.
>
> > recover must be called directly by a deferred function
> func logPanic() {
> defer func() {
> if err := r
> Basically, it's hard to be sure that there isn't any other slice
somewhere that might permit references to that trailing memory
Ian, I am kind of curious about this case. I understand that "hard" is not
"impossible", but still - if I copy the needed part to a smaller array, how
does the GC kn
For example:
type Page struct {
views uint32
}
func (page *Page) SetViews(n uint32) {
atomic.StoreUint32(&page.views, n)
}
func (page *Page) Views() uint32 {
return atomic.LoadUint32(&page.views)
}
Keith Randall and Ian Lance Taylor said that atomic.Load is a
memory_order_acquire
On Thu, Jul 18, 2019 at 8:35 AM Andrey Tcherepanov
wrote:
>
> > Basically, it's hard to be sure that there isn't any other slice somewhere
> > that might permit references to that trailing memory
>
> Ian, I am kind of curious about this case. I understand that "hard" is not
> "impossible", but s
On Thu, Jul 18, 2019 at 8:35 AM T L wrote:
>
> For example:
>
> type Page struct {
> views uint32
> }
>
> func (page *Page) SetViews(n uint32) {
> atomic.StoreUint32(&page.views, n)
> }
>
> func (page *Page) Views() uint32 {
> return atomic.LoadUint32(&page.views)
> }
>
> Keith Randall
Is it named try? :P
On Wednesday, July 17, 2019 at 8:37:53 PM UTC-7, Michael Jones wrote:
>
> There is a special “collapse if err != nil blocks plugin for VS code.
>
> On Wed, Jul 17, 2019 at 5:37 PM > wrote:
>
>> Context:
>> 1. Golang can be very verbose, for example checking if err != nil afte
It is my opinion that it is only polite to acknowledge corporate sponsors
in a tangible way.
The problem is if you have only one corporate sponsor. I know for a fact
that members of the Smythe Group have contributed time to Go dev without
compensation. Many other people have also made contribu
On Thu, Jul 18, 2019 at 11:21 AM David Skinner wrote:
>
> It is my opinion that it is only polite to acknowledge corporate sponsors in
> a tangible way.
>
> The problem is if you have only one corporate sponsor. I know for a fact that
> members of the Smythe Group have contributed time to Go dev
Ha!
https://github.com/rstuven/vscode-iferrblocks
On Thu, Jul 18, 2019 at 10:32 AM Jim Robinson
wrote:
> Is it named try? :P
>
> On Wednesday, July 17, 2019 at 8:37:53 PM UTC-7, Michael Jones wrote:
>>
>> There is a special “collapse if err != nil blocks plugin for VS code.
>>
>> On Wed, Jul 1
Inspired from reading
https://github.com/golang/go/issues/32437#issuecomment-50187
After some careful thoughts on various different concerns and criticisms of
the existing proposal, I'd want to give a try from a different approach.
Using the famous example of CopyFile:
func CopyFile(src
On Friday, July 19, 2019 at 1:01:27 AM UTC+8, Ian Lance Taylor wrote:
>
> On Thu, Jul 18, 2019 at 8:35 AM T L >
> wrote:
> >
> > For example:
> >
> > type Page struct {
> > views uint32
> > }
> >
> > func (page *Page) SetViews(n uint32) {
> > atomic.StoreUint32(&page.views, n)
That's cool, having quick actions to do the folding is part way there.
Hehe, I am genuinely looking for a 'try' alternative! I think that an
editor-supported solution would keep everybody happy.
It would let the code be read as if it were written with some syntactic
sugar macro, but the code und
>
> Are there any editors that support some kind of customisable collapsing
> behaviour? Where the above code could be collapsed to something like:
>
Might be worth reading, commenting on and/or possibly upvoting this feature
proposal for GoLand?
https://youtrack.jetbrains.com/issue/GO-7747
-
Thank you. The explanation really makes sense. I think I should modify the
source code of etcd, or change to another project that is not so hackful.
On Thursday, July 18, 2019 at 10:55:39 PM UTC+8, Ian Lance Taylor wrote:
>
> On Thu, Jul 18, 2019 at 6:50 AM Yuan Ting >
> wrote:
> >
> > Thank
Funny thing that today Google has announced "official" store for Go-related
merch, which in it's essence is a try to take away even an even tiny
business opportunities for artists who were creating some goods and had a
very very little outcome on this. Now they will have ZERO.
Well done Google.
Thanks! I haven't heard of GoLand before.
Looks like the One Line Returns feature is like an 80% solution, I would
toggle that on all the time.
I'm not sold on completely hiding the error line like you want, but I'll
definitely start a thread with that GoLand dev about how hard it would be
to
> Funny thing that today Google has announced "official" store for Go-related
> merch, which in it's essence is a try to take away even an even tiny business
> opportunities for artists who were creating some goods and had a very very
> little outcome on this. Now they will have ZERO.
really? t
I don't know how this works for vscode, but for GoLand you can write your
own syntax-aware custom folding plugin, see this plugin as an example of
how to do it:
https://plugins.jetbrains.com/plugin/9320-advanced-java-folding
This doesn't mean we are not open to new ideas on how to improve the e
Thank you Ian, you reply is very much appreciated.
... what if a compiler would do a bit of helping "magic"? I would suspect
it does know that you return a subslice of an allocated array (something
that compiler still sees up the call stack). Would it be possible to put a
code for "This big all
Another funny thing and I'm glad that you mentioned, is that "Woman Who Go"
and other known "non-google" initiatives, as you said, were founded or
co-founded by "developer advocate" Ashley McNamara. I don't know what kind
of contract or collaboration, or relations she had with Google or Google
what you're doing has a term: character assassination.
please take it elsewhere. there are plenty of forums to air your grievances.
On Thu, Jul 18, 2019 at 11:31 PM Space A. wrote:
>
> Another funny thing and I'm glad that you mentioned, is that "Woman Who Go"
> and other known "non-google" ini
On Friday, 19 July 2019 07:35:53 UTC+2, andrey mirtchovski wrote:
>
> what you're doing has a term: character assassination.
>
> please take it elsewhere. there are plenty of forums to air your
> grievances.
>
> - Strongly worded agreement deleted -
Lucio.
--
You received this message becau
26 matches
Mail list logo