Class: Rlang::Parser::MArg
- Includes:
- Log
- Defined in:
- lib/rlang/parser/marg.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#wtype ⇒ Object
Returns the value of attribute wtype.
Instance Method Summary collapse
- #_self_? ⇒ Boolean
-
#initialize(name, wtype = WType::DEFAULT) ⇒ MArg
constructor
A new instance of MArg.
- #wasm_name ⇒ Object
- #wasm_type ⇒ Object
Methods included from Log
included, logger, #logger, logger=
Constructor Details
#initialize(name, wtype = WType::DEFAULT) ⇒ MArg
Returns a new instance of MArg.
16 17 18 19 20 |
# File 'lib/rlang/parser/marg.rb', line 16 def initialize(name, wtype=WType::DEFAULT) @name = name @wtype = wtype logger.debug "Method argument #{name} created" end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
13 14 15 |
# File 'lib/rlang/parser/marg.rb', line 13 def name @name end |
#wtype ⇒ Object
Returns the value of attribute wtype.
14 15 16 |
# File 'lib/rlang/parser/marg.rb', line 14 def wtype @wtype end |
Instance Method Details
#_self_? ⇒ Boolean
22 23 24 |
# File 'lib/rlang/parser/marg.rb', line 22 def _self_? @name == :_self_ end |
#wasm_name ⇒ Object
26 27 28 |
# File 'lib/rlang/parser/marg.rb', line 26 def wasm_name "$#{@name}" end |
#wasm_type ⇒ Object
30 31 32 |
# File 'lib/rlang/parser/marg.rb', line 30 def wasm_type @wtype.wasm_type end |