ECF parsing issues
Sitsofe Wheeler <sitsofe-/[email protected]> Sat, 1 Aug 2009 13:08:54 +0100
| Newsgroups | gmane.comp.lang.eiffel.gobo.general |
|---|---|
| Message-ID | <[email protected]> |
Hi,
I've been trying to use Gobo's ECF parser but I'm find the results a bit
unpredictable and I'm wondering if this is to be expected.
When using the 6.3 ISE compiler and its distribution of Gobo, I have
code that is doing roughly the following:
create l_ecf_error_handler.make_standard
create l_ecf_parser.make ( l_ecf_error_handler )
create a_file.make ("test.ecf")
a_file.open_read
l_ecf_parser.parse_file ( a_file )
a_system := l_ecf_parser.last_system
a_system.activate_processors
a_system.preparse_local
a_class := a_system.class_by_name ( "TEST" )
a_class.process ( a_system.interface_checker )
a_class.process ( a_system.implementation_checker )
io.put_string ( a_class.out )
However when it runs always says that errors were found:
ET_CLASS [0x7F9EBD922368]
<snip>
has_deferred_features: BOOLEAN = False
ancestors_built: BOOLEAN = True
has_ancestors_error: BOOLEAN = True
redeclared_signatures_checked: BOOLEAN = False
features_flattened: BOOLEAN = True
has_flattening_error: BOOLEAN = True
interface_checked: BOOLEAN = True
has_interface_error: BOOLEAN = True
implementation_checked: BOOLEAN = True
has_implementation_error: BOOLEAN = True
I've written a small program that compares the results of parsing XACE
and ECF files ( http://sucs.org/~sits/test/ecf_testcase.zip ) and it has
the following results:
ET_CLASS (parsed by ecf)
ancestors_built: True
has_ancestors_error: True
has_features_flattened: True
has_flattening_error: True
interface_checked: True
has_interface_error: True
implementation_checked: True
has_implementation_error: True
ET_CLASS (parsed by xace(ise))
ancestors_built: True
has_ancestors_error: False
has_features_flattened: True
has_flattening_error: False
interface_checked: True
has_interface_error: False
implementation_checked: True
has_implementation_error: True
ET_CLASS (parsed by xace(ge))
ancestors_built: True
has_ancestors_error: False
has_features_flattened: True
has_flattening_error: False
interface_checked: True
has_interface_error: False
implementation_checked: True
has_implementation_error: False
(Gobo can pick to use different "base" libraries when parsing XACE files
and this is often done by looking at the GOBO_EIFFEL environment
variable. One other thing I noticed were lots of
Catcall detected in {PROCEDURE}.call for arg#1: expected TUPLE [ET_ECF_CLUSTER] but got TUPLE [ET_CLUSTER]
messages just after startup when using the ISE compiler with debugging
on and it ran very slowly)
I suspect that the issue is that any time an ECF file has to be parsed
the result isn't great. Is there a magic ECF -> XACE converter or is
this just the way things are because there are multiple standards?
I guess a related question could be - is it possible to programmaticly
tell Gobo where to parse all the typical libraries and just parse files
without restarting?
--
Sitsofe | http://sucs.org/~sits/
------------------------------------
To Post a message, send it to: [email protected]
To Unsubscribe, send a blank message to: [email protected]! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/gobo-eiffel/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/gobo-eiffel/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:[email protected]
mailto:[email protected]
<*> To unsubscribe from this group, send an email to:
[email protected]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/