eval( 可执行字符串)
Code a = 1 b="true" c="false" str =" if a==1 then puts '输出:#{b}' else puts '输出:#{c}' end " eval(str) 输出结果为:"true"
输出结果为:"true"
Powered by: 博客园 Copyright © 2024 Watir Powered by .NET 8.0 on Kubernetes