Class: AdLint::Cc1::ScanfFormat
- Inherits:
-
Object
- Object
- AdLint::Cc1::ScanfFormat
- Defined in:
- lib/adlint/cc1/format.rb
Instance Attribute Summary collapse
-
#directives ⇒ Object
readonly
Returns the value of attribute directives.
-
#extra_arguments ⇒ Object
readonly
Returns the value of attribute extra_arguments.
-
#location ⇒ Object
readonly
Returns the value of attribute location.
Instance Method Summary collapse
- #conversion_specifiers ⇒ Object
-
#initialize(fmt_str, loc, trailing_args, env) ⇒ ScanfFormat
constructor
A new instance of ScanfFormat.
Constructor Details
#initialize(fmt_str, loc, trailing_args, env) ⇒ ScanfFormat
Returns a new instance of ScanfFormat.
1710 1711 1712 1713 1714 |
# File 'lib/adlint/cc1/format.rb', line 1710 def initialize(fmt_str, loc, trailing_args, env) @location = loc @directives = create_directives(fmt_str, trailing_args, env) @extra_arguments = trailing_args end |
Instance Attribute Details
#directives ⇒ Object (readonly)
Returns the value of attribute directives.
1717 1718 1719 |
# File 'lib/adlint/cc1/format.rb', line 1717 def directives @directives end |
#extra_arguments ⇒ Object (readonly)
Returns the value of attribute extra_arguments.
1718 1719 1720 |
# File 'lib/adlint/cc1/format.rb', line 1718 def extra_arguments @extra_arguments end |
#location ⇒ Object (readonly)
Returns the value of attribute location.
1716 1717 1718 |
# File 'lib/adlint/cc1/format.rb', line 1716 def location @location end |
Instance Method Details
#conversion_specifiers ⇒ Object
1720 1721 1722 |
# File 'lib/adlint/cc1/format.rb', line 1720 def conversion_specifiers @directives.select { |dire| dire.conversion_specifier? } end |