This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Shen, copyright (C) 2010-2015 Mark Tarver | |
www.shenlanguage.org, Shen 20.1 | |
running under Scheme, implementation: chez-scheme | |
port 0.16 ported by Bruno Deferrari | |
(0-) (datatype any | |
X : Type; | |
________ | |
X : (mode any -); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(3-) (datatype globals | |
_______________________ | |
(value *proof*) : proof;) | |
<1> Inputs to shen.mu_reduction | |
[[shen.mu [mode V1189 +] [[shen.mu [mode V1190 +] [shen.rename shen.the shen.variables in [Context_1957] and shen.then [call shen.the shen.continuation [[unify [cons V1189 [cons V1190 []]] [cons [cons [cons value [cons *proof* []]] [cons : [cons [cons list [cons [cons [cons list [cons [cons [cons list [cons wff []]] [cons * [cons wff []]]] []]] [cons * [cons [cons [cons list [cons [cons [cons list [cons wff []]] [cons * [cons wff []]]] []]] [cons --> [cons [cons list [cons [cons [cons list [cons wff []]] [cons * [cons wff []]]] []]] []]]] []]]] []]] []]]] [cons Context_1957 []]]]]]]] V1192]] V1191], +, ==> | |
<2> Inputs to shen.mu_reduction | |
[[shen.mu V1189 [[shen.mu [mode V1190 +] [shen.rename shen.the shen.variables in [Context_1957] and shen.then [call shen.the shen.continuation [[unify [cons V1189 [cons V1190 []]] [cons [cons [cons value [cons *proof* []]] [cons : [cons [cons list [cons [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -u -w ../Shen 17.3/Sources/macros.shen shen-sources/macros.shen | |
--- ../Shen 17.3/Sources/macros.shen 2015-03-02 17:34:22.000000000 -0200 | |
+++ shen-sources/macros.shen 2015-03-15 12:48:45.000000000 -0300 | |
@@ -176,7 +176,7 @@ | |
(define function-abstraction-help | |
F 0 Vars -> [F | Vars] | |
F N Vars -> (let X (gensym (protect V)) | |
- [/. X (function-abstraction-help F (- N 1) (append Vars [X]))])) | |
+ [lambda X (function-abstraction-help F (- N 1) (append Vars [X]))])) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -u -r -d -w Shen 17.2/Sources/macros.shen shen-chibi/shen-sources/macros.shen | |
--- Shen 17.2/Sources/macros.shen 2015-02-12 13:09:50.000000000 -0200 | |
+++ shen-chibi/shen-sources/macros.shen 2015-03-02 19:03:33.000000000 -0200 | |
@@ -176,7 +176,7 @@ | |
(define function-abstraction-help | |
F 0 Vars -> [F | Vars] | |
F N Vars -> (let X (gensym (protect V)) | |
- [/. X (function-abstraction-help F (- N 1) (append Vars [X]))])) | |
+ [lambda X (function-abstraction-help F (- N 1) (append Vars [X]))])) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Eq a where | |
(==) :: a -> a -> Bool | |
(/=) :: a -> a -> Bool | |
x /= y = not (x == y) | |
instance Eq Integer where | |
x == y = compareIntegers x y | |
instance Eq Float where | |
x == y = compareFloats x y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let r = ref 0 | |
let h n m = n + m | |
let f = h 1 | |
let g = fun n -> h 1 n | |
let () = | |
for i = 1 to 100000000 do | |
r := (f i) | |
done; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use CGI qw/:standard -debug/; | |
my $value = param("B1"); | |
print "HTTP/1.0 200 OK\n"; | |
print "Content-type: text/html\n\n"; | |
print <<HTML; | |
<html> | |
<head> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
pattern = re.compile(r'\\\'([0-9a-fA-F]{2})') | |
def fix(s): | |
return unicode(chr(int(s.group(1), base=16)), encoding='mac_roman') | |
s = unicode( | |
r"\'f2ltimo d\'92a de las negociaciones por Siria, que se reanudar\'87n el 10 de febrero") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html5> | |
<html> | |
<head><title>Form Submission Test</title></head> | |
<body> | |
<form method="POST" action="http://localhost:9999/submit"> | |
<button name="button1" value="button1">BUTTON1</button> | |
<button name="button2" value="button2">BUTTON2</button> | |
<button name="submit" value="button1">BUTTON1</button> | |
<button name="submit" value="button2">BUTTON2</button> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
print "HTTP/1.0 200 OK\n"; | |
print "Content-type: text/html\n\n"; | |
print <<HTML; | |
<html> | |
<head> | |
<title>A Simple Perl CGI</title> | |
</head> | |
<body> |