Guild icon
DDraceNetwork
Development / developer
Development discussion. Logged to https://ddnet.tw/irclogs/ Connected with DDNet's IRC channel, Matrix room and GitHub repositories — IRC: #ddnet on Quakenet | Matrix: #ddnet-developer:matrix.org GitHub: https://github.com/ddnet
Between 2020-12-21 00:00:00Z and 2020-12-22 00:00:00Z
Avatar
i saw this by coincidence when i was moving in google 👨💻
01:58
this amazing and weird because this video before 9 years ago
Avatar
idk why we still not have something like this giftee_red and i remember i did suggest something like this but for hats and clothes
Avatar
0.7 has something like this
Avatar
Avatar
Learath2
0.7 has something like this
so why we no have this now?
Avatar
we are still running 0.6
Avatar
really?!
Avatar
nouis 0.7 was bad for while and nobody moved to the new protocol.
Avatar
oh yeah i remember
04:04
we have now just starting page like 0.7 but we still 0.6 right? (edited)
Avatar
it still lacks some of the protocol events (like changing names) but they are "supposedly" working on it.
04:04
we have a compatibility layer for 0.7 on the serverside
04:04
ddnet client is 0.6 only
Avatar
Avatar
hussainx3
we have now just starting page like 0.7 but we still 0.6 right? (edited)
yes
Avatar
Avatar
TsFreddie
it still lacks some of the protocol events (like changing names) but they are "supposedly" working on it.
this looks hard i not understand anything XD
Avatar
basically you can't change names mid-game in 0.7
04:07
so we can't steal some things than teeworld 0.6 and puting in ddnet? (edited)
Avatar
we can, with some patch work, but at that point it would be better off just move to 0.7.
Avatar
so what we wait?
Avatar
idk what everybody thinks.
04:09
I think we can wait.
04:09
it is perfectly playable. and we have skins downloads which is somewhat an alternative to 0.7's skin system.
04:10
other than that we miss nothing from 0.7 that would benefit ddrace.
Avatar
Avatar
hussainx3
idk why we still not have something like this giftee_red and i remember i did suggest something like this but for hats and clothes
i want hats and clothes
Avatar
you can't have those in 0.7 as well.
Avatar
this looks easier than make hat santa for everyskin
Avatar
that's true
04:13
still if we really want hat we can add a hat sprite and apply it to every skins. you don't need 0.7 protocol for that
04:13
but everybody hated the mapres change before. i doubt we can pull this off without some outrage lol. (edited)
04:15
also why am i here spitting opinions.
Avatar
👍 don't stop your opinions make you looks pro
Avatar
Avatar
TsFreddie
but everybody hated the mapres change before. i doubt we can pull this off without some outrage lol. (edited)
why ?
04:17
maps 0.6 not work in 0.7?
04:18
or what you mean
Avatar
Avatar
TsFreddie
still if we really want hat we can add a hat sprite and apply it to every skins. you don't need 0.7 protocol for that
i want make like million a hat
04:19
so add in every skin this like forever
04:20
and we still need group for skins if we will make a lot more skins
Avatar
Some people doesn't like the forced Halloween themed map for a while.
Avatar
Дядя Женя 2020-12-21 04:31:06Z
I'm still making some preparations to add possibility to choose hat that will be displayed on top of your tee. With restrictions to use some hats only if you have enough points for it
🤩 1
04:33
There is a problem btw, that's not all skins allows you to draw hat on them which will look normal
Avatar
Avatar
Дядя Женя
There is a problem btw, that's not all skins allows you to draw hat on them which will look normal
yeah of course because some skins not normal(circle/tee) but this problem for makers this skins not for we if it is work with most skins this would be perfect
Avatar
Дядя Женя 2020-12-21 05:20:28Z
@hussainx3 we have a ddnet database with skins. And we will also have such one for hats. So all the supported skins should be compatible with hats, otherwise some players would have to switch skin or play without a hat...
05:36
First time before doing something I would like to open discussion on it, so we could come up with some agreement. I really want to implement Hats in ddnet, so player could choose hat that will be displayed on top of his tee and make some points requirements for the hats. So you play >> you raise your pts >> you open new hats. Other players would see if you're pro if you have one of PRO hats with a lot of points required to open. Also new players would be motivated to play just a little mo...
Avatar
i think anyone can copy paste for hat and get it free
06:09
so for me this looks not work
06:11
i was think about just putting million hats there (anyone make hat and putting it in ddnet like skins)
Avatar
Дядя Женя 2020-12-21 06:13:58Z
Boring
06:17
this will so tirdy for you and you not sure if this will be work or not and if the players will be use hats?
06:19
and maybe example players see hat 100 points more pretty than hat for 5000
Avatar
Avatar
Дядя Женя
Boring
it is not boring
06:24
i guess if you finish than this will be there a lot players would be start make hats (edited)
06:28
and if this succeeded you can go for next level to clothesheartw
Avatar
useless
06:31
and a lot people if he have more choices to choice player for himself (in all games) he is can take hour and more
06:32
so if we can leave players take more time in game this point for we so not useless (edited)
Avatar
global leaderboard. barely ^^
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 08:31:56Z
@hussainx3 pls edit your messages a bit less in this channel. they get resend to the bridge and it gets a bit hard to follow the conversation :/
Avatar
If anyone wants to summarize the discussion, feel free to. I just wanted to create the issue now.
09:45
Talk about it MOOOORE
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 10:43:53Z
hmm on the server side i can do a m_Input.m_Direction = 1; but i cant do GetInput().m_Direction = 1;
10:43
CNetObj_PlayerInput GetInput() { return m_Input; };
10:44
it says error: using rvalue as lvalue
10:44
i dont get what is going on here
Avatar
it even tells you what's wrong 😛
11:12
you are using an rvalue as an lvalue
11:13
The call to GetInput returns m_Input by value, an rvalue to be specific. The LHS of the assignment operator needs to be an lvalue, thus your assignment is invalid
Avatar
👀 if you return a "class" like that, does it just copy the class data into the stack.
Avatar
many factors play into this. C++ really wants you to use value returns so it has many optimizations here
11:15
it will avoid a copy (copy-elision) at all costs if possible 😄
Avatar
i see
Avatar
if you don't store it at all, it shouldn't create a copy at all
Avatar
but like if you change it's member after return, it can't do anything but make a copy right?
Avatar
you can't change a member through an lvalue reference to an object 😛
Avatar

