helvede.net is one of the many independent Mastodon servers you can use to participate in the fediverse.
Velkommen til Helvede, fediversets hotteste instance! Vi er en queerfeministisk server, der shitposter i den 9. cirkel. Welcome to Hell, We’re a DK-based queerfeminist server. Read our server rules!

Server stats:

169
active users

#if

1 post1 participant0 posts today
Replied in thread

@thephd @fay59

> You, the vendor, parse things based on -std=... or /std:..., like everyone else.

So... basically if you have a C2y libc, you need an #if __STDC_VERSION__ gate around your printf declaration with different symbol versioning, to make sure that programs compiled with -std=C2y will fail to load on old systems whose libc doesn't support C2y, but still allow programs built with -std=C11 to work there?

@zarfeblong The Visible Zork is a work of pure genius!

What an incredible way to learn ZIL! This is why I need to retire, because I would love to shut myself off in a room for a few days, play the entire game through a time or two, and practice writing ZIL in aother buffer :P

eblong.com/infocom/visi-zork1/

eblong.comThe Visible ZorkerA software exhibit that allows you to explore Zork and also Zork's source code at the same time.
#if#zork#gaming

Coming Soon:
"Der Geist in der Tür"
Das erste Computerspiel im Setting Genius Loci!
Wer will im Rollenspiel keine Haustiere haben? Hier kann man reiten!

Die meisten Tiere sind Segramen, schlanke rotschwarze Renner mit kleinem Geweih, die auch die großen Raganaj tragen können.
Außerdem gibt es eine Anzahl treuherzig dreinblickender , deren flauschiges gelbgrünes Gefieder eifrig geraschelt wird, als sie dienstbar versuchen, dich anzulocken.

Hey #UnrealEngine code plugin devs, I'm releasing the code I use for my plugins to make #UE4 & #UE5 support a lot easier.

github.com/sbseltzer/VersionMa

Includes better macros for checking engine version and automatic prebuild scripts to work around the preprocessor limitations in UnrealHeaderTool, allowing you to `#if` out blocks of code that contain Unreal "magic macros". This allows you to maintain backwards compatibility without forsaking modern Unreal features. Includes installation instructions and examples of using it.

Feedback is appreciated! I'd also appreciate Linux users to verify it works for them.

GitHubGitHub - sbseltzer/VersionMacros: Helpful macros & prebuild scripts for supporting plugins across many versions of Unreal Engine.Helpful macros & prebuild scripts for supporting plugins across many versions of Unreal Engine. - sbseltzer/VersionMacros
Arcane Cache: Review to "Messages from the Universe Graveyard"

A interactive fiction with MUD elements, that takes place in the world of a shut-down MMORPG. Defunct, industrial spaces, overgrown greenhouses, and astral-surreal places – all of them forlorn, disturbed by glitches, and sometimes seemingly bleeding into each other. The best comparison to describe Messages from the Universe Graveyard’s general atmosphere might be Andrej Tarkovskys „Stalker“, although the spirits that haunt this zone clearly derive from an digital age...

https://thunderperfectwitchcraft.org/arcane_cache/2024/12/17/messages-from-the-universe-graveyard/

#game #videogame #indiegame #gamedev #indiegamedev #undergroundgame #exploration #2D #surreal #art #digitalart #opensource #freesoftware #freegame #free #libre #gaming #browser #indie #review #underground #haunted #hauntology #mud #interactivefiction #if #multiuserdungeon #interactive
Replied in thread

@millenomi @chbeer I wish we had a `not` identifier in Swift (I think C(++)’s iso646.h has that, for platforms where != caused encoding problems), that'd just stand out more.

And yeah, sometimes an #if is just for an obscure platform, and it just makes sense to front-load the code that's relevant for 90% of your devs.

Though generally I try to wrap stuff like that in functions or platform-specific classes that implement a shared interface. Then only object-creation is platform-specific.

Replied in thread

@mcc

I assume by "erase" you mean "suppress compile".

If so then yes, "#if false" works perfectly well for what you want.

C# "#if" is really a hybrid of C "#if" and "#ifdef". Any defined symbol evaluates to boolean true, regardless of what it's defined to, and you can do boolean math on them, e.g.
#if A || B

I use variations on "#if false" and "#if true" a lot when I'm debugging code I want to be conditionally compiled under some circumstances/targets.

Replied in thread

@mcc wow that documentation really doesn’t help

Running an experiment:
#if false appears to remove the code
#if true appears to keep the code
#define false is forbidden because false is a keyword not an identifier

Which all suggests to me that true/false are special in #if, but that page sure doesn’t say that…