summaryrefslogtreecommitdiff
path: root/examples/numerals/czech.gf
diff options
context:
space:
mode:
authorjohn.j.camilleri <john.j.camilleri@chalmers.se>2013-09-16 07:17:27 +0000
committerjohn.j.camilleri <john.j.camilleri@chalmers.se>2013-09-16 07:17:27 +0000
commitf5461eb3d4eb2605b546a4ed202c12bcdaa1f4e4 (patch)
tree946c9e8542b8e8271b6b529a95c0400fa6613cb4 /examples/numerals/czech.gf
parent8e1c6cca407c82fc09569d80c231b8d256735989 (diff)
Remove contribs and examples
Everything has now been moved to a separate repository at https://github.com/GrammaticalFramework/gf-contrib The contents of the examples folder are build during SetupWeb
Diffstat (limited to 'examples/numerals/czech.gf')
-rw-r--r--examples/numerals/czech.gf67
1 files changed, 0 insertions, 67 deletions
diff --git a/examples/numerals/czech.gf b/examples/numerals/czech.gf
deleted file mode 100644
index abbe16134..000000000
--- a/examples/numerals/czech.gf
+++ /dev/null
@@ -1,67 +0,0 @@
-concrete czech of Numerals = {
-flags coding = utf8 ;
--- include numerals.Abs.gf ;
--- flags coding=latinasupplement ;
-
-oper bind : Str -> Str -> Str = \s1 -> \s2 -> s1 ++ s2 ;
-
--- [c^], [s^], [r^], [e^]
-
-param Size = sg | twothreefour | fiveup ;
-param DForm = unit | teen | ten | hundred ;
-
-lincat Numeral = { s : Str } ;
-oper LinDigit = {s : DForm => Str ; size : Size} ;
-lincat Digit = LinDigit ;
-
-lincat Sub10 = {s : DForm => Str ; size : Size} ;
-lincat Sub100 = {s : Str; size : Size } ;
-lincat Sub1000 = {s : Str; size : Size } ;
-lincat Sub1000000 = { s : Str } ;
-
-oper mkNum : Str -> Str -> Str -> Str -> Size -> LinDigit =
- \dva -> \dvanast -> \dvadsat -> \dveste -> \sz ->
- { s = table {unit => dva ; teen => dvanast + "náct" ; ten => dvadsat ; hundred => dveste } ; size = sz };
-
-oper mk2Num : Str -> Str -> Str -> Str -> LinDigit = \unit -> \teenbase -> \tenbase -> \hundred ->
- mkNum unit teenbase (tenbase + "cet") hundred twothreefour ;
-
-oper mk5Num : Str -> Str -> Str -> LinDigit = \unit -> \teenbase -> \tenbase ->
- mkNum unit teenbase (tenbase + "desát") (unit ++ "set") fiveup ;
-
-lin num x = {s = [] ++ x.s ++ [] } ; -- Latin A supplement encoding
-
-lin n2 = mk2Num "dva" "dva" "dva" ("dve^" ++ "ste^") ;
-lin n3 = mk2Num "tr^i" "tr^i" "tr^i" ("tr^i" ++ "sta") ;
-lin n4 = mk2Num "čtyr^i" "čtr" "čtyr^i" ("čtyr^i" ++ "sta") ;
-lin n5 = mk5Num "pe^t" "pat" "pa" ;
-lin n6 = mk5Num "šest" "šest" "še" ;
-lin n7 = mk5Num "sedm" "sedm" "sedm";
-lin n8 = mk5Num "osm" "osm" "osm";
-lin n9 = mk5Num "deve^t" "devate" "deva" ;
-
-lin pot01 = {s = table {unit => "jeden" ; hundred => "sto" ; _ => "dummy" } ;
- size = sg } ;
-lin pot0 d = d ;
-lin pot110 = {s = "deset" ; size = fiveup } ;
-lin pot111 = {s = "jedenáct" ; size = fiveup };
-lin pot1to19 d = {s = d.s ! teen ; size = fiveup} ;
-lin pot0as1 n = {s = n.s ! unit ; size = n.size} ;
-lin pot1 d = {s = d.s ! ten ; size = fiveup} ;
-lin pot1plus d e = {s = variants { d.s ! ten ++ e.s ! unit ; bind (bind (e.s ! unit) "a") (d.s ! ten)} ; size = tfSize e.size} ;
-lin pot1as2 n = n ;
-lin pot2 d = {s = d.s ! hundred ; size = fiveup} ;
-lin pot2plus d e = {s = d.s ! hundred ++ e.s ; size = tfSize e.size} ;
-lin pot2as3 n = {s = n.s } ;
-lin pot3 n = {s = (mkTh n.s) ! n.size} ;
-lin pot3plus n m = {s = (mkTh n.s) ! n.size ++ m.s} ;
-
-oper tfSize : Size -> Size = \sz ->
- table {sg => fiveup ; other => other} ! sz ;
-
-oper mkTh : Str -> Size => Str = \attr ->
- table {sg => "tisíc" ;
- twothreefour => attr ++ "tisíce" ;
- fiveup => attr ++ "tisíc" } ;
-
-}