Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-4041-

FUCKING PROGRAMMING LANGUAGES

Name: Anonymous 2008-10-15 17:14

Now, I'm taking a programming languages, and as a project we're going to make our own programming language - and in a complete strike of unimaginativeness, everyone is writing out shitty c and java clones - even though it needs to be a very simple pet language capable of doing only the very fundamental. I've been planning on going basic style with fancy functional additions, but that sounded retarded when I verbalized it, so I'm reduced to begging /prog/ for advice.

Name: Anonymous 2008-10-15 17:24

C with Monads.

Name: Anonymous 2008-10-15 17:29

Just make another Lisp dialect with some half-baked feature to set it apart. You can even write it in Lisp.

Name: Anonymous 2008-10-15 17:34

make sure it doesn't have FORCED INDENTATION OF THE CODE

a very common beginner's mistake...

Name: Anonymous 2008-10-15 18:12

make sure it has FORCED INDENTATION OF THE CODE

a very common beginner's wish..

Name: Anonymous 2008-10-15 19:07

common beginner's wish

wait! you mean people actually want FIOC???

wtf is the world coming to?

Name: Anonymous 2008-10-15 19:27

>>6
People say that FIOC sucks, but given the choice in HASKELL, they still use it. It's all about having an alternative.

Name: Anonymous 2008-10-15 19:46

>>7
Python has an alternative too.

Name: Anonymous 2008-10-15 19:50

>>8
Does he?

Name: Anonymous 2008-10-15 19:57

>>9
def penis():
    hurr();\
 durr();\
   hurf();\
  durf()


Alternatively, from __future__ import braces.

Name: Anonymous 2008-10-15 20:24

Do python sans FIOC.

Name: Anonymous 2008-10-15 21:29

Do a stack language, they're dead easy.

Name: Anonymous 2008-10-15 22:21

>>2
Also, lazily evaluated C

Name: Anonymous 2008-10-16 1:36


func (f"")(String $s) {
    return File::open($s);
}
{lambda} = \ $a { puts $a; }
foreach f"/etc/passwd" \ $i, $line {
    lambda $line->explode(':')[1] if $i % 2 == 0;
}

Name: Anonymous 2008-10-16 4:30

http://www.thinkartlab.com/pkl/media/SUSHIS_LOGICS.pdf

even though it needs to be a very simple pet language capable of doing only the very fundamental

Write a minimal Turing-complete language.

Name: Anonymous 2008-10-16 4:41

Write a minimal Turing-complete language.
something like this?
http://barker.linguistics.fas.nyu.edu/Stuff/Iota/

Name: Anonymous 2008-10-16 7:50

Take some cues from The Ultimate Language hq9+:

http://www.cliff.biffle.org/esoterica/hq9plus.html

Name: Anonymous 2008-10-16 7:58

>>17
I'm not convinced that HQ9+ is Touring complete.

Name: Anonymous 2008-10-16 10:10

Hmm apparently it only needs to be capable of propositional calculus, input-output, loops etc.

So I'll just go for a shittier BASIC - only with lambdas.

Name: Anonymous 2008-10-16 10:59

Write a Ruby clone that isn't damn useless.

Name: Anonymous 2008-10-16 14:25

