Re: [Oberon] Win32 Plugin Oberon, status report II
hope to get PluginAos starting up during the weekend, IF so THEN SYSTEM.PUT(Champaign, Mouth(Felix)) (* nearly done .... ;) *) ELSE SYSTEM.PUT(Beer, Mouth(SYSTEM.VAL(Felix, picture of misery))) (* more work waiting ;( *) I hope that you can open the Champaign today :-) I would like to try to port my WebDAV client to PluginOberon. Because when I tried to port it to Native (November 2001) I found that I had problems with the port of AosIO when trying to assign methods to the AosIO.Sender variable. So my qestion is whether this should work or isn't this stuff supported by
Felix Friedrich <friedrich@gsf.de>: the Native compiler of November 2001 ? Perhaps an upgrade to a newer Native would help ? Cheers, Edgar -- edgar@edgarschwarz.de "http://www.edgarschwarz.de" "http://www.edgar-schwarz.de/forum/oberon" Running Active Oberon Make it as simple as possible, but not simpler. Albert Einstein
I hope that you can open the Champaign today :-) not yet, unfortunately. I had quite a lot to do on the weekend and nearly no time for programing. I'll go on trying today...
I would like to try to port my WebDAV client to PluginOberon. Because when I tried to port it to Native (November 2001) I found that I had problems with the port of AosIO when trying to assign methods to the AosIO.Sender variable. So my qestion is whether this should work or isn't this stuff supported by the Native compiler of November 2001 ? Perhaps an upgrade to a newer Native would help ?
I am currently working at the core of the new PluginOberon, parts are AosIO, Filesystems etc., so I think when this is done, porting WebDAV shouldn't make any problems (hopefully). I would have expected, that AosIO works with NativeOberon also, since it doesn't contain any active Object keywords (like AWAIT, EXCLUSIVE etc.) What kind of problems occured when you tried to assign the Sender variable ? Cheers, Felix. -----BEGIN PGP SIGNATURE----- Version: PGP 8.0 (Build 294) Beta iQA/AwUBPb0WlkxdycIDx9VEEQLNcQCfV6Vvh6xm8wgomQ6Fy1fuGjXFq0IAn1qT 3wWElF69eNppXaSyxI2tKEhL =rmRz -----END PGP SIGNATURE------- Felix Friedrich Institut für Biomathematik und Biometrie GSF - Forschungszentrum für Umwelt und Gesundheit, GmbH Ingolstädter Landstraße 1, D-85764 Neuherberg Tel: ++49 89 3187 2436 email: friedrich@gsf.de --
--- Felix Friedrich <friedrich@gsf.de> wrote:
I am currently working at the core of the new PluginOberon, parts are AosIO, Filesystems etc., so I think when this is done, porting WebDAV shouldn't make any problems (hopefully). I would have expected, that AosIO works with NativeOberon also, since it doesn't contain any active Object keywords (like AWAIT, EXCLUSIVE etc.) What kind of problems occured when you tried to assign the Sender variable ?
Cheers, Felix.
AosIO does include the active oberon specific keyword "DELEGATE". It's easy to miss this because it has (apparently) nothing to do with multitasking. Instead it's used to allow assigning of procedure variables to methods. Specifically: TYPE Sender* = PROCEDURE {DELEGATE} (VAR buf......) In my port of AosIO I defined Sender using the normal Oberon procedure type syntax: TYPE Sender* = PROCEDURE (VAR buf.....) But in retrospect I probably should have just taken Sender and Receiver out of the port to avoid confusion. Anyway the "workaround" is to simply not use procedure variables and just use the built in type hierarchy. For example AosIO defines and object class Writer. The constructor InitWriter takes a sender variable: PROCEDURE &InitWriter(send: Sender; size: LONGINT); I ignore the sender variable and redefine this as: PROCEDURE &InitWriter(size: LONGINT); Instead of passing the sender procedure to the object at creation, I just use the sender and receiver methods defined inside the object. While assigning procedure variable to method variables might add flexibility, it seems redundant to me and a throwback to Oberon-1. Anyway it just doesn't work under Native Oberon. I tested module AosFS (which I also ported) just to make sure that my ideas worked. Here's the code: MODULE TestAosFS; IMPORT AosFS, Out, AosIO; CONST filename = "TestAosFS.Mod"; PROCEDURE Do*; VAR f: AosFS.File; r: AosFS.Reader; ch : CHAR; count : INTEGER; BEGIN count := 0; f := AosFS.Old(filename); IF f # NIL THEN AosFS.OpenReader(r, f, 0); LOOP AosIO.Read(r, ch); IF r.res # AosIO.Ok THEN EXIT END; IF ch = ";" THEN INC(count); END; END; END; Out.Int(count, 5); Out.Ln(); END Do; END TestAosFS. TestAosFS.Do All this does is counts the number of semicolons in a text file. While this is not very useful, it does show that the AosFS port does work even without using the Sender and Receiver procedure types. Regards, John M. Drake __________________________________________________ Do you Yahoo!? Yahoo! Web Hosting - establish your business online http://webhosting.yahoo.com
--- Edgar@EdgarSchwarz.de wrote:
hope to get PluginAos starting up during the weekend, IF so THEN SYSTEM.PUT(Champaign, Mouth(Felix)) (* nearly done .... ;) *) ELSE SYSTEM.PUT(Beer, Mouth(SYSTEM.VAL(Felix, picture of misery))) (* more work waiting ;( *) I hope that you can open the Champaign today :-) I would like to try to port my WebDAV client to PluginOberon. Because when I tried to port it to Native (November
Felix Friedrich <friedrich@gsf.de>: 2001) I found that I had problems with the port of AosIO when trying to assign methods to the AosIO.Sender variable. So my qestion is whether this should work or isn't this stuff supported by the Native compiler of November 2001 ? Perhaps an upgrade to a newer Native would help ?
Cheers, Edgar
Yes. It doesn't seem like the Native Oberon compiler supports assigning procedure variables to methods. (Would someone on this list who knows more about both compilers please comment?) When I was porting XML I did workarounds for this issue whenever it came up. Which module were you attempting to port? Regards, John M. Drake __________________________________________________ Do you Yahoo!? Yahoo! Web Hosting - establish your business online http://webhosting.yahoo.com
participants (3)
-
Edgar@EdgarSchwarz.de -
Felix Friedrich -
John Drake