Hacker Newsnew | past | comments | ask | show | jobs | submit | ben-schaaf's commentslogin

> scale, security, whatever

Yea, who needs performance or security in a web framework!?


Did you deliberately miss my point?

Heck the longer I live, the more I realize AI is catching my mistakes.


I wasn't able to find the answer on that page or with google, does bluetooth LE solve the dogshit quality when using the microphone?

Yes, you can simultaneously use full-quality source and sink (speaker and microphone) streams [0]. And from personal experience, this works exactly as you would expect.

As you've seen, the documentation on LE Audio is rather horrible. The Android documentation [1] is semi-useful even on other platforms, and the official book [2] is also helpful if you're willing to wade through a ton of dense technical details, but there's not really much else available on the internet. I've had to spend an annoying amount of time tracing stuff with Wireshark and reading through the specifications [3] (which are thankfully free) and the BlueZ source code [4] to figure stuff out.

(The poor documentation mostly only matters if you're trying to do something specific; LE Audio mostly "just works" on Android out-of-the-box and Linux after you change the single config setting from [0])

[0]: https://www.collabora.com/news-and-blog/blog/2025/11/24/impl...

[1]: https://developer.android.com/develop/connectivity/bluetooth...

[2]: https://www.bluetooth.com/wp-content/uploads/2025/01/Introdu...

[3]: https://www.bluetooth.com/specifications/specs/

[4]: https://github.com/bluez/bluez/


In my experience, it's a significant improvement, but I wouldn't call it a solution. If non-LE drop in quality is like 1/10, with LE it's like 6/10.

I should point out that unlike the other reply I haven't really bothered researching it at all, I just upgraded from a non-LE pair to a LE pair recently.


Not sure why you're taking the rk3588 as a milestone for ARM, when it's a low end chip using core designs that were old when it released. Cortex-A76 is from 2018, so if that's the yardstick then the K3 is 8 years behind. Even then at the time the A76 was released Apple was significantly ahead with their own ARM CPUs.

I can't find anything related to division returning an error type. Looking at std.math.divExact, rem, mod, add, sub, etc. it looks to me like you're expected to use these if you don't want to panic.

Actually you're right, I was going by the source code which was in the link of the comment you replied to, but I missed that that was specifically for divExact and not just primitive division.


> Is there a difference between c++ and java/go/etc if you enforce at code review for C++ to use only auto memory management like smart ptrs, containers, etc?

Smart pointers and containers are nowhere near memory safe, just enforcing their use gets you nowhere. `std::vector::operator[](size_t)` doesn't check bounds, `std::unique_ptr::operator*()` doesn't check null.

> Imo the strong point of rust is compile error if you try to use an obj after move (unlike c++ with undef behavior

The state of a value after being moved is defined by the move constructor. It is unspecified by the spec, but it's generally not undefined behavior.


They do when using hardned runtimes configuration, which was compiler specific, and starting with C++26 is officially part of the standard.

It naturally doesn't cover C style programming in C++.


The hardened runtime improves things, but it's still a far cry from memory safety. For example `std::vector::erase` has no hardened precondition. And of course the rest of the language around the stdlib is still entirely unsafe, not just the C parts.


In theory, that will be taken care of with contracts and further revisions.

In practice, it depends on how the contracts drama folds out.

However I do agree it is still not quite there.

Still, C++ isn't going anywhere anytime soon, so any improvement is welcomed, even rustc has to gain from it.

I don't expect any RIR for GCC and LLVM happening any time soon, not only due to existing code, also due to all universities, and companies that contribute to upstream and aren't racing to adopt Rust.


What you mean by smart ptrs not being memory safe? Vector access can be done with at method


As I said, unique_ptr (or any of the others), do not check for null. So you can do this, and it will cause a segfault:

    std::unique_ptr<int> a;
    printf("%d\n", *a);
Similarly unique_ptr::operator[] doesn't (and can't) do bounds checking, for example:

    std::unique_ptr<int[]> a = std::make_unique<int[]>(2);
    printf("%d\n", a[2]);
There's also no attempt to limit the construction of invalid smart pointers, for example:

    int num;
    std::unique_ptr<int> a(&num);
Smart pointers simplify memory management, and they're slightly harder to misuse than regular pointers, but they simply make no attempt at providing memory safety.


Which unfortunately most people avoid using, and until C++26 there is no at() for span.

The best is really to enable compiler specific hardening.


> It's funny how pointing a fact is called whataboutism.

What do you think whataboutism is?


At this point, it's just something stupid people say. It used to mean that when you pointed out that my people were desperate for the freedom of living under capitalism, I would point out that you lived in an apartheid state.

Somehow, here, "whataboutism" means that if after you point out that the EU is coming up with an age verification system that they claim preserves personal privacy, I point out that the EU is also very much, openly, against any sort of personal privacy. Somehow that's some form of communist propaganda. Or Russian propaganda. Terrorist? Whatever. The important part is that I'm someone who should be watched or arrested if I continue to question your motives on behalf of our enemies.


Noise is one of the things that improved moving to an apartment for me. We've got bylaws about noise with quiet periods, bans on bothersome noise, a smoking ban and a (loud) pet ban. We also have better windows that block noise, and decent noise insulation in the floors despite the hard flooring.

Compared to suburbia where neighbours started mowing at 7am, loud parties went late into the night and dogs barked all day, it's oddly quiet.


Could you describe the difference between the artificial flavour vanilin made in a lab, and the natural flavour vanilin extracted from a vanilla bean?


OK for vanilla, however most of the fruit artificial flavors are compound that have nothing to do with the elements from the natural fruit but at some point, someone in the food industry decided it tasted "similar" to the natural fruit.

For some of them, like cherry or coconuts, the artificial flavor tastes nothing like the natural flavor.


To my knowledge benzaldehyde is the most common cherry flavor, and I agree it doesn't taste much like cherries. It's also a naturally occurring compound we produce from cassia oil, and it's naturally contained in almonds, apricots, apples and cherries.

As for coconut there's Lactones, which - you guessed it - occur naturally.

> OK for vanilla, however most of the fruit artificial flavors are compound that have nothing to do with the elements from the natural fruit but at some point, someone in the food industry decided it tasted "similar" to the natural fruit.

Care to provide a source?


Someone needs to gain physical access to the ballot after voting in order to erase it. If they can do that they can just as well make it invalid using a pen, or they can just tear it up.

On the other hand, disappearing ink has been around for a long time.


No, it is not statically knowable if it is actually moved.

    void foo(Obj && arg) {}
Does not move `arg`. It's fairly easy to write code that assumes `std::move` moves the value, but that can lead to bugs. For example:

    void some_function(std::vector<int> &&);
    void some_function2(std::vector<int> &&);

    void main() {
        std::vector<int> a = { 1 };
        some_function(std::move(a));

        a.push_back(2);
        some_other_function(std::move(a));
    }
The expectation is that `some_other_function` is always called with `{ 2 }`, but this will only happen if `some_function` actually moves `a`.


You're right, of course - I was completely messing up in my mind what r-value reference parameters actually do, and thinking that they need to be moved to, when the whole point is that they don't, they're just a reference.


Is pushing to a moved-from vector even legal? I thought in general the only guarantee you have after a move is that is save to destruct the object.


The state of a moved-from value is valid but unspecified (note, not undefined). IIRC the spec says vector must be `empty()` after a move. So all implementations do the obvious thing and revert back to an empty vector.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: