From 698a6743623c2ee94401679987f7fc59779d9359 Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Tue, 11 Jul 2017 17:10:09 +0200 Subject: [PATCH 1/1] code simplification: nobody use that extensibility feature anymore --- src/surf/xml/platf.hpp | 2 +- src/surf/xml/surfxml_sax_cb.cpp | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/surf/xml/platf.hpp b/src/surf/xml/platf.hpp index 010e6f0504..3d29ba49af 100644 --- a/src/surf/xml/platf.hpp +++ b/src/surf/xml/platf.hpp @@ -31,7 +31,7 @@ XBT_PUBLIC(double) surf_parse_get_size(const char *string, const char *entity_ki XBT_PUBLIC(double) surf_parse_get_bandwidth(const char *string, const char *entity_kind, const char *name); XBT_PUBLIC(double) surf_parse_get_speed(const char *string, const char *entity_kind, const char *name); -XBT_PUBLIC_DATA(int_f_void_t) surf_parse; /* Entry-point to the parser. Set this to your function. */ +XBT_PUBLIC(int) surf_parse(); /* Entry-point to the parser */ SG_END_DECL() diff --git a/src/surf/xml/surfxml_sax_cb.cpp b/src/surf/xml/surfxml_sax_cb.cpp index e304c1ffb5..b82863ae0d 100644 --- a/src/surf/xml/surfxml_sax_cb.cpp +++ b/src/surf/xml/surfxml_sax_cb.cpp @@ -1138,11 +1138,10 @@ void surf_parse_close() } } -/* Call the lexer to parse the currently opened file. This pointer to function enables bypassing of the parser */ -static int _surf_parse() { +/* Call the lexer to parse the currently opened file */ +int surf_parse() +{ return surf_parse_lex(); } -int_f_void_t surf_parse = &_surf_parse; - SG_END_DECL() -- 2.20.1