rev 707 - in trunk: . include/prothon pr/test src
SVN User <[email protected]> Mon, 05 Jul 2004 19:49:23 -0400
| Newsgroups | gmane.comp.lang.prothon.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: mark
Date: 2004-07-05 19:49:20 -0400 (Mon, 05 Jul 2004)
New Revision: 707
Modified:
trunk/CHANGES.txt
trunk/include/prothon/prothon.h
trunk/pr/test/int.pr
trunk/src/prothon.y
Log:
*** release build 707 ***
changed octal esc sequence from \0377 to \o377
Modified: trunk/CHANGES.txt
===================================================================
--- trunk/CHANGES.txt 2004-07-05 22:35:07 UTC (rev 706)
+++ trunk/CHANGES.txt 2004-07-05 23:49:20 UTC (rev 707)
@@ -1,7 +1,7 @@
----- Prothon Release History ----
-Version 0.1.2 - Build 706 - 7/05/04
+Version 0.1.2 - Build 707 - 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
@@ -24,6 +24,7 @@
- Added built-in range() generator (not list function)
- Added List(iter_) constructor
- Octal constant format changed from 0377 to 0o377
+ - Octal esc sequence changed from \0377 to \o377
- except keyword no longer allowed alone, must use "except Exception"
- except syntax changed from "except exc, var" to "except exc as var"
- Function formal params now introspectable via simple attribute
Modified: trunk/include/prothon/prothon.h
===================================================================
--- trunk/include/prothon/prothon.h 2004-07-05 22:35:07 UTC (rev 706)
+++ trunk/include/prothon/prothon.h 2004-07-05 23:49:20 UTC (rev 707)
@@ -81,7 +81,7 @@
#endif
#define PROTHON_VERSION_NUMBER "0.1"
-#define PROTHON_VERSION_BUILD "$Rev: 706$"
+#define PROTHON_VERSION_BUILD "$Rev: 707$"
#define PROTHON_VERSION_DATE __DATE__
#ifndef FALSE
Modified: trunk/pr/test/int.pr
===================================================================
--- trunk/pr/test/int.pr 2004-07-05 22:35:07 UTC (rev 706)
+++ trunk/pr/test/int.pr 2004-07-05 23:49:20 UTC (rev 707)
@@ -36,6 +36,9 @@
if 016 != 0o20 or 0o20 != 0x10: err(6)
+if "\o060" != '0': err(7)
+if "\x30" != '0': err(8)
+
y = 1002003004005006007008009000100200300400500600700800900
print """
--- All tests passed ---
Modified: trunk/src/prothon.y
===================================================================
--- trunk/src/prothon.y 2004-07-05 22:35:07 UTC (rev 706)
+++ trunk/src/prothon.y 2004-07-05 23:49:20 UTC (rev 707)
@@ -932,11 +932,12 @@
case 'r': c3 = '\r'; break;
case 't': c3 = '\t'; break;
case 'v': c3 = '\v'; break;
- case '0':
- case '1':
- case '2':
- case '3':
- c3 = (c2-'0');
+ case 'o':
+ if ((c2=getch(state)) < '0' || c2 > '3' ){
+ printf("Lexical error: bad octal constant \\ooo\n");
+ return ERR;
+ }
+ c3 = c2-'0';
if ((c2=getch(state)) < '0' || c2 > '7' ){
printf("Lexical error: bad octal constant \\ooo\n");
return ERR;