Module: Rucc::Type::Check
- Included in:
- Rucc::Type
- Defined in:
- lib/rucc/type/check.rb
Instance Method Summary collapse
- #is_arithtype(ty) ⇒ Boolean
- #is_flotype(ty) ⇒ Boolean
- #is_inttype(ty) ⇒ Boolean
- #is_string(ty) ⇒ Boolean
Instance Method Details
#is_arithtype(ty) ⇒ Boolean
6 7 8 |
# File 'lib/rucc/type/check.rb', line 6 def is_arithtype(ty) is_inttype(ty) || is_flotype(ty) end |
#is_flotype(ty) ⇒ Boolean
23 24 25 26 27 28 29 30 |
# File 'lib/rucc/type/check.rb', line 23 def is_flotype(ty) case ty.kind when Kind::FLOAT, Kind::DOUBLE, Kind::LDOUBLE true else false end end |