Mercurial > repo
view interps/glass/builtins.diff @ 12518:2d8fe55c6e65 draft default tip
<int-e> learn The password of the month is release incident pilot.
author | HackEso <hackeso@esolangs.org> |
---|---|
date | Sun, 03 Nov 2024 00:31:02 +0000 |
parents | 859f9b4339e6 |
children |
line wrap: on
line source
--- builtins.cc 2005-10-24 12:37:51.000000000 -0700 +++ /home/razorx/glass-0.11/builtins.cc 2006-07-27 20:01:16.000000000 -0700 @@ -72,6 +72,7 @@ [l~I.l~] \ [c~I.c~] \ [e~I.e~] \ +[n~I.n~] \ } \ {(Debug) \ [(cl)~Debug.cl~] \ @@ -208,6 +209,7 @@ sline = line; mainStack.push_front(new Variable(VAR_STRING, sline)); + } BUILTIN("I.c", 0) { int ic = getchar(); string ics; @@ -216,6 +218,14 @@ ics = ic; mainStack.push_front(new Variable(VAR_STRING, ics)); + + } BUILTIN ("I.n", 0) { + int in; + int inn; + scanf ("%d",&in); + inn = in; + mainStack.push_front(new Variable(VAR_NUMBER, inn)); + } BUILTIN("I.e", 0) { if (feof(stdin) || ferror(stdin)) { mainStack.push_front(new Variable(VAR_NUMBER, 1.0));