There have been multiple accounts created with the sole purpose of posting advertisement posts or replies containing unsolicited advertising.

Accounts which solely post advertisements, or persistently post them may be terminated.

programmerhumor

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

sasquash , in More confusion for recruiters

There is a Tiger Jyhton version for the web www.tigerjython.ch/en

But at least just for educational purposes😅

Boxscape , in Site: "I don't feel so good...."
@Boxscape@lemmy.sdf.org avatar
ininewcrow ,
@ininewcrow@lemmy.ca avatar
itsathursday , in Regex flavors

Named groups are nice but can I please define a group more than once because maybe I want to group my data and consolidate values in a logical way without you complaining I have already used a group previously. I know I did, I’m the one telling you, now capture it twice!

Australis13 , in More confusion for recruiters

Make sure it's not whitespace sensitive and requires explicit typing, just to mess with everyone.

lurch , in More confusion for recruiters

all lines not terminated by a single space are comments

Ziglin ,

Also each line starts with a semicolon and you have to escape spaces in strings using a double forward slash

turbowafflz ,

I realized a while ago that there’s nothing stopping me from writing rust like this


<span style="color:#323232;">;println!(</span><span style="color:#183691;">"This is great"</span><span style="color:#323232;">)
</span><span style="color:#323232;">;println!(</span><span style="color:#183691;">"I think everyone should write rust like this"</span><span style="color:#323232;">)
</span><span style="color:#323232;">;println!(</span><span style="color:#183691;">"Probably works in most languages that use semicolons"</span><span style="color:#323232;">)
</span><span style="color:#323232;">;
</span>
miningforrocks ,

Also a spicial place in hell for you

rovingnothing29 ,
@rovingnothing29@lemmy.world avatar

Can we add the comefrom function too?

AVincentInSpace ,

hope you don’t forget the semicolon on a line by itself at the end (except in functions where you want to return the value of the last expression)

Ziglin ,

Nasm programmers probably think that is old code that you commented out.

tabarnaski ,

There’s a special place in hell for you

bottleofchips , in More confusion for recruiters

…and it’s compiled

lurch ,

…but intended for web, but you can also misuse it for apps and system services

qaz ,

…to an intermediate set of instructions for a virtual machine…

…called the brainfuck interpreter

enleeten ,

Brainfuck.NET Interpreter that uses modified Java bytecode instructions.

qaz ,

Yes brainfuck with some Java Bytecode instructions for syscalls.

dactylotheca , in Regex flavors
@dactylotheca@suppo.fi avatar

Some people, when confronted with a problem, think “I know, I’ll use regular expressions.” Now they have two problems.

qaz ,

Regex really isn’t that bad when using named capture groups.

dactylotheca ,
@dactylotheca@suppo.fi avatar

Oh yeah they definitely have uses, but there’s a real tendency for people to go a bit crazy with them. Complex regexen aren’t exactly readable, there’s all kinds of fun performance gotchas, there’s sometimes other tools/algorithms that are more suitable for the task, and sometimes people try to use them to eg. parse HTML because they don’t know that it is literally impossible to use regular expressions to parse languages that aren’t regular

frezik ,

It’s entirely possible to parse HTML in PCRE. You shouldn’t, but it is possible. The language stopped being strictly regular a long time ago and is entirely capable of doing it.

stackoverflow.com/a/4234491/830741

dactylotheca ,
@dactylotheca@suppo.fi avatar

Oh yeah, extensions which make them non-regular definitely can make it possible, but just because it’s now somewhat possible with some regex engines doesn’t mean it’s a good idea

FooBarrington ,

I’ve once written a JS decompiler (de-bundler?) using ~150 regex for step-wise transformations. Worked surprisingly well!

Azzk1kr ,

What eldritch beast was summoned as a result?

FooBarrington ,

Well… No new ones, at least? Though it was around that time that I started hearing whispers in the night… “You can use WASM to ship Client-Side PHP”

bleistift2 ,

it is literally impossible to use regular expressions to parse languages that aren’t regular

It’s impossible to parse the whole syntax tree, but that doesn’t mean you can’t get the subset you’re interested in.

Mbourgon ,

Jwz’s 2nd law!

MashedTech ,

I learned Regex once and now it just works. Only problem for me is using MacOS so the Regex flavors aren’t consistent. But once I sort that, it’s smooth sailing.

bolexforsoup , in Site: "I don't feel so good...."

Like the idea, but this isn’t remotely how this meme is used lol

Dirk ,
@Dirk@lemmy.ml avatar

Are we gate-keeping meme usage now?

PhobosAnomaly ,
Dirk ,
@Dirk@lemmy.ml avatar

Mom! Look! Moooom! Moooooom! Look, I am in this! Mooom! You’re not looking! Moooom! Look!

jimitsoni18 ,

What clieny is that

PhobosAnomaly ,

Summit (Play Store)

bolexforsoup ,

How is it gatekeeping to say “you used it wrong“? If you put your car in reverse when you want to drive forward and I correct you, am I gatekeeping driving?

Saying “this is incorrect” when there is a clear right/wrong usage is not gatekeeping

Album ,
@Album@lemmy.ca avatar

Are you gatekeeping gatekeeping now?

