Show newer
xianc78 boosted
xianc78 boosted
xianc78 boosted
xianc78 boosted
spacex is controlled opposition to the better ways we could do space travel
xianc78 boosted
xianc78 boosted

Tip 25 of #TuesdayCodingTips - User-defined literals

C++ has many built-in literals for disambiguating types of constants, such as 'u' for unsigned, 'f' for float, or time-related literals from the chrono header (like ms, h, or min).

The really cool thing is that you can define your own literals (since C++11) to make your domain-specific constants more legible. All these literals overload the operator "" with your custom _suffix. The data type that is supposed to be before _suffix is then determined by the function parameter type (consult the documentation for allowed parameter types: en.cppreference.com/w/cpp/lang ).

Thanks to compile-time computing, these literals don't have to imply any runtime overhead for your code.

An interesting use-case that I found is that literals can be leveraged to make described bool constants without having to wrap them in a temporary.

#cpp #programming #tips

gamedev 

It's been a while, but I finally decided to take the gamble and use my dying laptop to add the ability to change which tile to place in the editor.

Show thread
xianc78 boosted
There is a NO COOMER RULE on my website. Can't believe I have to say this. There are so many other sites you can go to on the Fediverse to jack off. Don't do it on mine.
xianc78 boosted
@ChristiJunior @drawthentic
Women see freedom as the ability to whore around as much as they want then still settle down and find a husband who'll put up with their shit. What freedom do women consistently care about that consists of anything else?
xianc78 boosted
xianc78 boosted
Never trust anything that is not a local AI model otherwise the usual suspects will lobotomize it.
xianc78 boosted
xianc78 boosted
xianc78 boosted
xianc78 boosted
xianc78 boosted

.      ⠀⠀⠀✦ ⠀ ⠀              ⠀⠀⠀⠀⠀* ⠀⠀⠀.          . ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀✦⠀⠀⠀ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀☄️ ⠀ ⠀⠀⠀⠀⠀⠀.        ,     .   ゚ .          .                ✦      ,       .
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀☀️
 *        .
.             .   ✦⠀      *
    ⠀✦⠀ 
        
    .    .   ⠀🌕 ,
           .
       🚀
   ˚        ゚     .
 .⠀  🌎⠀‍⠀‍⠀‍⠀‍⠀‍⠀‍⠀‍⠀‍⠀‍⠀‍⠀,
   *  ⠀.
   ⠀✦

xianc78 boosted
xianc78 boosted
@Tadano @mischievoustomato @PurpCat @Zettour @lewdthewides @meso My issue is the church. Personally i think society should be more conscious and critical about their relationship with technology, but that should be on a personal level not decided by whatever arbitrary choice of the Church.
Show older
Game Liberty Mastodon

Mainly gaming/nerd instance for people who value free speech. Everyone is welcome.