[{"data":1,"prerenderedAt":451},["ShallowReactive",2],{"project-37744563":3},{"id":4,"name":5,"line":6,"line_source":7,"title":8,"url":9,"domain":10,"maker":11,"posted_at":12,"year":13,"points":14,"comments":15,"rank_in_year":16,"shown_in_year":17,"top":18,"tier":19,"category":20,"subcategory":21,"format":22,"keywords":23,"reception":29,"sentiment":30,"stance_mix":31,"scored_comments":36,"aspects":37,"strip":46,"post_text":48,"what":49,"said":87,"maker_in_thread":195,"shape":206,"grid":210,"attempts":413,"same_week":414,"maker_shows":43,"maker_hidden":443,"reader_version":444,"card":445},"37744563","pcz","A new stdlib for Golang focusing on platform native support","title","Show HN: A new stdlib for Golang focusing on platform native support","https:\u002F\u002Fgithub.com\u002Fprimecitizens\u002Fpcz","github.com","Leotard6963",1696281638,2023,154,82,396,3109,13,"notable","languages","standard library","library",[24,25,26,27,28],"go stdlib","golang","no gc","platform native","wasm","mixed",-0.132,{"positive":32,"neutral":33,"mixed":34,"critical":35},6,12,2,10,30,{"docs":38,"idea":39,"design":42,"execution":45},{"positive":34,"critical":34},{"positive":40,"critical":41},3,8,{"positive":43,"critical":44},1,0,{"positive":44,"critical":44},[40,40,44,44,44,47,40,40,40,43,43,47,40,40,40,40,40,44,44,40,44,44,44,44,44,40,43,40,44,44,44,44,44,44,43,40,40,43,47,43],5,"No gc, No goroutines, Produces small binaries while using the unmodified official go toolchain, and comes with complete Web SDK (generated from w3c\u002Fwebref).\n\nWe are building `pcz` to provide a reimagination of Go the language, in an effort to make it suitable for all kinds of programming tasks, and currently you can use it to build efficient web applications in Go using the generated Web SDK (as shown with the live web demo[1]).\n\nThe journey is just starting, any suggestions? or any critics?\n\n[1]: https:\u002F\u002Fprimecitizens.github.io\u002Flivedemos\u002F10-plat-web\u002F",{"problem":50,"audience":60,"pricing":70,"motivation":71,"time_to_build":70,"stack":75,"openness":84,"stage":85,"team_size":86},{"value":51,"source":52,"evidence":53},"Make Go suitable for more programming tasks, with platform-native APIs, small binaries and no GC or goroutines by default.","maker",[54,56],{"id":55},"post",{"id":57,"by":58,"text":59},"37751221","assbuttbuttass","I'm still a little confused after reading through the goals. It seems like there are a bunch of different unrelated goals: ``` - better js\u002Fwasm support - \"platform native sdk\" (I…",{"value":61,"source":62,"evidence":63},"Go developers building applications, including web and platform-native apps.","inferred",[64,67],{"id":65,"by":11,"text":66},"37751826","Yes, we are re-implementing (some of) the official std, but with careful redesign, and probably won't provide a lot of familiar apis, this is largely because packages from the…",{"id":68,"by":11,"text":69},"37749383","\"adapting to the platform\" is mostly related to the goroutine topic, as we are working on the js\u002Fwasm support and these applications prefer async\u002Fawait operations. re: goroutines…",null,{"value":72,"source":52,"evidence":73},"Reimagine Go to suit all kinds of programming tasks and platform-native development.",[74],{"id":55},[76,80],{"value":77,"source":52,"evidence":78},"Go",[79],{"id":55},{"value":81,"source":52,"evidence":82},"Generated Web SDK from w3c\u002Fwebref",[83],{"id":55},"open_source","prototype","unknown",{"praise":88,"objections":97,"requests":131,"questions":144,"alternatives":175},[89],{"value":90,"source":91,"evidence":92},"Clear non-goals and stated goals in the docs.","commenter",[93],{"id":94,"by":95,"text":96},"37748738","weinzierl","I love how they clearly state their goals at the beginning. This makes it immediately clear what it is about. Especially an importantly: \"Non-Goals\" \"Change the way the Go team…",[98,106,121],{"value":99,"source":91,"evidence":100},"Unclear what the project is or replaces; goals seem unrelated.",[101,105],{"id":102,"by":103,"text":104},"37749350","jonathanstrange","I don't think the goals are explained very clearly. Or, to put it another way, after the goals were explained I still had no idea what it actually does or replaces.",{"id":57,"by":58,"text":59},{"value":107,"source":91,"evidence":108},"Removing GC and goroutines removes what makes Go distinctive.",[109,113,117],{"id":110,"by":111,"text":112},"37749960","baq","> No gc, No goroutines You're taking away what makes Go Go - you're now building something that turns Go into Pascal, perhaps unwittingly? Curly braces are what's left, basically.",{"id":114,"by":115,"text":116},"37748683","DeathArrow","What is the point of Go without garbage collection and goroutines? You can use C.",{"id":118,"by":119,"text":120},"37750014","klabb3","At risk of derailment isn’t this a much better fit for Rust? I am saying this as someone who has used both extensively professionally and prefer Go in most cases. If you’re…",{"value":122,"source":91,"evidence":123},"Not a drop-in replacement for the official stdlib and not ABI-compatible with it.",[124,128],{"id":125,"by":126,"text":127},"37749900","jen20","I think the confusion is caused by the notion of a separate library that is also “stdlib” - which is the version that comes with the official distribution. This comment is the…",{"id":129,"by":11,"text":130},"37752271","Thank you for your suggestions, but I'm afraid the best we can do is to list packages compatible with both std. The problem is, in order to build a std, we have to use a lot of…",[132,137],{"value":133,"source":91,"evidence":134},"Clearer explanation of the project's goals and what it replaces.",[135,136],{"id":102,"by":103,"text":104},{"id":57,"by":58,"text":59},{"value":138,"source":91,"evidence":139},"Better explanation of the custom goroutine and scheduler design.",[140],{"id":141,"by":142,"text":143},"37752870","rogpeppe1","One of Go's big selling points is the avoidance of the \"red-blue problem\" (https:\u002F\u002Fjournal.stuffwithstuff.com\u002F2015\u002F02\u002F01\u002Fwhat-color-is-your-function\u002F). The standard Go…",[145,153,160],{"value":146,"source":91,"evidence":147},"How goroutine-less concurrency works with FFI and blocking calls.",[148,149],{"id":141,"by":142,"text":143},{"id":150,"by":151,"text":152},"37752804","maxmcd","Can you expand more on the ffi piece? Using CGO has never been fun. Will this expose threads and allow for C interop that is easier to reason about? Can I dream of using this…",{"value":154,"source":91,"evidence":155},"How memory is freed without GC.",[156],{"id":157,"by":158,"text":159},"37750181","ptsneves","One thing I do not understand is if there is no GC then how are stack allocated variables freed?in vanilla go there is no way to manually manage variable lifetime. Does this mean…",{"value":161,"source":91,"evidence":162},"How it compares to Zig, V, Rust, or TinyGo.",[163,167,171,172],{"id":164,"by":165,"text":166},"37753616","ngrilly","I'm glad seeing this, but without GC and goroutines, then I'm wondering why not use something like Zig instead?",{"id":168,"by":169,"text":170},"37748528","stefanos82","Goroutines was the selling point for me until they decided to introduce telemetry in their toolchain; that was what forced me to stop using Golang as a whole. About GC, I would…",{"id":118,"by":119,"text":120},{"id":173,"by":11,"text":174},"37750125","> converge or diverge Neither, though the final result can be similar, but at project level, tinygo and pcz has very different approaches to achieve the final result: - tinygo…",[176,183,187,191],{"value":177,"source":91,"evidence":178},"TinyGo",[179],{"id":180,"by":181,"text":182},"37749724","tbiehn","Reminds me of https:\u002F\u002Ftinygo.org\u002F - a project that brings Golang to embedded devices, browser (wasm) contexts. Do you converge or diverge from that project?",{"value":184,"source":91,"evidence":185},"Zig",[186],{"id":164,"by":165,"text":166},{"value":188,"source":91,"evidence":189},"V",[190],{"id":168,"by":169,"text":170},{"value":192,"source":91,"evidence":193},"Rust",[194],{"id":118,"by":119,"text":120},{"comments":196,"answered":197,"key":198},15,9,[199,202,205],{"id":200,"text":201},"37749501","Sorry to cause the confusion, we are building a stdlib for Go, and all these goals are related to the development experience when using our stdlib, and we are not aiming at…",{"id":203,"text":204},"37750241","You are right, the pcz std won't be a drop-in replacement to the official std as they have different modulepath. We decided to make it this way so: 1) you can import packages…",{"id":129,"text":130},{"commenters":207,"max_depth":197,"maker_replies":196,"first_comment_mins":208,"lifespan_hours":209},45,543,92,[211,213,215,217,219,221,225,228,232,234,236,239,242,243,246,250,252,253,254,256,259,261,263,265,267,270,271,273,277,278,281,282,285,287,289,292,294,297,299,301,303,306,309,311,314,318,321,323,326,328,330,332,334,336,338,341,345,347,350,352,354,357,361,363,366,368,371,373,375,377,380,382,384,385,389,392,395,398,400,401,403,406,408,410],[94,44,47,212,95,44],"project\u002Fpositive\u002Fdocs",[102,44,43,214,103,44],"project\u002Fcritical\u002Fdocs",[200,44,44,216,11,43],"maker\u002Fneutral\u002Fdocs",[125,44,40,218,126,44],"project\u002Fneutral\u002Fdocs",[203,44,44,220,11,43],"maker\u002Fneutral\u002Fdesign",[222,44,44,223,224,44],"37751034","commenter\u002Fneutral\u002Fnone","mst",[226,44,44,223,227,44],"37752408","tialaramex",[229,44,44,230,231,44],"37753992","other\u002Fneutral\u002Fnone","iudqnolq",[233,44,44,230,227,44],"37758983",[235,44,44,223,231,44],"37761830",[237,44,47,212,238,44],"37749504","diogenes4",[240,44,40,218,241,44],"37751317","dolmen",[129,44,44,216,11,43],[244,44,40,218,245,44],"37755819","anonacct37",[247,43,40,248,249,44],"37749208","project\u002Fneutral\u002Fidea","bjackman",[68,43,44,251,11,43],"maker\u002Fneutral\u002Fidea",[180,34,40,248,181,44],[173,34,44,251,11,43],[164,40,43,255,165,44],"project\u002Fcritical\u002Fidea",[257,40,44,223,258,44],"37754319","MarkMarine",[260,40,44,223,165,44],"37762445",[57,262,43,255,58,44],4,[264,262,44,251,11,43],"37751904",[150,47,47,266,151,44],"project\u002Fpositive\u002Fidea",[268,47,44,269,11,43],"37753119","maker\u002Fneutral\u002Fexecution",[141,32,40,248,142,44],[272,32,44,269,11,43],"37754049",[274,275,40,248,276,44],"37751210",7,"flkenosad",[65,275,44,220,11,43],[279,275,47,280,276,44],"37764035","project\u002Fpositive\u002Fdesign",[110,41,43,255,111,44],[283,197,40,248,284,44],"37750196","demi56",[286,197,44,269,11,43],"37750792",[157,35,40,288,158,44],"project\u002Fneutral\u002Fexecution",[290,35,44,230,291,44],"37750252","DanielHB",[293,35,44,230,224,44],"37751472",[295,35,44,230,296,44],"37753830","zoogeny",[298,35,44,230,291,44],"37756310",[300,35,44,269,11,43],"37750538",[168,302,40,248,169,44],11,[304,302,44,223,305,44],"37748595","fsociety",[307,302,44,223,308,44],"37748658","mseepgood",[310,302,44,223,169,44],"37748829",[312,302,44,223,313,44],"37748647","im_dario",[315,302,44,316,317,44],"37748783","other\u002Fneutral\u002Fprivacy","hknmtt",[319,302,44,230,320,44],"37749059","eddythompson80",[322,302,44,316,317,44],"37750443",[324,302,44,316,325,44],"37748871","fweimer",[327,302,44,316,320,44],"37749088",[329,302,44,316,241,44],"37751451",[331,302,44,316,241,44],"37751785",[333,302,44,251,11,43],"37748770",[335,302,40,218,241,44],"37751584",[337,302,44,216,11,43],"37752420",[339,302,43,214,340,44],"37749214","arendtio",[342,302,44,343,344,44],"37749275","commenter\u002Fneutral\u002Fdocs","elygre",[346,302,44,223,340,44],"37756522",[348,302,40,218,349,44],"37750197","dharmit",[351,302,44,223,241,44],"37751523",[353,302,44,223,284,44],"37751531",[355,302,44,223,356,44],"37751323","saclark11",[358,302,44,359,360,44],"37751780","commenter\u002Fcritical\u002Fnone","rakoo",[362,302,44,223,241,44],"37751854",[364,302,44,223,365,44],"37753109","d-z-m",[367,302,44,223,360,44],"37755361",[369,302,44,223,370,44],"37756337","duskwuff",[372,302,44,223,340,44],"37756494",[374,302,44,223,360,44],"37758583",[376,302,44,223,340,44],"37756453",[378,302,44,223,379,44],"37781774","harbage",[381,302,44,223,356,44],"37789873",[383,302,44,223,379,44],"37793189",[114,33,43,255,115,44],[386,33,40,387,388,44],"37748734","project\u002Fmixed\u002Fidea","debatem1",[390,33,44,223,391,44],"37749262","JodieBenitez",[393,33,47,266,394,44],"37749201","Cthulhu_",[396,33,43,255,397,44],"37749458","actionfromafar",[399,33,40,387,224,44],"37751556",[118,18,43,255,119,44],[402,18,44,251,11,43],"37750344",[404,18,47,405,224,44],"37751506","maker\u002Fpositive\u002Fidea",[407,18,44,251,11,43],"37751953",[409,18,43,255,119,44],"37752662",[411,18,43,255,412,44],"37752477","VWWHFSfQ",[],[415,420,424,429,434,439],{"id":416,"name":417,"points":418,"category":419},"37763098","Classic Video Poker",578,"games",{"id":421,"name":422,"points":423,"category":419},"37704760","overflow",400,{"id":425,"name":426,"points":427,"category":428},"37695530","Fill",360,"creative",{"id":430,"name":431,"points":432,"category":433},"37740870","OpenStatus",171,"infrastructure",{"id":435,"name":436,"points":437,"category":438},"37763822","Shuttle",167,"dev_tools",{"id":440,"name":441,"points":442,"category":438},"37710087","PDF Debugger",157,false,"v2",{"id":446,"name":5,"line":6,"ai":443,"cat":20,"year":13,"points":14,"comments":15,"rec":29,"s":447,"top":18,"kw":448,"maker":11,"domain":10,"tier":19,"attempts":44,"strip":449,"url":9,"mix":450,"praise":90,"objection":99,"sub":21},37744563,-0.13,[24,25,26,27,28],"3300053331153333300300000313000000133151",[32,33,34,35],1794036642655]