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

Pages: 1-4041-

The Sensible Language

Name: Anonymous 2008-04-10 16:30

display message, ask for age and print age in words,
where message is "Welcome to the example program of The Sensible Language."

ask for x1 means print "What's your age?" and get a line as x1

print x1 in words means:
 print the hundreds, tens and units.
 where units is num words at index n, where n is the last char of x1 or ""
 where tens is num words at index n, where n is x1 at index 2 (backwards) or ""
 where hundreds is num words at index n, where n is x1 at index 3 (backwards) or ""

the last char of x1 means x1 at index i, where i is the length of x1 - 1

x1 of words means num words at index x1

num words is a hash-table of nums to strings, containing
 "one","two","three","four","five","six","seven","eight","nine".
 failing with "".

-- Standard IO library

get a line means get x1 from stdin

get x1 from x2 means, using ffi function `get' as `ffiget', ffiget x2 as x1

print x1 means, using ffi function `putstr', putstr x1

Name: Anonymous 2008-04-10 16:31

I'll make the compiler open source in a few days. It compiles to C, if you hadn't guessed.

Name: Anonymous 2008-04-10 16:36

For the ask functionality, do you use gets? If not, what do you do?

Name: Anonymous 2008-04-10 16:52

>>3
NEVER USE gets!

Name: Anonymous 2008-04-10 16:55

>>4
What should i use?

Name: Anonymous 2008-04-10 16:57

>>5
man 3 fgets

Name: Anonymous 2008-04-10 17:13

>>3
It uses a built-in foreign function `get', which is written in C[1]. The `get x1 from x2' declaration is for using it the way language “sentences” are used.

[1] It uses Vstr, a sensible string library: http://www.and.org/vstr/#about

Name: Anonymous 2008-04-10 17:25

>>7
    *   a printf like function that is fully ISO 9899:1999 (C99) compliant, also having %m as standard and POSIX i18n parameter number modifiers. It also allows gcc warning compatible customer format specifiers (and includes pre-written custom format specifiers for ipv4 and ipv6 addresses, Vstr strings and more)
So let me get this straight.
You claim the printf-life function is C99 compliant (1)
then you say it supports the `m' format modifier (2)

From (1) + (2) we have pure nonsense.
If it were really C99 compliant it would be an uppercase letter (ie, %M) and not %m.
Fucking n00bs.

Name: Anonymous 2008-04-10 17:34

>>8
You claim the
Er, I didn't write it. But your criticism that the printf-life function does everything that C99 demands, and additionally supports the `m' modifier, is accurate albeit banal.

Name: Anonymous 2008-04-10 17:42

x1 fucked your x2 means x1 applied to x2

cdr fucked your cudder where cudder is cons of "EXPERT" and "PROGRAMMER"

i fucked your mother

Name: Anonymous 2008-04-10 17:44

>>10
i applied to motherOH SHIT!!!!

Name: Anonymous 2008-04-10 17:49

>>9
I am going to email the developer about this tremendous bug.
I'll make sure to express my disappointment with him and how low he now is to my respect-o meter.
Love is over.

vstr/examples/ex_httpd.c:
if (sa->sa_family != AF_INET) /* only support IPv4 atm. */
   goto sa_fail;

goto sa_fail;
oto sa_fail;
to sa_fail;
sa_fail;
FAIL

Name: Anonymous 2008-04-10 17:51

>>12
that's in a httpd, moron

Name: Anonymous 2008-04-10 17:52

>>13
Do you honestly, genuinely believe I am not aware of that?
Come on, make my day troll.
I repeat, this is not a question.

Name: Anonymous 2008-04-10 17:54

>>14
i don't know how to make a "day troll". your retarded

Name: Anonymous 2008-04-10 17:56

>>15
ergo your wrong bitch

Name: C99 Quoter 2008-04-10 17:57

7.26 Future library directions
[...]
7.26.9 Input/output <stdio.h>
1. Lowercase letters may be added to the conversion specifiers and length modifiers in fprintf and fscanf. Other characters may be used in extensions.

Name: Anonymous 2008-04-10 17:57

>>15
your retarded
YOUR?
OH GOD YOU ARE WORSE THAN THE PRINTF-LIKE-C99-COMPLIANT-%m-MODIFIER MORON.
I WANT EVERYTHING YOU EVER LOVED TO VANISH!

Name: Anonymous 2008-04-10 17:58

>>16
Igor your wrong bitch is twisting my arm.

Name: Anonymous 2008-04-10 17:59

>>18
EXPERT SHOUTER

Name: Anonymous 2008-04-10 18:03

>>17
%m invokes undefined behavior which instantly makes it non-compliant regardless of what 7.26.9 has to say.
Read 7.19.6.1
If a conversion specification is invalid, the behavior is undefined. If any argument is not the correct type for the corresponding conversion specification, the behavior is undefined.
Undefined behavior = non-compliant.
Sorry, you lost.

Name: Anonymous 2008-04-10 18:09

>>21
Except it IS defined by the library, you complete and utter fool.

Name: Anonymous 2008-04-10 18:10

[b]FUCK YOUR CUDDER NIGGER

Name: Anonymous 2008-04-10 18:11

the string library works. get over it. what paradigm is your language, OP? looks imperative, just with weird syntax

Name: Anonymous 2008-04-10 18:12

>>22
Irrelevant.
A library can have extensions, and in which particular case stands true.
What's bad is the false claim that his function is C99 compliant.
ME?! A FOOL? HA!
That was.. rather amusing, but now I must leave. It can't get any better than this.

Name: Anonymous 2008-04-10 18:25

>>25
It is c99 compliant.

Name: Anonymous 2008-04-10 18:51

lolcode + C + DQN grammarian?

Name: Anonymous 2008-04-10 18:57

>>27
what's DQN?

Name: Anonymous 2008-04-10 19:14

sounds awfully wordy for a code and needs more parenthesissessssHURRRRR LISP LISP LISP

Name: Anonymous 2008-04-10 19:20

>>29
That's the idea. It's kind of like predicates with place structure. I got the idea when thinking about how to have a programming language that's easy to talk about in person. Have a go at reading it aloud, I think it reads better than pseudocode.

Name: Anonymous 2008-04-10 19:21

>>28
google

Name: Anonymous 2008-04-10 19:23

>>31
I tried. can't find anything. relevant to grammar.

Name: Anonymous 2008-04-10 19:24

Reminds me of Lojban.

Name: Anonymous 2008-04-10 20:52

interesting way of binding variables

Name: Anonymous 2008-04-10 22:21

>>30
Unfortunately, natural languages are very ambiguous and context-sensitive, both very undesirable traits for a programming language.

Name: Anonymous 2008-04-11 9:31

>>35
Interestingly, in Haskell, what does show foo mean?

Name: Anonymous 2008-04-11 10:11

>>36
It invokes the show function with the argument foo, where foo is an instance of the Show class, the return value is a list of Char.

Name: Anonymous 2008-04-11 12:19

>>37
Correct. foo is type Show a => a. The list that is returned is dependent on the type of a. Thus, there exists context-sensitivity in a programming language.

Name: Anonymous 2009-03-06 12:28

Using archaic meanings of.

Name: Anonymous 2011-02-03 6:51

Name: Sgt.Kabukiman 2012-05-21 16:11

All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy
 All work and no play makes Jack a dull boy

Name: Anonymous 2013-01-19 23:09

/prog/ will be spammed continuously until further notice. we apologize for any inconvenience this may cause.

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