mirror of https://github.com/KLayout/klayout.git
Fixed code sample
This commit is contained in:
parent
be19165140
commit
2831dd7f26
|
|
@ -147,7 +147,10 @@ Class<Interpreter> decl_Macro ("tl", "Interpreter",
|
|||
"pya = RBA::Interpreter::python_interpreter\n"
|
||||
"out_param = RBA::Value::new(17)\n"
|
||||
"pya.define_variable(\"out_param\", out_param)\n"
|
||||
"pya.eval_string(\"print(\\\"This is Python now!\\\")\\nout_param.value = out_param.value + 25\")\n"
|
||||
"pya.eval_string(<<END)\n"
|
||||
"print(\"This is Python now!\")\n"
|
||||
"out_param.value = out_param.value + 25\n"
|
||||
"END\n"
|
||||
"puts out_param.value # gives '42'"
|
||||
"@/code\n"
|
||||
"\n"
|
||||
|
|
|
|||
Loading…
Reference in New Issue