hopehook
Repos
18
Followers
41
Following
22

The Go programming language

0
0

LiteIDE is a simple, open source, cross-platform Go IDE.

0
0

liteide.org source

0
0

Events

issue comment
time: Incorrect Time.IsDST() result for "Europe/Dublin" when using embedded timezone info

cc @ianlancetaylor @dmitshur

Created at 1 week ago
issue comment
unicode: use unicode.ToUpper on the result of unicode.ToLower returns the wrong rune if it is a Greek rune: ẞ and ϴ

CC @robpike

Created at 1 month ago

chore(deps): bump actions/setup-go from 2 to 3 (#3340)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Fix the GO-2022-0969 and GO-2022-0288 vulnerabilities (#3333)

chore(dep): Changes minimum support go version to go1.16 (#3361)

chore(go): Add support go 1.19 (#3272)

fix(typo): spelling covert -> convert (#3325)

chore(file): Creates a directory named path (#3316)

Co-authored-by: mohanak mohanak@mkcl.org

refactor(struct): Remove redundant type conversions (#3345)

Merge branch 'gin-gonic:master' into dev/unsafe_string

Created at 1 month ago

chore(deps): bump actions/setup-go from 2 to 3 (#3340)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Fix the GO-2022-0969 and GO-2022-0288 vulnerabilities (#3333)

chore(dep): Changes minimum support go version to go1.16 (#3361)

chore(go): Add support go 1.19 (#3272)

fix(typo): spelling covert -> convert (#3325)

chore(file): Creates a directory named path (#3316)

Co-authored-by: mohanak mohanak@mkcl.org

refactor(struct): Remove redundant type conversions (#3345)

Merge branch 'gin-gonic:master' into dev/strings_builder

Created at 1 month ago

chore(deps): bump actions/setup-go from 2 to 3 (#3340)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Fix the GO-2022-0969 and GO-2022-0288 vulnerabilities (#3333)

chore(dep): Changes minimum support go version to go1.16 (#3361)

chore(go): Add support go 1.19 (#3272)

fix(typo): spelling covert -> convert (#3325)

chore(file): Creates a directory named path (#3316)

Co-authored-by: mohanak mohanak@mkcl.org

refactor(struct): Remove redundant type conversions (#3345)

Created at 1 month ago
closed issue
x/website:

What is the URL of the page with the issue?

What is your user agent?

Screenshot

What did you do?

What did you expect to see?

What did you see instead?

Created at 1 month ago
issue comment
cmd/compile: unexpected error from constraint type inference

I'm not good at generics, maybe there is a flaw here. And I find the compiler will be happy with these cases:

Case one based on @RelicOfTesla's code:

type BaseT interface {
	Type1 | Type2
}
type BaseType int
type Type1 BaseType
type Type2 BaseType // float64

type ValueT[T BaseT] struct {
	A1 T
}

func NewType1() *ValueT[Type1] {
	r := NewT[Type1, ValueT[Type1]]()
	return r
}
func NewType2() *ValueT[Type2] {
	r := NewT[Type2, ValueT[Type2]]()  // add `, ValueT[Type2]`
	return r
}

func NewT[TBase BaseT, TVal ValueT[TBase]]() *TVal {
	ret := TVal{}
	return &ret
}
func TestGoType(t *testing.T) {
	r1 := NewType1()
	r2 := NewType2()
	t.Log(r1, r2)
	t.Log(reflect.TypeOf(r1), reflect.TypeOf(r2))
	fooT1(r1.A1)
	fooT2(r2.A1)
}

func fooT1(t1 Type1) {

}
func fooT2(t2 Type2) {

}

Case two based on @ianlancetaylor's code:

package p

type BaseT interface {
	Type1 | Type2
}
type BaseType int
type Type1 BaseType
type Type2 BaseType

type ValueT[T BaseT] struct {
	A1 T
}

func NewType1() *ValueT[Type1] {
	r := NewT[Type1, ValueT[Type1]]()  // add `, ValueT[Type1]`
	return r
}

func NewT[TInt BaseT, TVal ValueT[TInt]]() *TVal {
	ret := TVal{}
	return &ret
}

Case three is modified by me:

package p

type BaseT interface {
	Type1 | Type2
}

type Type1 int
type Type2 int

var _ = NewT[Type1, Type1]()  // add `Type1` or `Type2`

func NewT[TInt, TVal BaseT]() TVal {
	return TVal(0)
}

From the results, it seems that we do not support indirect type deduction TVal now.

Created at 1 month ago
issue comment
encoding/asn1: remove allocation from init

I checked all the code, the memory is allocated on initialization, nowhere else.

@ianlancetaylor @andig To clarify, do we need to deal with the allocation of memory during the program running phase?

Created at 1 month ago
pull request opened
Replace bytes.Buffer with strings.Builder where appropriate

To build strings more efficiently, use strings.Builder instead.

Created at 1 month ago
create branch
hopehook create branch dev/strings_builder
Created at 1 month ago
pull request opened
Remove redundant type conversions
  • With pull requests:
    • Open your pull request against master
    • Your pull request should have no more than two commits, if not you should squash them.
    • It should pass all tests in the available continuous integration systems such as GitHub Actions.
    • You should add/modify tests to cover your proposed code changes.
    • If your pull request contains a new feature, please document it on the README.
Created at 1 month ago
create branch
hopehook create branch dev/clean_up
Created at 1 month ago
issue comment
Feat: Convert strings and slices using the officially recommended way.

This change needs to wait for the release of go1.20, please review it at that time, thank you.

Created at 1 month ago
pull request opened
Feat: Convert strings and slices using the officially recommended way.

Go official is expected to provide unsafe.{SliceData, Slice, StringData, String} series methods in version 1.20 for conversion of strings and slices.

  • With pull requests:
    • Open your pull request against master
    • Your pull request should have no more than two commits, if not you should squash them.
    • It should pass all tests in the available continuous integration systems such as GitHub Actions.
    • You should add/modify tests to cover your proposed code changes.
    • If your pull request contains a new feature, please document it on the README.
Created at 1 month ago
create branch
hopehook create branch dev/unsafe_string
Created at 1 month ago
Created at 1 month ago
issue comment
time: unknown time zone "Europe/Kyiv"

also cc @dmitshur

Created at 1 month ago
issue comment
time: unknown time zone "Europe/Kyiv"

I confirmed, the master branch solved your problem, the version of playground may not be up to date. In addition, the latest timezone file was released after go1.19, this is not a bug of go1.19, so Backport does not seem to be feasible.

Created at 1 month ago
issue comment
time: unknown time zone "Europe/Kyiv"

@veqryn Does the latest timezone file solve your problem?

Created at 1 month ago
issue comment
time: unknown time zone "Europe/Kyiv"

In my local environment, Go 1.20 is ok. (Unpublished)

Created at 2 months ago
issue comment
time: unknown time zone "Europe/Kyiv"

cc @rsc

Created at 2 months ago
closed issue
# [Codecov](https://codecov.io/gh/ietf-tools/datatracker/pull/4475?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ietf-tools) Report

Codecov Report

Merging #4475 (455570a) into main (d3f25a6) will decrease coverage by 0.00%. The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #4475      +/-   ##
==========================================
- Coverage   88.43%   88.43%   -0.01%     
==========================================
  Files         296      296              
  Lines       39674    39689      +15     
==========================================
+ Hits        35086    35097      +11     
- Misses       4588     4592       +4     

| Impacted Files | Coverage Δ | | |---|---|---| | ietf/api/views.py | 89.06% <100.00%> (+0.17%) | :arrow_up: | | ietf/group/forms.py | 91.41% <100.00%> (+0.16%) | :arrow_up: | | ietf/nomcom/utils.py | 91.53% <100.00%> (+0.08%) | :arrow_up: | | ietf/nomcom/views.py | 96.73% <100.00%> (+<0.01%) | :arrow_up: | | ietf/stats/utils.py | 53.81% <100.00%> (ø) | | | ietf/utils/fields.py | 91.57% <100.00%> (+0.04%) | :arrow_up: | | ietf/utils/pipe.py | 82.60% <0.00%> (-4.35%) | :arrow_down: | | ietf/utils/text.py | 85.97% <0.00%> (-1.22%) | :arrow_down: | | ietf/doc/utils.py | 88.12% <0.00%> (-0.46%) | :arrow_down: | | ietf/submit/utils.py | 93.60% <0.00%> (-0.02%) | :arrow_down: | | ... and 3 more | |

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Originally posted by @codecov in https://github.com/ietf-tools/datatracker/pull/4475#issuecomment-1251191322

Created at 2 months ago
closed issue
x/tools/gopls:

gopls version

go env

What did you do?

What did you expect to see?

What did you see instead?

Editor and settings

Logs

Created at 2 months ago
closed issue
x/tools/gopls:

gopls version

go env

What did you do?

What did you expect to see?

What did you see instead?

Editor and settings

Logs

Created at 2 months ago
closed issue
x/vuln:

What version of Go are you using (go version)?

Does this issue reproduce at the latest version of golang.org/x/vuln?

What operating system and processor architecture are you using (go env)?

What did you do?

What did you expect to see?

What did you see instead?

Created at 2 months ago
closed issue
affected/package:

What version of Go are you using (go version)?

Does this issue reproduce with the latest release?

What operating system and processor architecture are you using (go env)?

What did you do?

What did you expect to see?

What did you see instead?

Created at 2 months ago
issue comment
runtime: go runs into a deadlock where a panicing application never acquires the debuglock due to non-atomic unlock

@a-milkyway Welcome back and your local complete stack trace can be very important. As you said the program has been suspended for so long, the situation should be more complicated.

I suspect cgo is the most insecure factor, it may not be handled well.

Created at 2 months ago
issue comment
unsafe: no documentation for unsafe.SliceData, StringData, or String

CC @mdempsky

Created at 2 months ago
issue comment
unsafe: no documentation for unsafe.SliceData, StringData, or String

Final work is in progress, there are still some comments on the revisions to the documentation that have not been resolved, so they have not been merged.

FYI: https://go-review.googlesource.com/c/go/+/427095

Created at 2 months ago
issue comment
all: using unsafe.{Slice,SliceData,String,StringData} to simplify code

CC @ianlancetaylor @mdempsky @randall77

Created at 2 months ago