[-] TwilightKiddy@programming.dev 8 points 2 months ago

How would one go about using that sink?

[-] TwilightKiddy@programming.dev 6 points 4 months ago

Well, jokes aside, people who install Arch usually want maximum flexibility out of their system (I have no idea why you would torture yourself like that otherwise). And after some time spent with Manjaro, I can confidently say that it greatly sacrifices your ability to tinker with the system in the name of user friendliness. A great distro to start with, but if you still like it after a couple of months, you probably didn't need Arch in the first place.

[-] TwilightKiddy@programming.dev 7 points 4 months ago

A switch to per minute, per megabyte plan made me a lot more concious about spending money on my phone. If I want something to watch/listen to during a trip, I download it beforehand. I almost never use any minutes, only communicating via the mobile data. With autodownloading of pictures disabled in all my chat apps, it runs about 50 MB per month, which charges me less than 50 cents.

[-] TwilightKiddy@programming.dev 5 points 5 months ago* (last edited 5 months ago)

I don't believe the first code sample is a valid C# code. Switch-case statements expect constants for case conditions and runtime types are not constants, obviously. What you can do is something like this:

void MyMethod(object arg)
{
    if (arg.GetType() == typeof(int))
        MyTypedMethod((int)arg);
    else if (arg.GetType() == typeof(int?))
        MyTypedMethod((int?)arg);
    else if (arg.GetType() == typeof(long))
        MyTypedMethod((long)arg);
}

This will work, but the problem here is that inheritance will fuck you up. All the types we check in this example are sealed and we don't really have to worry about it in this case, but generally this code is... just bad.

And yes, the correct way of implementing something like this is by using generic types. Starting from C# 7.0 we have this cool structure:

void MyMethod<T>(T arg)
{
    switch (arg)
    {
        case null:
            // Do something with null
            break;
        case int intArg:
            // Do something with intArg
            break;
        case long longArg:
            // Do something with longArg
            break;
    }
}

You'll have to check for null separately, as you can't use Nullable<> there, but overall, it looks much cleaner and handles inheritance properly for you.

This is called pattern matching, you can read more about it here: https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/operators/patterns

[-] TwilightKiddy@programming.dev 7 points 6 months ago

Arch with extra steps, AKA CachyOS.

[-] TwilightKiddy@programming.dev 5 points 6 months ago

Pay with Monero, set up a VPN, buy a phone specifically for the service. I doubt you can get any more anonymous than that. Cellular networks are by default monitored by governments, there is nothing a provider can do about it. But encrypting the traffic and getting a new phone should make that type of monitoring relatively useless. And if you never give your identity to the provider, they simply can't know who you are.

[-] TwilightKiddy@programming.dev 8 points 7 months ago

Maybe because it alters your maximized resolution, which makes you easier to identify? But that sounds like a bit of a stretch to me.

[-] TwilightKiddy@programming.dev 8 points 7 months ago

While Apple's products indeed are a bit less than compatible with privacy, it does not mean the owner of such products can't care about it. Maybe they just recenty got into it, or have to use their products for some Apple-only feature that is essential for them.

[-] TwilightKiddy@programming.dev 7 points 8 months ago

You can play HotS without Battle.net, you'll just have to input your credentials manually whenever you start the game. Alternatively, contrary to Steam, you can just kill Battle.net after it has updated and launched the game.

[-] TwilightKiddy@programming.dev 8 points 1 year ago* (last edited 1 year ago)

You can actually use it without giving it contacts permission, but you'll have to add people via short links, like wa.me/(number).

[-] TwilightKiddy@programming.dev 6 points 1 year ago

What's the name of the show, though?

view more: ‹ prev next ›

TwilightKiddy

joined 2 years ago