From 7a7ea498087922dedf7404ed242ef1b381a7306b Mon Sep 17 00:00:00 2001 From: Camil Staps Date: Mon, 9 Oct 2017 23:36:41 +0200 Subject: Skeleton 5 --- .gitignore | 2 ++ assignment-5/skeleton5.icl | 61 ++++++++++++++++++++++++++++++++++++++++++++++ assignment-5/skeleton5.prj | 59 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 122 insertions(+) create mode 100644 assignment-5/skeleton5.icl create mode 100644 assignment-5/skeleton5.prj diff --git a/.gitignore b/.gitignore index b1fe992..d0c506a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ Clean\ System\ Files/ a.out +*-www/ +*-sapl/ diff --git a/assignment-5/skeleton5.icl b/assignment-5/skeleton5.icl new file mode 100644 index 0000000..37115e4 --- /dev/null +++ b/assignment-5/skeleton5.icl @@ -0,0 +1,61 @@ +module skeleton5 + +import iTasks + +/* + * Pieter Koopman, pieter@cs.ru.nl + * Advanced Programming. Skeleton for assignment 5 + * - use this a project with environment iTasks + * - executable must be in Examples/iTasks or a subdirectory + * You can also use the -sdk commandline flag to set the path + * check Project Options -> Profiling -> Dynamics to prevent recompilation + */ + +:: Student = + { name :: String + , snum :: Int + , bama :: BaMa + , year :: Int + } + +:: BaMa = Bachelor | Master + +Start w = 42 + +students :: [Student] +students = + [ { name = "Alice" + , snum = 1000 + , bama = Master + , year = 1 + } + , { name = "Bob" + , snum = 1003 + , bama = Master + , year = 1 + } + , { name = "Carol" + , snum = 1024 + , bama = Master + , year = 2 + } + , { name = "Dave" + , snum = 2048 + , bama = Master + , year = 1 + } + , { name = "Eve" + , snum = 4096 + , bama = Master + , year = 1 + } + , { name = "Frank" + , snum = 1023 + , bama = Master + , year = 1 + } + ] + +generic gToString a :: a -> String + +instance + String where + s t = s +++ t diff --git a/assignment-5/skeleton5.prj b/assignment-5/skeleton5.prj new file mode 100644 index 0000000..2809873 --- /dev/null +++ b/assignment-5/skeleton5.prj @@ -0,0 +1,59 @@ +Version: 1.4 +Global + ProjectRoot: . + Target: iTasks + Exec: {Project}/skeleton5 + CodeGen + CheckStacks: False + CheckIndexes: True + Application + HeapSize: 2097152 + StackSize: 512000 + ExtraMemory: 8192 + IntialHeapSize: 204800 + HeapSizeMultiplier: 4096 + ShowExecutionTime: False + ShowGC: False + ShowStackSize: False + MarkingCollector: False + DisableRTSFlags: False + StandardRuntimeEnv: True + Profile + Memory: False + MemoryMinimumHeapSize: 0 + Time: False + Stack: False + Dynamics: True + DescExL: False + Output + Output: ShowConstructors + Font: Monaco + FontSize: 9 + WriteStdErr: False + Link + LinkMethod: Static + GenerateRelocations: False + GenerateSymbolTable: False + GenerateLinkMap: False + LinkResources: False + ResourceSource: + GenerateDLL: False + ExportedNames: + Paths + Path: {Project} + Precompile: + Postlink: +MainModule + Name: skeleton5 + Dir: {Project} + Compiler + NeverMemoryProfile: False + NeverTimeProfile: False + StrictnessAnalysis: True + ListTypes: StrictExportTypes + ListAttributes: True + Warnings: True + Verbose: True + ReadableABC: False + ReuseUniqueNodes: True + Fusion: False -- cgit v1.2.3