⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 id.642351.mal

📁 一个内存数据库的源代码这是服务器端还有客户端
💻 MAL
字号:
# Monet Mil to Mal compiler# Copyright (c) 2001-2004, CWI. All rights reserved.#Predefined code segment#The compiler can not guarantee an accurate compilation,#because MIL unlike MAL is a dynamically typed language.#A few guidelines to maximize usefullness.#- make the type of variables explicit, in particular 'nil'#- upon advice of M2m to remap identifiers, change it in your program directly#use the "mil_schema" for additional support routines#	io.print("# Date:\t\t2002-11-22 17:08\n");#	io.print("# Category: \tNone\n");#	io.print("# Group: \tNone\n");#	io.print("# Status: \tOpen\n");#	io.print("# Resolution: \tNone\n");#	io.print("# Priority: \t5\n");#	io.print("# Submitted By: Maurice van Keulen (mvankeulen)\n");#	io.print("# Assigned to: \tNobody/Anonymous (nobody)\n");#	io.print("# Summary: \tBug in kintersect\n");#	io.print("# \n");#	io.print("# Initial Comment:\n");#	io.print("# Sporadically, a bug in \"kintersect\" is haunting me. The\n");#	io.print("# result of the operation is not correct. I finally\n");#	io.print("# managed to construct an example that reproduces the\n");#	io.print("# bug. The attached file contains two exported bats and a\n");#	io.print("# small script that imports them and performs a\n");#	io.print("# kintersect. The result should be empty, but somehow one\n");#	io.print("# element ends up in the result anyway. To make the bug\n");#	io.print("# visible, I try to look up the elements of the result in\n");#	io.print("# one of the operands of kintersect. Since it is an\n");#	io.print("# intersection, those values should always be there,\n");#	io.print("# shouldn't they\?\n");#	io.print("module(\"unix\",\"ascii_io\");");	TTD := getenv("TSTTRGDIR");#	io.print("");	b := new(nil:oid,nil:str);#	io.print("var b:=new(oid,str);");	aa_a := +(TTD,"/ID.642351.b.txt");	ba_a := import(b,aa_a);#	io.print("b.import(TTD + \"/ID.642351.b.txt\");");	ca_a := print(b);#	io.print("b.print();");	c := new(nil:oid,nil:oid);#	io.print("var c:=new(oid,oid);");	da_a := +(TTD,"/ID.642351.c.txt");	ea_a := import(c,da_a);#	io.print("c.import(TTD + \"/ID.642351.c.txt\");");	fa_a := print(c);#	io.print("c.print();");	d := kintersect(c,b);#	io.print("var d:=c.kintersect(b);");	ga_a := print(d);#	io.print("d.print();");barrier	(ha_a,ha_aH,ha_aT) := newIterator(d);	ia_a := find(b,ha_aH);	ja_a := print(ia_a);redo	(ha_a,ha_aH,ha_aT) := hasMoreElements(d);exit	(ha_a,ha_aH,ha_aT) ;#	io.print("");	DBGMSK := setDebug();#	io.print("var DBGMSK := debugmask();");	ka_a := or(DBGMSK,2097152);	la_a := setDebug(ka_a);#	io.print("debugmask(or(DBGMSK,2097152));");	e := kintersect(c,b);#	io.print("var e:=c.kintersect(b);");	ma_a := setDebug(DBGMSK);#	io.print("debugmask(DBGMSK);");	na_a := print(e);#	io.print("e.print();");barrier	(oa_a,oa_aH,oa_aT) := newIterator(e);	pa_a := find(b,oa_aH);	qa_a := print(pa_a);redo	(oa_a,oa_aH,oa_aT) := hasMoreElements(e);exit	(oa_a,oa_aH,oa_aT) ;#Identifer 'debugmask' mapped to 'setDebug'

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -