Re: [Chicken-users] handling the undefined value
Am Donnerstag, den 25.11.2010, 22:34 +0100 schrieb Felix: > From: Jörg "F. Wittenberger" > Subject: Re: [Chicken-users] handling the undefined value > Date: Thu, 25 Nov 2010 16:24:01 +0100 > > > Am Mittwoch, den 24.11.2010, 18:53 +0100 schrieb Felix: > >> From: Jörg "F. Wittenberger" > >> Subject: Re: [Chicken-users] handling the undefined value > >> Date: Mon, 22 Nov 2010 15:08:46 +0100 > >> > >> > Have a compiler switch (since it may break some code), which changes the > >> > code to return zero values instead of the distinguished undefined value. > >> > >> I don't think this is a great idea: this will change the > >> semantics of code using call-with-values, > > > > So far I did not come around to test, whether or not I'll be able to > > find my undefined value with the new scrutinizer version. > > Unfortunately I had to disable this feature again. We probably need > some sort of "style" warning switch (there are too many places where > procedures without result or undefined result use forms like `when'). Sadly. The "style" warning I'd like to avoid if all possible. I'd rather vote for changing the syntax definitions (one-by-one, tell me the git/svn/wtf reference and I'll try my best). > > This however I don't understand. Why would it be less efficient to call > > a continuation with zero instead of one value? > > There is a bit of wrapping and result-value count checking going on > behind the scenes in that case. I see. I understand: could be as efficient, but that would need quite a lot of other changes. Right? ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] handling the undefined value
From: Jörg "F. Wittenberger" Subject: Re: [Chicken-users] handling the undefined value Date: Thu, 25 Nov 2010 16:24:01 +0100 > Am Mittwoch, den 24.11.2010, 18:53 +0100 schrieb Felix: >> From: Jörg "F. Wittenberger" >> Subject: Re: [Chicken-users] handling the undefined value >> Date: Mon, 22 Nov 2010 15:08:46 +0100 >> >> > Have a compiler switch (since it may break some code), which changes the >> > code to return zero values instead of the distinguished undefined value. >> >> I don't think this is a great idea: this will change the >> semantics of code using call-with-values, > > So far I did not come around to test, whether or not I'll be able to > find my undefined value with the new scrutinizer version. Unfortunately I had to disable this feature again. We probably need some sort of "style" warning switch (there are too many places where procedures without result or undefined result use forms like `when'). > > Otherwise I'm aware that this would change semantics. Hence I'd only > propose it as a switch. > >> will be less efficient, > > This however I don#t understand. Why would it be less efficient to call > a continuation with zero instead of one value? There is a bit of wrapping and result-value count checking going on behind the scenes in that case. cheers, felix ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] Can an egg have a library and executable with the same name?
On Thu, Nov 25, 2010 at 04:46:09AM -0500, Mario domenech Goulart wrote: > Hi Alan > > On Wed, 24 Nov 2010 20:16:55 -0700 Alan Post > wrote: > > > My egg, genturfa'i, has an executable and a library. I've named the > > library genturfahi and the executable genturfahi-peg. I'd rather > > name the executable genturfahi too, though I suspect I'm not able to > > do that. > > > > Is this true? If it isn't, can someone point me to an egg that has > > a library and an executable named after the egg? > > As Peter mentioned, awful does that. You just have to be careful > with the ids given to `install-program' and `install-extension' (they > must be different). > > That was pointed by Jim. He wrote about that in CG #9 (paragraph right > before the "Yolklore" section): > > ,[ http://gazette.call-cc.org/issues/9.html ] > | And now a public service announcement. Egg authors, now hear this. When > | your egg installs both library files via install-extension and also an > | executable via install-program, you need to use different IDs for > | each. By convention, the library files should use the name of the egg > | (such as chicken-doc) and the executable should use this same name with > | something appended, such as chicken-doc-cmd. This prevents the > | uninstaller from losing track of files. Specifically, the .setup-info > | files created by chicken-install to track extension metadata will > | clobber each other if the IDs are identical. > ` > Thank you, I remember seeing this now. The problem I was having related to different builds overwritting each other's .o files. It seemed as if the compile code was generating intermediate .o files with names I could not control, and they were clashing. Whether that was true or not, I've since moved the egg to use the make command, and using the advice from issue #9 I got my egg compiling with both a library and an executable. Thank you! -- .i ko djuno fi le do sevzi ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] utf8 and string-ref performance
On Thu, Nov 25, 2010 at 12:17:24PM +0100, Peter Bex wrote: > > I'm probably confused or didn't fully > > understand the original problem. > > Me too. I'll stop talking for Alan and let him answer your questions > instead ;) > I tested compiling the Lojban morphology file with and without utf8 enabled. It takes 5 seconds on my machine to parse the file and return the parser generator without utf8 enabled, and 20 seconds to perform the same operation with utf8 enabled. So I definitely have a problem to fix, re: the original question in this thread. I also added a test case for utf8 (I haven't checked it in yet) that does not work with utf8 enabled or disabled. I suspect I'm doing something chancy in my code, but I haven't sat down to figure out what is going on. I've put that issue on my backlog, and have disabled utf8 until I get my test case working. I won't have much more to contribute to the conversation until I get my utf8 test case passing. This is the first I've heard of locatives, so I'm likely to have more questions than answers. ;-) -Alan -- .i ko djuno fi le do sevzi ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] handling the undefined value
Am Mittwoch, den 24.11.2010, 18:53 +0100 schrieb Felix: > From: Jörg "F. Wittenberger" > Subject: Re: [Chicken-users] handling the undefined value > Date: Mon, 22 Nov 2010 15:08:46 +0100 > > > Have a compiler switch (since it may break some code), which changes the > > code to return zero values instead of the distinguished undefined value. > > I don't think this is a great idea: this will change the > semantics of code using call-with-values, So far I did not come around to test, whether or not I'll be able to find my undefined value with the new scrutinizer version. Otherwise I'm aware that this would change semantics. Hence I'd only propose it as a switch. > will be less efficient, This however I don#t understand. Why would it be less efficient to call a continuation with zero instead of one value? If we had a #define C_kontinue0(k)((C_proc1)(void *)C_u_i_car(k))(1, (k)) and the compiler would spit out that instead of C_kontinue(k, C_SCHEME_UNDEFINED) ??? > and may throw errors in some cases Hell, yes! That's what I want from the switch: throw errors in those cases where I try to bind a variable to undefined. cheers /Jörg ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] Can an egg have a library and executable with the same name?
On Nov 25, 2010, at 2:09, Peter Bex wrote: > On Wed, Nov 24, 2010 at 08:16:55PM -0700, Alan Post wrote: >> If it isn't, can someone point me to an egg that has >> a library and an executable named after the egg? > > awful does this. And chicken-doc, chicken-doc-admin, and chickadee. Jim ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] Chicken Gazette - Issue 13
Am Mittwoch, den 24.11.2010, 19:25 +0100 schrieb Peter Bex: > On Wed, Nov 24, 2010 at 06:15:24PM +0100, Jörg F. Wittenberger wrote: > > > I didn't know SQLite had any replication whatsoever at all. Or did you > > > roll your own? > > Well, I told you with a grin that this is a letters to the editor. So > > kind of a "me too". > > > > Yes, I did. Using chicken. Did you read my linked example code? > > http://www.askemos.org/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 > > I keep getting "connection refused" from that server, so I can't check. That's strange. But likely kind of hard to debug. Because "that server" does not really apply. It's a network of 7 hosts, 4 of which are in the DNS record. (I kind o struggle how to get dynamic IP's into the set without reducing the TTL for the majority of static IP's.) But besides what "dig" brings up, there is also isstvan.softeyes.net, a sheeva plug under my desk. Does the page still hang? If so, could you try those replicas: http://garkin.softeyes.net/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 http://garkin1.softeyes.net/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 http://askemos2.tc-mw.de/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 http://garkin2.tc-mw.de/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 http://garkin3.tzv.de/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 http://isstvan.softeyes.net/Adc5dd0c30f6e63932811ed60e019bb2d/Kalender?date=2010-11-01 BTW: My calendar actually uses the database. As does the wiki on the www.askemos.org (to store the internal references). 2nd side note: the same trick should work with many of those Axxx* URL's I posted. Just that some of those are not replicated to all hosts, because I need to test that replication is done according to the rules and not just universal. > > Adding yet another replica is as complicated as filling the id into this > > form (screenshot) > > http://www.askemos.org/Ab6c588dfa4ed826d7b387f19fbc60f10 > > Again, connection refused. > > > > If so, you could do that with any database! > > > > Maybe you could. > > I have no need for such a system right now :) I just wanted to let you > know it's unfair to cite it as an advantage of SQLite if you just hacked > it on top since the same could be done with postgres. Except that the > work has already been done for sqlite, of course ;) In a way, your are right. I was kidding a bit about this being an advantage of SWLite. But as I think about it, I must conclude: it actually is, because of the vfs interface, which made things easy. > > > That's what SSL connections (with client certificates) are for. > > > > Wait, security can be even stronger. What if replica is rooted? Or you > > got an admin bribed? > > That's not exactly a classical MitM situation, is it? How do you deal > with that now? By having a replica (ready to be) owned/maintained and administrated by each party. (And not having any central administration). Thus no single person has the (technical) ability to mess with data. I hope the site works now for you (and everyone else). It gives more details. If not ping me again (privately to reduce noise here). best regards /Jörg ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] utf8 and string-ref performance
From: Peter Bex Subject: Re: [Chicken-users] utf8 and string-ref performance Date: Thu, 25 Nov 2010 12:17:24 +0100 > On Thu, Nov 25, 2010 at 06:15:50AM -0500, Felix wrote: >> >> Sorry, I don't understand? They are not invalidated by GC (in case >> >> you mean that). >> > >> > So that means the locative will stay around while the string itself >> > might have been collected? >> >> If it's a weak locative, yes. But dereferencing will signal an >> error in this case. But I thought this is about being able to >> point into a string? > > Yeah, but it's stored in a closure and the GC should be prevented from > cleaning up the original string which may not be referenced anywhere > anymore I guess. It's a separate object and a non-weak locative will prevent the data pointed to from being GC'd. I still don't know whether it is of any help, though. cheers, felix ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] utf8 and string-ref performance
On Thu, Nov 25, 2010 at 06:15:50AM -0500, Felix wrote: > >> Sorry, I don't understand? They are not invalidated by GC (in case > >> you mean that). > > > > So that means the locative will stay around while the string itself > > might have been collected? > > If it's a weak locative, yes. But dereferencing will signal an > error in this case. But I thought this is about being able to > point into a string? Yeah, but it's stored in a closure and the GC should be prevented from cleaning up the original string which may not be referenced anywhere anymore I guess. > I'm probably confused or didn't fully > understand the original problem. Me too. I'll stop talking for Alan and let him answer your questions instead ;) Cheers, Peter -- http://sjamaan.ath.cx -- "The process of preparing programs for a digital computer is especially attractive, not only because it can be economically and scientifically rewarding, but also because it can be an aesthetic experience much like composing poetry or music." -- Donald Knuth ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] utf8 and string-ref performance
From: Peter Bex Subject: Re: [Chicken-users] utf8 and string-ref performance Date: Thu, 25 Nov 2010 09:08:28 +0100 > On Thu, Nov 25, 2010 at 02:50:23AM +0100, Felix wrote: >> > I'm afraid this is just the "shared substring/blob" structure proposal >> > in another guise. I don't know if locatives are useful; those can't >> > really be kept around for a long time, can they? >> >> Sorry, I don't understand? They are not invalidated by GC (in case >> you mean that). > > So that means the locative will stay around while the string itself > might have been collected? If it's a weak locative, yes. But dereferencing will signal an error in this case. But I thought this is about being able to point into a string? I'm probably confused or didn't fully understand the original problem. cheers, felix ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] Can an egg have a library and executable with the same name?
Hi Alan On Wed, 24 Nov 2010 20:16:55 -0700 Alan Post wrote: > My egg, genturfa'i, has an executable and a library. I've named the > library genturfahi and the executable genturfahi-peg. I'd rather > name the executable genturfahi too, though I suspect I'm not able to > do that. > > Is this true? If it isn't, can someone point me to an egg that has > a library and an executable named after the egg? As Peter mentioned, awful does that. You just have to be careful with the ids given to `install-program' and `install-extension' (they must be different). That was pointed by Jim. He wrote about that in CG #9 (paragraph right before the "Yolklore" section): ,[ http://gazette.call-cc.org/issues/9.html ] | And now a public service announcement. Egg authors, now hear this. When | your egg installs both library files via install-extension and also an | executable via install-program, you need to use different IDs for | each. By convention, the library files should use the name of the egg | (such as chicken-doc) and the executable should use this same name with | something appended, such as chicken-doc-cmd. This prevents the | uninstaller from losing track of files. Specifically, the .setup-info | files created by chicken-install to track extension metadata will | clobber each other if the IDs are identical. ` Best wishes. Mario -- http://parenteses.org/mario ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] utf8 and string-ref performance
On Thu, Nov 25, 2010 at 02:50:23AM +0100, Felix wrote: > > I'm afraid this is just the "shared substring/blob" structure proposal > > in another guise. I don't know if locatives are useful; those can't > > really be kept around for a long time, can they? > > Sorry, I don't understand? They are not invalidated by GC (in case > you mean that). So that means the locative will stay around while the string itself might have been collected? Cheers, Peter -- http://sjamaan.ath.cx -- "The process of preparing programs for a digital computer is especially attractive, not only because it can be economically and scientifically rewarding, but also because it can be an aesthetic experience much like composing poetry or music." -- Donald Knuth ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] Can an egg have a library and executable with the same name?
From: Alan Post Subject: [Chicken-users] Can an egg have a library and executable with the same name? Date: Wed, 24 Nov 2010 20:16:55 -0700 > My egg, genturfa'i, has an executable and a library. I've named the > library genturfahi and the executable genturfahi-peg. I'd rather > name the executable genturfahi too, though I suspect I'm not able to > do that. > > Is this true? If it isn't, can someone point me to an egg that has > a library and an executable named after the egg? I can't think of an example, but this should work. cheers, felix ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users
Re: [Chicken-users] Can an egg have a library and executable with the same name?
On Wed, Nov 24, 2010 at 08:16:55PM -0700, Alan Post wrote: > If it isn't, can someone point me to an egg that has > a library and an executable named after the egg? awful does this. Cheers, Peter -- http://sjamaan.ath.cx -- "The process of preparing programs for a digital computer is especially attractive, not only because it can be economically and scientifically rewarding, but also because it can be an aesthetic experience much like composing poetry or music." -- Donald Knuth ___ Chicken-users mailing list Chicken-users@nongnu.org http://lists.nongnu.org/mailman/listinfo/chicken-users