• 6 Posts
  • 315 Comments
Joined 2 years ago
cake
Cake day: July 6th, 2023

help-circle









  • In case the wording tripped anyone, generators (blocks and functions) have been available for a while as an unstable feature.

    This works (playground):

    #![feature(gen_blocks)]
    
    gen fn gfn() -> i32 {
        for i in 1..=10 {
            yield i;
        }
    }
    
    fn gblock() -> impl Iterator<Item = i32> {
        gen {
            for i in 1..=10 {
                yield i;
            }
        }
    }
    
    fn main() {
        for i in gfn() {
            println!("{i} from gfn()");
        }
        for i in gblock() {
            println!("{i} from gblock()");
        }
    }
    

    Note that the block-in-fn version works better at this moment (from a developer’s PoV) because rust-analyzer currently treats gfn() as an i32 value. But the block-in-fn pattern works perfectly already.



  • BB_C@programming.devtoRust@programming.devTypst 0.13 released
    link
    fedilink
    arrow-up
    4
    arrow-down
    2
    ·
    24 days ago

    While you missed the mark here since typst has all the important stuff open (I wouldn’t use the web interface even if it was free/open source), I appreciate that you’re keeping an eye open.

    If you were in r*ddit’s rust community a few years ago, you probably would have been banned, just like me😄

    A blog post from M$ mentioning Rust with zero code

    => straight to the top

    A news article regurgitating the same thing a week later

    => straight to the top

    Another news article two weeks later regurgitating the same thing, possibly with the addition of a random tweet from some M$ dev

    => straight to the top

    Anyone not sucking nu-M$'s ****

    => banished to the bottom, or worse.

    Things got so silly to the point where I made this jerk post (archive link) about one of these silly posts.


  • I wouldn’t correct you if this was a general community where the internet gantry hangs in numbers like the multiple !linux communities, but let’s keep things more factual here in !rust.

    After Wedson quit months ago, no one from the Rust-For-Linux effort has quit/resigned/whatever. No one quit who is relevant to current mainline kernel development in general, either.

    There is a difference between the actual Rust-For-Linux team, and Rust proponents who may write kernel code out-of-tree, or may happen to still be listed as maintainers in a dead poor GPU driver. Confusing the two is good for drama, but let’s not do that here.

    And the bad boy maintainer is entitled to his opinion (which I disagree with of course). An opinion which will always be more informed and relevant than 99.999% of whatever the internet gantry has been contributing.








  • Sure, there were/are still some bits and pieces of hardware support missing, but the overall experience rivaled or exceeded what you could get on most x86 laptops.


    But then also came the entitled users. This time, it wasn’t about stealing games, it was about features. “When is Thunderbolt coming?” “Asahi is useless to me until I can use monitors over USB-C” “The battery life sucks compared to macOS” (nobody ever complained when compared to x86 laptops…) “I can’t even check my CPU temperature” (yes, I seriously got that one).

    how many levels of dissonance is that?