diff --git a/lib/rpl/core/program.rb b/lib/rpl/core/program.rb index f7d14a8..3f8f7f0 100644 --- a/lib/rpl/core/program.rb +++ b/lib/rpl/core/program.rb @@ -12,7 +12,11 @@ module RplLang proc do args = stack_extract( [:any] ) - run( args[0][:value].to_s ) + if %i[list string numeric boolean].include?( args[0][:type] ) + @stack << args[0] # these types evaluate to themselves + else + run( args[0][:value].to_s ) + end end ) end end