ソースを参照

String literals make fresh copies of themselves every time they are evaluated.

master
Ian Piumarta 10ヶ月前
コミット
1bf9944ff1
1個のファイルの変更6行の追加3行の削除
  1. +6
    -3
      minproto.leg

+ 6
- 3
minproto.leg ファイルの表示

@ -1,9 +1,9 @@
# minproto.leg -- minimal prototype langauge for semantic experiments
#
# last edited: 2024-07-04 10:07:00 by piumarta on zora
# last edited: 2024-07-05 17:16:16 by piumarta on zora-1034.local
%{
;
;
//#define YY_DEBUG 1
#ifndef GC
@ -3907,7 +3907,10 @@ oop eval(oop exp, oop env)
# if PRIMCLOSURE
if (Lambda == type) return newClosure(exp, env);
# endif
if (Object != type) return exp;
if (Object != type) {
if (String == type) return newStringLen(_get(exp, String,value), _get(exp, String,length));
return exp;
}
if (!opt_O) {
Object_push(trace, exp);
if (opt_d && opt_v) {

読み込み中…
キャンセル
保存