use warnings;use strict;$/=$b;@_=map" bottle$_ of beer",s=>'';map/h/i?print
"Hello, World!\n":/../?bless[]:/9/?map{$a=$_[$_<2],print"$_$a on the wall,
$_$a,\ntake one down and pass it around,\n",$_-1,"$_[$_==2] on the wall.\n
"}reverse$...99:/q/i?print$b:/\+/?$^A++:2,($b=<>)=~/\+\+|./g# HQ9++ in Perl

Name: Anonymous 2008-10-16 14:38

>>20
>Ruby clone
>not damn useless
DOES NOT COMPUTE

Name: Anonymous 2008-10-16 17:19

PRORGAMMING BLAMGBLUGAGESSSSS LAMBDA

Name: Anonymous 2008-10-17 1:27

>>1
Make a virtual machine that runs your own high level instruction set.

Name: Anonymous 2008-10-17 2:21

Make it support lazy evaluation and lazy programming

Name: Anonymous 2008-10-17 2:24

>>25
you mean like some sort of weird mixture of haskell and perl like perl 6?

Name: Anonymous 2008-10-17 2:44

>>26
Lazy programming is a novel technique employed primarily by LISP hackers.  With lazy programming a program is not written but merely declared so; actual creation of the program is done after a first request for evaluation, which never comes, so the program is never written.  This saves LISP hackers a lot of time which can be spent in effective trolling.

Name: Anonymous 2008-10-17 2:59

>>27
lazy programming is basically what you described, except that actual creation of the program (which never happens) is in perl instead of lisp.

Name: Anonymous 2008-10-17 3:57

Since when is LISP lazy?

Name: Anonymous 2008-10-17 4:31

>>29
Lazy programming, not lazy programming languages.

Name: Anonymous 2008-10-17 13:46

>>28
Are you nuts, nobody writes in Perl, lazily or otherwise.

Name: Anonymous 2008-10-17 13:57

What is the actual problem with FIOC? Is there anyone who has used it for a considerable period of time and still sees it as a bad feature? I had an irrational dislike of it before I actually started using it, but now I wish more languages would embrace it.

Name: Anonymous 2008-10-17 14:22

>>32
one word,
FORCED INDENTATION OF THE CODE,
thread over

Name: Anonymous 2008-10-17 14:23

>>1
Does it have to be touring-complete?

Name: Anonymous 2008-10-17 14:25

>>32
I have no problem with the ``IOC'' part the problem is the ``F'' part

Name: Anonymous 2008-10-17 14:35

Writing your own language is the most fun you can possibly have.

Use bison and flex for parsing (unless you're making something like a lisp).

Make it compile "bytecode" for a simplistic VM. You might find "threaded code" is even simpler than "bytecode", YMMV.

As for the language, how about something strictly functional, but no lazy evaluation or strict types? You will have to implement tail recursion (which shouldn't be too hard), and real closures (which might be a bit harder; you'll certainly have to completely understand lexical scoping first).

Name: Anonymous 2008-10-17 14:44

>>35
Please review >>10. The indentation is not forced.

Name: Anonymous 2008-10-17 23:20

>>35
I hate how we're forced to declare C variables before we can use it. I hate FDOV.

Name: Anonymous 2008-10-18 1:24

>>38
You idiot.

Name: Anonymous 2008-10-18 2:57

Write your compiler in Prolog.  Seriously, it's the easiest way.

Name: Anonymous 2008-10-19 1:39

The best and simplest pet language is one that is comprised of single character syntax.

$^%&#^%^^$^$#%@#$%$#$&(*@@!^%@#$@!@$%%@#$#@$@

Name: Anonymous 2008-10-19 4:41

GOLF LOL

Name: Anonymous 2008-10-19 7:49

Make esoteric language, where 1 is 0 and 0 is 1, the compiler is just a matter of XORing MAXINT on the machinecode.

Name: Anonymous 2008-10-19 12:33

>>40
IHBT

Name: Anonymous 2008-10-19 12:54

>>38
Anyways, please listen to me. Not that it's really related to this profile.
I went to /prog/ a while ago; you know, world4chan?
Well anyways there was an insane number of C programmers resolving memory leaks there, and I couldn't post.
Then, I looked at a stickied thread, and it had "CFLAGS tutorial" written on it.
Oh, the stupidity. Those idiots.
You, don't come to /prog/ just because it's got a CFLAGS tutorial, fool.
It's only CFLAGS, CFLAGS are a workaround for crying out loud.
There're even entire teams here. Team of 6, all out for some m4d CFLAGS, huh? How fucking nice.
"Alright, I'm gonna compile with -O4 -malicious-double!" God I can't bear to watch.
You people, I'll give you algorithm help if you get out of my Internet.
/prog/ should be a bloody place.
That tense atmosphere, where two nerds on opposite sides of the thread can start a fight over the forced indentation of code at any time,
the stab-or-be-stabbed mentality, that's what's great about this place.
People with lives should screw off and stay home.
Anyways, I was about to start trolling, and then the bastard beside me goes "-fpie-extensions and -ffaggot-protector, with extra security."
Who in the world uses insecure languages nowadays, you moron?
I want to ask him, "do you REALLY want to compile it with extra security?"
I want to interrogate him. I want to interrogate him for roughly an hour.
Are you sure you don't just want to try saying "I'd better use Haskell for this"?
Coming from a /prog/ veteran such as myself, the latest trend among us vets is this, virtual machines.
That's right, programs running in virtual machines. This is the vet's way of programming.
Using a virtual machine means your program doesn't have direct access to the system. But on the other hand the program runs a tad slower. This is the key.
And then, it's Rapid Application Development. This is unbeatable.
However, if you use this then there is danger that you'll be marked by the process scheduler from next time on; it's a double-edged sword.
I can't recommend it to amateurs.
What this all really means, though, is that you, >>38, should just stick with today's special.

Name: ​​​​​​​​​​ 2010-09-08 13:36

<

Name: Anonymous 2010-12-06 9:47

Back to /b/, ``GNAA Faggot''

Don't change these.
Name: Email:
Entire Thread Thread List