News for hackers. Stuff that matters.
Re: by SirusCodes on Thursday February 27, 2025 @06:08AM (#43193275)
Interesting thought... But how will that work? The statement would be executed only it comes from that line?
Re: by movpasd on Thursday February 27, 2025 @07:30AM (#43193776)
The compiler inserts a goto to the statement following the comefrom statement into the line specified. :^)

If multiple comefroms to the same line are specified, the comefrom to jump to is selected randomly.

Re: by immibis on Thursday February 27, 2025 @06:13AM (#43193302)
It is reverse GOTO. After (or before - your choice) that line is executed, execution jumps to the comefrom.
Re: by SirusCodes on Thursday February 27, 2025 @06:30AM (#43193386)
I don't know how I'm going to implement it but seems pretty interesting flow.

Raised issue - https://github.com/SirusCodes/AntiLang/issues/7

Re: by lloeki on Thursday February 27, 2025 @06:34AM (#43193405)
I see no mention of INTERCAL in this thread, which implements COME FROM

If you don't know about it, you're in for a treat.

https://en.wikipedia.org/wiki/INTERCAL

The joke runs longer: https://en.wikipedia.org/wiki/COMEFROM

Re: by ambigious7777 on Thursday February 27, 2025 @07:21AM (#43193702)
that's absolutely evil
Re: by GuB-42 on Thursday February 27, 2025 @08:20AM (#43194109)
It is like a regular goto, but with the label and statement reversed.

So instead of

  label: 
  do_something
  goto label
You have

  comefrom label
  do_something
  label:
Really, that's just syntax. Declare your labels with "comefrom", and ":" means "jump". But it looks a lot more confusing this way.
Re: by TeMPOraL on Thursday February 27, 2025 @10:18AM (#43195125)
It's just syntax until you decide to support both.
Re: by kbelder on Thursday February 27, 2025 @06:46PM (#43199914)
Ok, so:

  comefrom label
  goto label
  label:
A brand new way to lock up your machine.