Class: Temple::StaticAnalyzer::ShorthandSyntaxChecker
- Defined in:
- lib/temple/static_analyzer.rb
Instance Attribute Summary collapse
-
#shorthand ⇒ Object
readonly
Returns the value of attribute shorthand.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ ShorthandSyntaxChecker
constructor
A new instance of ShorthandSyntaxChecker.
Constructor Details
#initialize ⇒ ShorthandSyntaxChecker
Returns a new instance of ShorthandSyntaxChecker.
128 129 130 131 |
# File 'lib/temple/static_analyzer.rb', line 128 def initialize(*) super @shorthand = nil end |
Instance Attribute Details
#shorthand ⇒ Object (readonly)
Returns the value of attribute shorthand.
126 127 128 |
# File 'lib/temple/static_analyzer.rb', line 126 def shorthand @shorthand end |
Class Method Details
.shorthand?(code) ⇒ Boolean
119 120 121 122 123 |
# File 'lib/temple/static_analyzer.rb', line 119 def shorthand?(code) instance = new(code) instance.parse instance.shorthand end |