@mcc@mastodon.social
@mcc@mastodon.social avatar

mcc

@mcc@mastodon.social

glitch girl

This profile is from a federated server and may be incomplete. Browse more on the original instance.

mcc, to random
@mcc@mastodon.social avatar

This Sunday at 3 PM EST (noon PST) me, Miguel @spookysquid and Christine @love are going to be streaming "Flashback". This week: It's the Death Tower Show! For reasons that more and more ill advised the more time we have to reflect on them, we have signed up as a contestant on something called "the Death Tower Show". There are lots of proto-vaporwave colors and a lot of death. Watch us die on Miguel's twitch, at: https://www.twitch.tv/spookysquidgames

( Find previous weeks' VODs at: https://www.youtube.com/channel/UCmwKUgZQDXd_UpY3xENDDfA )

mcc, to random
@mcc@mastodon.social avatar

Man though wouldn't it be really funny if a duck liked milkshakes

mcc,
@mcc@mastodon.social avatar

Imagine how cute it would be to watch the duck enjoying its milkshake

mcc,
@mcc@mastodon.social avatar

I have just learned that ducks cannot drink milkshake. All along we have been excoriating the duck, when in truth, the duck was a victim and the truly problematic one was the person feeding the duck the dairy products in the first place. I am crushed by this realization :(

mcc,
@mcc@mastodon.social avatar

@DanadasGrau I don't know what duck butter is. Let me check Google.

…huh! Huh! Well, okay.

mcc, to random
@mcc@mastodon.social avatar

You can now wear gigantic gauntlets on your giant hands. https://mastodon.social/@unormal/112022621325453491

mcc, to random
@mcc@mastodon.social avatar

More cursed C# questions!

We have a P/Invoke method. We want it to pass through a function pointer from the C# to the C side.

We say:
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
public delegate void Callback();

We make that an argument of our P/Invoke method:

[DllImport(Dll, CallingConvention = CallingConvention.Cdecl)]
public static extern void RegisterCEventHandler(Callback c);

If we have a method, we say: RegisterCEventHandler(MethodName);

This works so far. But then—

(1/2)

mcc,
@mcc@mastodon.social avatar

For reasons, we need to not call RegisterCEventHandler directly. We need to call a C#-side RegisterEventHandler() that does some setup. Now there's a question: What signature does RegisterEventHandler have? We think it ought to be RegisterEventHandler(Action c). But when we pass our Action to RegisterCEventHandler, it says: "cannot convert from System.Action" to "OurClass.Callback".

What do we do from here? What magical type does MethodName have, if it isn't Action?

(2/2)

mcc,
@mcc@mastodon.social avatar

Note, you MIGHT ask: Why not just take a OurClass.Callback as the argument to RegisterEventHandler? And the reason we can't is getting this working is a prelude to writing a templated void RegisterEventHandler<T> (Action<T> c), and in this case, we really will need to know what T is :(

There is some magic type that MethodName has before being converted to Action<T> that is compatible with that "public delegate void" type. What is it?

(3/2)

mcc,
@mcc@mastodon.social avatar

It turns out to be very difficult to google for "How do you pass an Action<> to p/invoke?"

mcc,
@mcc@mastodon.social avatar

@slyecho How do I represent a delegate or lambda in a type, if not Action<T>?

mcc,
@mcc@mastodon.social avatar

@PJB What is the type of the delegate? It seems to me the delegate must have a type, and I thought that type was Action, and if the delegate type is nameable then I can simply forget about using Action and use the "real type".

mcc,
@mcc@mastodon.social avatar

@doty I feel like this is trying to solve a different problem than the one I need solved.

mcc,
@mcc@mastodon.social avatar

@doty anyway, I solved it by changing the problem in the other direction and solving it a third way

mcc,
@mcc@mastodon.social avatar

@doty sorry, I mean: the goal I am trying to solve is figuring out what the type representation of functions in c# is. Your solution is to create a new thing with a known type , sidestepping the problem. However there are other details I didn't mention which makes this not quite appropriate for my situation

futurebird, to random
@futurebird@sauropods.win avatar

Can anyone tell me why that thing bros talk about too much that starts with a B and rhymes with loins is up recently? Without attracting any bots … please?

mcc,
@mcc@mastodon.social avatar

@futurebird It is very easy for someone with many 'oins to manipulate the price of 'oins, and there seem to be no laws preventing this that anyone is following. Amy Castor in this article https://amycastor.com/2024/02/21/the-halvening-is-coming-what-this-means-for-bitcoin/ claims the current reason for the high price is manipulation in advance of a protocol-mandated event called "the halvening" in April, which will meaningfully reduce the financial benefits of running a miner.

mcc,
@mcc@mastodon.social avatar

@futurebird I cannot confirm or deny this theory. I also don't understand why a reduction in their pay would be desirable to perform a pump right before the reduction happens, but 'oin miners do many things that seem illogical to me.

mcc,
@mcc@mastodon.social avatar

@WearsHats @Rycaut @futurebird That would make more sense to me than the halvening theory; an influx of new potential marks will increase the price naturally (and, unfortunately, maybe permanently). But as mentioned I don't entirely understand Amy's line of argument, so maybe she sees something I don't.

mcc, to random
@mcc@mastodon.social avatar

Filed a "security advisory" issue on Github yesterday and was slightly? surprised to discover you cannot see the security advisories you yourself have submitted. It makes sense they go into some separate queue but I'd have expected I'd have access to the queue for purposes of my own submissions, if for example I wanted to add additional details. Maybe I'm missing something.

mcc,
@mcc@mastodon.social avatar

@phillmv I see. Not that there's anything yo ucan do about it, but I guess it would have been nice to have a bit more heads up I was submitting Very Much Not An Issue since the issue I submitted was marginal (is it a security bug or a regular bug? kinda ambiguous). Anyway, next time I'll know

mcc,
@mcc@mastodon.social avatar

@phillmv uhhh there's in the "file an issue" page a button for "file a security advisory" which brings you to something that is similar enough to the issue submission page it's not clear it's anything other than a special template for filing issues

mcc, to random
@mcc@mastodon.social avatar

"We do not directly funnel your posts to 'generative AI' companies" is now being used as a marketing point for hosting solutions https://mastodon.world/@goodenoughllc/112015913259125028

mcc,
@mcc@mastodon.social avatar

@UkeBLCatboy @whimsy On the other hand, what I'm playing on Switch lately is

  • Rainbow Islands remaster
  • Tetris The Grand Master remaster
  • Mario's Super Picross for Super Nintendo
  • "Donut Dodo"
mcc, to random
@mcc@mastodon.social avatar

Sometimes when I open up my Lenovo+Linux laptop, I find it's just sut off, for no apparent reason. Sometimes it does this even when battery is at more than 50%. I feel like this really shouldn't be happening.

mcc,
@mcc@mastodon.social avatar

Wow!!! Wow the X session in Ubuntu 23.10 sure does crash so often!!! When I first started using Ubuntu 23.10 the Wayland session crashed so often, so I switched to X, but that also crashes so often!!!

mcc, to random
@mcc@mastodon.social avatar

A very good and correct opinion I have is that you should watch the anime "Frieren: Beyond Journey's End"

mcc,
@mcc@mastodon.social avatar

This show is!! So good!! Holy crud!!

mcc,
@mcc@mastodon.social avatar

@rotopenguin You have no idea

mcc, to random
@mcc@mastodon.social avatar

For the last year I've been semi-daily posting "What I'm Listening To Today" links in this thread:

https://mastodon.social/@mcc/108199886340178151

The thread is now so long it is increasingly breaking Mastodon, so I am making a new thread, starting here.

To recap, here's the entirety of the year-one thread in the most impractical possible format: A YouTube playlist containing 246 songs and running for just over 47 hours:

https://www.youtube.com/playlist?list=PLLIjft6ja7DP_GwDs3XuTbiFmHYTwJWa7

mcc,
@mcc@mastodon.social avatar

What I'm listening to today: "Sleepless", Soul Coughing

Gosh, I love Soul Coughing. Nobody before or since has ever quite nailed their particular bizarre formula.

Here's my favorite S.C., from "Irresistible Bliss", the album where they couldn't get their regular producer and M.Doughty talked everyone into a stripped-down sound. It's a quiet lounge song that hits like a truck; if you listen to it on a setup with a real subwoofer it will literally make your walls rattle.

https://www.youtube.com/watch?v=wLDRgFDcsDc

  • All
  • Subscribed
  • Moderated
  • Favorites
  • HellsKitchen
  • rosin
  • Youngstown
  • thenastyranch
  • everett
  • slotface
  • ethstaker
  • Durango
  • kavyap
  • mdbf
  • DreamBathrooms
  • rhentai
  • InstantRegret
  • magazineikmin
  • bokunoheroacademia
  • cubers
  • Leos
  • osvaldo12
  • modclub
  • cisconetworking
  • tacticalgear
  • GTA5RPClips
  • khanakhh
  • lostlight
  • relationshipadvice
  • normalnudes
  • tester
  • sketchdaily
  • All magazines