rev 709 - in trunk: . include/prothon src

SVN User <[email protected]> Mon, 05 Jul 2004 23:20:51 -0400
Newsgroups gmane.comp.lang.prothon.cvs
Message-ID <[email protected]>
Author: mark
Date: 2004-07-05 23:20:49 -0400 (Mon, 05 Jul 2004)
New Revision: 709

Modified:
   trunk/CHANGES.txt
   trunk/include/prothon/prothon.h
   trunk/src/builtins-dict.c
Log:
*** release build ***
added Dict.bool_?

Modified: trunk/CHANGES.txt
===================================================================
--- trunk/CHANGES.txt	2004-07-06 02:24:19 UTC (rev 708)
+++ trunk/CHANGES.txt	2004-07-06 03:20:49 UTC (rev 709)
@@ -1,7 +1,7 @@
 
 			----- Prothon Release History ----
 
-Version 0.1.2 - Build 708 - 7/05/04
+Version 0.1.2 - Build 709 - 7/05/04
 	- print is now a function, not a keyword
 	- function-as-command feature allows print to be used without parens
 	- Added prop keyword and properties feature with wildcards
@@ -31,6 +31,7 @@
 	- *args param local variable in func is now a tuple, not a list
 	- Fixed raise keyword so second arg is doc_ attribute of first
 	- Added immutable check to dictionary function key parameter
+	- Added Dict.len_ and Dict.bool_?
 	- Moved File from extension module to built-in
 	- Changed File.stdxxx to sys.stdIn, sys.stdOut, and sys.stdErr
 	- changed Len, Cmp, len,  cmp,  chr,  ord to 

Modified: trunk/include/prothon/prothon.h
===================================================================
--- trunk/include/prothon/prothon.h	2004-07-06 02:24:19 UTC (rev 708)
+++ trunk/include/prothon/prothon.h	2004-07-06 03:20:49 UTC (rev 709)
@@ -81,7 +81,7 @@
 #endif
  
 #define PROTHON_VERSION_NUMBER	"0.1"
-#define PROTHON_VERSION_BUILD   "$Rev: 708$"  
+#define PROTHON_VERSION_BUILD   "$Rev: 709$"  
 #define PROTHON_VERSION_DATE	__DATE__
 
 #ifndef FALSE

Modified: trunk/src/builtins-dict.c
===================================================================
--- trunk/src/builtins-dict.c	2004-07-06 02:24:19 UTC (rev 708)
+++ trunk/src/builtins-dict.c	2004-07-06 03:20:49 UTC (rev 709)
@@ -512,6 +512,12 @@
 	return NEW_INT(dict_len(ist, self));
 }
 
+DEF(Dict, bool__QUES, NULL) {
+	BIN_CONTENT_CHK(Dict);
+	if (dict_len(ist, self)) return OBJ(PR_TRUE);
+	else                     return OBJ(PR_FALSE);
+}
+
 DEF(Dict, items, NULL) {
 	BIN_CONTENT_CHK(Dict);
 	return dict_keys_values(ist, self, 3 /*tuples*/);
@@ -636,6 +642,7 @@
 	MODULE_ADD_SYM(Dict, hasKey_QUES);
 	MODULE_ADD_SYM(Dict, items);
 	MODULE_ADD_SYM(Dict, len_);
+	MODULE_ADD_SYM(Dict, bool__QUES);
 	MODULE_ADD_SYM(Dict, keys);
 	MODULE_ADD_SYM(Dict, values);
 	MODULE_ADD_SYM(Dict, get);