Hacker Newsnew | past | comments | ask | show | jobs | submit | more poizan42's commentslogin

GetAddrInfoEx[0] has async support support since Windows 8 - it had the overlapped parameters earlier but didn't support them. I'm guessing that is what GP is referring to.

[0] https://learn.microsoft.com/en-us/windows/win32/api/ws2tcpip...


There is a guide here on how to provision without a smartphone: https://community.home-assistant.io/t/commissioning-matter-d...


Thanks, but

> This process is a bit more involved but is also pretty straightforward and easy to do in most setups, though it is not officially supported and is intended for developer use.

I'll stick with my zigbee flow of "press 2 buttons"


I don't have any Intel MacBook to test it out on, but is Intel PTT permanently disabled on them? Almost all Intel CPUs from somewhere in 2014 and later has TPM 2.0 support as far as I'm aware.


I don't know much about MacBooks.

I recently sold my old computer with a i7-5820K. It's from 2014, but with 6 cores, 12 threads and 4 Ghz it is still fast enough for video and photo editing, and playing CPU intensive games like GTA or Red Dead Redemption 2. But can't run windows 11 because of TPM.


You are not supposed to use interceptors in code you write yourself. The feature exists for Roslyn Source Generators that runs every time you build the code.


I’m still confused though, if you’re generating the code anyway, why do you need an interceptor? Can’t you just generate the code to match what you want to redirect to, directly inline?


Yes if all the code was generated. The problem is when you want to modify the behavior of user-supplied code - Roslyn Source Generators are additive so you cannot make modifications directly to user-supplied code.

You can read about how they work here: https://github.com/dotnet/roslyn/blob/main/docs/features/inc...

Basically they get the files (and ambient metadata) that are part of the compilation, filter to the parts it depends on, transforms to a in-mem representation of the data needed for the code generation, and then finally adds new files to the compilation. Since they can only add new files they cannot e.g. add code to be executed before or after user code is executed like with AOP. Interceptors are a solution to that problem.


Interesting, so you’re saying generated code can change the behavior of user code with no indication this is happening from directly reading the user code… that sounds pretty horrifying. I guess AOP in general is pretty horrifying to me though. Maybe it’s useful if you restrict its use to very specific things like logging or something.


Well yes, hopefully you know what you are doing when you reference a source generator. This could ofc. also be done with custom msbuild task that modfies the code sent to the compiler or the assembly after compilation (like Fody), Source Generators just makes the process more streamlined and integrates with things like IntelliSense.


> Well yes, hopefully you know what you are doing when you reference a source generator

I don't think there's much that's scary about generating source code in general. If it's self-contained and you have to actually call the generated code to use it, it's not really much different than any other code. But the idea of having code A change the behavior of code B is what's horrifying, regardless of whether code A is generated or not. If I'm reading code B I want to be able to reason about what I see without having to worry about some spooky action at a distance coming from somewhere else.


> that sounds pretty horrifying.

Things are constantly doing this. Frameworks use reflection or markup or all other kinds of things that count as magic if you don't bother to understand what's going on.


"none" is saying something about all of the players, so how would that be singular? The word "none" is always used in a plural context, like if there is only one player then you won't say "none of the player"


I'm talking about the verb that follows 'none', not the noun.

'None of the team was [singular] prepared' and 'None of the team were [plural] prepared' are both correct.


You said

> A related example is the word 'none' (= 'not one'). Technically it should govern a singular verb

And I'm questioning why you think "none" should technically govern a singular verb when "none" is normally a non-singular subject.

I'm sure both are being used, and at the end of the day what is correct is determined by how a significant amount of people are using the language. But I just don't understand why you think a singular verb would be more "technically correct"

Did you mean that because you could replace none with "not one" then it should be singular? But that only works because the 'not' applies to the whole sentence, so the remainder is about 'one', i.e. "not (one of the team was prepared)". But that doesn't work for the word none because you can't read it as the 'not' applying to a singular part-sentence.


GDPR Art. 7 section 4:

> When assessing whether consent is freely given, utmost account shall be taken of whether, inter alia, the performance of a contract, including the provision of a service, is conditional on consent to the processing of personal data that is not necessary for the performance of that contract.

Don't blame the regulators, it's pretty clear that "paying" with consent is a no-go from the text itself.


It also has Greenland which is just an autonomous region of Denmark, but not the Faroe Islands which is our other autonomous region. I guess Greenland is just more visible due to its size (both regions actually have about the same population)


... because they just casted lParam into a pointer to DEV_BROADCAST_HDR a few lines above, which is the common part of the different structure it could point to. That's just doing inheritance the C way. What did they expect? A C++ class from a C api?


Generals was famously extremely rushed in development. Probably a novice programmer


Maybe a more natural way to make the distinction is by looking at the average width of the body of water seperating the landmass relative to the area of the landmass. That is an island is a landmass that has an area (A) of at least A_min and at most A_max and is either

a) Surrounded by a body of water with average width W_avg where W_avg > f_min*sqrt(A) - or

b) Surrounded by a body of water with average width W_avg where W_avg > W_min

Fill in the constants A_min, A_max, f_min and W_min to get as close as possible to real world usage of the word "island".


I like the effort - does feel like part of what makes something an island is the width of the water surrounding it relative to its size… but I dunno man, the Pacific ocean’s pretty wide… it’s going to make the ‘average width’ of the water around Committee’s Punch Bowl Bifurcation Island pretty big.



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

Search: