浏览代码

* outofmemory exception bug

peter 24 年之前
父节点
当前提交
9ac5af24c1
共有 1 个文件被更改,包括 12 次插入0 次删除
  1. 12 0
      tests/tbs/tb0357.pp

+ 12 - 0
tests/tbs/tb0357.pp

@@ -0,0 +1,12 @@
+{$ifdef fpc}{$MODE OBJFPC}{$endif}
+uses sysutils;
+var
+  p:pointer;
+begin
+  try
+    getmem(p, 1000000000);
+  except
+    on eoutofmemory do writeln('out of memory!');
+  end;
+  writeln('program lasts...')
+end.