6 ms·
Hopefully the licensing requirements can be made simple as well! I recently wanted to submit a 3 character change to golang that significantly speeds up strcon
by hannibalhorn 6y ago
Hopefully the licensing requirements can be made simple as well!
I recently wanted to submit a 3 character change to golang that significantly speeds up strconv.ParseFloat(), but lost interest about 2-3 minutes into reading this: https://golang.org/doc/contribute.html https://golang.org/doc/contribute.html
- nerdponx 6y agoThat seems outside of the scope of an in-browser text editor...
- hannibalhorn 6y agoSure - I'm just venting. I found something trivial that makes a small difference, but the contribution process was overly cumbersome. To the parent poster's point, I feel if I could easily submit even a small subset of the trivial changes I have sitting around in local forks, it'd greatly improve several projects.
- lukevp 6y agoWhy not post the change here so someone else could contribute it? Sounds useful.
- hannibalhorn 6y agoThat'd be awesome! diff --git a/src/strconv/atof.go b/src/strconv/atof.go index 28ad094..49cec69 100644 --- a/src/strconv/atof.go +++ b/src/strconv/atof.go @@ -410,12 +410,12 @@ out: } // Exact powers of 10. -var float64pow10 = []float64{ +var float64pow10 = [...]float64{ 1e0, 1e1, 1e2, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 1e12, 1e13, 1e14, 1e15, 1e16, 1e17, 1e18, 1e19, 1e20, 1e21, 1e22, } -var float32pow10 = []float32{1e0, 1e1, 1e2, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10} +var float32pow10 = [...]float32{1e0, 1e1, 1e2, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10} // If possible to convert decimal representation to 64-bit float f exactly, // entirely in floating-point math, do so, avoiding the expense of decimalToFloatBits. math.Pow10() already uses arrays this way, and I found a ~10% performance while optimizing an alternative float parsing implementation by making the same change.
- toomuchtodo 6y agoI just want to say kudos and well done to post the diff here.
- tom_mellior 6y agoDidn't you just poison this change and ensure that it can never be applied? Having posted this anonymously, nobody can sign the Contributor License Agreement and promise truthfully that this is original code that they have the rights to contribute. Including yourself, in the future.
- z3t4 6y agoYou can not copyright the ... (dot dot dot) nor can you claim copyright to an existing work by adding ... to it. You might be able to pattern it though...
- tom_mellior 6y agoI don't know the specifics of Google's contributor agreement (you need to log in with a Google account just to read it), but in my experience they are much stricter than copyright law. I've heard of organizations that would like to force people to sign contributor agreements just to be allowed to open GitHub issues. Because the issue might contain information that might taint everything. At least in the view of corporate lawyers.
- sally1620 6y agoTechnical advancements are always held back by politics. This is one of the main advantages of GPL, there is no CLA to sign.
- throwaway43423 6y agoCLA's are imposed by companies, not licenses. I'm quire sure that companies with OSS projects under GPL licenses would still want external contributors to certify that the code they contribute is theirs to contribute and can legally be licensed as GPL.
- pabs3 6y agoIndeed, there is the Developer Certificate of Origin for that: https://developercertificate.org/ https://developercertificate.org/
- semafour 6y agoSure there is: https://www.gnu.org/licenses/why-assign.html https://www.gnu.org/licenses/why-assign.html The owner of a GPL project doesn't own the copyright for contributed code (and therefore can't license it themselves under GPL), unless they receive a copyright assignment.