Checklist

  • [x] Tested the change ingame
  • [ ] Provided screenshots if it is a visual change
  • [ ] Tested in combination with possibly related configuration options
  • [ ] Written a unit test if it works standalone, system.c especially
  • [ ] Considered possible null pointers and out of bounds array indexing
  • [ ] Changed no physics that affect existing maps
  • [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--u...
Avatar
👀 i kinda get it but probably don't
Avatar
(strictly speaking I used the word "reference" wrongly there, it's more like a "label" I guess is the term the standard would refer to it)
Avatar
does lvalue/rvalue thing has to do with whether CNetObj_PlayerInput is a class or a struct
Avatar
Anonymously contributed, will need someone with Polish language to check

Checklist

  • [ ] Tested the change ingame
  • [ ] Provided screenshots if it is a visual change
  • [ ] Tested in combination with possibly related configuration options
  • [ ] Written a unit test if it works standalone, system.c especially
  • [ ] Considered possible null pointers and out of bounds array indexing
  • [ ] Changed no physics that affect existing maps
  • [ ] Tested the change with [ASan+UBSan or va...
Avatar
compiler can do copy elision even if copy has side effects 👀
Avatar
Avatar
TsFreddie
does lvalue/rvalue thing has to do with whether CNetObj_PlayerInput is a class or a struct
doesn't seem like it
11:20
me brain dead
Avatar
i think a value returned by a function is an rvalue
Avatar
A non reference return by a function is a prvalue
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:21:31Z
so i have to return a refrence when i want to change it?
Avatar
Which is an rvalue type, thus can't appear on the left side of an assignment
Avatar
u also have to hold the reference in a variable probs
Avatar
You don't
Avatar
ok i think i get it now
Avatar
ah i see
Avatar
A function call whose return type is an lvalue reference can appear on the left side of an assignment as it's an lvalue
Avatar
CNetObj_PlayerInput Input = GetInput(); Input.m_Direction = 1;
11:23
this way you put the rvalue into the stack but you don't change m_Input at all
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:23:17Z
but then this is a new object right?
11:23
ye
Avatar
rvalue lvalue glvalue xvalue prvalue
Avatar
That would create a new CNetObj_PlayerInput (probably on the stack)
Avatar
so you need either a pointer or reference
Avatar
Input is an lvalue at that point
Avatar
👀 how the hell have I never run into this before
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:24:25Z
so i have to edit character.h to add an CNetObj_PlayerInput *GetInput();
Avatar
This whole value type system allows a lot of optimizations
Avatar
Although i would probably never do GetInput().m_Direction because that sounds dumb with a Get in front of it
Avatar
ChillerDragon you might aswell return a reference not a pointer
11:25
Yeah, something like Input().m_Direction = 1 looks more sane
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:25:29Z
hmk
11:25
i never understood references thats why i stay away
Avatar
or even just SetInput(CNetObj_PlayerInput input)
11:25
make a copy and pass it back lol.
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:26:22Z
thats sounds hacky but i also thought about it actually xd
Avatar
👀 i would never pass a C++ interview like this
Avatar
@TsFreddie making a copy and setting it proooobably optimizes fine, but it sounds so wasteful 😛
Avatar
yeah, but although it does kinda make sense coming from high level oop lol
11:27
but although, what is english
Avatar
but although furthermore moreover however, I don't like oop to begin with so it makes sense that sounds bad to me 🙂
11:29
I'm still a typescript guy mind you.
11:29
i don't even know what kind of language ts is
Avatar
typescript is the only acceptable form of javascript, good for you
Avatar
js sucks so bad
11:29
ts saved it
Avatar
languages without type systems are just so goofy
11:30
every single one of them try to bolt on type systems now that they see it's an insane proposition to pass references to "thing" around and praying they are of the correct type
Avatar
well you can still "any" through the entire typescript
Avatar
rust and go seems cool.
11:30
never used em tho
Avatar
go can be learned in 1 day
Avatar
that's why i haven't done it
Avatar
learnt*
Avatar
anyway, I need to get out of bed and have breakfast, I can stay here all day chatting about static typing but that's not very good for me 😛
Avatar
good morning
Avatar
@Ryozuki but Go has a garbage collector 😄
Avatar
i love making cmd binaries with https://github.com/clap-rs/clap
A full featured, fast Command Line Argument Parser for Rust - clap-rs/clap
11:32
so packed
Avatar
GC bad gang is here
Avatar
@Comrade yeah xd
Avatar
tee_thinking tbh i really wish there's a typescript runtime that can optimize based on type. don't know if it is a factor tho.
11:36
I actually learnt typescript via lua. Because lua gave me a headache when i was making dota2 custom games.
Avatar
but Lua is so simple
11:37
everything is a table there
Avatar
1 based index always threw me off. tstl does index +1 and -1 for you.
Avatar
Is nutella and bread a healthy breakfast?
Avatar
tee_thinking am i allowed to ask what does deen do for daytime job.
Avatar
he works at SAP iirc
Avatar
making in memory databases
11:42
iirc
Avatar
cool
11:43
teeworlds always distract me from doing anything productive
Avatar
I lie to myself and say teeworlds is productive
11:43
It lets me keep my sanity
Avatar
i dont even code much in tw anymore
11:44
sadSnail
Avatar
well i kinda does that too but sometimes it is a bit too much.
Avatar
If I felt like teeworlds was a waste of time I might aswell just give up on doing anything at all since it's like the last thing that motivates me a bit
Avatar
👀 that sounds bad tbh
Avatar
Yes, so I keep pretending it's productive
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:47:13Z
why should it be a waste of time
Avatar
I sometime have thoughts of taking advantage of chinese teeworlds community to have monetary gain. Tom always talks me out of it.
11:48
which give me better reasons to do something else. but i keep come back to teeworlds for the past few months.
Avatar
ChillerDragon no monetary gain, no education value. Thus no value, thus a waste of time
Avatar
its fun
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:49:28Z
so ur meanin of life is education and money?
11:49
mine is fun
Avatar
fun has value
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:49:43Z
so tw is literally the meaning of my life xd
Avatar
fun doesn't put food on the table tho.👀
Avatar
You can't have fun if you make 8 euros an hour at a supermarket
Avatar
Avatar
TsFreddie
fun doesn't put food on the table tho.👀
for that you work
Avatar
👀 well if i have a job i wouldn't blame myself for being unproductive lol
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:51:10Z
make ddnet pay2win then
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:51:18Z
xd
Avatar
LCSG47 was trying to convince me to add microtransactions yesterday
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 11:51:56Z
or ask for donations to fund some food for Learath while he builds nice tw stuff
Avatar
i have other projects that i'm legally not allowed to monetize as well. it's like giving away your time for nothing.
11:52
👀 although teeworlds is the only one i still care about
Avatar
Teeworlds has an odd charm to it
11:54
The code just feels so familiar, I feel at home while coding tw
Avatar
we deserved it
11:55
aPESXMas_Hacker
Avatar
teeworlds also gave me a illusion of me being capable of making a game and selling it. which obviously isn't happening any time soon.
Avatar
also i think the hats issue opened by the russian guy is a rly bad thing
11:57
ddnet shouldnt have locked content
11:57
its rly good its so open
Avatar
tee_thinking like why bother when ppl can just make a one-liner patch to bypass it
Avatar
Hats I'm not sure about either, but a way to display your achiebement would be cute
Avatar
well achievements are not locked content
Avatar
steam achiebement when
Avatar
achievements can be tricky
Avatar
I didn't read his issue. Is it hats 4 money?
Avatar
i don't think tho
11:59
so*
Avatar
x points unlocks hats
11:59
or smth like that
11:59
a nono
Avatar
Eh, points are free
Avatar
achievements require account system, right?
Avatar
we are doing points without account just fine
Avatar
My red line is asking money for cosmetics
12:00
That's a no no :P
Avatar
it is no that bad considering it will just be a server feature like how you get points in mmotee or something
12:00
but ddnet itself is more free than other mods maybe
12:01
i mean like city mods or something
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:01:09Z
what about selling ddnet clients
12:01
add a pricetag on steam
Avatar
what about we kidnap ChillerDragon and sell for server cost.
Avatar
You know what's funny? This game is completely open source. If we actually get it popular a company can just take it, bolt on cosmetics and make bank :P
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:01:57Z
@TsFreddie i offered multiple times to host servers ...
Avatar
unless they have experienced ddnet devs its hard to compete against ddnet itself imho
12:02
it would be lot of resources and money
12:02
and that just for a community of 1k active players
Avatar
We already have more than enough for servers thanks to generous donations from people including ChillerDragon :P
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:02:51Z
seems like outplayed my self there
12:02
xd
Avatar
i mean a freaking company would have resources and money to burn if they have vision for net gain.
Avatar
@Learath2 thats why ddnet should be AGPL-3
12:03
hippo
Avatar
It's peanuts to hire 2-3 devs and host servers
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:03:06Z
like companys bother
Avatar
They already have the infrastructure
Avatar
blame teeworlds for not being GPL
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:03:42Z
nobody would notice if some big ass company uses tw networking code to build a new game with different physics and graphics
Avatar
The purpose of the GNU Affero GPL is to prevent a problem that affects developers of free programs that are often used on servers.
12:03
use AGPL for server stuff
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:04:04Z
who enforces these licenses tho @Ryozuki
Avatar
i think big ass company would just take the idea and use their own netcode
Avatar
Avatar
[quakenet] ChillerDragon
who enforces these licenses tho @Ryozuki
ur lawyer
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:04:20Z
mine?
Avatar
Avatar
TsFreddie
i think big ass company would just take the idea and use their own netcode
^^ this exactly
Avatar
companies often fail due to greed vs open source projects
12:04
btw
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:04:55Z
i feel like restrictive licenses just scare smol hobby devs
Avatar
Chiller has a point there, most of these licenses have never been tried in court
Avatar
like nobody can stop me from making a simplified mobile ddnet game with rooms, accounts and stuff
Avatar
in my day life, open source projects tend to be higher quality
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:05:06Z
but nobody has a chance to fight big company
Avatar
although i don't think it would be very popular tho
Avatar
It would take a buttload of money even against a normal entity to litigate this, let alone a megacorp
Avatar
Avatar
[quakenet] ChillerDragon
i feel like restrictive licenses just scare smol hobby devs
"restrictive" it ensures ur freedom and ur users freedom
12:05
restrictive for a random company to yoink it and use it
12:05
wihtout giving back
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:05:55Z
if i dont want to publish the code of my first crappy mod it is restrictive
Avatar
open source is just a tool for companies to use without giving back
Avatar
I think only gpl has been tested in courts before once
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 12:06:12Z
but i feel like they can still do that
12:06
if nobody finds out nobody can even go to court in the first place
Avatar
👀 @Learath2 have you finished your bread
Avatar
And that's only US courts, god knows how it would go in the EU
Avatar
u atleast have grounds to file a lawsuit
Avatar
Avatar
TsFreddie
👀 @Learath2 have you finished your bread
Bred gone
Avatar
imagine fighting a open-source case in china.
Avatar
and u can always contact the https://www.eff.org/ to defend your rights
Defending your rights in the digital world
12:07
or the FSF
Avatar
It should be trivial to fight it in china. Whoever donates more to the CCP wins
12:07
So we automatically lose, case over
Avatar
Let's sell ddnet to tencent actually
12:08
It's so successful in china
Avatar
[quakenet] Ryozuki BOT 2020-12-21 12:09:09Z
ChillerDragon "smol hobby devs"
Avatar
actually we'll know immediately when some company decided to copy ddnet
Avatar
Open source projects are so odd. Like who even owns the source code to ddnet?
Avatar
[quakenet] Ryozuki BOT 2020-12-21 12:09:25Z
ChillerDragon u know that smoll hobby devs are actually retarded for using MIT thinking a company will use their software
Avatar
even before they ever announce it
Avatar
[quakenet] Ryozuki BOT 2020-12-21 12:09:28Z
and somehow they will get something
12:09
they couldnt be more wrong
12:09
smoll hobby devs should be the most interested in using gpl
Avatar
ddnet will for sure be blocked by the wall, if a company decided to make one themselves
Avatar
Ryozuki that's a misconception. MIT or BSD literally says you want nothing in return
Avatar
[quakenet] Ryozuki BOT 2020-12-21 12:10:22Z
Learath2 probs whoever represents ddnet, my bet is whoever owns ddnet.tw rn
12:10
so deen
Avatar
Oh yeah? China has laws protecting local companies too?
Avatar
[quakenet] Ryozuki BOT 2020-12-21 12:10:47Z
Learath2 yeah but i read lot of forums and they use MIT for what i said
Avatar
Never going to sell, end of story
Avatar
nah, companies can report with much larger impact
Avatar
Turkey proposed this a couple times, never got it past the supreme court
Avatar
Avatar
deen
Never going to sell, end of story
Not like anyone needs us to sell, they can just make their own :P
Avatar
[quakenet] Ryozuki BOT 2020-12-21 12:11:47Z
deen will u trademark ddracenetwork? is that even useful? xd
Avatar
DDRaceNetwork Inc.
Avatar
i think its good to protect
12:12
against something
Avatar
hire me plz
Avatar
We should get one of those evil looking skyscrapers
Avatar
and learath will be at the top
12:12
with heinrich in the shadows
12:12
CTO Learath2
12:12
CEO deen
12:12
POGGIES
Avatar
It would be so nice to be at the top of an evil megacorp
Avatar
Imagine having so much money the world feels communist. All the resources are at your disposal
Avatar
communist lol
12:14
u would laugh like this guy
12:14
truly evil
Avatar
no trademark required I think
Avatar
If I owned a megacorp I think I would want to pay my employees a living wage. Which is one of the many reasons I would never own a megacorp :P
Avatar
i think the top CEOs always lack empathy
12:16
and thats why they are ceos
Avatar
Amazon warehouses literally look like slave workshops. People pissing in bottles to avoid taking breaks is an insane proposition to me
Avatar
Our food delivery service have very strict policy for drivers too i think.
Avatar
Recent research reveals CEOs are not very useful on the average. Ofc there are a couple very bright ones but most are apparently not very beneficial, especially given the salaries they get
Avatar
like anything less than a 5 star means a fine for them iirc.
Avatar
China cranking things up to 11 again
Avatar
i think the idea is that people won't rate unless it is bad. but it is kinda weird that your wages are ties to random ass factors
12:20
and I definitely know people that nitpicking everything online.
Avatar
Anyway, gtg. I have 95 kanji to review and thermodynamics to read up on
Avatar
Maybe even finish up computer networking if the sudden extreme sleepiness leaves me alone today
14:52
Would it be possible to have a rank Command like $points
14:52
But for the rank
Avatar
$profile
Avatar
Ops
Avatar

Checklist

  • [x] Tested the change ingame
  • [ ] Provided screenshots if it is a visual change
  • [ ] Tested in combination with possibly related configuration options
  • [ ] Written a unit test if it works standalone, system.c especially
  • [ ] Considered possible null pointers and out of bounds array indexing
  • [ ] Changed no physics that affect existing maps
  • [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--u...
Avatar
ee4866b Add CAN sponsorship by YupHio - def-
Avatar
why when i vote rnadom unfinished map i sometimes get harvest map which i already finished
16:08
i havent finished all novice maps
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 16:12:24Z
nub
Avatar
@noby can't reproduce
Avatar
Avatar
deen
@noby can't reproduce
does it depend on client version
Avatar
no, server-side query
16:18
and the sql is really simple, so hard to see how it could go wrong
Avatar
it just hapened ask @Skeith
Avatar
did, yea
Avatar
SELECT Map FROM %s_maps AS maps WHERE Server = ? AND Map != ? AND Map NOT IN (SELECT Map FROM %s_race as race WHERE Name = ? ORDER BY %s LIMIT 1;
Avatar
did you maybe call the vote with dummy? @noby
Avatar
that could be
16:21
i dnt remember
Avatar
noboy
Avatar
Nooby is too high to vote correctly
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 18:17:28Z
did you try sleeping first before voting @noby xd
Avatar
Or not smoking em grass
Avatar
Ddnet crashes when I press keys shift + backspace when I rename a file name in the game Ddnet's Version : 15.2.4 Window 10 (Sorry if it's the wrong place to report bugs)
Avatar
[quakenet] ChillerDragon BOT 2020-12-21 18:39:20Z
good place
Avatar
@DarkOort how to rename a file
justatest 1
19:02
With demos I can't reproduce
Avatar
I tried threading in rust for the first time and I have a question about channels. It seems like a common pattern to me to clone a mpsc::Sender in a loop and move each clone into it's own thread. But after the loop the original Sender that was returned by mpsc::channel() will still be alive in the main thread. I could drop() it explicitly or put it in a scope. But is there a more elegant solution?
19:19
@heinrich5991 @Learath2
19:22
I guess that's the way to do it. Found a reddit thread about that here https://www.reddit.com/r/learnrust/comments/iavolt/okay_to_drop_original_mpscsender_when_creating/
19:24
Explicitly calling drop() is much better than a opening a scope because the scope could look unnecessary to someone reading the code
Avatar
@timakro explicit mem::drop is fine
Avatar
@heinrich5991 Do you know a rust lib to distribute tasks to a bunch of threads? If you know openmp I'm looking for something like the guided (http://jakascorner.com/blog/2016/06/omp-for-scheduling.html#guided) scheduling strategy (edited)
Avatar
rayon @timakro
21:06
API documentation for the Rust rayon crate.
Avatar
Maybe you've seen the Computerphile video from a few days back. I've implemented what they did in rust and parallelized it with rayon. Runs in 2m48s on my machine ^^ https://github.com/timakro/rust-unsorted/blob/main/countdown/src/main.rs (edited)
Exported 370 message(s)