diff options
author | Dodji Seketeli <dodji@redhat.com> | 2016-11-10 09:52:42 +0100 |
---|---|---|
committer | Dodji Seketeli <dodji@redhat.com> | 2016-11-10 14:09:50 +0100 |
commit | b96ecbc065d84c1b98394f7680c0a4e8b2e3cf09 (patch) | |
tree | 7688f8540a28d901976ce90b8bbe306451c509cc | |
parent | Apply harmless and harmful filters in one pass (diff) | |
download | libabigail-b96ecbc065d84c1b98394f7680c0a4e8b2e3cf09.tar.gz libabigail-b96ecbc065d84c1b98394f7680c0a4e8b2e3cf09.tar.bz2 libabigail-b96ecbc065d84c1b98394f7680c0a4e8b2e3cf09.tar.xz |
Rename config::property_vector into config::properties_type
This renaming makes the code looks more consistent.
* include/abg-ini.h (config::properties_type): Rename the typedef
config::property_vector into this.
(config::section::{section, get_properties, set_properties}):
Adjust.
* src/abg-ini.cc (config::section::priv::properties_): Adjust the
name of its type.
(config::section::{section, get_properties, set_properties,
find_property}): Adjust.
(write_section): Adjust.
* src/abg-suppression.cc (read_function_suppression): Adjust.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
-rw-r--r-- | include/abg-ini.h | 8 | ||||
-rw-r--r-- | src/abg-ini.cc | 14 | ||||
-rw-r--r-- | src/abg-suppression.cc | 2 |
3 files changed, 12 insertions, 12 deletions
diff --git a/include/abg-ini.h b/include/abg-ini.h index 6e0ed6c6..e8ecb91d 100644 --- a/include/abg-ini.h +++ b/include/abg-ini.h | |||
@@ -357,7 +357,7 @@ public: | |||
357 | typedef vector<section_sptr> sections_type; | 357 | typedef vector<section_sptr> sections_type; |
358 | 358 | ||
359 | /// A convenience typedef for a vector of @ref property_sptr | 359 | /// A convenience typedef for a vector of @ref property_sptr |
360 | typedef vector<property_sptr> property_vector; | 360 | typedef vector<property_sptr> properties_type; |
361 | 361 | ||
362 | private: | 362 | private: |
363 | priv_sptr priv_; | 363 | priv_sptr priv_; |
@@ -398,16 +398,16 @@ class config::section | |||
398 | public: | 398 | public: |
399 | section(const string& name); | 399 | section(const string& name); |
400 | 400 | ||
401 | section(const string& name, const property_vector& properties); | 401 | section(const string& name, const properties_type& properties); |
402 | 402 | ||
403 | const string& | 403 | const string& |
404 | get_name() const; | 404 | get_name() const; |
405 | 405 | ||
406 | const property_vector& | 406 | const properties_type& |
407 | get_properties() const; | 407 | get_properties() const; |
408 | 408 | ||
409 | void | 409 | void |
410 | set_properties(const property_vector& properties); | 410 | set_properties(const properties_type& properties); |
411 | 411 | ||
412 | void | 412 | void |
413 | add_property(const property_sptr prop); | 413 | add_property(const property_sptr prop); |
diff --git a/src/abg-ini.cc b/src/abg-ini.cc index e1848762..2cae7890 100644 --- a/src/abg-ini.cc +++ b/src/abg-ini.cc | |||
@@ -757,7 +757,7 @@ is_tuple_property(const property_sptr p) | |||
757 | class config::section::priv | 757 | class config::section::priv |
758 | { | 758 | { |
759 | string name_; | 759 | string name_; |
760 | property_vector properties_; | 760 | properties_type properties_; |
761 | 761 | ||
762 | // Forbid this; | 762 | // Forbid this; |
763 | priv(); | 763 | priv(); |
@@ -785,7 +785,7 @@ config::section::section(const string& name) | |||
785 | /// | 785 | /// |
786 | /// @param properties the properties of the section. | 786 | /// @param properties the properties of the section. |
787 | config::section::section(const string& name, | 787 | config::section::section(const string& name, |
788 | const property_vector& properties) | 788 | const properties_type& properties) |
789 | : priv_(new priv(name)) | 789 | : priv_(new priv(name)) |
790 | {set_properties(properties);} | 790 | {set_properties(properties);} |
791 | 791 | ||
@@ -799,7 +799,7 @@ config::section::get_name() const | |||
799 | /// Get the properties of the section. | 799 | /// Get the properties of the section. |
800 | /// | 800 | /// |
801 | /// @return a vector of the properties of the section. | 801 | /// @return a vector of the properties of the section. |
802 | const config::property_vector& | 802 | const config::properties_type& |
803 | config::section::get_properties() const | 803 | config::section::get_properties() const |
804 | {return priv_->properties_;} | 804 | {return priv_->properties_;} |
805 | 805 | ||
@@ -807,7 +807,7 @@ config::section::get_properties() const | |||
807 | /// | 807 | /// |
808 | /// @param properties the new properties to set. | 808 | /// @param properties the new properties to set. |
809 | void | 809 | void |
810 | config::section::set_properties(const property_vector& properties) | 810 | config::section::set_properties(const properties_type& properties) |
811 | {priv_->properties_ = properties;} | 811 | {priv_->properties_ = properties;} |
812 | 812 | ||
813 | /// Add one property to this section. | 813 | /// Add one property to this section. |
@@ -828,7 +828,7 @@ config::section::add_property(const property_sptr prop) | |||
828 | property_sptr | 828 | property_sptr |
829 | config::section::find_property(const string& prop_name) const | 829 | config::section::find_property(const string& prop_name) const |
830 | { | 830 | { |
831 | for (property_vector::const_iterator i = get_properties().begin(); | 831 | for (properties_type::const_iterator i = get_properties().begin(); |
832 | i != get_properties().end(); | 832 | i != get_properties().end(); |
833 | ++i) | 833 | ++i) |
834 | if ((*i)->get_name() == prop_name) | 834 | if ((*i)->get_name() == prop_name) |
@@ -1582,7 +1582,7 @@ public: | |||
1582 | if (!skip_white_spaces_or_comments()) | 1582 | if (!skip_white_spaces_or_comments()) |
1583 | return nil; | 1583 | return nil; |
1584 | 1584 | ||
1585 | config::property_vector properties; | 1585 | config::properties_type properties; |
1586 | while (property_sptr prop = read_property()) | 1586 | while (property_sptr prop = read_property()) |
1587 | { | 1587 | { |
1588 | properties.push_back(prop); | 1588 | properties.push_back(prop); |
@@ -1827,7 +1827,7 @@ write_section(const config::section& section, | |||
1827 | std::ostream& out) | 1827 | std::ostream& out) |
1828 | { | 1828 | { |
1829 | out << "[" << section.get_name() << "]\n"; | 1829 | out << "[" << section.get_name() << "]\n"; |
1830 | for (config::property_vector::const_iterator i = | 1830 | for (config::properties_type::const_iterator i = |
1831 | section.get_properties().begin(); | 1831 | section.get_properties().begin(); |
1832 | i != section.get_properties().end(); | 1832 | i != section.get_properties().end(); |
1833 | ++i) | 1833 | ++i) |
diff --git a/src/abg-suppression.cc b/src/abg-suppression.cc index e9bee010..c25c38e1 100644 --- a/src/abg-suppression.cc +++ b/src/abg-suppression.cc | |||
@@ -3021,7 +3021,7 @@ read_function_suppression(const ini::config::section& section) | |||
3021 | 3021 | ||
3022 | function_suppression::parameter_spec_sptr parm; | 3022 | function_suppression::parameter_spec_sptr parm; |
3023 | function_suppression::parameter_specs_type parms; | 3023 | function_suppression::parameter_specs_type parms; |
3024 | for (ini::config::property_vector::const_iterator p = | 3024 | for (ini::config::properties_type::const_iterator p = |
3025 | section.get_properties().begin(); | 3025 | section.get_properties().begin(); |
3026 | p != section.get_properties().end(); | 3026 | p != section.get_properties().end(); |
3027 | ++p) | 3027 | ++p) |