Permalink
Browse files

複数ファイル同時実行時のバグ修正

  • Loading branch information...
1 parent 573f7f1 commit f32ba094543b7b87fd88ba23112dd7ff8440b21a @sile committed May 5, 2012
Showing with 4 additions and 5 deletions.
  1. BIN plc/stdlib/io.bc
  2. +1 −2 plc/stdlib/io.lisp
  3. +3 −3 plvm/src/bin/plvm.cc
View
Binary file not shown.
View
@@ -1,10 +1,9 @@
;(begin
(begin
(define fnfn (lambda (fn)
- show-stack
20
fn))
- ;(fnfn 10)
+ (fnfn 10)
)
; (define call-with-input-file (lambda (filepath proc)
View
@@ -22,14 +22,14 @@ int main(int argc, char** argv) {
const char* filepath = argv[i];
std::cout << "# " << filepath << std::endl;
- vm::FileContent fc(filepath);
+ vm::FileContent& fc = * new vm::FileContent(filepath);
if(! fc) {
std::cerr << "ERROR: can't open file" << std::endl;
return 1;
}
- vm::ByteStream bs(fc.bytes(), fc.size());
- vm::BytecodeObject bo(bs);
+ vm::ByteStream& bs = * new vm::ByteStream(fc.bytes(), fc.size());
+ vm::BytecodeObject& bo = * new vm::BytecodeObject(bs);
if(! bo) {
std::cerr << "ERROR: can't parse " << filepath << std::endl;
return 1;

0 comments on commit f32ba09

Please sign in to comment.