Class: NqString
- Includes:
- ClassHDL::AssignDefOpertor
- Defined in:
- lib/tdl/basefunc.rb,
lib/tdl/class_hdl/hdl_redefine_opertor.rb
Constant Summary
Constants included from ClassHDL::AssignDefOpertor
ClassHDL::AssignDefOpertor::OP_SYMBOLS
Instance Method Summary collapse
Methods included from ClassHDL::AssignDefOpertor
curr_assign_block, curr_assign_block=, curr_assign_block_stack, curr_opertor_stack, included, init_op_methods, use_new_yield_opertors, use_old_cond_opertors, with_new_assign_block, with_new_opertor, with_normal_opertor, with_rollback_opertors
Methods inherited from String
#high_signal, #low_signal, #snoop, #to_inp, #to_nq
Methods included from CtrlLogic
#broaden_and_cross_clk, #cross_clock, #latency
Instance Method Details
#[](a, b = nil) ⇒ Object
519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 |
# File 'lib/tdl/class_hdl/hdl_redefine_opertor.rb', line 519 def [](a,b=nil) if a.is_a? ClassHDL::OpertorChain a.slaver = true arel = a.instance(:slaver) else arel = a end if b.is_a? ClassHDL::OpertorChain b.slaver = true brel = b.instance(:slaver) else brel = b end unless b if a.is_a? Range af = a.first al = a.last return "#{self}[#{af}:#{al}]".to_nq end return "#{self}[#{arel}]".to_nq else return "#{self}[#{arel}:#{brel}]".to_nq end end |
#clog2 ⇒ Object
89 90 91 |
# File 'lib/tdl/basefunc.rb', line 89 def clog2 return "$clog2(#{self})" end |