bolexforsoup ,

Damn I got got

Dirk ,
@Dirk@lemmy.ml avatar

Are you gatekeeping gatekeeping-gatekeeping now?

pennomi ,

Yo dawg I heard you liked gatekeeping so I got you a gate to keep your gatekeepers.

Boxscape ,
@Boxscape@lemmy.sdf.org avatar
Kusimulkku ,

How dare you gaslight him

GissaMittJobb ,

Yes

TrickDacy ,

When haven’t we been? People will do any weird thing and call it a meme, least we can do it call them on it every now and then

entropicdrift ,
@entropicdrift@lemmy.sdf.org avatar

A meme is just any piece of cultural information. Some are gatekept and carefully guarded, others are just kinda around

ChillPenguin ,
SLVRDRGN ,
cypherpunks ,
@cypherpunks@lemmy.ml avatar
user224 ,
@user224@lemmy.sdf.org avatar
SLVRDRGN ,

Oh my word - its still alive?

mbfalzar ,

That which is dead can never die

gwen ,

NO NO N

anguo ,

N NO NO Nᴑ

gwen ,

FUCK YOU LMFAO

tfw_no_toiletpaper ,

Yeah I will forward this to friends but only the textbox

Oha ,

how is it used?

Ghostalmedia ,
@Ghostalmedia@lemmy.world avatar
Admetus ,

I just saw a variety of usages and nothing to indicate the standard use of this meme lol

kartonrealista , in Site: "I don't feel so good...."
@kartonrealista@lemmy.world avatar
Emotet ,
@Emotet@slrpnk.net avatar

Because this repo is going viral from time to time to developers, I’m open for discussion if you want to promote a product/service in this README file. Just mail me at XXXX

Ew.

RustyNova ,

Probably a joke

fdnomad ,

Looks like letsdeel took him up on the offer though, its even in the source code

jaybone , in Regex flavors

Can you actually name capture groups, or this means how you can refer to them by number?

mormund ,

In modern languages you can name them with labels as well yes. Not sure about the syntax right now. Something like (?label:…) I think

qaz ,

It’s (?<NAME>…) and those are the named capture groups referred to in the post.

VegOwOtenks OP ,

You can use backreferences 1 2 etc. but you can also give them names explicitly.
it looks like this: (?<name>inner-regex)
Some flavors support it, kotlins doesn’t apparently.

jaybone ,

TIL thanks!

whodatdair , in Regex flavors

Blasphemy, that’s not regex that’s just fancy grep

VegOwOtenks OP ,

I don’t actually know whether POSIX grep would support named groups :o

qaz ,

Don’t have you have to use the -P flag?

OmnislashIsACloudApp ,

which is just perl mode

qaz ,

Yes, but perl mode has more features.

kubica ,

I don't fully disagree but you are walking on a fine line...

PotatoesFall ,

any idea what the re in grep stands for?

nothacking , in Worst is UTC vs GMT

Na let’s keep timezones, there useful for humans who generally want time to mean something, but lets ditch daylight savings time, all it does is make scheduling a massive pain twice a year, and messes up everyone’s sleep cycle. Without it, timezones would just be a fixed offset from another, minimizing trouble.

jsomae , in Trying to understand JSON…

This is true in Lua as well (substituting ‘nil’ for 'null)

PeriodicallyPedantic , in Trying to understand JSON…

Ah yes the difference between “unset” and “intentionally set to null”, the bane of API devs who work in languages that don’t inherently distinguish between the two.

fibojoly , in Surely "1337" is the same as 1337, right?

I feel this in my bones. As an OG dev, I had this incredible urge to smack people when I was working for my last job and I saw the API specs with everything being sent as strings through JSON. Boolean? Sure, let’s use a string. Integers? Sure we’ll do conversion in our code, that’ll be more efficient… So fucking infuriating. Oh and don’t get me started on JsonSchema T_T

kureta ,

Please do get started. I am curious.

fibojoly , (edited )

JsonSchema is a way to validate some JSON. A great thing when you want to stop any sort of malformed data from coming in. Instead of wrecking your head in your code testing whether this bit here is not null, or is that string a valid boolean (I still remember that shitty piece of code they had, ugh!) or that bit is empty or that one is an actual number, or a string that can only have such and such value, well, you can formalise all this in one place, as a data file instead of code. Very convenient.

Except when it turns out you’re using a JSON library that’s not one, not two, but six major versions behind, and the security department won’t greenlight you using anything recent because… fuck you, that’s why. And to add insult to injury, we were the Quality department. Responsible for analysing the code quality of thousands of coders, around a hundred thousand programs (mostly COBOL but also C#), of a European banking group… The JSON schema was for adding a layer of non existant security to our API. But no, let’s keep accepting shitty malformed JSON (because of course we kept receiving shitty JSON; that’s why we wanted to implement this)

So I had to rewrite a lot of custom code to patch the bugs we found in the library, and none of the nifty tools that let you put in json and generate json schema would work for us. Heck, they even have JsonSchema to validate your JsonSchema but those wouldn’t work either, so far behind our version was.

Fucking awesome experience. I’m glad it’s behind me.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • [email protected]
  • lifeLocal
  • goranko
  • All magazines